Opened 8 years ago

Closed 8 years ago

#1640 closed defect (fixed)

incomplete pc file for botan and wrong filename for botan-config

Reported by: jreed Owned by: jelte
Priority: low Milestone: Sprint-20120320
Component: build system Version:
Keywords: Cc:
CVSS Scoring: Parent Tickets:
Sensitive: no Defect Severity: N/A
Sub-Project: Core Feature Depending on Ticket:
Estimated Difficulty: 4 Add Hours to Ticket: 0
Total Hours: 0 Internal?: no

Description

My initial configure failure was from:

/usr/local/lib/libbotan-1.10.so.0.0: undefined reference to `pthread_mutex_unlock'
/usr/local/lib/libbotan-1.10.so.0.0: undefined reference to `pthread_mutex_destroy'
/usr/local/lib/libbotan-1.10.so.0.0: undefined reference to `pthread_mutex_lock'
/usr/local/lib/libbotan-1.10.so.0.0: undefined reference to `pthread_mutex_init'

The installed tools:

$ botan-config-1.10 --libs   
-L/usr/local/lib -lbotan-1.10 -lbz2 -lcrypto -lgmp -lpthread -lz

$ pkg-config --libs botan-1.10   
-L/usr/local/lib -lbotan-1.10

As you can see the filename for botan-config script is versioned and the PC data is incomplete.

If --with-botan is set to a path it will run botan-config, but this one is versioned as part of file name. If with-botan is not set or is yes it will use pkg-config and as you can see above that is incomplete.

I will make a branch for configure.ac hack -- but only helps if --with-botan is used with the path.

Subtickets

Attachments (3)

botan-config.patch (4.0 KB) - added by jelte 8 years ago.
config.log (48.7 KB) - added by jaspain 8 years ago.
Config log after applying botan patch.
botan_config_2.patch (4.6 KB) - added by jelte 8 years ago.

Download all attachments as: .zip

Change History (37)

comment:1 Changed 8 years ago by jreed

commit ec46569c91883d85a961cd235650e00dae2ccceb

[trac1640] try different versioned botan-config files
This repeats same functionality twice. This should be cleaned up.

comment:2 Changed 8 years ago by jelte

  • Milestone changed from New Tasks to Next-Sprint-Proposed

comment:3 Changed 8 years ago by jelte

  • Estimated Difficulty changed from 0 to 4

comment:4 Changed 8 years ago by jelte

  • Milestone changed from Next-Sprint-Proposed to Sprint-20120221

comment:5 Changed 8 years ago by jaspain

I can successfully build bind10-devel-20120119 on Ubuntu Oneiric with botan 1.10.1 if the pkg-config package is installed. This makes bind10 configure refer to the file /usr/lib/pkgconfig/botan-1.10.pc, where it finds accurate include and library information for botan 1.10. Otherwise configure tries to use /usr/bin/botan-config for this information. Unfortunately in botan 1.10.1, this file has been renamed to /usr/bin/botan-config-1.10, and configure can't find it. Also in botan 1.10.1, /usr/include/botan has been changed to /usr/include/botan-1.10/botan, which creates yet a further challenge for configure. For additional detail, see https://lists.isc.org/pipermail/bind10-users/2012-February/000195.html. Thanks. Jeff.

comment:6 Changed 8 years ago by jaspain

I did some additional testing on Ubuntu Oneiric of bind10 configure in relation to botan. Starting with botan 1.10.1 built from source and installed, and the package pkg-config removed, I got the following excerpted output from bind10 configure:
checking for pkg-config... no
checking for botan-config... no
./configure: line 15911: --libs: command not found
./configure: line 15912: --cflags: command not found
checking botan/botan.h usability... no
checking botan/botan.h presence... no
checking for botan/botan.h... no
configure: error: Missing required header files.

Now to simulate bind10 configure being able to find botan-config-<version>, I executed:
ln /usr/bin/botan-config-1.10 /usr/bin/botan-config

