This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.
Summary: | Wrong rpath option added when link libraries added using | ||
---|---|---|---|
Product: | cnd | Reporter: | snunez |
Component: | Toolchain | Assignee: | Alexander Simon <alexvsimon> |
Status: | RESOLVED FIXED | ||
Severity: | normal | CC: | snunez |
Priority: | P3 | ||
Version: | 8.0.2 | ||
Hardware: | PC | ||
OS: | Linux | ||
Issue Type: | DEFECT | Exception Reporter: |
Description
snunez
2015-05-21 04:10:24 UTC
Possible problems: 1) doesn't work on Solaris. For example: https://mail.haskell.org/pipermail/ghc-devs/2013-January/000151.html 2) by default debug and run will fail with "./test2: error while loading shared libraries: libtest.so: cannot open shared object file: No such file or directory" error 1 ) I understand, this should be applied only for GNU on Linux. Maybe if using rpath or rpath-link could be configurable or taken from an environment variable if it exist. 2 ) This is because you need to set the lib path at LD_LIBRARY_PATH or ld.config. Using rpath as used right now allow you not to need define those settings, but generate a lib that reference a path that only exist on developement environment. Ther are other problems keeping rpath: Among that, rpath should appear only once in a compilation line, and as it is used right now, it appears many times, once for each libary referenced as a Project. Correction for what I said: rpath CAN be used more than one in a compile line. Note: All other linker library asociation ("Add Library" and "Add Library File") doesn't add any rpath link option, just add the -L and -l options. What I'd like to be able to do is to set RPATH as $ORIGIN/../lib as documented in http://man7.org/linux/man-pages/man8/ld.so.8.html fixed, change set:http://hg.netbeans.org/cnd-main/rev/da3a968ae73c Integrated into 'main-silver', will be available in build *201602180002* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress) Changeset: http://hg.netbeans.org/main-silver/rev/da3a968ae73c User: Alexander Simon <alexvsimon@netbeans.org> Log: fixed Bug #252516 Wrong rpath option added when link libraries added using "Add Project" Integrated into 'main-silver', will be available in build *201602190002* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress) Changeset: http://hg.netbeans.org/main-silver/rev/ea948753cfc4 User: Alexander Simon <alexvsimon@netbeans.org> Log: fixed Bug #252516 Wrong rpath option added when link libraries added using "Add Project" - extract origin constant |