Opened 9 years ago

Closed 8 years ago

#1201 closed defect (fixed)

On Ubuntu 11.04, if libbz2-dev is missing, configure stops with message that botan 1.8 is missing

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


however botan 1.8 including headers might be installed. The config.log gives the hint:

configure:15785: result: yes
configure:15785: checking botan/botan.h presence
configure:15785: g++ -E -I/usr/include   conftest.cpp
configure:15785: $? = 0
configure:15785: result: yes
configure:15785: checking for botan/botan.h
configure:15785: result: yes
configure:15813: g++ -o conftest -g -O2 -I/usr/include   -L/usr/lib -lbotan -lbz2 -lcrypto -lgmp -lpthread -lrt -lz  -R/usr/lib         conftest.cpp  >&5
g++: unrecognized option '-R/usr/lib'
/usr/bin/ld: cannot find -lbz2
collect2: ld returned 1 exit status
configure:15813: $? = 1
configure: failed program was:
| /* confdefs.h */
| #define PACKAGE_NAME "bind10-devel"
| #define PACKAGE_TARNAME "bind10-devel"
| #define PACKAGE_VERSION "20110819"
| #define PACKAGE_STRING "bind10-devel 20110819"
| #define PACKAGE_URL ""

this helps, but might not be obvious to a DNS admin compiling BIND 10:

sudo apt-get install libbz2-dev

I'm not sure if this is an issue with BIND 10 configure, or with Ubuntu dependencies.


Change History (9)

comment:1 Changed 9 years ago by shane

  • Defect Severity changed from N/A to Medium
  • Milestone changed from New Tasks to Next-Sprint-Proposed

Since Botan has a dependency on bzip2 and gives a confusing check, I suppose the best thing to do is to add an explicit check for the bzip2 library in our own Assuming this is the correct thing to do, it seems straightforward enough.

comment:2 Changed 9 years ago by jelte

IIRC we ran into this some time ago, and the problem was that botan-config gave the wrong output, we contacted the maintainer but apparently the update has not made it yet.

Come to think if it, I also thought we had put in some foo to remove these values should they be present, which i think is a better workaround than requiring the deps, if possible. If not, then yeah we might want to explicitely check (if needed).

comment:3 Changed 9 years ago by jreed

I think it may be a bug specifically on that packaging for now. Note that none of our autobuilders need it and on my system doesn't use libbz2.

Aharen and Shane both hit this problem (but for libgmp3 also). The guide has comment (in source only):

Debian and Ubuntu:

libgmp3-dev and libbz2-dev required for botan too


I wrote on jabber about this a few months ago.

It is a problem specifically with the broken packages. The botan-dev package you are using has a libtool and botan-config file that specifically mention libbz2 and libgmp with versioning numbers.
The dependencies only provide the specific numbered libraries, so you have to manually install extra packages to get the symlinks to those libraries.

To reproduce: run the botan-config, then run dpkg --listfiles on each package and see the needed libraries don't exist for each dependency package. To really reproduce by compiling, you would have to remove two package (if added to workaround problem).

Jelte talked to Ondrej about it in May 2011 and Ondrej said he would fix it right away. (Remove references I think since they are in Libs.private.)

comment:4 Changed 8 years ago by shane

  • Milestone set to Next-Sprint-Proposed
  • Sub-Project changed from DNS to Core

This hit another user. Probably we need to fix this ASAP.

comment:5 Changed 8 years ago by shane

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

comment:6 Changed 8 years ago by shane

We seem to have time in this sprint, we'll try doing it now.

comment:7 Changed 8 years ago by jelte

umz, thinking about it a bit more (and some very short discussion on jabber), I think we should just expand on the error; if headers are found but linking fails, changes are high either the version is too low, or we hit that dependency bug, and installing libbz2 and libgmp should fix it.

I was just working on some related code in #1640, and updated the relevant error to something like this. If people agree this is acceptable, I think this ticket can be closed.

comment:8 Changed 8 years ago by jelte

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

tentatively grabbing this ticket until 1640 is merged (At which point i'll close this unless people complain)

comment:9 Changed 8 years ago by jelte

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

relevant changes committed with #1640

Note: See TracTickets for help on using tickets.