Now bind10 configure behaved as follows:
checking for pkg-config... no
checking for botan-config... /usr/bin/botan-config
checking botan/botan.h usability... no
checking botan/botan.h presence... no
checking for botan/botan.h... no
configure: error: Missing required header files.

The output of botan-config is as follows:
root@oneiric:~/bind10-devel-20120119# botan-config --prefix
/usr
root@oneiric:~/bind10-devel-20120119# botan-config --cflags
root@oneiric:~/bind10-devel-20120119# botan-config --libs
-lbotan-1.10 -lbz2 -lcrypto -ldl -lgmp -lpthread -lrt -lz

Note that 'botan-config --cflags' returns null. Looking at botan-config itself, the relevant code is:
--cflags)

if [ $prefix != "/usr" -a $prefix != "/usr/local" ]
then

echo -I$prefix/$includedir

fi
;;

I'm not sure why the botan people don't want to return any cflags when --prefix is /usr or /usr/local. Perhaps -I/usr/include/botan-1.10 or -I/usr/local/include/botan-1.10 would be considered default paths by g++? Anyway, I commented out the conditional logic in botan-config for --cflags with the following result:
root@oneiric:~/bind10-devel-20120119# botan-config --cflags
-I/usr/include/botan-1.10

Now bind10 configure succeeds with botan:
checking for pkg-config... no
checking for botan-config... /usr/bin/botan-config
checking botan/botan.h usability... yes
checking botan/botan.h presence... yes
checking for botan/botan.h... yes
checking for Botan library... yes

But a little later:
checking boost/function.hpp usability... yes
checking boost/function.hpp presence... yes
checking for boost/function.hpp... yes
checking for pthread_create in -lpthread... yes
checking for pkg-config... no
configure: error: Please install pkg-config

The easiest solution to this problem, since pkg-config seems to be required anyway, might be to cause bind10 configure to error out when it checks for and doesn't find pkg-config just prior to checking for botan.

Otherwise if it is desirable to detect botan versions greater than 1.8 without pkg-config, then the following will be required:

  1. Check for and be able to use $prefix/bin/botan-config-(.*) as well as just $prefix/bin/botan-config. Here (.*) is a regular expression intended to capture the botan version number, hereinafter referred to as $botanVer.
  2. If 'botan-config-$botanVer --cflags' returns null, then manually look for the presence of the directory $prefix/include/botan-$botanVer. This directory should contain a botan directory which in turn should contain all the botan *.h files.

Hopefully this will be easy to implement. Note that Ubuntu Precise Pangolin (12.04LTS) due for release at the end of April will provide botan 1.10.0 as a standard package. Thanks. Jeff.

comment:7 Changed 8 years ago by jelte

apart from doing the pkgconfig check earlier in configure, would it perhaps be a good idea to stop 'guessing' if that config script exist and what name it has, and replace '--with-botan' by '--with-botan-config=' to which the argument would be the actual botan-config-X.XX script?

comment:8 Changed 8 years ago by jaspain

I’m in favor of adding the option --with-botan-config=<full path name of botan config script> and removing the current --with-botan option, which doesn’t work anyway with botan 1.10.

If your ultimate goal is to continue having the bind10 configure script be dependent on pkg-config, then I'm in favor of simply checking for pkg-config prior to botan processing and requiring it to be present. Then you can remove the existing botan guessing logic, which is not used when pkg-config is available. The --with-botan-config option would be there as a last resort in case, for example, the botan developers decided to stop supporting pkg-config.

On the other hand, if your goal is to remove all dependencies on pkg-config, then I would use the botan guessing logic suggested above (comment 6). The --with-botan-config option would be there just in case the botan developers change their botan-config script naming convention yet again.

comment:9 Changed 8 years ago by jelte

Actually, while I have no problem requiring pkg-config in itself, IIRC the reason it does both for botan is that not all installations get a botan pkg-config .pc file, and we need to try such files then anyway.

Hmm, come to think of it, in such cases we would still need to guess the -config scripts name. Then again, if we say 'either have pkgconfig and the needed .pc files, or specific -config script' could be enough. There are always ways to make a system so that automatic detection fails :p

