changeset 3167:d609b993be3b

[project @ 1998-04-17 04:41:59 by jwe]
author jwe
date Fri, 17 Apr 1998 04:42:03 +0000
parents c3409a0cafa8
children 1c267910655d
files PROJECTS README.Windows scripts/ChangeLog scripts/audio/loadaudio.m scripts/audio/playaudio.m scripts/audio/record.m scripts/audio/saveaudio.m src/ChangeLog src/dynamic-ld.cc test/ChangeLog test/octave.test/index/dfi-f/index.exp test/octave.test/index/dfi-f/m-2.m
diffstat 12 files changed, 107 insertions(+), 25 deletions(-) [+]
line wrap: on
line diff
--- a/PROJECTS
+++ b/PROJECTS
@@ -260,8 +260,6 @@
 
     will work as expected.
 
-  * Warn about M-files with timestamps in the future.
-
   * Fix the parser so that
 
       function foo ()
@@ -350,9 +348,7 @@
   * Recursive problems.
 
   * Improve the way ignore_function_time_stamp works to allow
-    selecting by individual directories or functions.  Also,
-    optionally allow checking only once between each prompt instead of
-    every time the function is called.
+    selecting by individual directories or functions.
 
   * Make it possible to ask exist() to only look for certain classes
    of variables, functions, files, etc. rather than always looking for
--- a/README.Windows
+++ b/README.Windows
@@ -1,6 +1,6 @@
-Octave has been ported to Windows NT and Windows 95 using the beta 18
-release of the Cygnus gnu-win32 tools.  If you would like to volunteer
-to work on improving this port, please contact bug-octave@bevo.che.wisc.edu.
+Octave has been ported to Windows NT and Windows 95 using the gnu-win32
+tools from Cygnus Support.  If you would like to volunteer to work on
+improving this port, please contact bug-octave@bevo.che.wisc.edu.
 
 The directory ftp://ftp.che.wisc.edu/pub/octave/BINARIES/gnu-win32
 contains a binary distribution of Octave for Windows NT/95 along with
@@ -10,15 +10,9 @@
 Here is a list of current problems (and workarounds, where available).
 
 * To compile and install Octave on a Windows NT/95 system,
-  you will need to get the beta 18 release of the gnu-win32 tools.
+  you will need to get the beta 19 release of the gnu-win32 tools.
   They are available from ftp://ftp.cygnus.com/pub/gnu-win32.
 
-* There is a conflict between /gnu-win32/b18/include/g++/String.h
-  and /gnu-win32/b18/H-i386-cygwin32/i386-cygwin32/include/string.h.
-  You should rename or remove /gnu-win32/b18/include/g++/String.h.
-  (These file names assume that you have installed the gnu-win32 tools
-  in /gnu-win32/b18).
-
 * You will need to have f2c and libf2c.a or g77 installed.  I would
   recommend using g77.  Mumit Khan has directions for building g77 at
   http://www.xraylith.wisc.edu/~khan/software/gnu-win32/g77.html.
@@ -29,6 +23,79 @@
   to work.  You can get it from any GNU archive site, including 
   ftp://ftp.gnu.org/pub/gnu/termcap-1.3.tar.gz.
 
+* It is possible to cross-compile Octave for Windows NT/95 systems.
+  On the same hardware, it's generally much faster to use gcc as a
+  cross compiler under Linux than as a native compiler under Windows.
+
+  Here are some instructions for building a cross version of gcc and
+  then using it to compile Octave.  I've done this using a Linux
+  system as the host, but it should work equally well on other systems
+  that can run gcc).
+
+    + install cdk on your Windows system
+
+    + build a cross version of binutils:
+
+      tar zxf binutils-2.9.tar.gz
+      cd binutils-2.9
+      ./configure --target=i386-pc-cygwin32 --prefix=/usr/local/cross-gcc
+      make
+      make install
+
+      (You can choose whatever value for prefix that you prefer, of
+      course, just remember to also make the corresponding changes in the
+      following steps as well.)
+
+    + copy libraries and include files from cdk.  You'll need the
+      library files from the following directory trees:
+
+	b19/H-i386-pc-cygwin32/lib
+	b19/H-i386-pc-cygwin32/i386-cygwin32/lib
+
+      Copy them to /usr/local/cross-gcc/i386-pc-cygwin32/lib.
+
+      You'll also need the include files from the following directory
+      trees:
+
+	b19/include
+	b19/H-i386-pc-cygwin32/include
+
+      Copy them to /usr/local/cross-gcc/i386-pc-cygwin32/include.
+
+    + build cross version of egcs:
+
+      tar zxf egcs-1.0.2.tar.gz
+      cd egcs-1.0.2
+      export PATH=/usr/local/cross-gcc/bin:$PATH
+      ./configure --target=i386-pc-cygwin32 --prefix=/usr/local/cross-gcc
+      make
+      make install
+
+    + cross-compile libtermcap:
+
+      export PATH=/usr/local/cross-gcc/i386-pc-cygwin32/bin:$PATH
+      tar zxf termcap-1.3.tar.gz
+      cd termcap-1.3
+      ./configure --host=i386-pc-cygwin3
+      make
+      cp termcap.h /usr/local/cross-gcc/i386-pc-cygwin32/include
+      cp libtermcap.a /usr/local/cross-gcc/i386-pc-cygwin32/lib
+
+    + cross-compile Octave using the compiler you just built:
+
+      export PATH=/usr/local/cross-gcc/i386-pc-cygwin32/bin:$PATH
+      tar zxf octave-2.0.12.tar.gz
+      cd octave-2.0.10
+      ./configure --host=i386-pc-cygwin3
+      make
+
+    + make a binary distribution to copy to your Windows system:
+
+      make -f octMakefile binary-dist
+
+    + copy the binary distribution to your Windows system and install
+      using the intall-octave shell script
+
 * Octave requires gnuplot for plotting, but the normal Windows version
   of gnuplot will not work because it only reads from the GUI and refuses
   to read input from stdin.  Mumit Khan has written a patch that fixes
