# HG changeset patch # User jwe # Date 850199631 0 # Node ID fa7dd5fc7c59a0c4445e0a7946bc03bc4817e8c9 # Parent 6e1d6e02fd8cbf74de57300bc26274c27ced96e0 [project @ 1996-12-10 06:30:41 by jwe] diff --git a/NEWS b/NEWS --- a/NEWS +++ b/NEWS @@ -9,13 +9,19 @@ do work, but they print an annoying warning message to try to get people to switch to using gset.) + * Dynamic linking works on more systems using dlopen() and friends + (most modern Unix systems) or shl_load() and friends (HP/UX + systems). A simple example is provided in examples/hello.cc. + For this feature to work, you must configure Octave with + --enable-shared. You may also need to have a shared-library + version of libg++ and libstdc++. + * New data types can be added to Octave by writing a C++ class. On systems that support dynamic linking, new data types can be added to an already running Octave binary. A simple example appears in the file examples/make_int.cc. Other examples are the standard Octave data types defined in the files src/ov*.{h,cc} and - src/op-*.cc. [This feature should be better documented by the - time 2.0 is released]. + src/op-*.cc. * The configure option --enable-bounds-check turns on bounds checking on element references for Octave's internal array and diff --git a/README b/README --- a/README +++ b/README @@ -2,7 +2,7 @@ Copyright (C) 1996 John W. Eaton -Last updated: Thu Nov 7 17:17:25 1996 +Last updated: Tue Dec 10 00:20:31 1996 Overview -------- @@ -36,18 +36,20 @@ compile from source (significantly less if you don't compile with debugging symbols or create shared libraries). Once installed, Octave requires approximately 65MB of disk space (again, considerably less if -the binaries and libraries do not include debugging symbols). +you don't build shared libraries or the binaries and libraries do not +include debugging symbols). In order to build Octave, you will need a current version of g++, -libg++, and GNU make. +libg++, and GNU make. Recommended versions are + + g++ 2.7.2 or 2.7.2.1 + libg++ 2.7.1 or 2.7.2 + make 3.75 YOU MUST HAVE GNU MAKE TO COMPILE OCTAVE. Octave's Makefiles use features of GNU Make that are not present in other versions of make. GNU Make is very portable and easy to install. -As of version 2.0, you must have G++ 2.7.2 or later to compile -Octave. - See the notes in the files INSTALL and INSTALL.OCTAVE for more specific installation instructions, including directions for installing Octave from a binary distribution. @@ -55,17 +57,16 @@ The file BUGS contains a recommended procedure for reporting bugs, as well as a list of known problems and possible fixes. -Binary Distributions --------------------- +Documentation +------------- -Binary copies of Octave are now distributed for several popular Unix -systems. To save disk space, the complete source code for Octave is -not included in the binary distributions, but should be available in -the same place as the binaries. If not, please contact -bug-octave@bevo.che.wisc.edu. - -The file INSTALL.OCTAVE contains specific installation instructions, -for installing Octave from a binary distribution. +Octave's manual has been revised for version 2.0, but it is lagging a +bit behind the development of the software. In particular, there is +currently no complete documentation of the C++ class libraries or the +support for dynamic linking and user-defined data types. If you +notice ommissions or inconsistencies, please report them as bugs to +bug-octave@bevo.che.wisc.edu. Specific suggestions for ways to +improve Octave and its documentation are always welcome. Implemenation ------------- diff --git a/src/ChangeLog b/src/ChangeLog --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,3 +1,14 @@ +Tue Dec 10 00:31:13 1996 John W. Eaton + + * SLList-expr.cc SLList-misc.cc SLList-plot.cc SLList-str.cc + SLList-tc.cc SLList-tm.cc SLList.h SLStack-i.cc SLStack-pc.cc + SLStack-str.cc SLStack-sym.cc SLStack-tok.cc SLStack-ue.cc + SLStack-ui.cc, pt-mat.cc: Include Stack.h, Stack.cc, SLStack.cc, + and SLList.cc as necessary. + + * Stack.cc, SLStack.cc, SLList.cc: New files. + * Makefile.in (SOURCES): Add them to the list. + Mon Dec 9 12:03:45 1996 John W. Eaton * Makefile.in (install-bin): Use $(EXE) suffix so install will diff --git a/src/Makefile.in b/src/Makefile.in --- a/src/Makefile.in +++ b/src/Makefile.in @@ -90,10 +90,9 @@ op-str-str.h TI_SRC := Array-oc.cc Array-os.cc Array-tc.cc Map-fnc.cc Map-tc.cc \ - SLList-expr.cc SLList-misc.cc SLList-plot.cc SLList-str.cc \ - SLList-tc.cc SLList-tm.cc SLStack-i.cc SLStack-pc.cc \ - SLStack-str.cc SLStack-sym.cc SLStack-tok.cc SLStack-ue.cc \ - SLStack-ui.cc + SLList-expr.cc SLList-misc.cc SLList-plot.cc SLList-tc.cc \ + SLList-tm.cc SLStack-i.cc SLStack-pc.cc SLStack-str.cc \ + SLStack-sym.cc SLStack-tok.cc SLStack-ue.cc SLStack-ui.cc TI_OBJ := $(patsubst %.cc, %.o, $(TI_SRC)) @@ -104,10 +103,11 @@ endif endif -SOURCES := BaseSLList.cc Map.cc data.cc defaults.cc \ - dirfns.cc dynamic-ld.cc error.cc file-io.cc fn-cache.cc gripes.cc \ - help.cc input.cc lex.l load-save.cc mappers.cc oct-fstrm.cc \ - oct-hist.cc oct-iostrm.cc oct-map.cc oct-obj.cc oct-prcstrm.cc \ +SOURCES := BaseSLList.cc Map.cc SLList.cc SLStack.cc Stack.cc \ + data.cc defaults.cc dirfns.cc dynamic-ld.cc error.cc \ + file-io.cc fn-cache.cc gripes.cc help.cc input.cc lex.l \ + load-save.cc mappers.cc oct-fstrm.cc oct-hist.cc \ + oct-iostrm.cc oct-map.cc oct-obj.cc oct-prcstrm.cc \ oct-procbuf.cc oct-stdstrm.cc oct-stream.cc oct-strstrm.cc \ pager.cc parse.y pr-output.cc procstream.cc pt-base.cc \ pt-cmd.cc pt-const.cc pt-exp-base.cc pt-exp.cc pt-fcn.cc \ diff --git a/src/SLList-expr.cc b/src/SLList-expr.cc --- a/src/SLList-expr.cc +++ b/src/SLList-expr.cc @@ -27,6 +27,7 @@ #endif #include "SLList.h" +#include "SLList.cc" #include "pt-exp.h" #include "pt-fvc.h" diff --git a/src/SLList-misc.cc b/src/SLList-misc.cc --- a/src/SLList-misc.cc +++ b/src/SLList-misc.cc @@ -27,6 +27,7 @@ #endif #include "SLList.h" +#include "SLList.cc" #include "pt-exp.h" #include "ov.h" diff --git a/src/SLList-plot.cc b/src/SLList-plot.cc --- a/src/SLList-plot.cc +++ b/src/SLList-plot.cc @@ -27,6 +27,7 @@ #endif #include "SLList.h" +#include "SLList.cc" #include "pt-plot.h" diff --git a/src/SLList-str.cc b/src/SLList-str.cc --- a/src/SLList-str.cc +++ b/src/SLList-str.cc @@ -27,6 +27,7 @@ #endif #include "SLList.h" +#include "SLList.cc" #include diff --git a/src/SLList-tc.cc b/src/SLList-tc.cc --- a/src/SLList-tc.cc +++ b/src/SLList-tc.cc @@ -27,6 +27,7 @@ #endif #include "SLList.h" +#include "SLList.cc" #include "ov.h" diff --git a/src/SLList-tm.cc b/src/SLList-tm.cc --- a/src/SLList-tm.cc +++ b/src/SLList-tm.cc @@ -27,6 +27,7 @@ #endif #include "SLList.h" +#include "SLList.cc" #include "pt-mat.h" diff --git a/src/SLList.h b/src/SLList.h --- a/src/SLList.h +++ b/src/SLList.h @@ -19,6 +19,10 @@ #ifndef _SLList_h #define _SLList_h 1 +#if defined (__GNUG__) +#pragma interface +#endif + #include #include @@ -47,7 +51,7 @@ SLList(const SLList& a) : BaseSLList() { copy(a); } SLList& operator = (const SLList& a) { BaseSLList::operator=((const BaseSLList&) a); return *this; } - ~SLList (void) { clear (); } + ~SLList (void); Pix prepend(const T& item) {return BaseSLList::prepend(&item);} Pix append(const T& item) {return BaseSLList::append(&item);} diff --git a/src/SLStack-i.cc b/src/SLStack-i.cc --- a/src/SLStack-i.cc +++ b/src/SLStack-i.cc @@ -27,13 +27,19 @@ #endif #include "SLList.h" +#include "SLList.cc" + +#include "Stack.h" +#include "Stack.cc" #include "SLStack.h" +#include "SLStack.cc" template class SLNode; template class SLList; template class Stack; + template class SLStack; /* diff --git a/src/SLStack-pc.cc b/src/SLStack-pc.cc --- a/src/SLStack-pc.cc +++ b/src/SLStack-pc.cc @@ -27,13 +27,19 @@ #endif #include "SLList.h" +#include "SLList.cc" + +#include "Stack.h" +#include "Stack.cc" #include "SLStack.h" +#include "SLStack.cc" template class SLNode; template class SLList; template class Stack; + template class SLStack; /* diff --git a/src/SLStack-str.cc b/src/SLStack-str.cc --- a/src/SLStack-str.cc +++ b/src/SLStack-str.cc @@ -26,15 +26,22 @@ #include #endif +#include "SLList.h" +#include "SLList.cc" + +#include "Stack.h" +#include "Stack.cc" + #include "SLStack.h" +#include "SLStack.cc" #include -// We already have SLList, so we don't need to make them here. +template class SLNode; +template class SLList; -// template class SLNode; -// template class SLList; template class Stack; + template class SLStack; /* diff --git a/src/SLStack-sym.cc b/src/SLStack-sym.cc --- a/src/SLStack-sym.cc +++ b/src/SLStack-sym.cc @@ -27,8 +27,13 @@ #endif #include "SLList.h" +#include "SLList.cc" + +#include "Stack.h" +#include "Stack.cc" #include "SLStack.h" +#include "SLStack.cc" #include "symtab.h" @@ -36,12 +41,14 @@ extern template class SLList; extern template class Stack; + extern template class SLStack; template class SLNode; template class SLList; template class Stack; + template class SLStack; /* diff --git a/src/SLStack-tok.cc b/src/SLStack-tok.cc --- a/src/SLStack-tok.cc +++ b/src/SLStack-tok.cc @@ -27,8 +27,13 @@ #endif #include "SLList.h" +#include "SLList.cc" + +#include "Stack.h" +#include "Stack.cc" #include "SLStack.h" +#include "SLStack.cc" #include "token.h" @@ -36,6 +41,7 @@ template class SLList; template class Stack; + template class SLStack; /* diff --git a/src/SLStack-ue.cc b/src/SLStack-ue.cc --- a/src/SLStack-ue.cc +++ b/src/SLStack-ue.cc @@ -27,8 +27,13 @@ #endif #include "SLList.h" +#include "SLList.cc" + +#include "Stack.h" +#include "Stack.cc" #include "SLStack.h" +#include "SLStack.cc" #include "unwind-prot.h" @@ -36,6 +41,7 @@ template class SLList; template class Stack; + template class SLStack; /* diff --git a/src/SLStack-ui.cc b/src/SLStack-ui.cc --- a/src/SLStack-ui.cc +++ b/src/SLStack-ui.cc @@ -27,13 +27,19 @@ #endif #include "SLList.h" +#include "SLList.cc" + +#include "Stack.h" +#include "Stack.cc" #include "SLStack.h" +#include "SLStack.cc" template class SLNode; template class SLList; template class Stack; + template class SLStack; /* diff --git a/src/SLStack.cc b/src/SLStack.cc --- a/src/SLStack.cc +++ b/src/SLStack.cc @@ -27,6 +27,7 @@ #include "SLStack.h" template +SLStack& SLStack::operator = (const SLStack& s) { if (this != &s) diff --git a/src/SLStack.h b/src/SLStack.h --- a/src/SLStack.h +++ b/src/SLStack.h @@ -36,6 +36,10 @@ #if !defined (_SLStack_h) #define _SLStack_h 1 +#if defined (__GNUG__) +#pragma interface +#endif + #include "SLList.h" #include "Stack.h" @@ -55,11 +59,7 @@ ~SLStack (void) { } - SLStack& operator = (const SLStack& s) - { - p = s.p; - return *this; - } + SLStack& operator = (const SLStack& s); void push (const T& item) { p.prepend (item); } diff --git a/src/Stack.h b/src/Stack.h --- a/src/Stack.h +++ b/src/Stack.h @@ -36,6 +36,10 @@ #if !defined (_Stack_h) #define _Stack_h 1 +#if defined (__GNUG__) +#pragma interface +#endif + template class Stack @@ -58,6 +62,7 @@ virtual void clear (void) = 0; void error (const char *msg); + virtual int OK (void) = 0; }; diff --git a/src/pt-mat.cc b/src/pt-mat.cc --- a/src/pt-mat.cc +++ b/src/pt-mat.cc @@ -247,6 +247,9 @@ ::warning ("%s near line %d, column %d", msg, l, c); } +#include "SLList.h" +#include "SLList.cc" + template class SLNode; template class SLList;