comment:10 Changed 8 years ago by jinmei

  • Owner changed from UnAssigned to jelte
  • Status changed from new to assigned

what's the current status of this ticket? tentatively giving it
to jelte...

comment:11 Changed 8 years ago by jelte

  • Owner changed from jelte to UnAssigned
  • Status changed from assigned to reviewing

The ticket was mostly waiting on someone to make a final decision on what to do with this :)

So I decided to replace --with-botan with --with-botan-config, which takes the full path to the config script (no ${val}/bin/scriptname guessing if this value is provided). In case it is not provided, and pkgconfig does not appear to know about botan, it will loop over a number of possible botan-config scripts (from botan-config-1.10 down to botan-config-1.8 and finally plainly botan-config).

I also expanded the compile/link test error with a message about if it fails, but botan is installed, it may be the case that there are missing dependencies and installing libbz2 and libgmp might help (which would 'solve' #1201, as far as i think we should solve it).

WARNING FOR REVIEWER: BRANCH IS CALLED trac1640_2

So this is ready for review. I had not realized Jeremy put in a branch yet, and since mine is based on a newer branch of master, I decided not to expand on his branch but create a new one called trac1640_2

WARNING FOR REVIEWER: BRANCH IS CALLED trac1640_2

Suggested changelog:

[build]* jelte
The configure option for botan (--with-botan=PATH) is replaced by --with-botan-config=PATH, which takes a full path to a botan-config script, instead of the botan 'install' directory. Also, if not provided, and pkg-config does not know about botan, it tries several possible names instead of just botan-config.

comment:12 Changed 8 years ago by kevin_tes

  • Owner changed from UnAssigned to kevin_tes

comment:13 Changed 8 years ago by kevin_tes

  • Owner changed from kevin_tes to jelte

There is another situation in my Ubuntu:

@ubuntu:~$ botan-config --libs
-lbotan
@ubuntu:~$ pkg-config --libs botan-1.8
-lbotan
You can see the PC data is incomplete and the filename for botan-config script 
is not versioned, but, it can "configure" and "make" bind successfully.
So, I'm not sure whether the fix will solve the problem.
The following is my botan-1.8.pc:
prefix=/usr
exec_prefix=${prefix}
libdir=${prefix}/lib
includedir=${prefix}/include
 
Name: Botan
Description: Multi-platform C++ crypto library
Version: 1.8.13
Libs: -L${libdir} -lbotan
Libs.private:  -L${libdir} -lbz2 -lcrypto -lgmp -lpthread -lz
Cflags: -I${includedir}

BTW, sorry for the late comments.

Last edited 8 years ago by kevin_tes (previous) (diff)

comment:14 Changed 8 years ago by jaspain

As a point of information, the botan developers changed their file naming convention between botan 1.8 and botan 1.10. In botan 1.10, the libraries have a version number appended. In 1.8 they do not. I don't have botan-config installed, but below is the result of pkg-config and the contents of botan-1.10.pc:

root@ns0:~# pkg-config --libs botan-1.10
-lbotan-1.10  
root@ns0:~# find / -name botan-config
root@ns0:~# find / -name botan-1.10.pc
/usr/lib/pkgconfig/botan-1.10.pc
/root/bind10_install/Botan-1.10.1/build/botan-1.10.pc
root@ns0:~# cat /usr/lib/pkgconfig/botan-1.10.pc 
prefix=/usr
exec_prefix=${prefix}
libdir=${prefix}/lib
includedir=${prefix}/include/botan-1.10

Name: Botan
Description: Multi-platform C++ crypto library
Version: 1.10.1

Libs: -L${libdir} -lbotan-1.10
Libs.private: -ldl -lpthread -lrt
Cflags: -I${includedir}

Thus bind10 configure needs to be able to deal with both unversioned and versioned botan libaray names. Previously, e.g. bind10-devel-20120119, bind10 configure would error out with botan 1.10 installed due to the versioned library names. The unversioned library names with botan 1.8 were correctly interpreted by bind10 configure, and so bind10 could be successfully built.

comment:15 Changed 8 years ago by jelte

  • Owner changed from jelte to kevin_tes

I'm not sure what the problem is now; does this branch not work? (it should catch everything in these two comments I believe)

This branch tries pkg-config files 'botan-1.10, botan-1.9, botan-1.8' in that order, and if not found, tries the scripts 'botan-config-1.10, botan-config-1.9, botan-config-1.8, botan-config', so even if botan-config-1.8 does not exist anywhere, it is just one check, and it will then use botan-config (and if THAT fails, you can now specify the config file by hand).

comment:16 Changed 8 years ago by jelte

(fyi, trying botan-config-1.8 might be unnecessary, I added it just in case some packager tries to backport the versioned-config 'feature' somewhere)

comment:17 follow-up: Changed 8 years ago by jaspain

From your description, it sounds as if this will work. I don't believe I have access to the code until published for anonymous access in git, but will be happy to test it then.

comment:18 Changed 8 years ago by jreed

On same OpenBSD system I used for the initial bug report for this ticket, I now get when setting no related ./configure arguments:

checking Checking botan version with pkg-config botan-1.10... found
checking botan/botan.h usability... yes
checking botan/botan.h presence... yes
checking for botan/botan.h... yes
checking for Botan library... no
configure: error: Needs Botan library 1.8 or higher. On some systems,
         the botan package has a few missing dependencies (libbz2 and
         libgmp), if libbotan has been installed and you see this error,
         try upgrading to a higher version of botan or installing libbz2
         and libgmp.

Why these three similar steps repeated:?

configure:20918: checking botan/botan.h usability
configure:20918: g++ -c -g -O2 -I/usr/local/include/botan-1.10  -DOS_BSD conftes
t.cpp >&5
configure:20918: $? = 0
configure:20918: result: yes
configure:20918: checking botan/botan.h presence
configure:20918: g++ -E -I/usr/local/include/botan-1.10  -DOS_BSD conftest.cpp
configure:20918: $? = 0
configure:20918: result: yes
configure:20918: checking for botan/botan.h
configure:20918: result: yes

The failure (as shown at start of this ticket) is:

configure:20946: g++ -o conftest -g -O2 -I/usr/local/include/botan-1.10  -DOS_BSD  -R/usr/local/lib    conftest.cpp  -L/usr/local/lib -lbotan-1.10  -lbotan-1.10 >&5
/usr/local/lib/libbz2.so.10.4: warning: strcat() is almost always misused, please use strlcat()
/usr/local/lib/libgmp.so.9.0: warning: strcpy() is almost always misused, please use strlcpy()
/usr/local/lib/libgmp.so.9.0: warning: vsprintf() is often misused, please use vsnprintf()
/usr/local/lib/libbotan-1.10.so.0.0: undefined reference to `pthread_mutex_unlock'
/usr/local/lib/libbotan-1.10.so.0.0: undefined reference to `pthread_mutex_destroy'
/usr/local/lib/libbotan-1.10.so.0.0: undefined reference to `pthread_mutex_lock'
/usr/local/lib/libbotan-1.10.so.0.0: undefined reference to `pthread_mutex_init'
collect2: ld returned 1 exit status
configure:20946: $? = 1

Probably should not default to checking pkg-config first (it is incomplete). Do we have systems or versions of botan where the pkgconfig is preferred? (I think we did and so it is not easy to solve.)

comment:19 Changed 8 years ago by jreed

The lines

        if test -d "${botan_config}" ; then
            AC_MSG_ERROR([${botan_config} is a directory])
        else

don't work as expected. It does not indicate it is botan related. Maybe say:

            AC_MSG_ERROR([--with-botan-config should point to a botan-config program and not a directory (${botan_config})])

comment:20 Changed 8 years ago by jreed

I forgot to mention that setting --with-botan-config=/usr/local/bin/botan-config-1.10 works for me. But I am hoping that I don't have to do that.

comment:21 Changed 8 years ago by jelte

  • Owner changed from kevin_tes to jreed

Oh ok apparently I misunderstood part of the problem, i thought it was about the -config script lying, which we have also seen... (but I think that has since been fixed by the maintainer, and that system did not have a .pc file for botan)

pkg-config was preferred since that is the official successor intended to solve this config script crap :p

Of course if it is lying, it is a bug that should be filed with the maintainer, but still something we need to work around. Not sure whether we should prefer the -config approach or just scratch the entire use of pkgconfig. Has anyone seen a system where the .pc file is installed but the config script is not?

Reversing the checks for now (first scripts, then pkgconfig).

Also copied your suggested error message.

BTW, the triple repeat there is some autoconf magic done by AC_CHECK_HEADERS I think.

Reassigning ticket to jeremy with the request to pull update and try again :)

