# HG changeset patch # User Marco Atzeri # Date 1251985598 -7200 # Node ID e51c07d34b2f7f439192f152deca3d22206cf8e8 # Parent 5846c9c6ecd80a179ce4727d8044bf31d38df4a9 LD_PRELOAD definition and Cygwin documentation diff -r 5846c9c6ecd8 -r e51c07d34b2f ChangeLog --- a/ChangeLog Thu Sep 03 12:09:39 2009 +0200 +++ b/ChangeLog Thu Sep 03 15:46:38 2009 +0200 @@ -1,3 +1,7 @@ +2009-09-03 Marco Atzeri + * run-octave.in: modified LD_PRELOAD for cygwin compatibility + * README.Cygwin: added note on LD_PRELOAD + 2009-09-02 Marco Atzeri * Makeconf.in: changed order for SPARSE_LIBS diff -r 5846c9c6ecd8 -r e51c07d34b2f README.Cygwin --- a/README.Cygwin Thu Sep 03 12:09:39 2009 +0200 +++ b/README.Cygwin Thu Sep 03 15:46:38 2009 +0200 @@ -14,19 +14,6 @@ Marco Atzeri http://matzeri.altervista.org -An obsolete version of Octave (2.1.73) is part of the normal net -distribution of Cygwin, available from http://www.cygwin.com. Check -the package list in Cygwin's setup.exe installer if you would like to -try using it. However, 2.1.73 is unsupported and we STRONGLY -recommended that you use a more recent version of Octave. - -It should be possible to build Octave on Windows systems with Cygwin, -but at the time of this writing, there are some performance problems -related to the way C++ exception handling is implemented with the -default Cygwin compiler. This is a known problem with a long history. -If you would like to see this problem corrected, please search the -Cygwin mailing lists for threads related to "sjlj exception handling" -(or similar). There is also an "unofficial" Octave distribution for Cygwin: @@ -43,7 +30,38 @@ This binary is maintained by Tatsuro Matsuroka. +############################################################### +Note on LD_PRELOAD. + +Due to specific cygwin implementation the + +LD_PRELOAD="$liboctinterp $liboctave $libcruft" + +on run-octave.in does not work. +It must be replaced with + +LD_PRELOAD="$libcruft:$liboctave:$liboctinterp" + +Two reasons for the change: + +- the Space is not accepted as separator as in a MS + systems too many directories have names with space. + +- the DLL's must be loaded following the dependency, + $liboctinterp needs $liboctave that needs $libcruft. + +This solution should also work on all the other sytems. + +An alternative solution is to remove completely the LD_PRELOAD +definition and replace it with a PATH definition + +PATH="$builddir/src:$builddir/liboctave:$builddir/libcruft:$PATH" + +this second solution has less risk of address collision +between the various systems DLL's. + +################################################################ John W. Eaton address@hidden @@ -56,4 +74,4 @@ address@hidden Italy -Wed, 17 Sep 2008 14:16:03 EDT +Thu Sep 3 15:43:59 WEDT 2009 diff -r 5846c9c6ecd8 -r e51c07d34b2f run-octave.in --- a/run-octave.in Thu Sep 03 12:09:39 2009 +0200 +++ b/run-octave.in Thu Sep 03 15:46:38 2009 +0200 @@ -68,7 +68,7 @@ fi OCTAVE_SITE_INITFILE="$top_srcdir/scripts/startup/main-rcfile" \ -LD_PRELOAD="$liboctinterp $liboctave $libcruft" \ +LD_PRELOAD="$libcruft:$liboctave:$liboctinterp" \ %library_path_var%="$builddir/src:$builddir/liboctave:$builddir/libcruft:$%library_path_var%" \ exec $driver "$builddir/src/octave" --no-init-path --path="$LOADPATH" --image-path="$IMAGEPATH" --doc-cache-file="$DOCFILE" --info-file="$INFOFILE" "$@"