Bugzilla – Full Text Bug Listing |
Summary: | wrong RPATH in build.py | ||
---|---|---|---|
Product: | ns-3 | Reporter: | Nicola Baldo <baldo> |
Component: | build system | Assignee: | ns-bugs <ns-bugs> |
Status: | RESOLVED INVALID | ||
Severity: | critical | Keywords: | bug |
Priority: | P1 | ||
Version: | pre-release | ||
Hardware: | PC | ||
OS: | Linux | ||
Attachments: | patch implementing solution proposed in comment #2 |
Description
Nicola Baldo
2006-10-21 09:15:13 UTC
You are supposed to invoke binaries from the top-level directory and not from the 'bin' directory: The following will work: ./build-dir/opt-shared/bin/run-tests It was done that way to save you from having to cd to the correct directory. I could be convinced to change the current way of doing this to use absolute paths which would allow you to invoke the binary from any directory but this would break the build if you move around the source tree. A better solution is then to use $ORIGIN symbol (the "slightly more complex approach" I mentioned above) which has the benefits of being independent of the working directory: baldo@pcsignet08:/locale/baldo/src/ns-3/build-dir/dbg-shared/bin$ objdump -p sample-packet | grep RPATH RPATH $ORIGIN/../lib baldo@pcsignet08:/locale/baldo/src/ns-3/build-dir/dbg-shared/bin$ ./sample-test PASS Callback PASS ReferenceList PASS My baldo@pcsignet08:/locale/baldo/src/ns-3$ ./build-dir/dbg-shared/bin/sample-test PASS Callback PASS ReferenceList PASS My Created attachment 1 [details] patch implementing solution proposed in comment #2 I applied a patch similar to the one you suggested. Do you have any idea whether or not your approach will work also on OSX ? (I don't have a system to test it on) thanks ! For reference, I found the following: http://www.flipcode.com/cgi-bin/fcarticles.cgi?show=63919 which seems to imply that ORIGIN will not work but that something else will. we use waf to build the code so, the scons scripts are dead. |