BTW, if this fixes it for some, but then breaks it again on other systems, there is yet another approach we can take, and that is to try every possible combination, and actually do a compile test for each, instead of just assuming we get correct data. And if THAT still fails we could then also include switching some well-known flags on an off. But I really don't want to go there :)

Changed 8 years ago by jelte

comment:22 in reply to: ↑ 17 ; follow-up: Changed 8 years ago by jelte

Replying to jaspain:

From your description, it sounds as if this will work. I don't believe I have access to the code until published for anonymous access in git, but will be happy to test it then.

I'm not sure what the status of anonymous git access is atm, but I've attached a patch of the current branch that should apply cleanly to the latest release (and works with current master as well, though probably with some offsets)

comment:23 Changed 8 years ago by jreed

b78153aae59d37e4c2807c4d19c4b548be13adc0 worked for me on OpenBSD. Detected and no configure switch used. Thanks.

comment:24 Changed 8 years ago by jreed

  • Owner changed from jreed to UnAssigned

comment:25 in reply to: ↑ 22 Changed 8 years ago by jaspain

Replying to jelte:

I'm not sure what the status of anonymous git access is atm, but I've attached a patch of the current branch that should apply cleanly to the latest release (and works with current master as well, though probably with some offsets)

I applied the patch and configure fails as follows:

