Operating System - HP-UX
1833764 Members
3041 Online
110063 Solutions
New Discussion

ld: Unrecognized argument: -Wl,+s

 
SOLVED
Go to solution
Youlette Etienne_2
Regular Advisor

ld: Unrecognized argument: -Wl,+s

Hello Everyone:

I have Perl 5.6.1 installed, and am trying to compile DBD-Oracle-1.15. When I run make, I get:
ld: Unrecognized argument: -Wl,+s
Fatal error.
*** Error exit code 1

I have the latest ld linker patch isntalled PHSS_30968 (11.11. I have run out of ideas and am checking google also. Need help.
Thanks
If at first you don't succeed, change the rules!
4 REPLIES 4
A. Clay Stephenson
Acclaimed Contributor
Solution

Re: ld: Unrecognized argument: -Wl,+s

I suspect that you are doing a 64-bit compile/link and -s is only valid for 32-bit
links. Man ld for details.
If it ain't broke, I can fix that.
Indira Aramandla
Honored Contributor

Re: ld: Unrecognized argument: -Wl,+s

Yes I agree with S. Clay. +s option is ignored for 32-bit links. It turns on standard mode, which is the default in 64-bit mode.


Indira A
Never give up, Keep Trying
Ermin Borovac
Honored Contributor

Re: ld: Unrecognized argument: -Wl,+s

Option in this format should be passed to compiler (cc or gcc), not linker (ld).

cc -Wl,+s

tells cc to pass '+s' option to ld

Linker (ld) doesn't understand -Wl,+s. It should simply be called with '+s'.

I'm not sure why you got this error, but you can try editing Makefile and changing '-Wl,+s' to '+s'. Then issue make to compile.
ranganath ramachandra
Esteemed Contributor

Re: ld: Unrecognized argument: -Wl,+s

you should be using "+s" instead of "-Wl,+s".

possibly a bad makefile or a bad configuration: the makefile may expect that you specify a compiler driver where you specified the linker.

as ermin says, you need the "-Wl," part only when you are using the compiler driver to link and not when using the linker directly.

the +s option for PA32 enables SHLIB_PATH lookup which is disabled by default (this does not imply a complete standard mode - there is no standard mode in PA32).

the +s option is not ignored in PA64 links: you could have a +compat link with +s so that while the executable is "+compat" in other respects (depth-first search etc), SHLIB_PATH/LD_LIBRARY_PATH lookup is enabled.
 
--
ranga
hp-ux 11i v3[i work for hpe]

Accept or Kudo