From help-octave-request at bevo dot che dot wisc dot edu Fri Sep 1 16:35:56 2000 Subject: FreeBSD linking bug From: Nimrod Mesika To: help-octave at bevo dot che dot wisc dot edu Date: Fri, 01 Sep 2000 23:28:55 +0200 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 -----------------------------------------------------------------------