configure: WARNING: Missing setproctitle python module.
Use --disable-setproctitle-check to skip this check.
In this case we will continue, but naming of python processes will not work.
configure: error: Missing required header files.

I will attach config.log. Please let me know if you would like additional information.

Changed 8 years ago by jaspain

Config log after applying botan patch.

comment:26 Changed 8 years ago by jelte

Ok, so on your system, it's the -config script that is not giving the right data.

This is starting to drive me insane.

I've now modified it to actually do a full compilation test for the outputs of -config scripts and pkgconfig, and don't assume that any of them is actually correct; Unfortunately we can't use CHECK_HEADER for this, or even CHECK_PROG, since they cache results and I have found no reliably portable way to clear the cache for that.

So latest commit has some new functions (a simplified non-caching AC_CHECK_PROG, and one to see if a given script or program gives us data we can compile with). All very experimental and probably needs to be cleaned up (and also not entirely sure whether I introduced other nonportabilities), but worth a shot.

Can you get to the branch in git yet or shall I attach another patch?

comment:27 Changed 8 years ago by jelte

  • Owner changed from UnAssigned to jelte

comment:28 Changed 8 years ago by jaspain

I'm still having difficulty with git, so would you please be so kind as to post another patch. Thanks.

Changed 8 years ago by jelte

comment:29 Changed 8 years ago by jelte

attached (note: it is just the diff of the final additions, so when starting out from the release, the other patch must be applied first)

comment:30 Changed 8 years ago by jaspain

Thanks for providing the patch. Meanwhile I believe I have figured out
how to use git. I tested four scenarios after checking out branch trac1640_2
(git checkout origin/trac1640_2 -b trac1640_2):

  1. With Botan 1.10.1 installed and pkg-config installed
  2. With Botan 1.10.1 installed and pkg-config not installed
  3. With Botan 1.8.13 installed and pkg-config installed
  4. With Botan 1.8.13 installed and pkg-config not installed

