Boost logo

Boost-Build :

Subject: Re: [Boost-build] Linking problem in HP-UX with aCC
From: João Luís Pinto (joaoluispinto_at_[hidden])
Date: 2009-05-26 12:13:20


Hi,

On Mon, May 25, 2009 at 5:44 PM, Vladimir Prus <ghost_at_[hidden]> wrote:
> I am afraid I don't know the answers. This questions are probably best
> answered by looking at the aCC documentation. If you find out
> how and why the passed flags must be changed, we can make the change.

After some more attempts, I found out that I also need to link against
libstream to suppress the warning, even though the man page lists
libstream as being associated to the deprecated version of libstd
(-AP). Perhaps one of the dependencies I link against has not been
compiled with the same set off flags and therefore depends on the
deprecated stdlib...

> Can you post a minimal example reproducing this problem, and tell what
> exact error message you get?

This one is really strange, and appears to be a linker issue:

This component compiles OK:

aCC -AA -g +DD64 -mt -o "bus-extensions/target/bin/uid_allocator-d"
-L/oracle/oraHome1/lib -L/soft/omniORB/lib -L/soft/xerces-c/lib
-L/usr/X11R6/lib -L/usr/lib/hpux64 -L/usr/local/lib
-L/usr/users/genesys/lib
"bus-extensions/src/main/cpp/components/uid_allocator/bin/acc/debug/address-model-64/threading-multi/src/persistent_store_comp.o"
"bus-extensions/src/main/cpp/components/uid_allocator/bin/acc/debug/address-model-64/threading-multi/src/uid_allocator_comp.o"
"bus-extensions/src/main/cpp/components/uid_allocator/bin/acc/debug/address-model-64/threading-multi/src/uid_allocator_app.o"
"/oracle/oraHome1/lib/libclntsh.so"
"bus-core/src/main/cpp/lib/frk_gui/bin/acc/debug/address-model-64/threading-multi/libfrk_gui-d.so.1.0.0"
"bus-core/src/main/cpp/lib/efa/bin/acc/debug/address-model-64/threading-multi/libefa-d.so.1.0.0"
"bus-core/src/main/cpp/lib/bus_services/bin/acc/debug/address-model-64/threading-multi/libbus_services-d.so.1.0.0"
"bus-core/src/main/cpp/lib/bus/bin/acc/debug/address-model-64/threading-multi/libbus-d.so.1.0.0"
  -lz -lxerces-c -lXt -lX11 -lstream -lomniORB4 -lomniDynamic4 -locci
-lboost_thread-mt-d-1_39

While this doesn't:

aCC -AA -g +DD64 -mt -o "bus-extensions/target/bin/db_channel-d"
-L/oracle/oraHome1/lib -L/soft/omniORB/lib -L/soft/xerces-c/lib
-L/usr/X11R6/lib -L/usr/lib/hpux64 -L/usr/local/lib
-L/usr/users/genesys/lib
"bus-extensions/src/main/cpp/components/db_channel/bin/acc/debug/address-model-64/threading-multi/src/start_transaction_callback.o"
"bus-extensions/src/main/cpp/components/db_channel/bin/acc/debug/address-model-64/threading-multi/src/end_transaction_callback.o"
"bus-extensions/src/main/cpp/components/db_channel/bin/acc/debug/address-model-64/threading-multi/src/connection_geo_timer.o"
"bus-extensions/src/main/cpp/components/db_channel/bin/acc/debug/address-model-64/threading-multi/src/channel_component.o"
"bus-extensions/src/main/cpp/components/db_channel/bin/acc/debug/address-model-64/threading-multi/src/channel_application.o"
"bus-extensions/src/main/cpp/components/db_channel/bin/acc/debug/address-model-64/threading-multi/src/xstatement.o"
"bus-extensions/src/main/cpp/components/db_channel/bin/acc/debug/address-model-64/threading-multi/src/transaction_callback.o"
"bus-extensions/src/main/cpp/components/db_channel/bin/acc/debug/address-model-64/threading-multi/src/get_construction_callback.o"
"bus-extensions/src/main/cpp/components/db_channel/bin/acc/debug/address-model-64/threading-multi/src/request_version_callback.o"
"bus-extensions/src/main/cpp/components/db_channel/bin/acc/debug/address-model-64/threading-multi/src/bus_data_reply_callback.o"
"bus-extensions/src/main/cpp/components/db_channel/bin/acc/debug/address-model-64/threading-multi/src/service_callback.o"
"/oracle/oraHome1/lib/libclntsh.so"
"bus-core/src/main/cpp/lib/bus_services/bin/acc/debug/address-model-64/threading-multi/libbus_services-d.so.1.0.0"
"bus-extensions/src/main/cpp/lib/database/bin/acc/debug/address-model-64/threading-multi/libdatabase-d.so.2.0.0"
"bus-core/src/main/cpp/lib/frk_gui/bin/acc/debug/address-model-64/threading-multi/libfrk_gui-d.so.1.0.0"
"bus-core/src/main/cpp/lib/efa/bin/acc/debug/address-model-64/threading-multi/libefa-d.so.1.0.0"
"bus-core/src/main/cpp/lib/bus/bin/acc/debug/address-model-64/threading-multi/libbus-d.so.1.0.0"
  -lz -lXt -lX11 -lstream -locci -lxerces-c -lomniORB4 -lomniDynamic4
-lboost_thread-mt-d-1_39

with "ld: Can't find dependent library "libfrk_gui-d.so.1.0.0""

The only noticeable difference is that the second target depends on an
aditional project library (lib database).

I am building the several projects under bus-core/ beforehand, and
installing them in bus-core/target/lib. I noticed that if I add "-L
bus-core/target/lib " to the command line, it then compiles OK.

Btw, compilation works flawlessly in msvc and linux.

João


Boost-Build list run by bdawes at acm.org, david.abrahams at rcn.com, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk