Mercury Bugs - mercury
View Issue Details
0000397mercuryBugpublic2015-10-13 17:432015-10-20 18:00
Reporterwangp 
Assigned Towangp 
PrioritynormalSeverityminorReproducibilityalways
StatusresolvedResolutionfixed 
PlatformOSOS Version
Product Version 
Target VersionFixed in Version 
Summary0000397: Clang fails to deal with -R command line parameter
DescriptionNot necessarily our bug, but clang 3.4 does not like -R/foo:

clang -R/foo --version
clang: error: unknown argument: '-R/foo'
FreeBSD clang version 3.4.1 (tags/RELEASE_34/dot1-final 208032) 20140512
Target: i386-unknown-freebsd10.1
Thread model: posix

https://llvm.org/bugs/show_bug.cgi?id=18164
TagsNo tags attached.
Attached Files

Notes
(0000851)
juliensf   
2015-10-14 10:08   
Presumably it is happy with -Wl,-rpath though? We may need to make the definitions of SHLIB_RPATH_OPT etc in the configure script dependent on the C compiler type on the affected platforms.
(0000853)
wangp   
2015-10-14 12:38   
Yes, all of these work. The linker is GNU ld.

-Wl,-R
-Wl,-rpath
-rpath

so we can probably just remove lines in configure.ac that force "-R" for FreeBSD.
(0000854)
juliensf   
2015-10-14 15:14   
Yep, that would work for GCC as well. I assume you have a FreeBSD system set up to test this on?

Issue History
2015-10-13 17:43wangpNew Issue
2015-10-14 10:08juliensfNote Added: 0000851
2015-10-14 12:38wangpNote Added: 0000853
2015-10-14 15:14juliensfNote Added: 0000854
2015-10-20 18:00wangpStatusnew => resolved
2015-10-20 18:00wangpResolutionopen => fixed
2015-10-20 18:00wangpAssigned To => wangp