Bug 553

Summary: Running code built with a special gcc
Product: ns-3 Reporter: Faker Moatamri <faker.moatamri>
Component: build systemAssignee: ns-bugs <ns-bugs>
Status: RESOLVED FIXED    
Severity: normal CC: gjcarneiro, mathieu.lacage
Priority: P5    
Version: pre-release   
Hardware: All   
OS: All   
Attachments: a patch
another patch
patch using xxx_LIBRARY_PATH

Description Faker Moatamri 2009-04-17 12:31:28 UTC
The build works with gcc 4.4.0 but the checktests and the regression tests doesn't pass in the optimized mode.
Comment 1 Mathieu Lacage 2009-04-20 02:52:56 UTC
On a system with multiple compilers installed, we need to link explicitely against the compiler's c++ library:

For example:
bash-3.2$ g++-4.4.0 -print-file-name=libstdc++.so
/usr/local/lib/gcc/x86_64-unknown-linux-gnu/4.4.0/../../../../lib64/libstdc++.so

Would it be possible/would it make sense to use -rpath with the above command to link against the c++ stl library with waf ?
Comment 2 Gustavo J. A. M. Carneiro 2009-04-20 13:35:18 UTC
Created attachment 421 [details]
a patch

Patch implementing Mathieu's suggestion.  No idea if this solves the problem.  I don't think I have the correct environment to test.
Comment 3 Gustavo J. A. M. Carneiro 2009-04-20 13:40:19 UTC
Created attachment 422 [details]
another patch

Then again, Mathieu says rpath, so could be this patch instead.
Comment 4 Gustavo J. A. M. Carneiro 2009-04-20 13:42:43 UTC
Created attachment 423 [details]
patch using xxx_LIBRARY_PATH

Then again, if this works it is probably more portable.
Comment 5 Mathieu Lacage 2009-04-21 03:59:07 UTC
changeset: 2e79cbd62d28