This is the mail archive of the
mailing list for the binutils project.
hpux -B nonfatal equivalent
- From: Marco Colombo <linux at esiway dot net>
- To: binutils at sourceware dot org
- Date: Fri, 21 Mar 2014 19:38:09 +0100
- Subject: hpux -B nonfatal equivalent
- Authentication-results: sourceware.org; auth=none
I'm porting an old software from HPUX to linux. In LDFLAGS there's the
option '-B nonfatal', which, in my understanding, allows unresolved
symbols to be ignored until runtime.
In particular I'm having troubles with one shared lib, which does have a
bunch of unresolved symbols. I tried with --allow-shlib-undefined, that
produces an executable (instead of stopping with an error), but the
unresolved symbol error appears as soon as I try and run the it. In HPUX
it seems that unresolved symbols go undetected until the program tries
to access them. In this case, the program never does, and it runs just fine.
While I smell some sort of bad programming (I think that the original
programmers thought it was wise to move common functions used by many
different programs into one library, including a few of them that refer
to _global_ variables) I'm not really allowed to change the source (so
far it was a matter of adding some missing includes).
So I wonder if there's any flag in GNU ld to get the same effect of -B
nonfatal under HPUX.