The results, given in detail below, are summarized as follows. Bind10
configure succeeds in scenarios 1 and 3 with either version of botan
and pkg-config installed. Scenario 2 with botan 1.10.1 and without
pkg-config fails, perhaps because the botan header files are buried
in the botan subdirectory of /usr/include/botan-1.10. Scenario 4 fails
not due to botan, but because pkg-config is required later on for boost
but is not present.

It may be that you don't want to have any dependency on pkg-config, in
which case the boost configuration logic needs to be enhanced. On the
other hand, if you are going to require pkg-config anyway, why not
require it for the botan configuration logic and not worry about the
complexities that occur without it? Jeff.


  1. With Botan 1.10.1 installed and pkg-config installed:
    root@oneiric:~/bind10_install/bind10-devel-git# ./configure --prefix=/usr --sysconfdir=/etc --localstatedir=/var
    ...
    checking OS family... Linux
    checking for sa_len in struct sockaddr... no
    checking for usability of botan-config-1.10 ... not usable
    checking for usability of botan-config-1.9 ... not found
    checking for usability of botan-config-1.8 ... not found
    checking for usability of botan-config ... not found
    checking for pkg-config... /usr/bin/pkg-config
    checking for usability of pkg-config botan-1.10 --silence-errors... ok
    checking botan/botan.h usability... yes
    checking botan/botan.h presence... yes
    checking for botan/botan.h... yes
    checking for Botan library... yes
    checking log4cplus/logger.h usability... yes
    ...
         BIND 10 source configure results:
        -=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
    ...
      Botan:         -I/usr/include/botan-1.10  
                      
                     -lbotan-1.10   -lbotan-1.10
    ...
    root@oneiric:~# ls /usr/include/botan-1.10/
    botan
    
    root@oneiric:~# ls /usr/include/botan-1.10/botan
    adler32.h       cascade.h    dlies.h        get_pbe.h       lookup.h        pbkdf2.h        rw.h              tls_magic.h
    ...
    
    root@oneiric:~# ls /usr/lib/*botan*
    /usr/lib/libbotan-1.10.a  /usr/lib/libbotan-1.10.so  /usr/lib/libbotan-1.10.so.0  /usr/lib/libbotan-1.10.so.0.1
    
    root@oneiric:~# ls /usr/lib/pkgconfig/
    botan-1.10.pc  dbus-python.pc  python-3.2m.pc  python-3.2.pc  python3.pc  sqlite3.pc
    

  1. With Botan 1.10.1 installed and pkg-config not installed:
    root@oneiric:~/bind10_install/bind10-devel-git# ./configure --prefix=/usr --sysconfdir=/etc --localstatedir=/var
    ...
    checking OS family... Linux
    checking for sa_len in struct sockaddr... no
    checking for usability of botan-config-1.10 ... not usable
    checking for usability of botan-config-1.9 ... not found
    checking for usability of botan-config-1.8 ... not found
    checking for usability of botan-config ... not found
    checking for pkg-config... no
    checking botan/botan.h usability... no
    checking botan/botan.h presence... no
    checking for botan/botan.h... no
    configure: error: Missing required header files.
    
    root@oneiric:~# ls /usr/include/botan-1.10/
    botan
    
    root@oneiric:~# ls /usr/include/botan-1.10/botan
    adler32.h       cascade.h    dlies.h        get_pbe.h       lookup.h        pbkdf2.h        rw.h              tls_magic.h
    ...
    
    root@oneiric:~# ls /usr/lib/*botan*
    /usr/lib/libbotan-1.10.a  /usr/lib/libbotan-1.10.so  /usr/lib/libbotan-1.10.so.0  /usr/lib/libbotan-1.10.so.0.1
    
    root@oneiric:~# ls /usr/lib/pkgconfig/
    botan-1.10.pc  dbus-python.pc  python-3.2m.pc  python-3.2.pc  python3.pc  sqlite3.pc
    

  1. With Botan 1.8.13 installed and pkg-config installed:
    root@oneiric:~/bind10_install/bind10-devel-git# ./configure --prefix=/usr --sysconfdir=/etc --localstatedir=/var
    ...
    checking OS family... Linux
    checking for sa_len in struct sockaddr... no
    checking for usability of botan-config-1.10 ... not found
    checking for usability of botan-config-1.9 ... not found
    checking for usability of botan-config-1.8 ... not found
    checking for usability of botan-config ... ok
    checking botan/botan.h usability... yes
    checking botan/botan.h presence... yes
    checking for botan/botan.h... yes
    checking for Botan library... yes
    checking log4cplus/logger.h usability... yes
    ...
         BIND 10 source configure results:
        -=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
    ...
      Botan:         -I/usr/include 
                      -L/usr/lib   
    ...
    
    root@oneiric:~# ls /usr/include/botan/
    adler32.h       cbc.h           der_enc.h      elg_op.h       gost_28147.h  md5.h       pbes1.h         rotate.h         timer.h
    ...
    
    root@oneiric:~# ls /usr/lib/*botan*
    /usr/lib/libbotan-1.8.13.so  /usr/lib/libbotan.a  /usr/lib/libbotan.so
    
    root@oneiric:~# ls /usr/lib/pkgconfig/
    botan-1.8.pc  dbus-python.pc  python-3.2m.pc  python-3.2.pc  python3.pc  sqlite3.pc
    

  1. With Botan 1.8.13 installed and pkg-config not installed:
    root@oneiric:~/bind10_install/bind10-devel-git# ./configure --prefix=/usr --sysconfdir=/etc --localstatedir=/var
    ...
    checking OS family... Linux
    checking for sa_len in struct sockaddr... no
    checking for usability of botan-config-1.10 ... not found
    checking for usability of botan-config-1.9 ... not found
    checking for usability of botan-config-1.8 ... not found
    checking for usability of botan-config ... ok
    checking botan/botan.h usability... yes
    checking botan/botan.h presence... yes
    checking for botan/botan.h... yes
    checking for Botan library... yes
    checking log4cplus/logger.h usability... yes
    ...
    checking boost/function.hpp presence... yes
    checking for boost/function.hpp... yes
    checking for pthread_create in -lpthread... yes
    checking for pkg-config... no
    configure: error: Please install pkg-config
    
    root@oneiric:~# ls /usr/include/botan/
    adler32.h       cbc.h           der_enc.h      elg_op.h       gost_28147.h  md5.h       pbes1.h         rotate.h         timer.h
    ...
    
    root@oneiric:~# ls /usr/lib/*botan*
    /usr/lib/libbotan-1.8.13.so  /usr/lib/libbotan.a  /usr/lib/libbotan.so
    
    root@oneiric:~# ls /usr/lib/pkgconfig/
    botan-1.8.pc  dbus-python.pc  python-3.2m.pc  python-3.2.pc  python3.pc  sqlite3.pc
    

comment:31 Changed 8 years ago by jelte

I am about to leave and cannot look into this further right now, but I do want to mention that relying on pkg-config itself is not a problem (as you said, we also use it later), the problem is that on some systems, the .pc file for pkg-config is supplying wrong information (whereas on yours, it's botan-config that is wrong), so that's why I'm trying to make it work with both (while one of them is bad).

comment:32 Changed 8 years ago by jreed

commit 812cea250215b93bd4567873910e2449f5b559ec worked for me on OpenBSD using no configure switch. It also worked using the new --with-botan-config switch. Thanks.

comment:33 Changed 8 years ago by jelte

Ok, I'm working on some final cleanup now, jeremy, can you add the new configure switch to the testbots that need it? I want to run it through all systems before I merge :)

comment:34 Changed 8 years ago by jelte

  • Resolution set to fixed
  • Status changed from reviewing to closed

It's been merged to master, thanks for all the feedback, Jeff and Jeremy :)

Note: See TracTickets for help on using tickets.