[C++-sig] Re: boost.Python/Jam with shared libraries

John Meinel john at arbash-meinel.com
Wed Nov 10 17:50:26 CET 2004


Aaron Bentley wrote:
> John Meinel <john <at> johnmeinel.com> writes:
> 
> 
>>You might want to try the "don't do it but tell me what you want to do." 
>>flag.
>>
>>bjam -n
> 
> 
> Here's the meat of the output (with library-file):
> 
> "bin/python/pfengine.so/gcc/debug/shared-linkable-true/pfengine.so.1.31.0"
> 
> -L"/home/abentley/devel/.libs" -L"/home/abentley/lib/python2.3/config"
> 
> "bin/python/pfengine.so/gcc/debug/shared-linkable-true/pfengine.o"
> 
> "/home/abentley/devel/libpdf.a"  "/home/abentley/devel/libpdf.a"   -lpanutil
> 
> -lpantemplate -lpanpdfgen -lpancompile -lpanconsult -lpanelement -lpanlang
> 
> -lpancore -lpanexport -lpanreport -lpancgi -lchart -lecommerce -licuio -licudata
> 
> -licutoolutil -licule -licui18n  -Wl,-rpath-link,.  
> 
> -Wl,-soname,pfengine.so.1.31.0 
> 

I would have thought that you would want it to say:

-L"/home/abentley/devel" -lpdf

Where is libpdf.a anyway? Because you are including ~/devel/.libs, but 
you seem to have the actual library in ~/devel/libpdf.a

I would say the lines:

   <library-path>/home/abentley/devel
   <find-library>pdf

Would do what I'm mentioning. I don't really know how <library-file> 
works (I don't use it myself.)

I think suppling the full path to the library file should work, though. 
I'm not sure why it is supplying it twice. Unless it's just trying to 
get the linking order correct. I believe there have been bugs where 
doing "gcc file.cpp -llib1 -llib2" works, but "gcc file.cpp -llib2 
-llib1" does not (if one depends on the other.)

I'm not really sure. All of my static libs are managed by Jamfiles right 
now, so I haven't learned how to access external static libraries. I 
thought it would be the same as external dynamic ones.

John
=:->
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 256 bytes
Desc: OpenPGP digital signature
URL: <http://mail.python.org/pipermail/cplusplus-sig/attachments/20041110/8e800001/attachment.pgp>


More information about the Cplusplus-sig mailing list