You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@qpid.apache.org by Fraser Adams <fr...@blueyonder.co.uk> on 2012/01/02 11:17:42 UTC

Re: qpid 0.12 make fails on Linux Mint 12 (I think derived from Ubuntu 11.10)

Hi again all, I've done a bit of Googling on this and it appears that 
this behaviour has something to do with changes that have been made to 
the linker behaviour 
http://fedoraproject.org/wiki/UnderstandingDSOLinkChange (this is a 
Fedora page and I'm using Mint but the symptoms seem identical).

Has anyone else seen this and got a decent workaround?

I'll have a play and see if I can hack the makefile, at a guess it 
probably just needs an *explicit* -lboost_program_options added to the 
right place in the Makefile my problem is that I'm clueless about 
automake, so if it doesn't "just work" I'm working blind. At a guess 
some work is needed to the automake generation templates to fix this 
properly, but I wouldn't know where to begin.

I suspect that I'm not the only one who's going to be seeing this issue 
(my Mint 12 box uses gcc version 4.6.1) given the description in the 
Fedora page.

I'd appreciate any thoughts/tips
cheers,
Frase


On 31/12/11 14:07, Fraser Adams wrote:
> Hi all,
> in a fit of post Xmas madness I decided it would be a good idea to 
> upgrade my old (but working) Ubuntu Studio 9 based box to something a 
> bit more up to date.
>
> I opted for Linux Mint 12 which I believe is based on Ubuntu 11.10
>
> I installed all of the packages that I believe were necessary to make 
> and install qpid (I've done it several times on my old box) and 
> configure seemed to complete fine with no issues of note.
>
> I installed Cajus Pollmeier's "fix-unused.patch" which gets rid of 
> make problems relating to ignored return values from things like 
> ::lockf, ::write and ::system in a couple of places.
>
> However when I run make I fail with the error a the bottom of this mail:
>
> The key thing seems to be "undefined reference to symbol 
> 'boost::program_options::validate".
>
> It seems a bit weird to me though as I've checked through on my 
> package manager and I've got all of the boost and boost dev packages 
> installed for boost 1.46.
>
> I'm suspecting a linker path issue, but all the automake stuff is 
> voodoo to me so I'm not quite sure where to look first. I might have a 
> play with LDFLAGS to see if I can get anywhere but I thought I'd post 
> to see if anyone else has hit this issue. I'm guessing I'm not alone 
> on this - has anyone else tried compiling qpid 0.12 on Linux Mint 12 
> or Ubuntu 11.10? Has anyone got it working?
>
> Cheers (and Happy New Year to everyone)
> Frase
>
> /bin/bash ../libtool --tag=CXX   --mode=link g++ -Werror -pedantic 
> -Wall -Wextra -Wno-shadow -Wpointer-arith -Wcast-qual -Wcast-align 
> -Wno-long-long -Wvolatile-register-var -Winvalid-pch 
> -Wno-system-headers -Woverloaded-virtual 
> -DQPID_LIBEXEC_DIR=\"/usr/local/libexec/qpid\" 
> -DBOOST_FILESYSTEM_VERSION=2 
> -DQPIDD_MODULE_DIR=\"/usr/local/lib/qpid/daemon\" 
> -DQPIDD_CONF_FILE=\"/usr/local/etc/qpidd.conf\" -g -O2  
> -L/home/fadams/qpid/qpid-0.12/cpp/src/.libs -L/usr/lib/openais 
> -L/usr/lib64/openais -L/usr/lib/corosync -L/usr/lib64/corosync -o 
> qpidd qpidd-qpidd.o posix/qpidd-QpiddBroker.o libqpidbroker.la 
> libqpidcommon.la
> libtool: link: g++ -Werror -pedantic -Wall -Wextra -Wno-shadow 
> -Wpointer-arith -Wcast-qual -Wcast-align -Wno-long-long 
> -Wvolatile-register-var -Winvalid-pch -Wno-system-headers 
> -Woverloaded-virtual -DQPID_LIBEXEC_DIR=\"/usr/local/libexec/qpid\" 
> -DBOOST_FILESYSTEM_VERSION=2 
> -DQPIDD_MODULE_DIR=\"/usr/local/lib/qpid/daemon\" 
> -DQPIDD_CONF_FILE=\"/usr/local/etc/qpidd.conf\" -g -O2 -o .libs/qpidd 
> qpidd-qpidd.o posix/qpidd-QpiddBroker.o  
> -L/home/fadams/qpid/qpid-0.12/cpp/src/.libs -L/usr/lib/openais 
> -L/usr/lib64/openais -L/usr/lib/corosync -L/usr/lib64/corosync 
> ./.libs/libqpidbroker.so ./.libs/libqpidcommon.so
> /usr/bin/ld: posix/qpidd-QpiddBroker.o: undefined reference to symbol 
> 'boost::program_options::validate(boost::any&, 
> std::vector<std::basic_string<char, std::char_traits<char>, 
> std::allocator<char> >, std::allocator<std::basic_string<char, 
> std::char_traits<char>, std::allocator<char> > > > const&, 
> std::basic_string<char, std::char_traits<char>, std::allocator<char> 
> >*, int)'
> /usr/bin/ld: note: 'boost::program_options::validate(boost::any&, 
> std::vector<std::basic_string<char, std::char_traits<char>, 
> std::allocator<char> >, std::allocator<std::basic_string<char, 
> std::char_traits<char>, std::allocator<char> > > > const&, 
> std::basic_string<char, std::char_traits<char>, std::allocator<char> 
> >*, int)' is defined in DSO 
> /usr/lib/libboost_program_options.so.1.46.1 so try adding it to the 
> linker command line
> /usr/lib/libboost_program_options.so.1.46.1: could not read symbols: 
> Invalid operation
> collect2: ld returned 1 exit status
>
>


---------------------------------------------------------------------
Apache Qpid - AMQP Messaging Implementation
Project:      http://qpid.apache.org
Use/Interact: mailto:users-subscribe@qpid.apache.org


Re: qpid 0.12 make fails on Linux Mint 12 (I think derived from Ubuntu 11.10)

Posted by Fraser Adams <fr...@blueyonder.co.uk>.
Thanks for the "me too" Kalle. I was beginning to wonder if it was just me.

Out of curiosity did you try the patch that I submitted in the Jira 
associated with this thread?

As well as link errors I also got compilation errors (really promoted 
warnings) about unused return types, so I also included Cajus' 
fix-unused.patch. I believe doing ./configure --disable-warnings would 
resolve this too.


In my case if I added the patches and did.

cd qpid/cpp
export LDFLAGS=-L`dirname $(pwd)`/cpp/src/.libs
./bootstrap
./configure
make
sudo make install

*in that order*

I got a clean build (on Linux Mint 12 at least, which is apparently 
derived from Ubuntu 11.10)


You say "Older ubuntus seem to have no problem (natty for example) " 
that wasn't my experience. I was previously running Ubuntu Studio 9 
which was based on Karmic (so a couple of years old) before I upgraded 
to Mint 12 over Xmas. With the Karmic derivative I had to do the LDFLAGS 
bit above to get a clean build, but I didn't have to patch the 
Makefile.am though as I've said previously in this thread as far as I 
can see this latter problem looks like it could be related to the 
behaviour of ld in recent gcc versions being more pedantic.

I guess the core qpid guys use RedHat so I wonder what compiler version 
they are using - though as I've posted earlier I've seen what look like 
related linker issues on other projects posted to Fedora forums so I'm 
curious whether it "just works" on a recent Fedora derivative.