@@ -59,4 +126,4 @@
 University of Wisconsin-Madison
 Department of Chemical Engineering
 
-Sat Feb 14 13:12:19 1998
+Thu Apr 16 23:39:13 1998
--- a/scripts/ChangeLog
+++ b/scripts/ChangeLog
@@ -1,3 +1,11 @@
+Wed Apr 15 11:16:01 1998  John W. Eaton  <jwe@bevo.che.wisc.edu>
+
+	* audio/loadaudio.m: Accept "pcm" as another file extension for
+	linear encoding.
+
+	* audio/saveaudio.m, audio/loadaudio.m, audio/playaudio.m,
+	audio/record.m: Open files in binary mode.
+
 Fri Apr 10 10:46:21 1998  John W. Eaton  <jwe@bevo.che.wisc.edu>
 
 	* miscellaneous/dump_prefs.m: Use string array for list of values.
--- a/scripts/audio/loadaudio.m
+++ b/scripts/audio/loadaudio.m
@@ -23,8 +23,8 @@
 ## Default value for the "ext" argument, which has to be written
 ## without the initial ".", is "lin".
 ## Currently, the following audio formats are supported:
-## *) mu-law encoding with extension "mu", "au" or "snd"
-## *) linear encoding with extension "lin" or "raw"
+## *) mu-law encoding with extension "mu", "au", or "snd"
+## *) linear encoding with extension "lin", "pcm", or "raw"
 ##
 ## The `bit' argument can be either 8 (default) or 16.
 ## Depending on the value of bit, linearly encoded files are
@@ -53,9 +53,9 @@
   endif
 
   name = [name, ".", ext];
-  num = fopen (name, "r");
+  num = fopen (name, "rb");
 
-  if (strcmp (ext, "lin") || strcmp (ext, "raw"))
+  if (strcmp (ext, "lin") || strcmp (ext, "raw") || strcmp (ext, "pcm"))
     if (bit == 8)
       [Y, c] = fread (num, inf, "uchar");
       X = Y - 127;
--- a/scripts/audio/playaudio.m
+++ b/scripts/audio/playaudio.m
@@ -53,7 +53,7 @@
     X = name + 127;
     unwind_protect
       file = tmpnam ();
-      num = fopen (file, "w");
+      num = fopen (file, "wb");
       c = fwrite (num, X, "uchar");
       fclose (num);
       system (sprintf ("cat %s > /dev/dsp", file));
--- a/scripts/audio/record.m
+++ b/scripts/audio/record.m
@@ -47,7 +47,7 @@
 
     system (cmd);
 
-    num = fopen (file, "r");
+    num = fopen (file, "rb");
 
     [Y, c] = fread (num, sampling_rate * sec, "uchar");
 
--- a/scripts/audio/saveaudio.m
+++ b/scripts/audio/saveaudio.m
@@ -59,7 +59,7 @@
     endif
   endif
 
-  num = fopen ([name, ".", ext], "w");
+  num = fopen ([name, ".", ext], "wb");
 
   if (strcmp (ext, "lin") || strcmp (ext, "raw"))
     if (bit == 8)
--- a/src/ChangeLog
+++ b/src/ChangeLog
@@ -1,3 +1,7 @@
+Thu Apr 16 01:00:12 1998  John W. Eaton  <jwe@bevo.che.wisc.edu>
+
+	* dynamic-ld.cc: Only include dlfcn.h if HAVE_DLFCN_H.
+
 Wed Apr 15 01:03:05 1998  John W. Eaton  <jwe@bevo.che.wisc.edu>
 
 	* input.cc (Vlast_prompt_time): New global variable.
--- a/src/dynamic-ld.cc
+++ b/src/dynamic-ld.cc
@@ -34,7 +34,9 @@
 extern "C"
 {
 #if defined (WITH_DL)
+#if defined (HAVE_DLFCN_H)
 #include <dlfcn.h>
+#endif
 #ifndef RTLD_LAZY
 #define RTLD_LAZY 1
 #endif
--- a/test/ChangeLog
+++ b/test/ChangeLog
@@ -1,3 +1,8 @@
+Wed Apr 15 15:23:43 1998  John W. Eaton  <jwe@bevo.che.wisc.edu>
+
+	* octave.test/index/dfi-f/m-2.m, octave.test/index/dfi-f/index.exp:
+	Expect this test to succed now.
+
 Thu Mar  5 20:35:26 1998  John W. Eaton  <jwe@bevo.che.wisc.edu>
 
 	* octave.test/system/gmtime-1.m, octave.test/system/localtime-1.m:
--- a/test/octave.test/index/dfi-f/index.exp
+++ b/test/octave.test/index/dfi-f/index.exp
@@ -151,7 +151,7 @@
 do_test m-1.m
 
 set test index-m-2
-set prog_output "error:.*"
+set prog_output "ans = 1"
 do_test m-2.m
 
 set test index-m-3
--- a/test/octave.test/index/dfi-f/m-2.m
+++ b/test/octave.test/index/dfi-f/m-2.m
@@ -5,4 +5,4 @@
 a_col_2 = [2;4];
 a_row_1 = [1,2];
 a_row_2 = [3,4];
-a(:)
+all (a(:) == a_fvec)