help-octave
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

FreeBSD linking bug


From: Nimrod Mesika
Subject: FreeBSD linking bug
Date: Fri, 01 Sep 2000 23:28:55 +0200
User-agent: Mutt/1.2i

A week or two ago I posted information about a problem with .oct
files and FreeBSD. jwe correctly identified the problem - turned out
global variables' constructors were not being executed when the
module was loaded.

Seems like the problem is in 'mkoctfile'. On my machine it has the
following lines:

: ${SH_LDFLAGS="-Bshareable"}

...and finally...

$SH_LD $SH_LDFLAGS -o $octfile $objfiles $ldflags


Replacing the above lines with:


: ${SH_LDFLAGS="-shared"}

..and..

$CC    $SH_LDFLAGS -o $octfile $objfiles $ldflags

Solves the problem. I'm not much of an expert in shared libraries so
I can't really tell why using $SH_LD does not work (probably
another option that the C compiler automatically passes to the
linker).


-- 
Nimrod.
http://www.geocities.com/rodd_27



-----------------------------------------------------------------------
Octave is freely available under the terms of the GNU GPL.

Octave's home on the web:  http://www.che.wisc.edu/octave/octave.html
How to fund new projects:  http://www.che.wisc.edu/octave/funding.html
Subscription information:  http://www.che.wisc.edu/octave/archive.html
-----------------------------------------------------------------------



reply via email to

[Prev in Thread] Current Thread [Next in Thread]