Perhaps it's all just some voodoo related to automake configurations on 
particular distributions - automake is black magic to me :-(


Regards,
Frase

>
> The compilation problem plagues us too, and I've made it compile really crudely by using ldflags.
>
> It seems that the linker does not pick up the compiled libraries from src/.lib, nor the boost ones. As to what makes it go so bad, I can only wonder. Older ubuntus seem to have no problem (natty for example). I would like to be able to update my environments, but losing smooth quid support seems hardly a bargain. :(
>
>
> Cheers,
>
> Kalle.
>
>


---------------------------------------------------------------------
Apache Qpid - AMQP Messaging Implementation
Project:      http://qpid.apache.org
Use/Interact: mailto:users-subscribe@qpid.apache.org


Re: qpid 0.12 make fails on Linux Mint 12 (I think derived from Ubuntu 11.10)

Posted by Kalle <ka...@airdice.com>.
Hi
 
> To be honest I can't believe that nobody else has commented on this, we
> surely can't be the only people who've been trying to get qpid to run on 
> Ubuntu 11.10 (or derivatives such as Mint 12) also I'm surprised it's 
> not cropped up for people using other distros as the fedora link above 
> describes similar issues for other projects that definitely relate to 
> changes that have been made to the default behaviour of ld in recent 
> versions of gcc.
> 
> 


The compilation problem plagues us too, and I've made it compile really crudely by using ldflags.

It seems that the linker does not pick up the compiled libraries from src/.lib, nor the boost ones. As to what makes it go so bad, I can only wonder. Older ubuntus seem to have no problem (natty for example). I would like to be able to update my environments, but losing smooth quid support seems hardly a bargain. :(


Cheers,

Kalle.
 

Re: qpid 0.12 make fails on Linux Mint 12 (I think derived from Ubuntu 11.10)

Posted by Fraser Adams <fr...@blueyonder.co.uk>.
Hi Cajus et al
You say "I don't think that this is a linker issue, because stuff builds 
fine with the unmodified Makefile.in files."
I don't really understand what you are saying here, especially after 
you've said "I've some minor modifications in a couple of Makefile.am 
files where the bootstrap produces a non buildable qpid-cpp. If I ignore 
the .am"

As I said previously I ended up patching the Makefile.am to include 
explicit linkage information and (with my Linux Mint 12 box at any rate) 
running bootstrap, configure, make then gives a clean build (I've not 
tried 0.14 yet).

The reason I cite it being a linker issue is because the patch I had to 
put in place was consistent with adding explicit "-l<some library>" to a 
load of Makefile.am

This was all related to a linker error that I was getting, which seems 
to have generated a lot of Internet traffic including this link 
http://fedoraproject.org/wiki/UnderstandingDSOLinkChange which set me on 
the track of getting something that worked for me.

To be honest I can't believe that nobody else has commented on this, we 
surely can't be the only people who've been trying to get qpid to run on 
Ubuntu 11.10 (or derivatives such as Mint 12) also I'm surprised it's 
not cropped up for people using other distros as the fedora link above 
describes similar issues for other projects that definitely relate to 
changes that have been made to the default behaviour of ld in recent 
versions of gcc.

I've not had any comments on the Jira other than from Cajus so I don't 
know at all whether this is seen as a problem.

At the moment my broker really is a patchy qpid :-)

Frase



On 18/01/12 10:20, Cajus Pollmeier wrote:
> Although this thread turns a month now, I'd like to comment on it ;-)
>
> The build problems are reproducible from the moment you start to let 
> whatever script recreate the autotools related files of the qpid-cpp 
> package. In the Debian packages, I've some minor modifications in a 
> couple of Makefile.am files where the bootstrap produces a non 
> buildable qpid-cpp. If I ignore the .am files and do some hackish 
> Makefile.in modifications, the build and the tests work fine.
>
> For the upcoming 0.14 the problem still exists, and it is not possible 
> to do a clean build with the modifications. Additional 
> "fix-inplicit-linking" modifications are needed to get a clean bulid - 
> but most of the tests related to SASL fail in this case.
>
> I don't think that this is a linker issue, because stuff builds fine 
> with the unmodified Makefile.in files. And they do not really differ 
> in the linker options that I can see an error there...
>
> The question is: how do I regenerate the autotools files in a way that 
> it just works?
>
>
> Am 02.01.2012 21:38, schrieb Fraser Adams:
>> I *think" I've cracked this......
>> I built everything fresh and added the patches fresh and make install
>> seemed to then work. I was a bit baffled then realised my shell had
>> some environment variables set.
>>
>> My suspicion is that I needed to have
>> export LDFLAGS=-L`dirname $(pwd)`/cpp/src/.libs
>>
>> set before calling ./bootstrap
>> This would have been the case for the make that worked so it's got me
>> wondering.
>>
>> I'll try again from absolute scratch tomorrow to see if I can get a
>> systematic build (I must be mad uninstalling a working build, but I
>> really want to be able to do a reproducible build)
>>
>> I'll keep you posted.
>> Frase
>>
>>
>> On 02/01/12 17:34, Fraser Adams wrote:
>>> Hi again,
>>> I've now got a bit further forward and have got make to work. I had 
>>> an awful lot of problems due to the explicit linkage issue that 
>>> seems to be caused by recent versions of gcc (I'm using 4.6.1)
>>>
>>> From a virgin qpid-0.12.tar.gz download I had to
>>>
>>> cd qpid-0.12/cpp
>>> patch -p1 < ../../fixed_unused.patch
>>> patch -p1 < ../../fix-explicit-link-problem.patch
>>> ./bootstrap
>>> ./configure
>>> make
>>>
>>> I've attached the patches, the first of these is Cajus Pollmeier's 
>>> patch the fix-explicit-link-problem.patch is a patch I've put 
>>> together for a number of Makefile.am files to add the necessary 
>>> explicit linkage.
>>>
>>> So far this seems to give me a make that completes and I can run 
>>> qpidd in qpid-0.12/cpp/src OK but unfortunately sudo make install 
>>> fails with the errors below.
>>>
>>> Previously when I had libtool linkage errors with make install I did:
>>>
>>> export LDFLAGS=-L`dirname $(pwd)`/cpp/src/.libs
>>>
>>> which used to work on my old Ubuntu 9.1 box. Unfortunately this 
>>> doesn't seem to work on my Mint 12 box running gcc version 4.6.1
>>>
>>> I'd really appreciate any help, this is really bugging me now - I 
>>> don't think this is necessarily a qpid problem per se, but given 
>>> what I'm seeing I'd be surprised if anyone has managed to build on 
>>> Ubuntu 11.10 without a fight - am I wrong, have I missed something 
>>> obvious????
>>>
>>> heeeellllppppp!!!!
>>> Frase
>>>
>>>
>>> Making install in managementgen
>>> make[1]: Entering directory 
>>> `/home/fadams/qpid/qpid-0.12/cpp/managementgen'
>>> make[2]: Entering directory 
>>> `/home/fadams/qpid/qpid-0.12/cpp/managementgen'
>>> test -z "/usr/local/bin" || /bin/mkdir -p "/usr/local/bin"
>>>  /usr/bin/install -c qmf-gen '/usr/local/bin'
>>> test -z "/usr/local/lib/python2.7/site-packages/qmfgen" || 
>>> /bin/mkdir -p "/usr/local/lib/python2.7/site-packages/qmfgen"
>>>  /usr/bin/install -c -m 644 qmfgen/__init__.py qmfgen/generate.py 
>>> qmfgen/schema.py qmfgen/management-types.xml 
>>> '/usr/local/lib/python2.7/site-packages/qmfgen'
>>> Byte-compiling python modules...
>>> __init__.pygenerate.pyschema.py
>>> Byte-compiling python modules (optimized versions) ...
>>> __init__.pygenerate.pyschema.py
>>> test -z "/usr/local/lib/python2.7/site-packages/qmfgen/templates" || 
>>> /bin/mkdir -p "/usr/local/lib/python2.7/site-packages/qmfgen/templates"
>>>  /usr/bin/install -c -m 644 qmfgen/templates/Args.h 
>>> qmfgen/templates/Class.cpp qmfgen/templates/Class.h 
>>> qmfgen/templates/Event.cpp qmfgen/templates/Event.h 
>>> qmfgen/templates/Makefile.mk qmfgen/templates/Package.cpp 
>>> qmfgen/templates/Package.h qmfgen/templates/V2Package.cpp 
>>> qmfgen/templates/V2Package.h 
>>> '/usr/local/lib/python2.7/site-packages/qmfgen/templates'
>>> Byte-compiling python modules...
>>>
>>> Byte-compiling python modules (optimized versions) ...
>>>
>>> make[2]: Nothing to be done for `install-data-am'.
>>> make[2]: Leaving directory 
>>> `/home/fadams/qpid/qpid-0.12/cpp/managementgen'
>>> make[1]: Leaving directory 
>>> `/home/fadams/qpid/qpid-0.12/cpp/managementgen'
>>> Making install in etc
>>> make[1]: Entering directory `/home/fadams/qpid/qpid-0.12/cpp/etc'
>>> make[2]: Entering directory `/home/fadams/qpid/qpid-0.12/cpp/etc'
>>> test -z "/usr/local/etc" || /bin/mkdir -p "/usr/local/etc"
>>>  /usr/bin/install -c -m 644  qpidd.conf '/usr/local/etc/.'
>>> /bin/mkdir -p '/usr/local/etc/sasl2'
>>>  /usr/bin/install -c -m 644  sasl2/qpidd.conf '/usr/local/etc/sasl2'
>>> test -z "/usr/local/etc/qpid" || /bin/mkdir -p "/usr/local/etc/qpid"
>>>  /usr/bin/install -c -m 644  qpidc.conf '/usr/local/etc/qpid/.'
>>> test -z "/usr/local/var/lib/qpidd" || /bin/mkdir -p 
>>> "/usr/local/var/lib/qpidd"
>>>  /usr/bin/install -c -m 644 qpidd.sasldb '/usr/local/var/lib/qpidd'
>>> make[2]: Leaving directory `/home/fadams/qpid/qpid-0.12/cpp/etc'
>>> make[1]: Leaving directory `/home/fadams/qpid/qpid-0.12/cpp/etc'
>>> Making install in src
>>> make[1]: Entering directory `/home/fadams/qpid/qpid-0.12/cpp/src'
>>> Making install in .
>>> make[2]: Entering directory `/home/fadams/qpid/qpid-0.12/cpp/src'
>>> make[3]: Entering directory `/home/fadams/qpid/qpid-0.12/cpp/src'
>>> test -z "/usr/local/lib/qpid/client" || /bin/mkdir -p 
>>> "/usr/local/lib/qpid/client"
>>> test -z "/usr/local/lib/qpid/daemon" || /bin/mkdir -p 
>>> "/usr/local/lib/qpid/daemon"
>>>  /bin/bash ../libtool   --mode=install /usr/bin/install -c   
>>> cluster.la watchdog.la acl.la xml.la replicating_listener.la 
>>> replication_exchange.la '/usr/local/lib/qpid/daemon'
>>> libtool: install: warning: relinking `cluster.la'
>>> libtool: install: (cd /home/fadams/qpid/qpid-0.12/cpp/src; /bin/bash 
>>> /home/fadams/qpid/qpid-0.12/cpp/libtool  --tag CXX --mode=relink g++ 
>>> -Werror -pedantic -Wall -Wextra -Wno-shadow -Wpointer-arith 
>>> -Wcast-qual -Wcast-align -Wno-long-long -Wvolatile-register-var 
>>> -Winvalid-pch -Wno-system-headers -Woverloaded-virtual 
>>> -DQPID_LIBEXEC_DIR=\"/usr/local/libexec/qpid\" 
>>> -DBOOST_FILESYSTEM_VERSION=2 -fno-strict-aliasing -g -O2 
>>> -no-undefined -module -avoid-version -L/usr/lib/openais 
>>> -L/usr/lib64/openais -L/usr/lib/corosync -L/usr/lib64/corosync -o 
>>> cluster.la -rpath /usr/local/lib/qpid/daemon 
>>> qpid/cluster/cluster_la-Quorum_cman.lo 
>>> qpid/cluster/cluster_la-Cluster.lo 
>>> qpid/cluster/cluster_la-ClusterTimer.lo 
>>> qpid/cluster/cluster_la-Decoder.lo 
>>> qpid/cluster/cluster_la-ClusterMap.lo 
>>> qpid/cluster/cluster_la-ClusterPlugin.lo 
>>> qpid/cluster/cluster_la-Connection.lo 
>>> qpid/cluster/cluster_la-ConnectionCodec.lo 
>>> qpid/cluster/cluster_la-Cpg.lo 
>>> qpid/cluster/cluster_la-UpdateClient.lo 
>>> qpid/cluster/cluster_la-RetractClient.lo 
>>> qpid/cluster/cluster_la-ErrorCheck.lo 
>>> qpid/cluster/cluster_la-Event.lo 
>>> qpid/cluster/cluster_la-EventFrame.lo 
>>> qpid/cluster/cluster_la-ExpiryPolicy.lo 
>>> qpid/cluster/cluster_la-FailoverExchange.lo 
>>> qpid/cluster/cluster_la-UpdateExchange.lo 
>>> qpid/cluster/cluster_la-Multicaster.lo 
>>> qpid/cluster/cluster_la-OutputInterceptor.lo 
>>> qpid/cluster/cluster_la-PollerDispatch.lo 
>>> qpid/cluster/cluster_la-InitialStatusMap.lo 
>>> qpid/cluster/cluster_la-MemberSet.lo 
>>> qpid/cluster/cluster_la-SecureConnectionFactory.lo 
>>> qpid/cluster/cluster_la-StoreStatus.lo 
>>> qpid/cluster/cluster_la-UpdateDataExchange.lo -lcpg -lcman 
>>> libqpidbroker.la libqpidclient.la )
>>> libtool: relink: g++  -fPIC -DPIC -shared -nostdlib 
>>> /usr/lib/gcc/x86_64-linux-gnu/4.6.1/../../../x86_64-linux-gnu/crti.o 
>>> /usr/lib/gcc/x86_64-linux-gnu/4.6.1/crtbeginS.o  
>>> qpid/cluster/.libs/cluster_la-Quorum_cman.o 
>>> qpid/cluster/.libs/cluster_la-Cluster.o 
>>> qpid/cluster/.libs/cluster_la-ClusterTimer.o 
>>> qpid/cluster/.libs/cluster_la-Decoder.o 
>>> qpid/cluster/.libs/cluster_la-ClusterMap.o 
>>> qpid/cluster/.libs/cluster_la-ClusterPlugin.o 
>>> qpid/cluster/.libs/cluster_la-Connection.o 
>>> qpid/cluster/.libs/cluster_la-ConnectionCodec.o 
>>> qpid/cluster/.libs/cluster_la-Cpg.o 
>>> qpid/cluster/.libs/cluster_la-UpdateClient.o 
>>> qpid/cluster/.libs/cluster_la-RetractClient.o 
>>> qpid/cluster/.libs/cluster_la-ErrorCheck.o 
>>> qpid/cluster/.libs/cluster_la-Event.o 
>>> qpid/cluster/.libs/cluster_la-EventFrame.o 
>>> qpid/cluster/.libs/cluster_la-ExpiryPolicy.o 
>>> qpid/cluster/.libs/cluster_la-FailoverExchange.o 
>>> qpid/cluster/.libs/cluster_la-UpdateExchange.o 
>>> qpid/cluster/.libs/cluster_la-Multicaster.o 
>>> qpid/cluster/.libs/cluster_la-OutputInterceptor.o 
>>> qpid/cluster/.libs/cluster_la-PollerDispatch.o 
>>> qpid/cluster/.libs/cluster_la-InitialStatusMap.o 
>>> qpid/cluster/.libs/cluster_la-MemberSet.o 
>>> qpid/cluster/.libs/cluster_la-SecureConnectionFactory.o 
>>> qpid/cluster/.libs/cluster_la-StoreStatus.o 
>>> qpid/cluster/.libs/cluster_la-UpdateDataExchange.o   
>>> -L/usr/lib/openais -L/usr/lib64/openais -L/usr/lib/corosync 
>>> -L/usr/lib64/corosync -lcpg -lcman -L/usr/local/lib -lqpidbroker 
>>> -lqpidclient -L/usr/lib/gcc/x86_64-linux-gnu/4.6.1 
>>> -L/usr/lib/gcc/x86_64-linux-gnu/4.6.1/../../../x86_64-linux-gnu 
>>> -L/usr/lib/gcc/x86_64-linux-gnu/4.6.1/../../../../lib 
>>> -L/lib/x86_64-linux-gnu -L/lib/../lib -L/usr/lib/x86_64-linux-gnu 
>>> -L/usr/lib/../lib -L/usr/lib/gcc/x86_64-linux-gnu/4.6.1/../../.. 
>>> -lstdc++ -lm -lc -lgcc_s 
>>> /usr/lib/gcc/x86_64-linux-gnu/4.6.1/crtendS.o 
>>> /usr/lib/gcc/x86_64-linux-gnu/4.6.1/../../../x86_64-linux-gnu/crtn.o  -O2   
>>> -Wl,-soname -Wl,cluster.so -o .libs/cluster.so
>>> /usr/bin/ld: cannot find -lqpidbroker
>>> /usr/bin/ld: cannot find -lqpidclient
>>> collect2: ld returned 1 exit status
>>> libtool: install: error: relink `cluster.la' with the above command 
>>> before installing it
>>> make[3]: *** [install-dmoduleexecLTLIBRARIES] Error 1
>>> make[3]: Leaving directory `/home/fadams/qpid/qpid-0.12/cpp/src'
>>> make[2]: *** [install-am] Error 2
>>> make[2]: Leaving directory `/home/fadams/qpid/qpid-0.12/cpp/src'
>>> make[1]: *** [install-recursive] Error 1
>>> make[1]: Leaving directory `/home/fadams/qpid/qpid-0.12/cpp/src'
>>> make: *** [install-recursive] Error 1
>>>
>>>
>>>
>>>
>>> On 02/01/12 10:17, Fraser Adams wrote:
>>>> Hi again all, I've done a bit of Googling on this and it appears 
>>>> that this behaviour has something to do with changes that have been 
>>>> made to the linker behaviour 
>>>> http://fedoraproject.org/wiki/UnderstandingDSOLinkChange (this is a 
>>>> Fedora page and I'm using Mint but the symptoms seem identical).
>>>>
>>>> Has anyone else seen this and got a decent workaround?
>>>>
>>>> I'll have a play and see if I can hack the makefile, at a guess it 
>>>> probably just needs an *explicit* -lboost_program_options added to 
>>>> the right place in the Makefile my problem is that I'm clueless 
>>>> about automake, so if it doesn't "just work" I'm working blind. At 
>>>> a guess some work is needed to the automake generation templates to 
>>>> fix this properly, but I wouldn't know where to begin.
>>>>
>>>> I suspect that I'm not the only one who's going to be seeing this 
>>>> issue (my Mint 12 box uses gcc version 4.6.1) given the description 
>>>> in the Fedora page.
>>>>
>>>> I'd appreciate any thoughts/tips
>>>> cheers,
>>>> Frase
>>>
>>>
>>>
>>>
>>> ---------------------------------------------------------------------
>>> Apache Qpid - AMQP Messaging Implementation
>>> Project:      http://qpid.apache.org
>>> Use/Interact: mailto:users-subscribe@qpid.apache.org
>
>
> ---------------------------------------------------------------------
> Apache Qpid - AMQP Messaging Implementation
> Project:      http://qpid.apache.org
> Use/Interact: mailto:users-subscribe@qpid.apache.org
>


---------------------------------------------------------------------
Apache Qpid - AMQP Messaging Implementation
Project:      http://qpid.apache.org
Use/Interact: mailto:users-subscribe@qpid.apache.org


Re: qpid 0.12 make fails on Linux Mint 12 (I think derived from Ubuntu 11.10)

Posted by Cajus Pollmeier <ca...@naasa.net>.
Although this thread turns a month now, I'd like to comment on it ;-)

The build problems are reproducible from the moment you start to let 
whatever script recreate the autotools related files of the qpid-cpp 
package. In the Debian packages, I've some minor modifications in a 
couple of Makefile.am files where the bootstrap produces a non buildable 
qpid-cpp. If I ignore the .am files and do some hackish Makefile.in 
modifications, the build and the tests work fine.

For the upcoming 0.14 the problem still exists, and it is not possible 
to do a clean build with the modifications. Additional 
"fix-inplicit-linking" modifications are needed to get a clean bulid - 
but most of the tests related to SASL fail in this case.

I don't think that this is a linker issue, because stuff builds fine 
with the unmodified Makefile.in files. And they do not really differ in 
the linker options that I can see an error there...

The question is: how do I regenerate the autotools files in a way that 
it just works?


Am 02.01.2012 21:38, schrieb Fraser Adams:
> I *think" I've cracked this......
> I built everything fresh and added the patches fresh and make install
> seemed to then work. I was a bit baffled then realised my shell had
> some environment variables set.
>
> My suspicion is that I needed to have
> export LDFLAGS=-L`dirname $(pwd)`/cpp/src/.libs
>
> set before calling ./bootstrap
> This would have been the case for the make that worked so it's got me
> wondering.
>
> I'll try again from absolute scratch tomorrow to see if I can get a
> systematic build (I must be mad uninstalling a working build, but I
> really want to be able to do a reproducible build)
>
> I'll keep you posted.
> Frase
>
>
> On 02/01/12 17:34, Fraser Adams wrote:
>> Hi again,
>> I've now got a bit further forward and have got make to work. I had 
>> an awful lot of problems due to the explicit linkage issue that seems 
>> to be caused by recent versions of gcc (I'm using 4.6.1)
>>
>> From a virgin qpid-0.12.tar.gz download I had to
>>
>> cd qpid-0.12/cpp
>> patch -p1 < ../../fixed_unused.patch
>> patch -p1 < ../../fix-explicit-link-problem.patch
>> ./bootstrap
>> ./configure
>> make
>>
>> I've attached the patches, the first of these is Cajus Pollmeier's 
>> patch the fix-explicit-link-problem.patch is a patch I've put together 
>> for a number of Makefile.am files to add the necessary explicit 
>> linkage.
>>
>> So far this seems to give me a make that completes and I can run 
>> qpidd in qpid-0.12/cpp/src OK but unfortunately sudo make install 
>> fails with the errors below.
>>
>> Previously when I had libtool linkage errors with make install I 
>> did:
>>
>> export LDFLAGS=-L`dirname $(pwd)`/cpp/src/.libs
>>
>> which used to work on my old Ubuntu 9.1 box. Unfortunately this 
>> doesn't seem to work on my Mint 12 box running gcc version 4.6.1
>>
>> I'd really appreciate any help, this is really bugging me now - I 
>> don't think this is necessarily a qpid problem per se, but given what 
>> I'm seeing I'd be surprised if anyone has managed to build on Ubuntu 
>> 11.10 without a fight - am I wrong, have I missed something 
>> obvious????
>>
>> heeeellllppppp!!!!
>> Frase
>>
>>
>> Making install in managementgen
>> make[1]: Entering directory 
>> `/home/fadams/qpid/qpid-0.12/cpp/managementgen'
>> make[2]: Entering directory 
>> `/home/fadams/qpid/qpid-0.12/cpp/managementgen'
>> test -z "/usr/local/bin" || /bin/mkdir -p "/usr/local/bin"
>>  /usr/bin/install -c qmf-gen '/usr/local/bin'
>> test -z "/usr/local/lib/python2.7/site-packages/qmfgen" || 
>> /bin/mkdir -p "/usr/local/lib/python2.7/site-packages/qmfgen"
>>  /usr/bin/install -c -m 644 qmfgen/__init__.py qmfgen/generate.py 
>> qmfgen/schema.py qmfgen/management-types.xml 
>> '/usr/local/lib/python2.7/site-packages/qmfgen'
>> Byte-compiling python modules...
>> __init__.pygenerate.pyschema.py
>> Byte-compiling python modules (optimized versions) ...
>> __init__.pygenerate.pyschema.py
>> test -z "/usr/local/lib/python2.7/site-packages/qmfgen/templates" || 
>> /bin/mkdir -p 
>> "/usr/local/lib/python2.7/site-packages/qmfgen/templates"
>>  /usr/bin/install -c -m 644 qmfgen/templates/Args.h 
>> qmfgen/templates/Class.cpp qmfgen/templates/Class.h 
>> qmfgen/templates/Event.cpp qmfgen/templates/Event.h 
>> qmfgen/templates/Makefile.mk qmfgen/templates/Package.cpp 
>> qmfgen/templates/Package.h qmfgen/templates/V2Package.cpp 
>> qmfgen/templates/V2Package.h 
>> '/usr/local/lib/python2.7/site-packages/qmfgen/templates'
>> Byte-compiling python modules...
>>
>> Byte-compiling python modules (optimized versions) ...
>>
>> make[2]: Nothing to be done for `install-data-am'.
>> make[2]: Leaving directory 
>> `/home/fadams/qpid/qpid-0.12/cpp/managementgen'
>> make[1]: Leaving directory 
>> `/home/fadams/qpid/qpid-0.12/cpp/managementgen'
>> Making install in etc
>> make[1]: Entering directory `/home/fadams/qpid/qpid-0.12/cpp/etc'
>> make[2]: Entering directory `/home/fadams/qpid/qpid-0.12/cpp/etc'
>> test -z "/usr/local/etc" || /bin/mkdir -p "/usr/local/etc"
>>  /usr/bin/install -c -m 644  qpidd.conf '/usr/local/etc/.'
>> /bin/mkdir -p '/usr/local/etc/sasl2'
>>  /usr/bin/install -c -m 644  sasl2/qpidd.conf '/usr/local/etc/sasl2'
>> test -z "/usr/local/etc/qpid" || /bin/mkdir -p "/usr/local/etc/qpid"
>>  /usr/bin/install -c -m 644  qpidc.conf '/usr/local/etc/qpid/.'
>> test -z "/usr/local/var/lib/qpidd" || /bin/mkdir -p 
>> "/usr/local/var/lib/qpidd"
>>  /usr/bin/install -c -m 644 qpidd.sasldb '/usr/local/var/lib/qpidd'
>> make[2]: Leaving directory `/home/fadams/qpid/qpid-0.12/cpp/etc'
>> make[1]: Leaving directory `/home/fadams/qpid/qpid-0.12/cpp/etc'
>> Making install in src
>> make[1]: Entering directory `/home/fadams/qpid/qpid-0.12/cpp/src'
>> Making install in .
>> make[2]: Entering directory `/home/fadams/qpid/qpid-0.12/cpp/src'
>> make[3]: Entering directory `/home/fadams/qpid/qpid-0.12/cpp/src'
>> test -z "/usr/local/lib/qpid/client" || /bin/mkdir -p 
>> "/usr/local/lib/qpid/client"
>> test -z "/usr/local/lib/qpid/daemon" || /bin/mkdir -p 
>> "/usr/local/lib/qpid/daemon"
>>  /bin/bash ../libtool   --mode=install /usr/bin/install -c   
>> cluster.la watchdog.la acl.la xml.la replicating_listener.la 
>> replication_exchange.la '/usr/local/lib/qpid/daemon'
>> libtool: install: warning: relinking `cluster.la'
>> libtool: install: (cd /home/fadams/qpid/qpid-0.12/cpp/src; /bin/bash 
>> /home/fadams/qpid/qpid-0.12/cpp/libtool  --tag CXX --mode=relink g++ 
>> -Werror -pedantic -Wall -Wextra -Wno-shadow -Wpointer-arith 
>> -Wcast-qual -Wcast-align -Wno-long-long -Wvolatile-register-var 
>> -Winvalid-pch -Wno-system-headers -Woverloaded-virtual 
>> -DQPID_LIBEXEC_DIR=\"/usr/local/libexec/qpid\" 
>> -DBOOST_FILESYSTEM_VERSION=2 -fno-strict-aliasing -g -O2 -no-undefined 
>> -module -avoid-version -L/usr/lib/openais -L/usr/lib64/openais 
>> -L/usr/lib/corosync -L/usr/lib64/corosync -o cluster.la -rpath 
>> /usr/local/lib/qpid/daemon qpid/cluster/cluster_la-Quorum_cman.lo 
>> qpid/cluster/cluster_la-Cluster.lo 
>> qpid/cluster/cluster_la-ClusterTimer.lo 
>> qpid/cluster/cluster_la-Decoder.lo 
>> qpid/cluster/cluster_la-ClusterMap.lo 
>> qpid/cluster/cluster_la-ClusterPlugin.lo 
>> qpid/cluster/cluster_la-Connection.lo 
>> qpid/cluster/cluster_la-ConnectionCodec.lo 
>> qpid/cluster/cluster_la-Cpg.lo qpid/cluster/cluster_la-UpdateClient.lo 
>> qpid/cluster/cluster_la-RetractClient.lo 
>> qpid/cluster/cluster_la-ErrorCheck.lo qpid/cluster/cluster_la-Event.lo 
>> qpid/cluster/cluster_la-EventFrame.lo 
>> qpid/cluster/cluster_la-ExpiryPolicy.lo 
>> qpid/cluster/cluster_la-FailoverExchange.lo 
>> qpid/cluster/cluster_la-UpdateExchange.lo 
>> qpid/cluster/cluster_la-Multicaster.lo 
>> qpid/cluster/cluster_la-OutputInterceptor.lo 
>> qpid/cluster/cluster_la-PollerDispatch.lo 
>> qpid/cluster/cluster_la-InitialStatusMap.lo 
>> qpid/cluster/cluster_la-MemberSet.lo 
>> qpid/cluster/cluster_la-SecureConnectionFactory.lo 
>> qpid/cluster/cluster_la-StoreStatus.lo 
>> qpid/cluster/cluster_la-UpdateDataExchange.lo -lcpg -lcman 
>> libqpidbroker.la libqpidclient.la )
>> libtool: relink: g++  -fPIC -DPIC -shared -nostdlib 
>> /usr/lib/gcc/x86_64-linux-gnu/4.6.1/../../../x86_64-linux-gnu/crti.o 
>> /usr/lib/gcc/x86_64-linux-gnu/4.6.1/crtbeginS.o  
>> qpid/cluster/.libs/cluster_la-Quorum_cman.o 
>> qpid/cluster/.libs/cluster_la-Cluster.o 
>> qpid/cluster/.libs/cluster_la-ClusterTimer.o 
>> qpid/cluster/.libs/cluster_la-Decoder.o 
>> qpid/cluster/.libs/cluster_la-ClusterMap.o 
>> qpid/cluster/.libs/cluster_la-ClusterPlugin.o 
>> qpid/cluster/.libs/cluster_la-Connection.o 
>> qpid/cluster/.libs/cluster_la-ConnectionCodec.o 
>> qpid/cluster/.libs/cluster_la-Cpg.o 
>> qpid/cluster/.libs/cluster_la-UpdateClient.o 
>> qpid/cluster/.libs/cluster_la-RetractClient.o 
>> qpid/cluster/.libs/cluster_la-ErrorCheck.o 
>> qpid/cluster/.libs/cluster_la-Event.o 
>> qpid/cluster/.libs/cluster_la-EventFrame.o 
>> qpid/cluster/.libs/cluster_la-ExpiryPolicy.o 
>> qpid/cluster/.libs/cluster_la-FailoverExchange.o 
>> qpid/cluster/.libs/cluster_la-UpdateExchange.o 
>> qpid/cluster/.libs/cluster_la-Multicaster.o 
>> qpid/cluster/.libs/cluster_la-OutputInterceptor.o 
>> qpid/cluster/.libs/cluster_la-PollerDispatch.o 
>> qpid/cluster/.libs/cluster_la-InitialStatusMap.o 
>> qpid/cluster/.libs/cluster_la-MemberSet.o 
>> qpid/cluster/.libs/cluster_la-SecureConnectionFactory.o 
>> qpid/cluster/.libs/cluster_la-StoreStatus.o 
>> qpid/cluster/.libs/cluster_la-UpdateDataExchange.o   
>> -L/usr/lib/openais -L/usr/lib64/openais -L/usr/lib/corosync 
>> -L/usr/lib64/corosync -lcpg -lcman -L/usr/local/lib -lqpidbroker 
>> -lqpidclient -L/usr/lib/gcc/x86_64-linux-gnu/4.6.1 
>> -L/usr/lib/gcc/x86_64-linux-gnu/4.6.1/../../../x86_64-linux-gnu 
>> -L/usr/lib/gcc/x86_64-linux-gnu/4.6.1/../../../../lib 
>> -L/lib/x86_64-linux-gnu -L/lib/../lib -L/usr/lib/x86_64-linux-gnu 
>> -L/usr/lib/../lib -L/usr/lib/gcc/x86_64-linux-gnu/4.6.1/../../.. 
>> -lstdc++ -lm -lc -lgcc_s /usr/lib/gcc/x86_64-linux-gnu/4.6.1/crtendS.o 
>> /usr/lib/gcc/x86_64-linux-gnu/4.6.1/../../../x86_64-linux-gnu/crtn.o  
>> -O2   -Wl,-soname -Wl,cluster.so -o .libs/cluster.so
>> /usr/bin/ld: cannot find -lqpidbroker
>> /usr/bin/ld: cannot find -lqpidclient
>> collect2: ld returned 1 exit status
>> libtool: install: error: relink `cluster.la' with the above command 
>> before installing it
>> make[3]: *** [install-dmoduleexecLTLIBRARIES] Error 1
>> make[3]: Leaving directory `/home/fadams/qpid/qpid-0.12/cpp/src'
>> make[2]: *** [install-am] Error 2
>> make[2]: Leaving directory `/home/fadams/qpid/qpid-0.12/cpp/src'
>> make[1]: *** [install-recursive] Error 1
>> make[1]: Leaving directory `/home/fadams/qpid/qpid-0.12/cpp/src'
>> make: *** [install-recursive] Error 1
>>
>>
>>
>>
>> On 02/01/12 10:17, Fraser Adams wrote:
>>> Hi again all, I've done a bit of Googling on this and it appears 
>>> that this behaviour has something to do with changes that have been 
>>> made to the linker behaviour 
>>> http://fedoraproject.org/wiki/UnderstandingDSOLinkChange (this is a 
>>> Fedora page and I'm using Mint but the symptoms seem identical).
>>>
>>> Has anyone else seen this and got a decent workaround?
>>>
>>> I'll have a play and see if I can hack the makefile, at a guess it 
>>> probably just needs an *explicit* -lboost_program_options added to 
>>> the right place in the Makefile my problem is that I'm clueless about 
>>> automake, so if it doesn't "just work" I'm working blind. At a guess 
>>> some work is needed to the automake generation templates to fix this 
>>> properly, but I wouldn't know where to begin.
>>>
>>> I suspect that I'm not the only one who's going to be seeing this 
>>> issue (my Mint 12 box uses gcc version 4.6.1) given the description 
>>> in the Fedora page.
>>>
>>> I'd appreciate any thoughts/tips
>>> cheers,
>>> Frase
>>
>>
>>
>> 
>> ---------------------------------------------------------------------
>> Apache Qpid - AMQP Messaging Implementation
>> Project:      http://qpid.apache.org
>> Use/Interact: mailto:users-subscribe@qpid.apache.org


---------------------------------------------------------------------
Apache Qpid - AMQP Messaging Implementation
Project:      http://qpid.apache.org
Use/Interact: mailto:users-subscribe@qpid.apache.org


Re: qpid 0.12 make fails on Linux Mint 12 (I think derived from Ubuntu 11.10)

Posted by Fraser Adams <fr...@blueyonder.co.uk>.
I *think" I've cracked this......
I built everything fresh and added the patches fresh and make install 
seemed to then work. I was a bit baffled then realised my shell had some 
environment variables set.

My suspicion is that I needed to have
export LDFLAGS=-L`dirname $(pwd)`/cpp/src/.libs

set before calling ./bootstrap
This would have been the case for the make that worked so it's got me 
wondering.

I'll try again from absolute scratch tomorrow to see if I can get a 
systematic build (I must be mad uninstalling a working build, but I 
really want to be able to do a reproducible build)

I'll keep you posted.
Frase


On 02/01/12 17:34, Fraser Adams wrote:
> Hi again,
> I've now got a bit further forward and have got make to work. I had an 
> awful lot of problems due to the explicit linkage issue that seems to 
> be caused by recent versions of gcc (I'm using 4.6.1)
>
> From a virgin qpid-0.12.tar.gz download I had to
>
> cd qpid-0.12/cpp
> patch -p1 < ../../fixed_unused.patch
> patch -p1 < ../../fix-explicit-link-problem.patch
> ./bootstrap
> ./configure
> make
>
> I've attached the patches, the first of these is Cajus Pollmeier's 
> patch the fix-explicit-link-problem.patch is a patch I've put together 
> for a number of Makefile.am files to add the necessary explicit linkage.
>
> So far this seems to give me a make that completes and I can run qpidd 
> in qpid-0.12/cpp/src OK but unfortunately sudo make install fails with 
> the errors below.
>
> Previously when I had libtool linkage errors with make install I did:
>
> export LDFLAGS=-L`dirname $(pwd)`/cpp/src/.libs
>
> which used to work on my old Ubuntu 9.1 box. Unfortunately this 
> doesn't seem to work on my Mint 12 box running gcc version 4.6.1
>
> I'd really appreciate any help, this is really bugging me now - I 
> don't think this is necessarily a qpid problem per se, but given what 
> I'm seeing I'd be surprised if anyone has managed to build on Ubuntu 
> 11.10 without a fight - am I wrong, have I missed something obvious????
>
> heeeellllppppp!!!!
> Frase
>
>
> Making install in managementgen
> make[1]: Entering directory 
> `/home/fadams/qpid/qpid-0.12/cpp/managementgen'
> make[2]: Entering directory 
> `/home/fadams/qpid/qpid-0.12/cpp/managementgen'
> test -z "/usr/local/bin" || /bin/mkdir -p "/usr/local/bin"
>  /usr/bin/install -c qmf-gen '/usr/local/bin'
> test -z "/usr/local/lib/python2.7/site-packages/qmfgen" || /bin/mkdir 
> -p "/usr/local/lib/python2.7/site-packages/qmfgen"
>  /usr/bin/install -c -m 644 qmfgen/__init__.py qmfgen/generate.py 
> qmfgen/schema.py qmfgen/management-types.xml 
> '/usr/local/lib/python2.7/site-packages/qmfgen'
> Byte-compiling python modules...
> __init__.pygenerate.pyschema.py
> Byte-compiling python modules (optimized versions) ...
> __init__.pygenerate.pyschema.py
> test -z "/usr/local/lib/python2.7/site-packages/qmfgen/templates" || 
> /bin/mkdir -p "/usr/local/lib/python2.7/site-packages/qmfgen/templates"
>  /usr/bin/install -c -m 644 qmfgen/templates/Args.h 
> qmfgen/templates/Class.cpp qmfgen/templates/Class.h 
> qmfgen/templates/Event.cpp qmfgen/templates/Event.h 
> qmfgen/templates/Makefile.mk qmfgen/templates/Package.cpp 
> qmfgen/templates/Package.h qmfgen/templates/V2Package.cpp 
> qmfgen/templates/V2Package.h 
> '/usr/local/lib/python2.7/site-packages/qmfgen/templates'
> Byte-compiling python modules...
>
> Byte-compiling python modules (optimized versions) ...
>
> make[2]: Nothing to be done for `install-data-am'.
> make[2]: Leaving directory 
> `/home/fadams/qpid/qpid-0.12/cpp/managementgen'
> make[1]: Leaving directory 
> `/home/fadams/qpid/qpid-0.12/cpp/managementgen'
> Making install in etc
> make[1]: Entering directory `/home/fadams/qpid/qpid-0.12/cpp/etc'
> make[2]: Entering directory `/home/fadams/qpid/qpid-0.12/cpp/etc'
> test -z "/usr/local/etc" || /bin/mkdir -p "/usr/local/etc"
>  /usr/bin/install -c -m 644  qpidd.conf '/usr/local/etc/.'
> /bin/mkdir -p '/usr/local/etc/sasl2'
>  /usr/bin/install -c -m 644  sasl2/qpidd.conf '/usr/local/etc/sasl2'
> test -z "/usr/local/etc/qpid" || /bin/mkdir -p "/usr/local/etc/qpid"
>  /usr/bin/install -c -m 644  qpidc.conf '/usr/local/etc/qpid/.'
> test -z "/usr/local/var/lib/qpidd" || /bin/mkdir -p 
> "/usr/local/var/lib/qpidd"
>  /usr/bin/install -c -m 644 qpidd.sasldb '/usr/local/var/lib/qpidd'
> make[2]: Leaving directory `/home/fadams/qpid/qpid-0.12/cpp/etc'
> make[1]: Leaving directory `/home/fadams/qpid/qpid-0.12/cpp/etc'
> Making install in src
> make[1]: Entering directory `/home/fadams/qpid/qpid-0.12/cpp/src'
> Making install in .
> make[2]: Entering directory `/home/fadams/qpid/qpid-0.12/cpp/src'
> make[3]: Entering directory `/home/fadams/qpid/qpid-0.12/cpp/src'
> test -z "/usr/local/lib/qpid/client" || /bin/mkdir -p 
> "/usr/local/lib/qpid/client"
> test -z "/usr/local/lib/qpid/daemon" || /bin/mkdir -p 
> "/usr/local/lib/qpid/daemon"
>  /bin/bash ../libtool   --mode=install /usr/bin/install -c   
> cluster.la watchdog.la acl.la xml.la replicating_listener.la 
> replication_exchange.la '/usr/local/lib/qpid/daemon'
> libtool: install: warning: relinking `cluster.la'
> libtool: install: (cd /home/fadams/qpid/qpid-0.12/cpp/src; /bin/bash 
> /home/fadams/qpid/qpid-0.12/cpp/libtool  --tag CXX --mode=relink g++ 
> -Werror -pedantic -Wall -Wextra -Wno-shadow -Wpointer-arith 
> -Wcast-qual -Wcast-align -Wno-long-long -Wvolatile-register-var 
> -Winvalid-pch -Wno-system-headers -Woverloaded-virtual 
> -DQPID_LIBEXEC_DIR=\"/usr/local/libexec/qpid\" 
> -DBOOST_FILESYSTEM_VERSION=2 -fno-strict-aliasing -g -O2 -no-undefined 
> -module -avoid-version -L/usr/lib/openais -L/usr/lib64/openais 
> -L/usr/lib/corosync -L/usr/lib64/corosync -o cluster.la -rpath 
> /usr/local/lib/qpid/daemon qpid/cluster/cluster_la-Quorum_cman.lo 
> qpid/cluster/cluster_la-Cluster.lo 
> qpid/cluster/cluster_la-ClusterTimer.lo 
> qpid/cluster/cluster_la-Decoder.lo 
> qpid/cluster/cluster_la-ClusterMap.lo 
> qpid/cluster/cluster_la-ClusterPlugin.lo 
> qpid/cluster/cluster_la-Connection.lo 
> qpid/cluster/cluster_la-ConnectionCodec.lo 
> qpid/cluster/cluster_la-Cpg.lo qpid/cluster/cluster_la-UpdateClient.lo 
> qpid/cluster/cluster_la-RetractClient.lo 
> qpid/cluster/cluster_la-ErrorCheck.lo qpid/cluster/cluster_la-Event.lo 
> qpid/cluster/cluster_la-EventFrame.lo 
> qpid/cluster/cluster_la-ExpiryPolicy.lo 
> qpid/cluster/cluster_la-FailoverExchange.lo 
> qpid/cluster/cluster_la-UpdateExchange.lo 
> qpid/cluster/cluster_la-Multicaster.lo 
> qpid/cluster/cluster_la-OutputInterceptor.lo 
> qpid/cluster/cluster_la-PollerDispatch.lo 
> qpid/cluster/cluster_la-InitialStatusMap.lo 
> qpid/cluster/cluster_la-MemberSet.lo 
> qpid/cluster/cluster_la-SecureConnectionFactory.lo 
> qpid/cluster/cluster_la-StoreStatus.lo 
> qpid/cluster/cluster_la-UpdateDataExchange.lo -lcpg -lcman 
> libqpidbroker.la libqpidclient.la )
> libtool: relink: g++  -fPIC -DPIC -shared -nostdlib 
> /usr/lib/gcc/x86_64-linux-gnu/4.6.1/../../../x86_64-linux-gnu/crti.o 
> /usr/lib/gcc/x86_64-linux-gnu/4.6.1/crtbeginS.o  
> qpid/cluster/.libs/cluster_la-Quorum_cman.o 
> qpid/cluster/.libs/cluster_la-Cluster.o 
> qpid/cluster/.libs/cluster_la-ClusterTimer.o 
> qpid/cluster/.libs/cluster_la-Decoder.o 
> qpid/cluster/.libs/cluster_la-ClusterMap.o 
> qpid/cluster/.libs/cluster_la-ClusterPlugin.o 
> qpid/cluster/.libs/cluster_la-Connection.o 
> qpid/cluster/.libs/cluster_la-ConnectionCodec.o 
> qpid/cluster/.libs/cluster_la-Cpg.o 
> qpid/cluster/.libs/cluster_la-UpdateClient.o 
> qpid/cluster/.libs/cluster_la-RetractClient.o 
> qpid/cluster/.libs/cluster_la-ErrorCheck.o 
> qpid/cluster/.libs/cluster_la-Event.o 
> qpid/cluster/.libs/cluster_la-EventFrame.o 
> qpid/cluster/.libs/cluster_la-ExpiryPolicy.o 
> qpid/cluster/.libs/cluster_la-FailoverExchange.o 
> qpid/cluster/.libs/cluster_la-UpdateExchange.o 
> qpid/cluster/.libs/cluster_la-Multicaster.o 
> qpid/cluster/.libs/cluster_la-OutputInterceptor.o 
> qpid/cluster/.libs/cluster_la-PollerDispatch.o 
> qpid/cluster/.libs/cluster_la-InitialStatusMap.o 
> qpid/cluster/.libs/cluster_la-MemberSet.o 
> qpid/cluster/.libs/cluster_la-SecureConnectionFactory.o 
> qpid/cluster/.libs/cluster_la-StoreStatus.o 
> qpid/cluster/.libs/cluster_la-UpdateDataExchange.o   
> -L/usr/lib/openais -L/usr/lib64/openais -L/usr/lib/corosync 
> -L/usr/lib64/corosync -lcpg -lcman -L/usr/local/lib -lqpidbroker 
> -lqpidclient -L/usr/lib/gcc/x86_64-linux-gnu/4.6.1 
> -L/usr/lib/gcc/x86_64-linux-gnu/4.6.1/../../../x86_64-linux-gnu 
> -L/usr/lib/gcc/x86_64-linux-gnu/4.6.1/../../../../lib 
> -L/lib/x86_64-linux-gnu -L/lib/../lib -L/usr/lib/x86_64-linux-gnu 
> -L/usr/lib/../lib -L/usr/lib/gcc/x86_64-linux-gnu/4.6.1/../../.. 
> -lstdc++ -lm -lc -lgcc_s /usr/lib/gcc/x86_64-linux-gnu/4.6.1/crtendS.o 
> /usr/lib/gcc/x86_64-linux-gnu/4.6.1/../../../x86_64-linux-gnu/crtn.o  
> -O2   -Wl,-soname -Wl,cluster.so -o .libs/cluster.so
> /usr/bin/ld: cannot find -lqpidbroker
> /usr/bin/ld: cannot find -lqpidclient
> collect2: ld returned 1 exit status
> libtool: install: error: relink `cluster.la' with the above command 
> before installing it
> make[3]: *** [install-dmoduleexecLTLIBRARIES] Error 1
> make[3]: Leaving directory `/home/fadams/qpid/qpid-0.12/cpp/src'
> make[2]: *** [install-am] Error 2
> make[2]: Leaving directory `/home/fadams/qpid/qpid-0.12/cpp/src'
> make[1]: *** [install-recursive] Error 1
> make[1]: Leaving directory `/home/fadams/qpid/qpid-0.12/cpp/src'
> make: *** [install-recursive] Error 1
>
>
>
>
> On 02/01/12 10:17, Fraser Adams wrote:
>> Hi again all, I've done a bit of Googling on this and it appears that 
>> this behaviour has something to do with changes that have been made 
>> to the linker behaviour 
>> http://fedoraproject.org/wiki/UnderstandingDSOLinkChange (this is a 
>> Fedora page and I'm using Mint but the symptoms seem identical).
>>
>> Has anyone else seen this and got a decent workaround?
>>
>> I'll have a play and see if I can hack the makefile, at a guess it 
>> probably just needs an *explicit* -lboost_program_options added to 
>> the right place in the Makefile my problem is that I'm clueless about 
>> automake, so if it doesn't "just work" I'm working blind. At a guess 
>> some work is needed to the automake generation templates to fix this 
>> properly, but I wouldn't know where to begin.
>>
>> I suspect that I'm not the only one who's going to be seeing this 
>> issue (my Mint 12 box uses gcc version 4.6.1) given the description 
>> in the Fedora page.
>>
>> I'd appreciate any thoughts/tips
>> cheers,
>> Frase
>
>
>
> ---------------------------------------------------------------------
> Apache Qpid - AMQP Messaging Implementation
> Project:      http://qpid.apache.org
> Use/Interact: mailto:users-subscribe@qpid.apache.org


Re: qpid 0.12 make fails on Linux Mint 12 (I think derived from Ubuntu 11.10)

Posted by Fraser Adams <fr...@blueyonder.co.uk>.
Hi again,
I've now got a bit further forward and have got make to work. I had an 
awful lot of problems due to the explicit linkage issue that seems to be 
caused by recent versions of gcc (I'm using 4.6.1)

 From a virgin qpid-0.12.tar.gz download I had to

cd qpid-0.12/cpp
patch -p1 < ../../fixed_unused.patch
patch -p1 < ../../fix-explicit-link-problem.patch
./bootstrap
./configure
make

I've attached the patches, the first of these is Cajus Pollmeier's patch 
the fix-explicit-link-problem.patch is a patch I've put together for a 
number of Makefile.am files to add the necessary explicit linkage.

So far this seems to give me a make that completes and I can run qpidd 
in qpid-0.12/cpp/src OK but unfortunately sudo make install fails with 
the errors below.

Previously when I had libtool linkage errors with make install I did:

export LDFLAGS=-L`dirname $(pwd)`/cpp/src/.libs

which used to work on my old Ubuntu 9.1 box. Unfortunately this doesn't 
seem to work on my Mint 12 box running gcc version 4.6.1

I'd really appreciate any help, this is really bugging me now - I don't 
think this is necessarily a qpid problem per se, but given what I'm 
seeing I'd be surprised if anyone has managed to build on Ubuntu 11.10 
without a fight - am I wrong, have I missed something obvious????

heeeellllppppp!!!!
Frase


Making install in managementgen
make[1]: Entering directory `/home/fadams/qpid/qpid-0.12/cpp/managementgen'
make[2]: Entering directory `/home/fadams/qpid/qpid-0.12/cpp/managementgen'
test -z "/usr/local/bin" || /bin/mkdir -p "/usr/local/bin"
  /usr/bin/install -c qmf-gen '/usr/local/bin'
test -z "/usr/local/lib/python2.7/site-packages/qmfgen" || /bin/mkdir -p 
"/usr/local/lib/python2.7/site-packages/qmfgen"
  /usr/bin/install -c -m 644 qmfgen/__init__.py qmfgen/generate.py 
qmfgen/schema.py qmfgen/management-types.xml 
'/usr/local/lib/python2.7/site-packages/qmfgen'
Byte-compiling python modules...
__init__.pygenerate.pyschema.py
Byte-compiling python modules (optimized versions) ...
__init__.pygenerate.pyschema.py
test -z "/usr/local/lib/python2.7/site-packages/qmfgen/templates" || 
/bin/mkdir -p "/usr/local/lib/python2.7/site-packages/qmfgen/templates"
  /usr/bin/install -c -m 644 qmfgen/templates/Args.h 
qmfgen/templates/Class.cpp qmfgen/templates/Class.h 
qmfgen/templates/Event.cpp qmfgen/templates/Event.h 
qmfgen/templates/Makefile.mk qmfgen/templates/Package.cpp 
qmfgen/templates/Package.h qmfgen/templates/V2Package.cpp 
qmfgen/templates/V2Package.h 
'/usr/local/lib/python2.7/site-packages/qmfgen/templates'
Byte-compiling python modules...

Byte-compiling python modules (optimized versions) ...

make[2]: Nothing to be done for `install-data-am'.
make[2]: Leaving directory `/home/fadams/qpid/qpid-0.12/cpp/managementgen'
make[1]: Leaving directory `/home/fadams/qpid/qpid-0.12/cpp/managementgen'
Making install in etc
make[1]: Entering directory `/home/fadams/qpid/qpid-0.12/cpp/etc'
make[2]: Entering directory `/home/fadams/qpid/qpid-0.12/cpp/etc'
test -z "/usr/local/etc" || /bin/mkdir -p "/usr/local/etc"
  /usr/bin/install -c -m 644  qpidd.conf '/usr/local/etc/.'
/bin/mkdir -p '/usr/local/etc/sasl2'
  /usr/bin/install -c -m 644  sasl2/qpidd.conf '/usr/local/etc/sasl2'
test -z "/usr/local/etc/qpid" || /bin/mkdir -p "/usr/local/etc/qpid"
  /usr/bin/install -c -m 644  qpidc.conf '/usr/local/etc/qpid/.'
test -z "/usr/local/var/lib/qpidd" || /bin/mkdir -p 
"/usr/local/var/lib/qpidd"
  /usr/bin/install -c -m 644 qpidd.sasldb '/usr/local/var/lib/qpidd'
make[2]: Leaving directory `/home/fadams/qpid/qpid-0.12/cpp/etc'
make[1]: Leaving directory `/home/fadams/qpid/qpid-0.12/cpp/etc'
Making install in src
make[1]: Entering directory `/home/fadams/qpid/qpid-0.12/cpp/src'
Making install in .
make[2]: Entering directory `/home/fadams/qpid/qpid-0.12/cpp/src'
make[3]: Entering directory `/home/fadams/qpid/qpid-0.12/cpp/src'
test -z "/usr/local/lib/qpid/client" || /bin/mkdir -p 
"/usr/local/lib/qpid/client"
test -z "/usr/local/lib/qpid/daemon" || /bin/mkdir -p 
"/usr/local/lib/qpid/daemon"
  /bin/bash ../libtool   --mode=install /usr/bin/install -c   cluster.la 
watchdog.la acl.la xml.la replicating_listener.la 
replication_exchange.la '/usr/local/lib/qpid/daemon'
libtool: install: warning: relinking `cluster.la'
libtool: install: (cd /home/fadams/qpid/qpid-0.12/cpp/src; /bin/bash 
/home/fadams/qpid/qpid-0.12/cpp/libtool  --tag CXX --mode=relink g++ 
-Werror -pedantic -Wall -Wextra -Wno-shadow -Wpointer-arith -Wcast-qual 
-Wcast-align -Wno-long-long -Wvolatile-register-var -Winvalid-pch 
-Wno-system-headers -Woverloaded-virtual 
-DQPID_LIBEXEC_DIR=\"/usr/local/libexec/qpid\" 
-DBOOST_FILESYSTEM_VERSION=2 -fno-strict-aliasing -g -O2 -no-undefined 
-module -avoid-version -L/usr/lib/openais -L/usr/lib64/openais 
-L/usr/lib/corosync -L/usr/lib64/corosync -o cluster.la -rpath 
/usr/local/lib/qpid/daemon qpid/cluster/cluster_la-Quorum_cman.lo 
qpid/cluster/cluster_la-Cluster.lo 
qpid/cluster/cluster_la-ClusterTimer.lo 
qpid/cluster/cluster_la-Decoder.lo qpid/cluster/cluster_la-ClusterMap.lo 
qpid/cluster/cluster_la-ClusterPlugin.lo 
qpid/cluster/cluster_la-Connection.lo 
qpid/cluster/cluster_la-ConnectionCodec.lo 
qpid/cluster/cluster_la-Cpg.lo qpid/cluster/cluster_la-UpdateClient.lo 
qpid/cluster/cluster_la-RetractClient.lo 
qpid/cluster/cluster_la-ErrorCheck.lo qpid/cluster/cluster_la-Event.lo 
qpid/cluster/cluster_la-EventFrame.lo 
qpid/cluster/cluster_la-ExpiryPolicy.lo 
qpid/cluster/cluster_la-FailoverExchange.lo 
qpid/cluster/cluster_la-UpdateExchange.lo 
qpid/cluster/cluster_la-Multicaster.lo 
qpid/cluster/cluster_la-OutputInterceptor.lo 
qpid/cluster/cluster_la-PollerDispatch.lo 
qpid/cluster/cluster_la-InitialStatusMap.lo 
qpid/cluster/cluster_la-MemberSet.lo 
qpid/cluster/cluster_la-SecureConnectionFactory.lo 
qpid/cluster/cluster_la-StoreStatus.lo 
qpid/cluster/cluster_la-UpdateDataExchange.lo -lcpg -lcman 
libqpidbroker.la libqpidclient.la )
libtool: relink: g++  -fPIC -DPIC -shared -nostdlib 
/usr/lib/gcc/x86_64-linux-gnu/4.6.1/../../../x86_64-linux-gnu/crti.o 
/usr/lib/gcc/x86_64-linux-gnu/4.6.1/crtbeginS.o  
qpid/cluster/.libs/cluster_la-Quorum_cman.o 
qpid/cluster/.libs/cluster_la-Cluster.o 
qpid/cluster/.libs/cluster_la-ClusterTimer.o 
qpid/cluster/.libs/cluster_la-Decoder.o 
qpid/cluster/.libs/cluster_la-ClusterMap.o 
qpid/cluster/.libs/cluster_la-ClusterPlugin.o 
qpid/cluster/.libs/cluster_la-Connection.o 
qpid/cluster/.libs/cluster_la-ConnectionCodec.o 
qpid/cluster/.libs/cluster_la-Cpg.o 
qpid/cluster/.libs/cluster_la-UpdateClient.o 
qpid/cluster/.libs/cluster_la-RetractClient.o 
qpid/cluster/.libs/cluster_la-ErrorCheck.o 
qpid/cluster/.libs/cluster_la-Event.o 
qpid/cluster/.libs/cluster_la-EventFrame.o 
qpid/cluster/.libs/cluster_la-ExpiryPolicy.o 
qpid/cluster/.libs/cluster_la-FailoverExchange.o 
qpid/cluster/.libs/cluster_la-UpdateExchange.o 
qpid/cluster/.libs/cluster_la-Multicaster.o 
qpid/cluster/.libs/cluster_la-OutputInterceptor.o 
qpid/cluster/.libs/cluster_la-PollerDispatch.o 
qpid/cluster/.libs/cluster_la-InitialStatusMap.o 
qpid/cluster/.libs/cluster_la-MemberSet.o 
qpid/cluster/.libs/cluster_la-SecureConnectionFactory.o 
qpid/cluster/.libs/cluster_la-StoreStatus.o 
qpid/cluster/.libs/cluster_la-UpdateDataExchange.o   -L/usr/lib/openais 
-L/usr/lib64/openais -L/usr/lib/corosync -L/usr/lib64/corosync -lcpg 
-lcman -L/usr/local/lib -lqpidbroker -lqpidclient 
-L/usr/lib/gcc/x86_64-linux-gnu/4.6.1 
-L/usr/lib/gcc/x86_64-linux-gnu/4.6.1/../../../x86_64-linux-gnu 
-L/usr/lib/gcc/x86_64-linux-gnu/4.6.1/../../../../lib 
-L/lib/x86_64-linux-gnu -L/lib/../lib -L/usr/lib/x86_64-linux-gnu 
-L/usr/lib/../lib -L/usr/lib/gcc/x86_64-linux-gnu/4.6.1/../../.. 
-lstdc++ -lm -lc -lgcc_s /usr/lib/gcc/x86_64-linux-gnu/4.6.1/crtendS.o 
/usr/lib/gcc/x86_64-linux-gnu/4.6.1/../../../x86_64-linux-gnu/crtn.o  
-O2   -Wl,-soname -Wl,cluster.so -o .libs/cluster.so
/usr/bin/ld: cannot find -lqpidbroker
/usr/bin/ld: cannot find -lqpidclient
collect2: ld returned 1 exit status
libtool: install: error: relink `cluster.la' with the above command 
before installing it
make[3]: *** [install-dmoduleexecLTLIBRARIES] Error 1
make[3]: Leaving directory `/home/fadams/qpid/qpid-0.12/cpp/src'
make[2]: *** [install-am] Error 2
make[2]: Leaving directory `/home/fadams/qpid/qpid-0.12/cpp/src'
make[1]: *** [install-recursive] Error 1
make[1]: Leaving directory `/home/fadams/qpid/qpid-0.12/cpp/src'
make: *** [install-recursive] Error 1




On 02/01/12 10:17, Fraser Adams wrote:
> Hi again all, I've done a bit of Googling on this and it appears that 
> this behaviour has something to do with changes that have been made to 
> the linker behaviour 
> http://fedoraproject.org/wiki/UnderstandingDSOLinkChange (this is a 
> Fedora page and I'm using Mint but the symptoms seem identical).
>
> Has anyone else seen this and got a decent workaround?
>
> I'll have a play and see if I can hack the makefile, at a guess it 
> probably just needs an *explicit* -lboost_program_options added to the 
> right place in the Makefile my problem is that I'm clueless about 
> automake, so if it doesn't "just work" I'm working blind. At a guess 
> some work is needed to the automake generation templates to fix this 
> properly, but I wouldn't know where to begin.
>
> I suspect that I'm not the only one who's going to be seeing this 
> issue (my Mint 12 box uses gcc version 4.6.1) given the description in 
> the Fedora page.
>
> I'd appreciate any thoughts/tips
> cheers,
> Frase