John Tytgat wrote:

And as soon as we've convinced ourselves the shared libraries are working
for a decent set of real live programs (and a FF release with shared
library would be very convincing ;-)), we make a release with that part of
the functionality too.

I got it to build with a minimum of hacks, but I ran into various
issues.  wrt to the other post on !GCC, I think the contents of
my release-area was stale (as in, by many months - it still contain
the older DSO-Libs app and some bogus generated libraries) and had to be
cleaned out.

Hello world works ok when compiled with dynamic UnixLib, however:

*gcc -o hello helloworld.c -ldl
ADFS::Puffin.$.Temp.Examples.C.hello: can't load library 'libdl.so.1'

Which is indeed true enough - it's actually libdl/1/so.  If I create
a symlink (and the 'ln' utility incidentally only understands RISC OS
filenames), then I get:

*hello
ADFS::Puffin.$.Temp.Examples.C.hello: 'SharedLibs:lib.libdl/so/1' is missing the som___got symbol
ADFS::Puffin.$.Temp.Examples.C.hello: can't load library 'libdl.so.1'

The only way I could get SOManager to consider the Firefox shared
libraries was to put them in !SharedLibs.lib.  I tried setting:

LD_LIBRARY_PATH=Firefox: as part of LD$Env

firefox-binSOLib$Path to Firefox: (similar to GCC)

All to no avail.  My final concern is about the use of -fPIC, which
the documentation says not to use (but doesn't mention why other
than it won't work).  The problem here is that its use is widespread in
shared library building systems, so it generally is needed.  Its
accidental use is almost certain, although the linker should complain if
there's any mixed usage.  Either -fPIC needs to do nothing, or generate
an error.



_______________________________________________
GCCSDK mailing list [email protected]
Bugzilla: http://www.riscos.info/bugzilla/index.cgi
List Info: http://www.riscos.info/mailman/listinfo/gcc
Main Page: http://www.riscos.info/index.php/GCCSDK

Reply via email to