[plplot] 01/68: Import Debian changes 4.99j-8
Ole Streicher
olebole at moszumanska.debian.org
Mon Jul 10 07:38:23 UTC 2017
This is an automated email from the git hooks/post-receive script.
olebole pushed a commit to branch master
in repository plplot.
commit 82f6292bff3092a64f5217b39f34abfb7f1b8549
Author: Rafael Laboissiere <rafael at icp.inpg.fr>
Date: Fri Dec 11 22:20:08 1998 +0100
Import Debian changes 4.99j-8
plplot (4.99j-8) frozen unstable; urgency=low
* Recompiled with new release of libc6 (cf discussion in debian-devel
starting at
http://www.debian.org/Lists-Archives/debian-devel-9812/msg00998.html).
* Changed LDC in cf/sysconf.in to F77 (link with gcc complains because
it is lacking symbols from g77).
plplot (4.99j-7) frozen unstable; urgency=low, closes=29694 29704
* Set Conflicts relationship because files were moved around in the
latest release (Fixes Bug#29694, reported by Francesco Potorti`
<F.Potorti at cnuce.cnr.it>).
* Rebuilt to fix bogus dependency on tkstep8.0 (closes Bug#29704
reported by Matthias Klose <doko at cs.tu-berlin.de>)
plplot (4.99j-6) frozen unstable; urgency=low, closes=28534
* Uploading to frozen and unstable. (The previous release, 4.99j-5, was
rejected and I never reuploaded it.)
* Revamped debian/rules with use of variables for the debian dirs.
* Corrected typo in plplot-dev.README (closes Bug#28534).
* No compression of executable exemples in package plplot-doc.
* Fixed paths only for tk* scripts under /usr/doc/plplot/examples/tk.
* Fixed permission for plcolor.tcl and tkdemos.tcl.
* Fixed path for script x16.py (in plplot-doc).
* Moved library files libMatrix and libplplotdtk from plplot-tcl to
plplot.
* Moved info file from the plplot-doc package to the base package
plplot: this is the only documentation availalbe for the PLplot API.
* Fixed typo ("\*") in debhelper compress files.
* Fixed the problem related to the naming of shared libraries.
* Improved "Description:" fields in debian/control:
- Added "a scientific library" to first line (as suggested by
Christopher J. Fearnley <cjf at I21.com>).
- Included URL of PLplot homepage for each package.
* dh_shlibdeps does not act on package python-plplot.
* postinst and postrm test now for its argument.
* Rewrote README.Debian files.
plplot (4.99j-5) unstable; urgency=low
* Build with patch from Joao Cardoso <jcardoso at inescn.pt> for Octave
interface. The patch file is included in the debian/ directory.
* The orig.tar.gz and the diff.gz files were absent from 4.99j-4
upload. This is corrected now (bug reported by Paul Slootman
<paul at wau.mis.ah.nl>).
* Corrected sed expression for fixing the #! path in Python scripts
* Corrected bug in debian/compress file which was causing compression of
executable scripts under usr/doc/plplot/examples.
* Created plplot-tcl.postinst with a call to ldconfig, as plplot-tcl
includes shared libraries.
* Links to the shared library are now Policy compliant, i.e. their names
have only one number after .so.
* debain/shlibs.local is renamed to debian/shlibs, and
debian/plplot-tcl.shlibs is created.
* The scripts installed under usr/lib/tcl8.0/plplot/ should not be
executable.
plplot (4.99j-4) unstable; urgency=low
* debian/fix-tk-path.pl script is chmod'd in debian/rules files: now
fixes really first part of Bug#26935. Fix suggested by Paul Slootman
<paul at wau.mis.ah.nl>.
* debian/control: plplot-doc architecture is now "all" and is compiled
in the binary-indep section of debian/rules (suggested by
Paul Slootman <paul at wau.mis.ah.nl>). In order to do that, big changes
in debian/rules were done. Hope I did not screw things up.
* debian/rules: Corrected hideous bug in chmod mode switches: "chmod -x"
should be "chmod +x".
* Corrected some typos in debian/control, debian/copyright.
* cf/pkg_tcl.in: put number version in libMatrix.so (changed
README.Debian to document the fix).
* Moved libMatrix.so and libMatrix.a to plplot-dev package.
* Moved libMatrix.so.* and libplplotdtk.so.* to plplot-tcl package, and
made plplot-dev depend on plplot-tcl (changed debian/control file to
reflect the changes).
* I just realized that the upstream Python support works only with
python-1.4. I will fix this in the next release.
plplot (4.99j-3) unstable; urgency=low
* debian/rules: fixing Python path for python scripts is done now with a
sed command (get rid of debian/fix-python-path.pl). Suggested by
Matthias Klose <doko at cs.tu-berlin.de>.
* Change in upstream file utils/pltek.c: gcc 2.7.2.3 deprecates the use
of gets
* Corrected file debian/plplot-dev.files, in order to have the files
libMatrix.* included in the right package (plplot).
* Make plplot conflict with plplot-dev for versions previous to this
one, because of the move of libMatrix.*.
* Changed mode of debian/fix-tk-path.pl script to executable (fixes
first part of Bug#26935).
* Building is now done entirely under debian/tmp (fixes second part of
Bug#26935).
* Buildning now `with double' instead of `with float', as required for
the PLplot Octave interface. Also, all instances of `libplotf*' were
changed to `libplotd*' (in debian/rules and in debian/*.files).
* /usr/lib/libplplotdtk.so.* files moved to the plplot package (they were
in plplot-tcl): this fixes the problem of installing the plplot-dev
package with a dangling symlink.
* Removed file debian/dirs, which had no function at all.
* Tcl/Tk and Python scripts under /usr/doc/plplot/examples are now
executable.
* fix-tk-path.pl: corrected "/example/" -> "/examples/"
plplot (4.99j-2) unstable; urgency=low
* Using debhelper 0.93 : README.Debian files are installed automatically
by dh_installdocs
* Fixed some problems found by Matthias Klose <doko at cs.tu-berlin.de>.
Danke Matthias!
* Corrected typo in fix-pytho-path.pl, that made all python examples
have size equal to zero.
* examples/Makefile has now correct references to /usr directories
* Scripts under /usr/doc/plplot/examples are no more compressed
* Tk scripts under /usr/doc/examples/tk have now the right path after
`#!'
* Added dependency python-tk to python-plplot
plplot (4.99j-1) experimental; urgency=low
* Initial Release.
---
bindings/tcl/matrixInit.c | 3 +
bindings/tk/help_keys.tcl | 12 +-
bindings/tk/pldefaults.tcl | 2 +
bindings/tk/plframe.c | 3 +-
bindings/tk/plserver.tcl | 10 +-
bindings/tk/plwidget.tcl | 35 +-
cf/configure.in | 14 +-
cf/dist.in | 6 +-
cf/initlib.in | 7 +-
cf/inst_lib.in | 6 +-
cf/inst_lib_linux.in | 8 +-
cf/lib_sh.in | 2 +-
cf/lib_sh_linux.in | 31 +-
cf/{lib_sh_linux.in => lib_sh_sco.in} | 21 +-
cf/pkg_cxx.in | 4 +-
cf/pkg_python.in | 8 +-
cf/pkg_tcl.in | 12 +-
cf/pkg_tk.in | 6 +-
cf/sysconf.in | 10 +-
cf/sysloc.in | 38 +-
debian/README.debian | 80 +
debian/changelog | 144 ++
debian/compress | 9 +
debian/control | 69 +
debian/copyright | 92 ++
debian/fix-tk-path.pl | 21 +
debian/plm2gif.1 | 32 +
debian/plplot-980407-plplot-980407-new.patch | 2065 ++++++++++++++++++++++++++
debian/plplot-dev.README.Debian | 24 +
debian/plplot-dev.dirs | 2 +
debian/plplot-dev.files | 9 +
debian/plplot-doc.README.Debian | 13 +
debian/plplot-doc.compress | 9 +
debian/plplot-doc.files | 3 +
debian/plplot-tcl.README.Debian | 14 +
debian/plplot-tcl.dirs | 1 +
debian/plplot-tcl.files | 13 +
debian/plplot.dirs | 3 +
debian/plpr.1 | 25 +
debian/plrender.1 | 23 +
debian/plserver.1 | 28 +
debian/pltcl.1 | 21 +
debian/pltek.1 | 22 +
debian/postinst | 24 +
debian/postrm | 26 +
debian/python-exec-header | 1 +
debian/python-plplot.README.Debian | 16 +
debian/python-plplot.dirs | 2 +
debian/python-plplot.files | 1 +
debian/rules | 161 ++
drivers/plbuf.c | 3 +
drivers/tk.c | 30 +-
drivers/xwin.c | 4 +
examples/c/x17c.c | 316 +---
examples/c/x18c.c | 4 +-
include/plplot.h | 27 +
src/plargs.c | 6 +-
src/plctrl.c | 2 +-
src/plstripc.c | 354 +++++
src/plvpor.c | 12 +
utils/pltek.c | 6 +-
61 files changed, 3632 insertions(+), 323 deletions(-)
diff --git a/bindings/tcl/matrixInit.c b/bindings/tcl/matrixInit.c
index f7181da..c41afb6 100644
--- a/bindings/tcl/matrixInit.c
+++ b/bindings/tcl/matrixInit.c
@@ -8,6 +8,9 @@ int Matrix_Init( Tcl_Interp *interp ) {
Tcl_CreateCommand(interp, "matrix", Tcl_MatrixCmd,
(ClientData) NULL, (void (*)(ClientData)) NULL);
+#if ( TCL_MAJOR_VERSION == 7 && TCL_MINOR_VERSION > 4 ) // jc:
Tcl_PkgProvide(interp, "Matrix", "0.1");
+#endif
+
return TCL_OK;
}
diff --git a/bindings/tk/help_keys.tcl b/bindings/tk/help_keys.tcl
index 0bf6d1f..28da713 100644
--- a/bindings/tk/help_keys.tcl
+++ b/bindings/tk/help_keys.tcl
@@ -27,8 +27,18 @@ When a plframe widget has the input focus, keyboard input is relayed to
its remote TK driver. The default actions of the keyboard handler are as
follows:
-"Q" Terminate program
+ "Q" | <Ctrl-x> Terminate program
<Return> or <Page Down> Advance to the next page
+ "z" enter zoom (Cliking once zooms x 2)
+ "b" back zoom
+ "f" forward zoom
+ "z" reset zoom
+ "P" print
+ "s" save again
+ "5" scroll magnification factor ??
+ "1" scroll speed ??
+ <left><right><up><down> scroll after zoom
+ <Alt><key> increase scroll speed
The user code can supply its own keyboard handler, and thereby add to
or modify these actions (this is in fact what is done by plrender).
diff --git a/bindings/tk/pldefaults.tcl b/bindings/tk/pldefaults.tcl
index f422981..be075d2 100644
--- a/bindings/tk/pldefaults.tcl
+++ b/bindings/tk/pldefaults.tcl
@@ -239,6 +239,8 @@ proc pldefaults {} {
# Turn them into an empty string to disable.
global key_zoom_select; set key_zoom_select "z"
+ global key_zoom_back; set key_zoom_back "b"
+ global key_zoom_forward; set key_zoom_forward "f"
global key_zoom_reset; set key_zoom_reset "r"
global key_print; set key_print "P"
global key_save_again; set key_save_again "s"
diff --git a/bindings/tk/plframe.c b/bindings/tk/plframe.c
index 0368e54..8728800 100644
--- a/bindings/tk/plframe.c
+++ b/bindings/tk/plframe.c
@@ -317,7 +317,8 @@ static Tk_ConfigSpec configSpecs[] = {
TK_CONFIG_COLOR_ONLY},
*/
#ifndef MAC_TCL
- {TK_CONFIG_COLOR, "-plbg", (char *) NULL, (char *) NULL,
+// jc: {TK_CONFIG_COLOR, "-plbg", (char *) NULL, (char *) NULL,
+ {TK_CONFIG_COLOR, "-plbg", "plbackground", "Plbackground",
DEF_PLFRAME_BG_COLOR, Tk_Offset(PlFrame, bgColor),
TK_CONFIG_COLOR_ONLY},
#endif
diff --git a/bindings/tk/plserver.tcl b/bindings/tk/plserver.tcl
index 9918644..ee5c71f 100644
--- a/bindings/tk/plserver.tcl
+++ b/bindings/tk/plserver.tcl
@@ -54,7 +54,9 @@ proc plserver_init {} {
plstdwin .
# Create the window for the menu bar
+# jc: top menu, with file and help submenus removed to save ploting space
+if { 0 } {
frame .menu -relief raised -borderwidth 1
pack append . .menu {top fillx}
@@ -132,6 +134,9 @@ proc plserver_init {} {
-underline 3
pack append .menu .menu.help {right}
+}
+
+ bind . <Control-x> exit
# Set up for keyboard-based menu traversal
@@ -170,7 +175,10 @@ proc client_cmd {msg} {
if { $dp } then {
after 1 catch [list "dp_RDO [list $client] $msg"]
} else {
- after 1 catch [list "send [list $client] after 1 $msg"]
+# jc: after 1 catch [list "send [list $client] after 1 $msg"]
+# try to avoid the server hanging; related with zoom/buttonpress problem
+# Side effects ??
+ after 1 catch [list "send -async [list $client] $msg"]
}
}
diff --git a/bindings/tk/plwidget.tcl b/bindings/tk/plwidget.tcl
index be1bbc4..ae8624d 100644
--- a/bindings/tk/plwidget.tcl
+++ b/bindings/tk/plwidget.tcl
@@ -111,6 +111,8 @@
proc plw_create {w {client_id {}}} {
plxframe $w $client_id
+# jc: puts name into window decoration frame
+ wm title . [string trim $w .]
}
#----------------------------------------------------------------------------
@@ -341,11 +343,38 @@ proc plw_create_pmenu {w pmbut} {
plw_create_pmenu_zoom $w
plw_create_pmenu_page $w
plw_create_pmenu_options $w
+ plw_create_pmenu_help $w
+ plw_create_pmenu_exit $w
return $pmbut
}
#----------------------------------------------------------------------------
+# plw_create_pmenu_exit
+#----------------------------------------------------------------------------
+
+proc plw_create_pmenu_exit {w} {
+
+ global pmenu
+
+ $pmenu($w) add command -label "Exit" \
+ -command exit
+
+}
+
+#----------------------------------------------------------------------------
+# plw_create_pmenu_help
+#----------------------------------------------------------------------------
+
+proc plw_create_pmenu_help {w} {
+
+ global pmenu
+
+ $pmenu($w) add command -label "Help" \
+ -command "help_keys"
+}
+
+#----------------------------------------------------------------------------
# plw_create_pmenu_print
#
# Create plot-print menu
@@ -644,6 +673,8 @@ proc plw_key_filter {w keycode state x y keyname ascii} {
global user_key_filter
global key_zoom_select
+ global key_zoom_back
+ global key_zoom_forward
global key_zoom_reset
global key_print
global key_save_again
@@ -664,8 +695,8 @@ proc plw_key_filter {w keycode state x y keyname ascii} {
switch $keyname \
$key_zoom_select "plw_zoom_select $w" \
- "b" "plw_zoom_back $w" \
- "f" "plw_zoom_forward $w" \
+ $key_zoom_back "plw_zoom_back $w" \
+ $key_zoom_forward "plw_zoom_forward $w" \
$key_zoom_reset "plw_zoom_reset $w" \
$key_print "plw_print $w" \
$key_save_again "plw_save_again $w" \
diff --git a/cf/configure.in b/cf/configure.in
index 15197da..53568a8 100644
--- a/cf/configure.in
+++ b/cf/configure.in
@@ -490,6 +490,9 @@ if test "$with_shlib" = "yes"; then
Linux* )
cat $srcdir/cf/lib_sh_linux.in >>Makefile.in
;;
+ SCO* )
+ cat $srcdir/cf/lib_sh_sco.in >>Makefile.in
+ ;;
* )
cat $srcdir/cf/lib_sh.in >>Makefile.in
;;
@@ -550,16 +553,16 @@ if test "$prefix" = NONE; then
prefix=$ac_default_prefix
fi
if test -z "$LIB_DIR"; then
- LIB_DIR=$prefix/lib
+ LIB_DIR=$prefix/lib/plplot
fi
if test -z "$BIN_DIR"; then
BIN_DIR=$prefix/bin
fi
if test -z "$TCL_DIR"; then
- TCL_DIR=$prefix/tcl
+ TCL_DIR=$prefix/lib/tcl8.0/plplot
fi
if test -z "$PYTHON_DIR"; then
- PYTHON_DIR=$prefix/python
+ PYTHON_DIR=$prefix/lib/python1.5/site-packages
fi
if test "$enable_python" = "yes"; then
if test "$PYTHON_DIR" != "$PYTHON_MACH_DIR"; then
@@ -568,7 +571,7 @@ if test "$enable_python" = "yes"; then
fi
fi
if test -z "$DOC_DIR"; then
- DOC_DIR=$prefix/doc
+ DOC_DIR=$prefix/doc/plplot
fi
if test -z "$INFO_DIR"; then
INFO_DIR=$prefix/info
@@ -577,7 +580,7 @@ if test -z "$INCLUDE_DIR"; then
INCLUDE_DIR=$prefix/include
fi
if test -z "$DEMOS_DIR"; then
- DEMOS_DIR=$prefix/examples
+ DEMOS_DIR=$prefix/doc/plplot/examples
fi
AC_DEFINE_UNQUOTED(LIB_DIR, "$LIB_DIR")
@@ -606,6 +609,7 @@ AC_MSG_RESULT(creating links...)
ln -s \
$srcdir/src/*.c \
+$srcdir/bindings/tk/stupidtk.c \
$srcdir/drivers/*.c \
$srcdir/include/*.h \
. 2>/dev/null
diff --git a/cf/dist.in b/cf/dist.in
index e1493e0..96174e2 100644
--- a/cf/dist.in
+++ b/cf/dist.in
@@ -34,7 +34,8 @@ CORE_C = \
plsym.c \
pltick.c \
plvpor.c \
- plwind.c
+ plwind.c \
+ plstripc.c
CORE_OBJ = \
pdfutils$O \
@@ -56,7 +57,8 @@ CORE_OBJ = \
plsym$O \
pltick$O \
plvpor$O \
- plwind$O
+ plwind$O \
+ plstripc$O
# Support files for font generators.
diff --git a/cf/initlib.in b/cf/initlib.in
index 85e1415..3920160 100644
--- a/cf/initlib.in
+++ b/cf/initlib.in
@@ -58,13 +58,16 @@ PLLIB_AR = $(PLLIB_PATH)$(PLLIB_BASE)$(LIB_TAG)$A
PLLIB_SO = $(PLLIB_PATH)$(PLLIB_BASE)$(LIB_TAG)$(SO)
PLLIB_SA = $(PLLIB_PATH)$(PLLIB_BASE)$(LIB_TAG)$(SA)
+# The following corrects error detected by Lintian
+# ldconfig-symlink-referencing-wrong-file (should not link to ./*
+# file)
PLLIB_SO = $(PLLIB_PATH)$(PLLIB_BASE)$(LIB_TAG)$(SO)
# This is used for making the install versions of plrender & plserver
# (Must relink after installing shared library!)
-LIB_INSTALL = -L$(LIB_DIR) -l$(PLLIB_NAME)$(LIB_TAG) $(MAT_LINK)
-LIB_INSTALL = -L$(LIB_DIR) -l$(PLLIB_NAME) $(MAT_LINK)
+LIB_INSTALL = -L$(LIB_DIR)/.. -l$(PLLIB_NAME)$(LIB_TAG) $(MAT_LINK)
+#LIB_INSTALL = -L$(LIB_DIR) -l$(PLLIB_NAME) $(MAT_LINK)
# These are what we link against.
diff --git a/cf/inst_lib.in b/cf/inst_lib.in
index 3c072ed..6f1004f 100644
--- a/cf/inst_lib.in
+++ b/cf/inst_lib.in
@@ -15,11 +15,11 @@ install_lib:
-if test ! -d $(INFO_DIR); then mkdir -p $(INFO_DIR); fi
-cd $(top_srcdir)/lib; cp *.fnt *.map $(LIB_DIR)
-cp $(PLLIB_BASE)* $(LIB_DIR); \
- for file in $(PLLIB_BASE)*; do $(RANLIB) $(LIB_DIR)/$$file; done
+ for file in $(PLLIB_BASE)*.a; do $(RANLIB) $(LIB_DIR)/$$file; done
-cp libMatrix.* $(LIB_DIR); \
- if test -r libMatrix.a; then $(RANLIB)) $(LIB_DIR)/libMatrix.a; done
+ if test -r libMatrix.a; then $(RANLIB) $(LIB_DIR)/libMatrix.a; fi
-cp libPLcxx.* $(LIB_DIR); \
- if test -r libPLcxx.a; then $(RANLIB)) $(LIB_DIR)/libPLcxx.a; done
+ if test -r libPLcxx.a; then $(RANLIB) $(LIB_DIR)/libPLcxx.a; fi
-cd $(top_srcdir); \
cp README NEWS CHANGES Copyright COPYING.LIB FAQ ToDo \
mklinks $(DOC_DIR)
diff --git a/cf/inst_lib_linux.in b/cf/inst_lib_linux.in
index 34d5d9b..e1574ef 100644
--- a/cf/inst_lib_linux.in
+++ b/cf/inst_lib_linux.in
@@ -15,10 +15,10 @@ install_lib:
-if test ! -d $(BIN_DIR); then mkdir -p $(BIN_DIR); fi
-if test ! -d $(INFO_DIR); then mkdir -p $(INFO_DIR); fi
-cd $(top_srcdir)/lib; cp *.fnt *.map $(LIB_DIR)
- -cp $(PLLIB_BASE)*.a $(LIB_DIR); \
- for file in $(PLLIB_BASE)*.a; do $(RANLIB) $(LIB_DIR)/$$file; done
- -cp $(PLLIB_SO).$(LIBVERSION_INST) $(LIB_DIR)
- -cd $(LIB_DIR); \
+ -cp $(PLLIB_BASE)*.a $(LIB_DIR)/..; \
+ for file in $(PLLIB_BASE)*.a; do $(RANLIB) $(LIB_DIR)/../$$file; done
+ -cp $(PLLIB_SO).$(LIBVERSION_INST) $(LIB_DIR)/..
+ -cd $(LIB_DIR)/..; \
ln -sf $(PLLIB_SO).$(LIBVERSION_INST) $(SONAME); \
ln -sf $(SONAME) $(PLLIB_BASE)$(LIB_TAG).so
-cd $(top_srcdir); \
diff --git a/cf/lib_sh.in b/cf/lib_sh.in
index 7991e72..3e532ab 100644
--- a/cf/lib_sh.in
+++ b/cf/lib_sh.in
@@ -55,7 +55,7 @@ $(MATLIB_AR): $(MAT_OBJS)
$(RANLIB) $(MATLIB_AR)
$(MATLIB_SO): $(MAT_OBJS)
- -$(RM) $(PLLIB_SO)
+ -$(RM) $(MATLIB_SO)
@echo ""; echo "Building shared library"; echo ""
cd shared; \
$(SHLIB_BUILD) ../$(MATLIB_SO) $(MAT_OBJS)
diff --git a/cf/lib_sh_linux.in b/cf/lib_sh_linux.in
index 326284a..b885e1d 100644
--- a/cf/lib_sh_linux.in
+++ b/cf/lib_sh_linux.in
@@ -34,9 +34,17 @@ SOVERSION = @SOVERSION@
LIBVERSION := $(shell ./version)
PLLIB_SO = $(PLLIB_PATH)$(PLLIB_BASE)$(LIB_TAG).so.$(SOVERSION)
-PLLIB_SO = $(PLLIB_PATH)$(PLLIB_BASE).so.$(SOVERSION)
-SONAME = $(PLLIB_BASE)$(LIB_TAG).so.$(SOVERSION)
-SONAME = $(PLLIB_BASE).so.$(SOVERSION)
+# Modified by Rafael Laboissiere <rafael at icp.inpg.fr> on 1998/06/13
+# avoid "./" prepended to *.so name
+# PLLIB_SO = $(PLLIB_PATH)$(PLLIB_BASE).so.$(SOVERSION)
+PLLIB_SO = $(PLLIB_BASE)$(LIB_TAG).so.$(SOVERSION)
+# Modified by Rafael Laboissiere <rafael at icp.inpg.fr>
+# on Thu Nov 12 18:11:45 CET 1998
+# For the Debian plplot pakcage
+# should include $(LIB_TAG) in SONAME and have only $(MAJOR_VERSION) at end
+# SONAME = $(PLLIB_BASE)$(LIB_TAG).so.$(SOVERSION)
+# SONAME = $(PLLIB_BASE).so.$(SOVERSION)
+SONAME = $(PLLIB_BASE)$(LIB_TAG).so.$(MAJOR_VERSION)
PLLIBS = $(PLLIB_AR) $(PLLIB_SO)
@@ -80,9 +88,12 @@ $(PLLIB_SO): $(LIB_OBJS) stupidtk.o
cd shared; \
$(SHLIB_BUILD) ../$(PLLIB_SO).$(LIBVERSION) \
-Wl,-soname -Wl,$(SONAME) \
- $(LIB_OBJS) stupidtk.o -L.. -lMatrix $(LDC_LIBS)
+ $(LIB_OBJS) stupidtk.o $(LDC_LIBS)
ln -sf $(PLLIB_SO).$(LIBVERSION) $(SONAME)
- ln -sf $(SONAME) $(PLLIB_BASE).so
+# Modified by Rafael Laboissiere <rafael at icp.inpg.fr>
+# on Thu Nov 12 20:07:46 CET 1998
+# ln -sf $(SONAME) $(PLLIB_BASE).so
+ ln -sf $(SONAME) $(PLLIB_BASE)$(LIB_TAG).so
echo $(LIBVERSION) > version.built
./version inc
@echo ""
@@ -92,8 +103,16 @@ $(PLLIB_SO): $(LIB_OBJS) stupidtk.o
$(MATLIB_SO): $(MAT_OBJS)
-$(RM) $(MATLIB_SO)
@echo ""; echo "Building shared library"; echo ""
+# Modified by Rafael Laboissiere <rafael at icp.inpg.fr>
+# on Thu Nov 12 20:07:46 CET 1998
+# When bulding the Python module we will need a shared libs
+# libMatrix.so to link against
cd shared; \
- $(SHLIB_BUILD) ../$(MATLIB_SO) $(MAT_OBJS)
+ $(SHLIB_BUILD) ../$(MATLIB_SO) \
+ -Wl,-soname -Wl,libMatrix$(SO).$(MAJOR_VERSION) \
+ $(MAT_OBJS)
+ ln -sf $(MATLIB_SO) libMatrix$(SO).$(MAJOR_VERSION)
+ ln -sf libMatrix$(SO).$(MAJOR_VERSION) libMatrix$(SO)
@echo ""
$(CXXLIB_SO): $(CXX_OBJS)
diff --git a/cf/lib_sh_linux.in b/cf/lib_sh_sco.in
similarity index 83%
copy from cf/lib_sh_linux.in
copy to cf/lib_sh_sco.in
index 326284a..d996406 100644
--- a/cf/lib_sh_linux.in
+++ b/cf/lib_sh_sco.in
@@ -1,5 +1,5 @@
# -*-makefile-*--------------------------------------------------------------
-# $Id: lib_sh_linux.in,v 1.9 1996/10/25 18:56:57 furnish Exp $
+# $Id: lib_sh_linux.in,v 1.8 1996/10/22 19:52:41 furnish Exp $
#
# Geoffrey Furnish
# IFS, University of Texas at Austin
@@ -31,19 +31,16 @@
# -----------------------------------------------------------------------------
SOVERSION = @SOVERSION@
-LIBVERSION := $(shell ./version)
PLLIB_SO = $(PLLIB_PATH)$(PLLIB_BASE)$(LIB_TAG).so.$(SOVERSION)
-PLLIB_SO = $(PLLIB_PATH)$(PLLIB_BASE).so.$(SOVERSION)
-SONAME = $(PLLIB_BASE)$(LIB_TAG).so.$(SOVERSION)
-SONAME = $(PLLIB_BASE).so.$(SOVERSION)
+SONAME = $(PLLIB_BASE)$(LIB_TAG).so
PLLIBS = $(PLLIB_AR) $(PLLIB_SO)
MATLIBS = $(MATLIB_AR) $(MATLIB_SO)
CXXLIBS = $(CXXLIB_AR) $(CXXLIB_SO)
-libs: $(MATLIBS) $(PLLIBS) $(CXXLIBS)
+libs: $(PLLIBS) $(MATLIBS) $(CXXLIBS)
$(PLLIB_AR): $(LIB_OBJS)
-$(RM) $(PLLIB_AR)
@@ -78,17 +75,11 @@ $(PLLIB_SO): $(LIB_OBJS) stupidtk.o
-$(RM) $(PLLIB_SO)
@echo ""; echo "Building shared library"; echo ""
cd shared; \
- $(SHLIB_BUILD) ../$(PLLIB_SO).$(LIBVERSION) \
- -Wl,-soname -Wl,$(SONAME) \
- $(LIB_OBJS) stupidtk.o -L.. -lMatrix $(LDC_LIBS)
- ln -sf $(PLLIB_SO).$(LIBVERSION) $(SONAME)
- ln -sf $(SONAME) $(PLLIB_BASE).so
- echo $(LIBVERSION) > version.built
- ./version inc
+ $(SHLIB_BUILD) ../$(PLLIB_SO) \
+ $(LIB_OBJS) stupidtk.o
+ ln -sf $(PLLIB_SO) $(SONAME)
@echo ""
-# ln -sf $(SONAME) $(PLLIB_BASE)$(LIB_TAG).so
-
$(MATLIB_SO): $(MAT_OBJS)
-$(RM) $(MATLIB_SO)
@echo ""; echo "Building shared library"; echo ""
diff --git a/cf/pkg_cxx.in b/cf/pkg_cxx.in
index f4b5508..3dda33a 100644
--- a/cf/pkg_cxx.in
+++ b/cf/pkg_cxx.in
@@ -19,8 +19,8 @@ CXX_INSTALL = install_cxx
install_cxx:
-cd $(top_srcdir)/bindings/c++; cp plstream.h $(INCLUDE_DIR)
- -cp libPLcxx* $(LIB_DIR)
- if test -r libPLcxx.a; then $(RANLIB) $(LIB_DIR)/libPLcxx.a; fi
+ -cp libPLcxx* $(LIB_DIR)/..
+ if test -r libPLcxx.a; then $(RANLIB) $(LIB_DIR)/../libPLcxx.a; fi
-if test ! -d $(DEMOS_DIR)/c++; then mkdir -p $(DEMOS_DIR)/c++; fi
-$(LN) $(DEMOS_DIR)/Makefile $(DEMOS_DIR)/c++
-cd $(top_srcdir)/examples/c++; cp * $(DEMOS_DIR)/c++
diff --git a/cf/pkg_python.in b/cf/pkg_python.in
index bec9080..cbb0bdf 100644
--- a/cf/pkg_python.in
+++ b/cf/pkg_python.in
@@ -26,7 +26,7 @@ PYTHON_INC_DIR = @PYTHON_INC_DIR@
PYTHON_MOD_DIR = @PYTHON_MOD_DIR@
PYTHON_MACH_DIR = @PYTHON_MACH_DIR@
PYTHON_CFG_DIR = @PYTHON_CFG_DIR@
-PYTHON_LIBS = -L$(PYTHON_CFG_DIR) -lModules -lObjects -lParser -lPython
+PYTHON_LIBS = -L$(PYTHON_CFG_DIR) -lpython1.5
PYTHON_DIR = @PYTHON_DIR@
LDSHARED = @LDSHARED@
@@ -40,11 +40,11 @@ $(PYTHON_EXE): plmodule$O
@echo "Building Python module."
@echo " "
$(LDSHARED) $(LDC_FLAGS) plmodule$O $(PYTHON_LIBS) $(PLLIB_LDC) \
- -o $(PYTHON_EXE) $(LDC_LIBS)
+ -o $(PYTHON_EXE) -lc $(LDC_LIBS)
install_python:
- $(LDSHARED) $(LDC_FLAGS) plmodule$O $(PYTHON_LIBS) $(LIB_INSTALL) \
- -o $(PYTHON_EXE) $(LDC_LIBS)
+ $(LDSHARED) $(LDC_FLAGS) plmodule$O $(PYTHON_LIBS) $(LIB_INSTALL) \
+ -o $(PYTHON_EXE) -lc $(LDC_LIBS)
-if test ! -d $(PYTHON_DIR); then mkdir -p $(PYTHON_DIR); fi
-cp $(PYTHON_EXE) $(PYTHON_DIR)
-if test ! -d $(DEMOS_DIR)/python; then mkdir -p $(DEMOS_DIR)/python; fi
diff --git a/cf/pkg_tcl.in b/cf/pkg_tcl.in
index f8f6228..536a639 100644
--- a/cf/pkg_tcl.in
+++ b/cf/pkg_tcl.in
@@ -26,7 +26,11 @@ MAT_OBJS = tclMatrix$O matrixInit$O
MAT_OBJS_SO =
MAT_OBJS_SA =
MATLIB_AR = libMatrix.a
-MATLIB_SO = libMatrix$(SO)
+# Changed by Rafael Laboissiere
+# on Tue Oct 13 13:42:54 CEST 1998
+# Numbering the so file for correct library dependency in the Debian package
+# MATLIB_SO = libMatrix$(SO)
+MATLIB_SO = libMatrix$(SO).$(SOVERSION)
MAT_INSTALL = install_mat
MAT_LINK = -lMatrix
@@ -35,7 +39,7 @@ MAT_BUILD = $(MATLIBS)
tclAPI.c: tclgen.h tclgen_s.h tclgen.c
tclgen.h tclgen_s.h tclgen.c : plapi.tpl
- pltclgen
+ ./pltclgen
#tclIndex:
# mktclidx *.tcl
@@ -58,6 +62,6 @@ install_tcl:
install_mat:
cp tclMatrix.h $(INCLUDE_DIR)
- cp libMatrix* $(LIB_DIR)
- if test -r libMatrix.a; then $(RANLIB) $(LIB_DIR)/libMatrix.a; fi
+ cp libMatrix* $(LIB_DIR)/..
+ if test -r libMatrix.a; then $(RANLIB) $(LIB_DIR)/../libMatrix.a; fi
diff --git a/cf/pkg_tk.in b/cf/pkg_tk.in
index aa55e20..d9116e0 100644
--- a/cf/pkg_tk.in
+++ b/cf/pkg_tk.in
@@ -30,5 +30,9 @@ install_tk:
-if test ! -d $(DEMOS_DIR)/tk; then mkdir -p $(DEMOS_DIR)/tk; fi
-$(LN) $(DEMOS_DIR)/Makefile $(DEMOS_DIR)/tk
-cd $(top_srcdir)/examples/tk; cp * $(DEMOS_DIR)/tk
- -$(LN) $(DEMOS_DIR)/tcl/x??.tcl $(DEMOS_DIR)/tk
+# Modified by Rafael Laboissiere <rafael at icp.oinpg.fr>
+# on Fri Nov 13 03:37:04 CET 1998
+# -$(LN) $(DEMOS_DIR)/tcl/x??.tcl $(DEMOS_DIR)/tk
+ ( cd $(DEMOS_DIR)/tk ; $(LN) ../tcl/x??.tcl $(DEMOS_DIR)/tk )
+
diff --git a/cf/sysconf.in b/cf/sysconf.in
index ba354dc..9998e37 100644
--- a/cf/sysconf.in
+++ b/cf/sysconf.in
@@ -194,7 +194,7 @@ fi
if test "$enable_cxx" = "yes"; then
if test -z "$CXX"; then
if test "$with_gcc" = "yes"; then
- CXX=gcc
+ CXX=g++
else
CXX=CC
case "$system" in
@@ -252,7 +252,7 @@ fi
# Optimization
if test "$with_opt" = "yes"; then
- OPT_FLAG_C=-O
+ OPT_FLAG_C=-O2
OPT_FLAG_CXX=-O
OPT_FLAG_F=-O
fi
@@ -305,7 +305,7 @@ fi
if test "$with_gcc" = "yes"; then
CC=gcc
- CXX=gcc
+ CXX=g++
OCC=gcc
CPP="gcc -E"
@@ -328,7 +328,7 @@ if test "$enable_f77" = "yes"; then
if test "$with_f2c" = "yes"; then
AC_CHECK_PROG(found_fc, fc, yes, no)
if test "$found_fc" = "yes" ; then
- F77=fc
+ F77=/usr/bin/fc
else
AC_CHECK_PROG(found_f77, f77, yes, no)
if test "$found_f77" = "yes" ; then
@@ -352,7 +352,7 @@ fi
# ----------------------------------------------------------------------------
if test -z "$LDC"; then
- LDC="$CC"
+ LDC="$F77"
fi
if test -z "$LDCXX"; then
LDCXX="$CXX"
diff --git a/cf/sysloc.in b/cf/sysloc.in
index df28f2f..252683e 100644
--- a/cf/sysloc.in
+++ b/cf/sysloc.in
@@ -457,8 +457,8 @@ fi
if test "$enable_python" = "yes"; then
if test -z "$PYTHON_INC_DIR" -o ! -d "$PYTHON_INC_DIR"; then
incdirs="\
- $prefix/include/python1.4 \
- /usr/include/python1.4 \
+ $prefix/include/python1.5 \
+ /usr/include/python1.5 \
$prefix/include/Py \
$HOME/local/include/Py \
$HOME/local/python/include/Py \
@@ -495,12 +495,20 @@ if test "$enable_python" = "yes"; then
fi
python_dir=`echo $PYTHON_INC_DIR|sed 's,/[[^/]]*/[[^/]]*$,,'`
- PYTHON_MOD_DIR=$python_dir/lib/python
+ # Changed by Rafael Laboissiere <rafael at icp.inpg.fr>
+ # on Mon Oct 12 11:12:00 CEST 1998
+ # (For the Debian plplot package).
+ # PYTHON_MOD_DIR=$python_dir/lib/python
+ PYTHON_MOD_DIR=$prefix/lib/python
PYTHON_MACH_DIR=$PYTHON_MOD_DIR/$MACHDEP
if test ! -d "$PYTHON_MOD_DIR"; then
# tricky, must be a new style
python_ver=`echo $PYTHON_INC_DIR|sed 's,/.*/,,'`
- PYTHON_MOD_DIR=$python_dir/lib/$python_ver
+ # Changed by Rafael Laboissiere <rafael at icp.inpg.fr>
+ # on Mon Oct 12 11:12:00 CEST 1998
+ # (For the Debian plplot package).
+ # PYTHON_MOD_DIR=$python_dir/lib/$python_ver
+ PYTHON_MOD_DIR=$prefix/lib/$python_ver
PYTHON_MACH_DIR=$PYTHON_MOD_DIR/$MACHDEP
if test ! -d "$PYTHON_MOD_DIR"; then
enable_python=no
@@ -510,7 +518,11 @@ if test "$enable_python" = "yes"; then
fi
fi
- PYTHON_CFG_DIR=$PYTHON_MOD_DIR/config
+ # Changed by Rafael Laboissiere <rafael at icp.inpg.fr>
+ # on Mon Oct 12 11:12:00 CEST 1998
+ # (For the Debian plplot package).
+ # PYTHON_CFG_DIR=$PYTHON_MOD_DIR/config
+ PYTHON_CFG_DIR=$python_dir/lib/$python_ver/config
fi
fi
@@ -613,9 +625,9 @@ if test "$with_shlib" = "yes"; then
SHLIB_LIBS=$LIBS
if test "$with_gcc" = "yes"; then
- SHLIB_CCFLAGS=-fpic
- SHLIB_CXXFLAGS=-fpic
- SHLIB_BUILD="gcc -shared -fpic -o"
+ SHLIB_CCFLAGS="-fpic -fPIC"
+ SHLIB_CXXFLAGS="-fpic -fPIC"
+ SHLIB_BUILD="gcc -shared -fpic -fPIC -lc -o"
else
SHLIB_CCFLAGS=
SHLIB_CXXFLAGS=
@@ -635,12 +647,20 @@ if test "$with_shlib" = "yes"; then
SHLIB_BUILD="ld -assert pure-text -o"
fi
;;
+ SCO* )
+# SO='.so.$(MAJOR_VERSION).$(MINOR_VERSION)'
+# SA='.sa.$(MAJOR_VERSION).$(MINOR_VERSION)'
+ AC_MSG_RESULT([Assuming sco-3.2v5 with gcc. Otherwise, reconfigure --without-shlib])
+ SOVERSION='$(MAJOR_VERSION).$(MINOR_VERSION)'
+ LDSHARED='gcc -fpic -shared'
+ SHLIB_BUILD="gcc -shared -fpic -o"
+ ;;
Linux* )
# Should do something to make sure this is an ELF system, as
# don't have patience for DLL...
AC_MSG_RESULT([Assuming Linux ELF. Otherwise, reconfigure --without-shlib])
# SO='.so.$(MAJOR_VERSION).$(MINOR_VERSION)'
- SHLIB_BUILD="gcc -shared -fpic -o"
+ SHLIB_BUILD="gcc -shared -fpic -fPIC -lc -o"
SOVERSION='$(MAJOR_VERSION).$(MINOR_VERSION)'
diff --git a/debian/README.debian b/debian/README.debian
new file mode 100644
index 0000000..f1b083f
--- /dev/null
+++ b/debian/README.debian
@@ -0,0 +1,80 @@
+plplot for DEBIAN
+----------------------
+
+1. INTRODUCTION & ORIGIN
+
+ This is the debianized package for PLplot, a scientific plotting
+ library. It was put together by Rafael Laboissiere.
+
+ The sources were downloaded from
+ http://emma.la.asu.edu/plplot/source/plplot-980407.tar.gz.
+
+
+1. PACKAGES
+
+ The original PLplot distribution was broken down in several Debian
+ packages:
+
+ * plplot: Contains the dynamic libraries for C, C++ and Fortran,
+ as well as the pltek program. The library present was
+ stripped down from the Tcl/Tk support. Man pages and info
+ documentation is included.
+
+ * plplot-dev: Headers and static libraries for developing
+ programs using the PLplot API.
+
+ * plplot-doc: PostScript manual, as well as many examples in C,
+ C++, Fortran, Tcl/Tk, and Python.
+
+ * plplot-tcl: Modules allowing binding of the PLplot functions
+ for Tcl/Tk. Contains also some interactive programs and
+ utilities for converting PLplot meta files.
+
+ * python-plplot: Glue library with bindings for Python
+
+
+3. CHANGES FOR THIS DEBIAN PACKAGE
+
+ Several changes were done to the autoconf of the upstream source:
+
+ * the egcs compiler g++ was used to generate the C++ library
+ * python support was linked against libpython1.5
+ * the python module has to go into /usr/lib/python1.5/site-packages
+ * the path to the f2c frontend script has to be given explicitly
+ (/usr/bin/fc), in order to avoid namespace clash with the bash
+ builtin command `fc'
+ * file stupidtk.c has to be included in libplplotfX (library with Tk
+ support stripped down)
+ * linking to files under /usr/lib with a leading `./' was corrected
+ (lintian complained about that)
+ * the paths for building the python bindings were redefined, as it
+ was impossible to compile entirely in the debian/tmp directory
+ * cf/pkg_tcl.in: the libMatrix library is generated with a version
+ number
+ * cf/lib_sh_linux.in: the libMatrix is generated with a
+ corrected soname and a link called libMatrix.so.4 is created.
+ * cf/sysconf.in: LDC is set to F77 (symbols s_cmp and s_copy
+ were causing problems when linking plrender).
+
+
+4. DOCUMENTATION
+
+ Further documentation for PLplot can be found in
+ /usr/infp/plplot.info.gz (Info format) or in the plplot-doc
+ package.
+
+
+5. DEMOS & EXAMPLES
+
+ A lot of examples were included in the plplot-doc package. Look at
+ /usr/doc/plplot/exemples. Instructions to compile the C and C++
+ examples are in /usr/doc/plplot-dev/README.Debian. To run the
+ Tcl/Tk demos you will have to figure out how to source the plplot
+ modules under /usr/lib/tcl8.0/plplot. As I never used Tcl in my
+ life, I have no clue how to do it. If you figure out how to run
+ the Tcl/Tk demos, please let me know (or file a bug report against
+ the Debian package plplot-doc).
+
+
+Rafael Laboissiere <rafael at icp.inpg.fr>, Thu Nov 12 16:38:26 CET 1998
+
diff --git a/debian/changelog b/debian/changelog
new file mode 100644
index 0000000..fe0c64d
--- /dev/null
+++ b/debian/changelog
@@ -0,0 +1,144 @@
+plplot (4.99j-8) frozen unstable; urgency=low
+
+ * Recompiled with new release of libc6 (cf discussion in debian-devel
+ starting at
+ http://www.debian.org/Lists-Archives/debian-devel-9812/msg00998.html).
+ * Changed LDC in cf/sysconf.in to F77 (link with gcc complains because
+ it is lacking symbols from g77).
+
+ -- Rafael Laboissiere <rafael at icp.inpg.fr> Fri, 11 Dec 1998 22:20:08 +0100
+
+plplot (4.99j-7) frozen unstable; urgency=low, closes=29694 29704
+
+ * Set Conflicts relationship because files were moved around in the
+ latest release (Fixes Bug#29694, reported by Francesco Potorti`
+ <F.Potorti at cnuce.cnr.it>).
+ * Rebuilt to fix bogus dependency on tkstep8.0 (closes Bug#29704
+ reported by Matthias Klose <doko at cs.tu-berlin.de>)
+
+ -- Rafael Laboissiere <rafael at icp.inpg.fr> Thu, 19 Nov 1998 16:33:24 +0100
+
+plplot (4.99j-6) frozen unstable; urgency=low, closes=28534
+
+ * Uploading to frozen and unstable. (The previous release, 4.99j-5, was
+ rejected and I never reuploaded it.)
+ * Revamped debian/rules with use of variables for the debian dirs.
+ * Corrected typo in plplot-dev.README (closes Bug#28534).
+ * No compression of executable exemples in package plplot-doc.
+ * Fixed paths only for tk* scripts under /usr/doc/plplot/examples/tk.
+ * Fixed permission for plcolor.tcl and tkdemos.tcl.
+ * Fixed path for script x16.py (in plplot-doc).
+ * Moved library files libMatrix and libplplotdtk from plplot-tcl to
+ plplot.
+ * Moved info file from the plplot-doc package to the base package
+ plplot: this is the only documentation availalbe for the PLplot API.
+ * Fixed typo ("\*") in debhelper compress files.
+ * Fixed the problem related to the naming of shared libraries.
+ * Improved "Description:" fields in debian/control:
+ - Added "a scientific library" to first line (as suggested by
+ Christopher J. Fearnley <cjf at I21.com>).
+ - Included URL of PLplot homepage for each package.
+ * dh_shlibdeps does not act on package python-plplot.
+ * postinst and postrm test now for its argument.
+ * Rewrote README.Debian files.
+
+ -- Rafael Laboissiere <rafael at icp.inpg.fr> Fri, 13 Nov 1998 03:02:34 +0100
+
+plplot (4.99j-5) unstable; urgency=low
+
+ * Build with patch from Joao Cardoso <jcardoso at inescn.pt> for Octave
+ interface. The patch file is included in the debian/ directory.
+ * The orig.tar.gz and the diff.gz files were absent from 4.99j-4
+ upload. This is corrected now (bug reported by Paul Slootman
+ <paul at wau.mis.ah.nl>).
+ * Corrected sed expression for fixing the #! path in Python scripts
+ * Corrected bug in debian/compress file which was causing compression of
+ executable scripts under usr/doc/plplot/examples.
+ * Created plplot-tcl.postinst with a call to ldconfig, as plplot-tcl
+ includes shared libraries.
+ * Links to the shared library are now Policy compliant, i.e. their names
+ have only one number after .so.
+ * debain/shlibs.local is renamed to debian/shlibs, and
+ debian/plplot-tcl.shlibs is created.
+ * The scripts installed under usr/lib/tcl8.0/plplot/ should not be
+ executable.
+
+ -- Rafael Laboissiere <rafael at icp.inpg.fr> Wed, 14 Oct 1998 16:42:08 +0200
+
+plplot (4.99j-4) unstable; urgency=low
+
+ * debian/fix-tk-path.pl script is chmod'd in debian/rules files: now
+ fixes really first part of Bug#26935. Fix suggested by Paul Slootman
+ <paul at wau.mis.ah.nl>.
+ * debian/control: plplot-doc architecture is now "all" and is compiled
+ in the binary-indep section of debian/rules (suggested by
+ Paul Slootman <paul at wau.mis.ah.nl>). In order to do that, big changes
+ in debian/rules were done. Hope I did not screw things up.
+ * debian/rules: Corrected hideous bug in chmod mode switches: "chmod -x"
+ should be "chmod +x".
+ * Corrected some typos in debian/control, debian/copyright.
+ * cf/pkg_tcl.in: put number version in libMatrix.so (changed
+ README.Debian to document the fix).
+ * Moved libMatrix.so and libMatrix.a to plplot-dev package.
+ * Moved libMatrix.so.* and libplplotdtk.so.* to plplot-tcl package, and
+ made plplot-dev depend on plplot-tcl (changed debian/control file to
+ reflect the changes).
+ * I just realized that the upstream Python support works only with
+ python-1.4. I will fix this in the next release.
+
+ -- Rafael Laboissiere <rafael at icp.inpg.fr> Tue, 13 Oct 1998 20:00:06 +0200
+
+plplot (4.99j-3) unstable; urgency=low
+
+ * debian/rules: fixing Python path for python scripts is done now with a
+ sed command (get rid of debian/fix-python-path.pl). Suggested by
+ Matthias Klose <doko at cs.tu-berlin.de>.
+ * Change in upstream file utils/pltek.c: gcc 2.7.2.3 deprecates the use
+ of gets
+ * Corrected file debian/plplot-dev.files, in order to have the files
+ libMatrix.* included in the right package (plplot).
+ * Make plplot conflict with plplot-dev for versions previous to this
+ one, because of the move of libMatrix.*.
+ * Changed mode of debian/fix-tk-path.pl script to executable (fixes
+ first part of Bug#26935).
+ * Building is now done entirely under debian/tmp (fixes second part of
+ Bug#26935).
+ * Buildning now `with double' instead of `with float', as required for
+ the PLplot Octave interface. Also, all instances of `libplotf*' were
+ changed to `libplotd*' (in debian/rules and in debian/*.files).
+ * /usr/lib/libplplotdtk.so.* files moved to the plplot package (they were
+ in plplot-tcl): this fixes the problem of installing the plplot-dev
+ package with a dangling symlink.
+ * Removed file debian/dirs, which had no function at all.
+ * Tcl/Tk and Python scripts under /usr/doc/plplot/examples are now
+ executable.
+ * fix-tk-path.pl: corrected "/example/" -> "/examples/"
+
+ -- Rafael Laboissiere <rafael at icp.inpg.fr> Mon, 12 Oct 1998 15:20:26 +0200
+
+plplot (4.99j-2) unstable; urgency=low
+
+ * Using debhelper 0.93 : README.Debian files are installed automatically
+ by dh_installdocs
+ * Fixed some problems found by Matthias Klose <doko at cs.tu-berlin.de>.
+ Danke Matthias!
+ * Corrected typo in fix-pytho-path.pl, that made all python examples
+ have size equal to zero.
+ * examples/Makefile has now correct references to /usr directories
+ * Scripts under /usr/doc/plplot/examples are no more compressed
+ * Tk scripts under /usr/doc/examples/tk have now the right path after
+ `#!'
+ * Added dependency python-tk to python-plplot
+
+ -- Rafael Laboissiere <rafael at icp.inpg.fr> Mon, 22 Jun 1998 21:53:26 +0200
+
+plplot (4.99j-1) experimental; urgency=low
+
+ * Initial Release.
+
+ -- Rafael Laboissiere <rafael at icp.inpg.fr> Sat, 13 Jun 1998 00:50:50 +0200
+
+Local variables:
+mode: debian-changelog
+add-log-mailing-address: "rafael at icp.inpg.fr"
+End:
diff --git a/debian/compress b/debian/compress
new file mode 100644
index 0000000..5e153be
--- /dev/null
+++ b/debian/compress
@@ -0,0 +1,9 @@
+#! /bin/sh
+# compress (debhelper file) for plplot package
+# Written by Rafael Laboissiere <rafael at icp.inpg.fr>
+# on Mon, 22 Jun 1998 19:56:26 +0200
+
+find usr/info usr/man -type f
+find usr/doc -type f \
+ \( -size +4k -or -name "changelog*" \) \
+ ! -name "copyright"
diff --git a/debian/control b/debian/control
new file mode 100644
index 0000000..77d3365
--- /dev/null
+++ b/debian/control
@@ -0,0 +1,69 @@
+Source: plplot
+Section: math
+Priority: optional
+Maintainer: Rafael Laboissiere <rafael at icp.inpg.fr>
+Standards-Version: 2.4.0.0
+
+Package: plplot
+Architecture: any
+Depends: ${shlibs:Depends}
+Conflicts: plplot-dev (<= 4.99j-2), plplot-tcl (<= 4.99j-5), plplot-doc (<= 4.99j-5)
+Description: Scientific plotting library
+ PLplot is relatively small, portable, freely distributable, and is rich
+ enough to satisfy most users. It has a wide range of plot types including
+ line (linear, log), contour, 3D, fill, and almost 1000 characters
+ (including Greek and mathematical) in its extended font set. The package
+ is designed to make it easy to quickly get graphical output; only a
+ handful of function calls is typically required. For more advanced use,
+ virtually all aspects of plotting are configurable.
+ .
+ APIs are provided for C, C++, and Fortran (Tcl/Tk and Python bindings
+ are available as separate packages, plplot-tcl and python-plplot
+ respectively).
+ .
+ A program for rendering Tektronix vector files is also included in
+ this package.
+ .
+ See http://emma.la.asu.edu/plplot for more information on PLplot.
+
+Package: plplot-tcl
+Architecture: any
+Depends: ${shlibs:Depends}, plplot
+Description: Tcl/Tk support for PLplot, a plotting library
+ This package contains the Tcl/Tk support for PLplot, a scientific
+ plotting library: shared and static libraries, Tcl modules, some
+ programs for interactive use of PLplot (plrender, plserver, and
+ pltcl), and utility programs for converting PLplot meta files (plpr
+ and plm2gif).
+ .
+ See http://emma.la.asu.edu/plplot for more information on PLplot.
+
+Package: plplot-dev
+Architecture: any
+Depends: plplot, plplot-tcl, libc6-dev
+Description: Header and static libraries for PLplot, a plotting library
+ This package contains all that is needed for doing development in C,
+ C++, Fortran, and Tcl/Tk with the PLplot, a scientific plotting library.
+ .
+ See http://emma.la.asu.edu/plplot for more information on PLplot.
+
+Package: python-plplot
+Architecture: any
+Depends: plplot, python-base, python-tk
+Description: Python support for PLplot, a plotting library
+ This package contains the library plmodule.so for gluing the PLplot
+ scientific plotting library into Python applications.
+ .
+ See http://emma.la.asu.edu/plplot for more information on PLplot.
+
+Package: plplot-doc
+Architecture: all
+Recommends: plplot
+Description: Documentation for PLplot, a plotting library
+ This package contains documentation for PLplot, a scientific plotting
+ library. A manual in PostScript format and an info file are
+ included, as well as examples for C, C++, Fortran, Tcl/Tk, and
+ Python.
+ .
+ See http://emma.la.asu.edu/plplot for more information on PLplot.
+
diff --git a/debian/copyright b/debian/copyright
new file mode 100644
index 0000000..562974b
--- /dev/null
+++ b/debian/copyright
@@ -0,0 +1,92 @@
+This package was debianized by Rafael Laboissiere rafael at icp.inpg.fr on
+Sat, Tue Oct 13 10:01:28 CEST 1998.
+
+It was downloaded from:
+
+ http://emma.la.asu.edu/plplot/source/plplot-980407.tar.gz
+
+The documentation was obtained in PS format and info directly from the
+home page at locations:
+
+ ftp://dino.ph.utexas.edu/plplot/docs/plplot.ps.gz
+ ftp://dino.ph.utexas.edu/plplot/docs/plplot.info.gz
+
+Below is the copyright notice that comes with the source distribution
+(reference to the location of LGPL text in the Debian system was
+added):
+
+
+Copyright (from file "Copyright" in the pristine source distributions;
+added text for the Debian package are between brackets):
+
+The PLplot package may be distributed under the following terms:
+
+ This library is free software; you can redistribute it and/or
+ modify it under the terms of the GNU Library General Public
+ License as published by the Free Software Foundation; either
+ version 2 of the License, or (at your option) any later version.
+
+ This library is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ Library General Public License for more details.
+
+ You should have received a copy of the GNU Library General Public
+ License along with this library; if not, write to the Free
+ Software Foundation, Inc. [59 Temple Place - Suite 330, Boston, MA
+ 02111-1307, USA.]
+
+The text of this license is given in the file COPYING.LIB in the
+distribution directory. [In Debian systems, see the file
+/usr/doc/copyright/LGPL.] Exceptions are noted below.
+
+The intent behind distributing PLplot under the LGPL is to ensure that it
+continues to evolve in a positive way, while remaining freely
+distributable. The package is considered a "library" even though there
+are associated programs, such as plrender, pltek, plserver, and pltcl.
+The ties between these programs and the library are so great that I
+consider them as part of the library, so distribution under the terms of
+the LGPL makes sense. Software developers are allowed and encouraged to
+use PLplot as an integral part of their product, even a commercial
+product. Under the conditions of the LGPL, however, the PLplot source
+code must remain freely available, including any modifications you make to
+it (if you distribute a program based on the modified library). Please
+read the full license for more info.
+
+
+Additional Copyrights
+---------------------
+
+The startup code used in argument handling (utils/plrender.c and
+src/plargs.c) is partially derived from "xterm.c" of the X11R5
+distribution, and its copyright is reproduced here:
+
+******************************************************************************
+Copyright 1987, 1988 by Digital Equipment Corporation, Maynard, Massachusetts,
+and the Massachusetts Institute of Technology, Cambridge, Massachusetts.
+
+ All Rights Reserved
+
+Permission to use, copy, modify, and distribute this software and its
+documentation for any purpose and without fee is hereby granted,
+provided that the above copyright notice appear in all copies and that
+both that copyright notice and this permission notice appear in
+supporting documentation, and that the names of Digital or MIT not be
+used in advertising or publicity pertaining to distribution of the
+software without specific, written prior permission.
+
+DIGITAL DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING
+ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO EVENT SHALL
+DIGITAL BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR
+ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS,
+WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION,
+ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS
+SOFTWARE.
+******************************************************************************
+
+Any file that is explicitly marked as "public domain" is free from any
+restriction on distribution.
+
+Any file that has a explicit copyright notice may be distributed under
+the terms of both the LGPL and whatever stated conditions accompany the
+copyright.
diff --git a/debian/fix-tk-path.pl b/debian/fix-tk-path.pl
new file mode 100644
index 0000000..fb8818d
--- /dev/null
+++ b/debian/fix-tk-path.pl
@@ -0,0 +1,21 @@
+#!/usr/bin/perl
+# File: fix-tk-path.pl
+# Written by Rafael Laboissiere <rafael at icp.inpg.fr> 15 Jun 1998 22:03:41 +0200
+# Fix path for Tk scripts after initial `#!'
+
+$done = 0;
+while(<>){
+ $line = $_;
+ if ((not $done) && /^\#\![ ]*(.*) (.*)$/ ) {
+ if ( $1 eq "plserver" ) {
+ print "#!/usr/bin/plserver $2\n";
+ }
+ else {
+ print "#!/usr/doc/plplot/examples/tk/$1 $2\n";
+ }
+ $done = 1;
+ }
+ else {
+ print $line;
+ }
+}
diff --git a/debian/plm2gif.1 b/debian/plm2gif.1
new file mode 100644
index 0000000..386fe76
--- /dev/null
+++ b/debian/plm2gif.1
@@ -0,0 +1,32 @@
+.\" -*- nroff -*-
+.TH PLM2GIF 1
+.SH NAME
+plm2gif \- converts PLplot metafiles to GIF files
+.SH SYNOPSIS
+.B plm2gif
+.I "[files]"
+.SH "DESCRIPTION"
+This manual page documents briefly the
+.BR plm2gif
+command.
+This manual page was written for the Debian GNU/Linux distribution
+because the original program does not have a manual page.
+.PP
+.B plm2gif
+is a program that Converts specified PLplot metafiles to GIF format
+files. This is a two-step process: 1. process into postscript (with
+custom flags); and 2. convert to GIF using ghostscript (more custom
+flags).
+.PP
+Each input file must end with
+.I ".plm"
+, and a corresponding family of GIF
+files ending with
+.I "<number>.gif"
+(one for each page) is created.
+.PP
+.SH "SEE ALSO"
+See /usr/doc/plplot/plplot.ps.gz for more details.
+.SH AUTHOR
+This manual page was written by Rafael Laboissiere <rafael at icp.inpg.fr>,
+for the Debian GNU/Linux system (but may be used by others).
diff --git a/debian/plplot-980407-plplot-980407-new.patch b/debian/plplot-980407-plplot-980407-new.patch
new file mode 100644
index 0000000..7408a59
--- /dev/null
+++ b/debian/plplot-980407-plplot-980407-new.patch
@@ -0,0 +1,2065 @@
+diff -cbNr plplot-980407/bindings/tcl/matrixInit.c plplot-980407-new/bindings/tcl/matrixInit.c
+*** plplot-980407/bindings/tcl/matrixInit.c Tue Apr 7 20:02:41 1998
+--- plplot-980407-new/bindings/tcl/matrixInit.c Thu May 7 18:23:54 1998
+***************
+*** 8,13 ****
+--- 8,16 ----
+ Tcl_CreateCommand(interp, "matrix", Tcl_MatrixCmd,
+ (ClientData) NULL, (void (*)(ClientData)) NULL);
+
++ #if ( TCL_MAJOR_VERSION == 7 && TCL_MINOR_VERSION > 4 ) // jc:
+ Tcl_PkgProvide(interp, "Matrix", "0.1");
++ #endif
++
+ return TCL_OK;
+ }
+diff -cbNr plplot-980407/bindings/tk/help_keys.tcl plplot-980407-new/bindings/tk/help_keys.tcl
+*** plplot-980407/bindings/tk/help_keys.tcl Tue Apr 7 20:02:46 1998
+--- plplot-980407-new/bindings/tk/help_keys.tcl Thu May 7 16:31:21 1998
+***************
+*** 27,34 ****
+ its remote TK driver. The default actions of the keyboard handler are as
+ follows:
+
+! "Q" Terminate program
+ <Return> or <Page Down> Advance to the next page
+
+ The user code can supply its own keyboard handler, and thereby add to
+ or modify these actions (this is in fact what is done by plrender).
+--- 27,44 ----
+ its remote TK driver. The default actions of the keyboard handler are as
+ follows:
+
+! "Q" | <Ctrl-x> Terminate program
+ <Return> or <Page Down> Advance to the next page
++ "z" enter zoom (Cliking once zooms x 2)
++ "b" back zoom
++ "f" forward zoom
++ "z" reset zoom
++ "P" print
++ "s" save again
++ "5" scroll magnification factor ??
++ "1" scroll speed ??
++ <left><right><up><down> scroll after zoom
++ <Alt><key> increase scroll speed
+
+ The user code can supply its own keyboard handler, and thereby add to
+ or modify these actions (this is in fact what is done by plrender).
+diff -cbNr plplot-980407/bindings/tk/pldefaults.tcl plplot-980407-new/bindings/tk/pldefaults.tcl
+*** plplot-980407/bindings/tk/pldefaults.tcl Tue Apr 7 20:02:47 1998
+--- plplot-980407-new/bindings/tk/pldefaults.tcl Thu May 7 16:31:21 1998
+***************
+*** 239,244 ****
+--- 239,246 ----
+ # Turn them into an empty string to disable.
+
+ global key_zoom_select; set key_zoom_select "z"
++ global key_zoom_back; set key_zoom_back "b"
++ global key_zoom_forward; set key_zoom_forward "f"
+ global key_zoom_reset; set key_zoom_reset "r"
+ global key_print; set key_print "P"
+ global key_save_again; set key_save_again "s"
+diff -cbNr plplot-980407/bindings/tk/plframe.c plplot-980407-new/bindings/tk/plframe.c
+*** plplot-980407/bindings/tk/plframe.c Tue Apr 7 20:02:48 1998
+--- plplot-980407-new/bindings/tk/plframe.c Thu May 7 18:23:54 1998
+***************
+*** 317,323 ****
+ TK_CONFIG_COLOR_ONLY},
+ */
+ #ifndef MAC_TCL
+! {TK_CONFIG_COLOR, "-plbg", (char *) NULL, (char *) NULL,
+ DEF_PLFRAME_BG_COLOR, Tk_Offset(PlFrame, bgColor),
+ TK_CONFIG_COLOR_ONLY},
+ #endif
+--- 317,324 ----
+ TK_CONFIG_COLOR_ONLY},
+ */
+ #ifndef MAC_TCL
+! // jc: {TK_CONFIG_COLOR, "-plbg", (char *) NULL, (char *) NULL,
+! {TK_CONFIG_COLOR, "-plbg", "plbackground", "Plbackground",
+ DEF_PLFRAME_BG_COLOR, Tk_Offset(PlFrame, bgColor),
+ TK_CONFIG_COLOR_ONLY},
+ #endif
+diff -cbNr plplot-980407/bindings/tk/plserver.tcl plplot-980407-new/bindings/tk/plserver.tcl
+*** plplot-980407/bindings/tk/plserver.tcl Tue Apr 7 20:02:49 1998
+--- plplot-980407-new/bindings/tk/plserver.tcl Thu May 7 16:31:21 1998
+***************
+*** 54,60 ****
+--- 54,62 ----
+ plstdwin .
+
+ # Create the window for the menu bar
++ # jc: top menu, with file and help submenus removed to save ploting space
+
++ if { 0 } {
+ frame .menu -relief raised -borderwidth 1
+ pack append . .menu {top fillx}
+
+***************
+*** 132,137 ****
+--- 134,142 ----
+ -underline 3
+
+ pack append .menu .menu.help {right}
++ }
++
++ bind . <Control-x> exit
+
+ # Set up for keyboard-based menu traversal
+
+***************
+*** 170,176 ****
+ if { $dp } then {
+ after 1 catch [list "dp_RDO [list $client] $msg"]
+ } else {
+! after 1 catch [list "send [list $client] after 1 $msg"]
+ }
+ }
+
+--- 175,184 ----
+ if { $dp } then {
+ after 1 catch [list "dp_RDO [list $client] $msg"]
+ } else {
+! # jc: after 1 catch [list "send [list $client] after 1 $msg"]
+! # try to avoid the server hanging; related with zoom/buttonpress problem
+! # Side effects ??
+! after 1 catch [list "send -async [list $client] $msg"]
+ }
+ }
+
+diff -cbNr plplot-980407/bindings/tk/plwidget.tcl plplot-980407-new/bindings/tk/plwidget.tcl
+*** plplot-980407/bindings/tk/plwidget.tcl Tue Apr 7 20:02:50 1998
+--- plplot-980407-new/bindings/tk/plwidget.tcl Thu May 7 16:31:21 1998
+***************
+*** 111,116 ****
+--- 111,118 ----
+
+ proc plw_create {w {client_id {}}} {
+ plxframe $w $client_id
++ # jc: puts name into window decoration frame
++ wm title . [string trim $w .]
+ }
+
+ #----------------------------------------------------------------------------
+***************
+*** 341,351 ****
+--- 343,380 ----
+ plw_create_pmenu_zoom $w
+ plw_create_pmenu_page $w
+ plw_create_pmenu_options $w
++ plw_create_pmenu_help $w
++ plw_create_pmenu_exit $w
+
+ return $pmbut
+ }
+
+ #----------------------------------------------------------------------------
++ # plw_create_pmenu_exit
++ #----------------------------------------------------------------------------
++
++ proc plw_create_pmenu_exit {w} {
++
++ global pmenu
++
++ $pmenu($w) add command -label "Exit" \
++ -command exit
++
++ }
++
++ #----------------------------------------------------------------------------
++ # plw_create_pmenu_help
++ #----------------------------------------------------------------------------
++
++ proc plw_create_pmenu_help {w} {
++
++ global pmenu
++
++ $pmenu($w) add command -label "Help" \
++ -command "help_keys"
++ }
++
++ #----------------------------------------------------------------------------
+ # plw_create_pmenu_print
+ #
+ # Create plot-print menu
+***************
+*** 644,649 ****
+--- 673,680 ----
+ global user_key_filter
+
+ global key_zoom_select
++ global key_zoom_back
++ global key_zoom_forward
+ global key_zoom_reset
+ global key_print
+ global key_save_again
+***************
+*** 664,671 ****
+
+ switch $keyname \
+ $key_zoom_select "plw_zoom_select $w" \
+! "b" "plw_zoom_back $w" \
+! "f" "plw_zoom_forward $w" \
+ $key_zoom_reset "plw_zoom_reset $w" \
+ $key_print "plw_print $w" \
+ $key_save_again "plw_save_again $w" \
+--- 695,702 ----
+
+ switch $keyname \
+ $key_zoom_select "plw_zoom_select $w" \
+! $key_zoom_back "plw_zoom_back $w" \
+! $key_zoom_forward "plw_zoom_forward $w" \
+ $key_zoom_reset "plw_zoom_reset $w" \
+ $key_print "plw_print $w" \
+ $key_save_again "plw_save_again $w" \
+diff -cbNr plplot-980407/cf/configure.in plplot-980407-new/cf/configure.in
+*** plplot-980407/cf/configure.in Tue Apr 7 20:02:52 1998
+--- plplot-980407-new/cf/configure.in Thu May 7 16:31:21 1998
+***************
+*** 490,495 ****
+--- 490,498 ----
+ Linux* )
+ cat $srcdir/cf/lib_sh_linux.in >>Makefile.in
+ ;;
++ SCO* )
++ cat $srcdir/cf/lib_sh_sco.in >>Makefile.in
++ ;;
+ * )
+ cat $srcdir/cf/lib_sh.in >>Makefile.in
+ ;;
+diff -cbNr plplot-980407/cf/dist.in plplot-980407-new/cf/dist.in
+*** plplot-980407/cf/dist.in Tue Apr 7 20:02:52 1998
+--- plplot-980407-new/cf/dist.in Thu May 7 16:31:21 1998
+***************
+*** 34,40 ****
+ plsym.c \
+ pltick.c \
+ plvpor.c \
+! plwind.c
+
+ CORE_OBJ = \
+ pdfutils$O \
+--- 34,41 ----
+ plsym.c \
+ pltick.c \
+ plvpor.c \
+! plwind.c \
+! plstripc.c
+
+ CORE_OBJ = \
+ pdfutils$O \
+***************
+*** 56,62 ****
+ plsym$O \
+ pltick$O \
+ plvpor$O \
+! plwind$O
+
+ # Support files for font generators.
+
+--- 57,64 ----
+ plsym$O \
+ pltick$O \
+ plvpor$O \
+! plwind$O \
+! plstripc$O
+
+ # Support files for font generators.
+
+diff -cbNr plplot-980407/cf/initlib.in plplot-980407-new/cf/initlib.in
+*** plplot-980407/cf/initlib.in Tue Apr 7 20:02:53 1998
+--- plplot-980407-new/cf/initlib.in Thu May 7 17:13:24 1998
+***************
+*** 64,70 ****
+ # (Must relink after installing shared library!)
+
+ LIB_INSTALL = -L$(LIB_DIR) -l$(PLLIB_NAME)$(LIB_TAG) $(MAT_LINK)
+- LIB_INSTALL = -L$(LIB_DIR) -l$(PLLIB_NAME) $(MAT_LINK)
+
+ # These are what we link against.
+
+--- 64,69 ----
+diff -cbNr plplot-980407/cf/inst_lib.in plplot-980407-new/cf/inst_lib.in
+*** plplot-980407/cf/inst_lib.in Tue Apr 7 20:02:53 1998
+--- plplot-980407-new/cf/inst_lib.in Thu May 7 16:31:21 1998
+***************
+*** 15,25 ****
+ -if test ! -d $(INFO_DIR); then mkdir -p $(INFO_DIR); fi
+ -cd $(top_srcdir)/lib; cp *.fnt *.map $(LIB_DIR)
+ -cp $(PLLIB_BASE)* $(LIB_DIR); \
+! for file in $(PLLIB_BASE)*; do $(RANLIB) $(LIB_DIR)/$$file; done
+ -cp libMatrix.* $(LIB_DIR); \
+! if test -r libMatrix.a; then $(RANLIB)) $(LIB_DIR)/libMatrix.a; done
+ -cp libPLcxx.* $(LIB_DIR); \
+! if test -r libPLcxx.a; then $(RANLIB)) $(LIB_DIR)/libPLcxx.a; done
+ -cd $(top_srcdir); \
+ cp README NEWS CHANGES Copyright COPYING.LIB FAQ ToDo \
+ mklinks $(DOC_DIR)
+--- 15,25 ----
+ -if test ! -d $(INFO_DIR); then mkdir -p $(INFO_DIR); fi
+ -cd $(top_srcdir)/lib; cp *.fnt *.map $(LIB_DIR)
+ -cp $(PLLIB_BASE)* $(LIB_DIR); \
+! for file in $(PLLIB_BASE)*.a; do $(RANLIB) $(LIB_DIR)/$$file; done
+ -cp libMatrix.* $(LIB_DIR); \
+! if test -r libMatrix.a; then $(RANLIB) $(LIB_DIR)/libMatrix.a; fi
+ -cp libPLcxx.* $(LIB_DIR); \
+! if test -r libPLcxx.a; then $(RANLIB) $(LIB_DIR)/libPLcxx.a; fi
+ -cd $(top_srcdir); \
+ cp README NEWS CHANGES Copyright COPYING.LIB FAQ ToDo \
+ mklinks $(DOC_DIR)
+diff -cbNr plplot-980407/cf/lib_sh.in plplot-980407-new/cf/lib_sh.in
+*** plplot-980407/cf/lib_sh.in Tue Apr 7 20:02:54 1998
+--- plplot-980407-new/cf/lib_sh.in Thu May 7 16:31:21 1998
+***************
+*** 55,61 ****
+ $(RANLIB) $(MATLIB_AR)
+
+ $(MATLIB_SO): $(MAT_OBJS)
+! -$(RM) $(PLLIB_SO)
+ @echo ""; echo "Building shared library"; echo ""
+ cd shared; \
+ $(SHLIB_BUILD) ../$(MATLIB_SO) $(MAT_OBJS)
+--- 55,61 ----
+ $(RANLIB) $(MATLIB_AR)
+
+ $(MATLIB_SO): $(MAT_OBJS)
+! -$(RM) $(MATLIB_SO)
+ @echo ""; echo "Building shared library"; echo ""
+ cd shared; \
+ $(SHLIB_BUILD) ../$(MATLIB_SO) $(MAT_OBJS)
+diff -cbNr plplot-980407/cf/lib_sh_sco.in plplot-980407-new/cf/lib_sh_sco.in
+*** plplot-980407/cf/lib_sh_sco.in Thu Jan 1 00:00:00 1970
+--- plplot-980407-new/cf/lib_sh_sco.in Thu May 7 16:31:21 1998
+***************
+*** 0 ****
+--- 1,110 ----
++ # -*-makefile-*--------------------------------------------------------------
++ # $Id: lib_sh_linux.in,v 1.8 1996/10/22 19:52:41 furnish Exp $
++ #
++ # Geoffrey Furnish
++ # IFS, University of Texas at Austin
++ # 6-Jun-1995
++ #
++ # PLplot build rules for archive and shared library under Linux.
++ # Based on prior work by Maurice.
++ # -----------------------------------------------------------------------------
++
++ # -----------------------------------------------------------------------------
++ # Set up inference rules appropriate for building both archive and shared
++ # libraries.
++ # -----------------------------------------------------------------------------
++
++ .cc.o:
++ $(CXX) $(CXX_FLAGS) $<
++ cd shared; $(CXX) $(SHLIB_CXXFLAGS) $(CXX_FLAGS) ../$<
++
++ .c.o:
++ $(CC) $(CC_FLAGS) $<
++ cd shared; $(CC) $(SHLIB_CCFLAGS) $(CC_FLAGS) ../$<
++
++ .f.o:
++ $(F77) $(F77_FLAGS) $<
++ cd shared; $(F77) $(SHLIB_F77FLAGS) $(F77_FLAGS) ../$<
++
++ # -----------------------------------------------------------------------------
++ # Library dependency list and targets
++ # -----------------------------------------------------------------------------
++
++ SOVERSION = @SOVERSION@
++
++ PLLIB_SO = $(PLLIB_PATH)$(PLLIB_BASE)$(LIB_TAG).so.$(SOVERSION)
++ SONAME = $(PLLIB_BASE)$(LIB_TAG).so
++
++
++ PLLIBS = $(PLLIB_AR) $(PLLIB_SO)
++ MATLIBS = $(MATLIB_AR) $(MATLIB_SO)
++ CXXLIBS = $(CXXLIB_AR) $(CXXLIB_SO)
++
++ libs: $(PLLIBS) $(MATLIBS) $(CXXLIBS)
++
++ $(PLLIB_AR): $(LIB_OBJS)
++ -$(RM) $(PLLIB_AR)
++ @echo ""; echo "Building archive library"; echo ""
++ $(ARLIB_BUILD) $(PLLIB_AR) $(LIB_OBJS)
++ $(RANLIB) $(PLLIB_AR)
++
++ $(MATLIB_AR): $(MAT_OBJS)
++ -$(RM) $(MATLIB_AR)
++ @echo ""; echo "Building archive library"; echo ""
++ $(ARLIB_BUILD) $(MATLIB_AR) $(MAT_OBJS)
++ $(RANLIB) $(MATLIB_AR)
++ @echo ""
++
++ $(CXXLIB_AR): $(CXX_OBJS)
++ -$(RM) $(CXXLIB_AR)
++ @echo ""; echo "Building archive library"; echo ""
++ $(ARLIB_BUILD) $(CXXLIB_AR) $(CXX_OBJS)
++ $(RANLIB) $(CXXLIB_AR)
++ @echo ""
++
++ # The following rule based (very) loosely on what I see David Engel
++ # did in his Linux Tcl/Tk port.
++
++ # NOTE: We have to link with iostream in order to satisfy the
++ # references to cout and friends in the C++ interface class. And we
++ # do /not/ link with libg++ so as to avoid conflicts between the
++ # libg++ String class and the DS++ String class. Oh, but for C++
++ # namespace support...
++
++ $(PLLIB_SO): $(LIB_OBJS) stupidtk.o
++ -$(RM) $(PLLIB_SO)
++ @echo ""; echo "Building shared library"; echo ""
++ cd shared; \
++ $(SHLIB_BUILD) ../$(PLLIB_SO) \
++ $(LIB_OBJS) stupidtk.o
++ ln -sf $(PLLIB_SO) $(SONAME)
++ @echo ""
++
++ $(MATLIB_SO): $(MAT_OBJS)
++ -$(RM) $(MATLIB_SO)
++ @echo ""; echo "Building shared library"; echo ""
++ cd shared; \
++ $(SHLIB_BUILD) ../$(MATLIB_SO) $(MAT_OBJS)
++ @echo ""
++
++ $(CXXLIB_SO): $(CXX_OBJS)
++ -$(RM) $(CXXLIB_SO)
++ @echo ""; echo "Building shared library"; echo ""
++ cd shared; \
++ $(SHLIB_BUILD) ../$(CXXLIB_SO) $(CXX_OBJS)
++ @echo ""
++
++ # -----------------------------------------------------------------------------
++ # Sick hacks.
++ # -----------------------------------------------------------------------------
++
++ # Needs to be compiled using K&R C.
++
++ tcpip.o:
++ $(OCC) $(CC_FLAGS) tcpip.c
++ cd shared; $(OCC) $(SHLIB_CCFLAGS) $(CC_FLAGS) ../tcpip.c
++
++ stupidtk.o:
++ $(CC) $(CC_FLAGS) stupidtk.c
++ cd shared; $(CC) $(SHLIB_CCFLAGS) $(CC_FLAGS) ../stupidtk.c
++
+diff -cbNr plplot-980407/cf/pkg_tcl.in plplot-980407-new/cf/pkg_tcl.in
+*** plplot-980407/cf/pkg_tcl.in Tue Apr 7 20:02:56 1998
+--- plplot-980407-new/cf/pkg_tcl.in Thu May 7 16:31:21 1998
+***************
+*** 35,41 ****
+ tclAPI.c: tclgen.h tclgen_s.h tclgen.c
+
+ tclgen.h tclgen_s.h tclgen.c : plapi.tpl
+! pltclgen
+
+ #tclIndex:
+ # mktclidx *.tcl
+--- 35,41 ----
+ tclAPI.c: tclgen.h tclgen_s.h tclgen.c
+
+ tclgen.h tclgen_s.h tclgen.c : plapi.tpl
+! ./pltclgen
+
+ #tclIndex:
+ # mktclidx *.tcl
+diff -cbNr plplot-980407/cf/sysloc.in plplot-980407-new/cf/sysloc.in
+*** plplot-980407/cf/sysloc.in Tue Apr 7 20:02:57 1998
+--- plplot-980407-new/cf/sysloc.in Thu May 7 16:31:21 1998
+***************
+*** 635,640 ****
+--- 635,648 ----
+ SHLIB_BUILD="ld -assert pure-text -o"
+ fi
+ ;;
++ SCO* )
++ # SO='.so.$(MAJOR_VERSION).$(MINOR_VERSION)'
++ # SA='.sa.$(MAJOR_VERSION).$(MINOR_VERSION)'
++ AC_MSG_RESULT([Assuming sco-3.2v5 with gcc. Otherwise, reconfigure --without-shlib])
++ SOVERSION='$(MAJOR_VERSION).$(MINOR_VERSION)'
++ LDSHARED='gcc -fpic -shared'
++ SHLIB_BUILD="gcc -shared -fpic -o"
++ ;;
+ Linux* )
+ # Should do something to make sure this is an ELF system, as
+ # don't have patience for DLL...
+diff -cbNr plplot-980407/confdefs.h plplot-980407-new/confdefs.h
+*** plplot-980407/confdefs.h Thu Jan 1 00:00:00 1970
+--- plplot-980407-new/confdefs.h Thu May 7 17:13:37 1998
+***************
+*** 0 ****
+--- 1 ----
++
+diff -cbNr plplot-980407/config.log plplot-980407-new/config.log
+*** plplot-980407/config.log Thu Jan 1 00:00:00 1970
+--- plplot-980407-new/config.log Thu May 7 17:13:38 1998
+***************
+*** 0 ****
+--- 1,3 ----
++ This file contains any messages produced by compilers while
++ running configure, to aid debugging if configure makes a mistake.
++
+diff -cbNr plplot-980407/configure plplot-980407-new/configure
+*** plplot-980407/configure Tue Apr 7 20:02:33 1998
+--- plplot-980407-new/configure Thu May 7 16:31:22 1998
+***************
+*** 3685,3690 ****
+--- 3685,3698 ----
+ SHLIB_BUILD="ld -assert pure-text -o"
+ fi
+ ;;
++ SCO* )
++ # SO='.so.$(MAJOR_VERSION).$(MINOR_VERSION)'
++ # SA='.sa.$(MAJOR_VERSION).$(MINOR_VERSION)'
++ echo "$ac_t""Assuming sco-3.2v5 with gcc. Otherwise, reconfigure --without-shlib" 1>&6
++ SOVERSION='$(MAJOR_VERSION).$(MINOR_VERSION)'
++ LDSHARED='gcc -fpic -shared'
++ SHLIB_BUILD="gcc -shared -fpic -o"
++ ;;
+ Linux* )
+ # Should do something to make sure this is an ELF system, as
+ # don't have patience for DLL...
+***************
+*** 4250,4261 ****
+
+
+ echo $ac_n "checking for ANSI C header files""... $ac_c" 1>&6
+! echo "configure:4254: checking for ANSI C header files" >&5
+ if eval "test \"`echo '$''{'ac_cv_header_stdc'+set}'`\" = set"; then
+ echo $ac_n "(cached) $ac_c" 1>&6
+ else
+ cat > conftest.$ac_ext <<EOF
+! #line 4259 "configure"
+ #include "confdefs.h"
+ #include <stdlib.h>
+ #include <stdarg.h>
+--- 4258,4269 ----
+
+
+ echo $ac_n "checking for ANSI C header files""... $ac_c" 1>&6
+! echo "configure:4262: checking for ANSI C header files" >&5
+ if eval "test \"`echo '$''{'ac_cv_header_stdc'+set}'`\" = set"; then
+ echo $ac_n "(cached) $ac_c" 1>&6
+ else
+ cat > conftest.$ac_ext <<EOF
+! #line 4267 "configure"
+ #include "confdefs.h"
+ #include <stdlib.h>
+ #include <stdarg.h>
+***************
+*** 4263,4269 ****
+ #include <float.h>
+ EOF
+ ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
+! { (eval echo configure:4267: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+ ac_err=`grep -v '^ *+' conftest.out`
+ if test -z "$ac_err"; then
+ rm -rf conftest*
+--- 4271,4277 ----
+ #include <float.h>
+ EOF
+ ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
+! { (eval echo configure:4275: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+ ac_err=`grep -v '^ *+' conftest.out`
+ if test -z "$ac_err"; then
+ rm -rf conftest*
+***************
+*** 4280,4286 ****
+ if test $ac_cv_header_stdc = yes; then
+ # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
+ cat > conftest.$ac_ext <<EOF
+! #line 4284 "configure"
+ #include "confdefs.h"
+ #include <string.h>
+ EOF
+--- 4288,4294 ----
+ if test $ac_cv_header_stdc = yes; then
+ # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
+ cat > conftest.$ac_ext <<EOF
+! #line 4292 "configure"
+ #include "confdefs.h"
+ #include <string.h>
+ EOF
+***************
+*** 4298,4304 ****
+ if test $ac_cv_header_stdc = yes; then
+ # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
+ cat > conftest.$ac_ext <<EOF
+! #line 4302 "configure"
+ #include "confdefs.h"
+ #include <stdlib.h>
+ EOF
+--- 4306,4312 ----
+ if test $ac_cv_header_stdc = yes; then
+ # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
+ cat > conftest.$ac_ext <<EOF
+! #line 4310 "configure"
+ #include "confdefs.h"
+ #include <stdlib.h>
+ EOF
+***************
+*** 4319,4325 ****
+ :
+ else
+ cat > conftest.$ac_ext <<EOF
+! #line 4323 "configure"
+ #include "confdefs.h"
+ #include <ctype.h>
+ #define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
+--- 4327,4333 ----
+ :
+ else
+ cat > conftest.$ac_ext <<EOF
+! #line 4331 "configure"
+ #include "confdefs.h"
+ #include <ctype.h>
+ #define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
+***************
+*** 4330,4336 ****
+ exit (0); }
+
+ EOF
+! if { (eval echo configure:4334: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
+ then
+ :
+ else
+--- 4338,4344 ----
+ exit (0); }
+
+ EOF
+! if { (eval echo configure:4342: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
+ then
+ :
+ else
+***************
+*** 4357,4373 ****
+ do
+ ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
+ echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
+! echo "configure:4361: checking for $ac_hdr" >&5
+ if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
+ echo $ac_n "(cached) $ac_c" 1>&6
+ else
+ cat > conftest.$ac_ext <<EOF
+! #line 4366 "configure"
+ #include "confdefs.h"
+ #include <$ac_hdr>
+ EOF
+ ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
+! { (eval echo configure:4371: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+ ac_err=`grep -v '^ *+' conftest.out`
+ if test -z "$ac_err"; then
+ rm -rf conftest*
+--- 4365,4381 ----
+ do
+ ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
+ echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
+! echo "configure:4369: checking for $ac_hdr" >&5
+ if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
+ echo $ac_n "(cached) $ac_c" 1>&6
+ else
+ cat > conftest.$ac_ext <<EOF
+! #line 4374 "configure"
+ #include "confdefs.h"
+ #include <$ac_hdr>
+ EOF
+ ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
+! { (eval echo configure:4379: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+ ac_err=`grep -v '^ *+' conftest.out`
+ if test -z "$ac_err"; then
+ rm -rf conftest*
+***************
+*** 4396,4402 ****
+ # Extract the first word of "ranlib", so it can be a program name with args.
+ set dummy ranlib; ac_word=$2
+ echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
+! echo "configure:4400: checking for $ac_word" >&5
+ if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
+ echo $ac_n "(cached) $ac_c" 1>&6
+ else
+--- 4404,4410 ----
+ # Extract the first word of "ranlib", so it can be a program name with args.
+ set dummy ranlib; ac_word=$2
+ echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
+! echo "configure:4408: checking for $ac_word" >&5
+ if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
+ echo $ac_n "(cached) $ac_c" 1>&6
+ else
+***************
+*** 4423,4434 ****
+ fi
+
+ echo $ac_n "checking for pid_t""... $ac_c" 1>&6
+! echo "configure:4427: checking for pid_t" >&5
+ if eval "test \"`echo '$''{'ac_cv_type_pid_t'+set}'`\" = set"; then
+ echo $ac_n "(cached) $ac_c" 1>&6
+ else
+ cat > conftest.$ac_ext <<EOF
+! #line 4432 "configure"
+ #include "confdefs.h"
+ #include <sys/types.h>
+ #if STDC_HEADERS
+--- 4431,4442 ----
+ fi
+
+ echo $ac_n "checking for pid_t""... $ac_c" 1>&6
+! echo "configure:4435: checking for pid_t" >&5
+ if eval "test \"`echo '$''{'ac_cv_type_pid_t'+set}'`\" = set"; then
+ echo $ac_n "(cached) $ac_c" 1>&6
+ else
+ cat > conftest.$ac_ext <<EOF
+! #line 4440 "configure"
+ #include "confdefs.h"
+ #include <sys/types.h>
+ #if STDC_HEADERS
+***************
+*** 4457,4473 ****
+
+ ac_safe=`echo "vfork.h" | sed 'y%./+-%__p_%'`
+ echo $ac_n "checking for vfork.h""... $ac_c" 1>&6
+! echo "configure:4461: checking for vfork.h" >&5
+ if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
+ echo $ac_n "(cached) $ac_c" 1>&6
+ else
+ cat > conftest.$ac_ext <<EOF
+! #line 4466 "configure"
+ #include "confdefs.h"
+ #include <vfork.h>
+ EOF
+ ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
+! { (eval echo configure:4471: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+ ac_err=`grep -v '^ *+' conftest.out`
+ if test -z "$ac_err"; then
+ rm -rf conftest*
+--- 4465,4481 ----
+
+ ac_safe=`echo "vfork.h" | sed 'y%./+-%__p_%'`
+ echo $ac_n "checking for vfork.h""... $ac_c" 1>&6
+! echo "configure:4469: checking for vfork.h" >&5
+ if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
+ echo $ac_n "(cached) $ac_c" 1>&6
+ else
+ cat > conftest.$ac_ext <<EOF
+! #line 4474 "configure"
+ #include "confdefs.h"
+ #include <vfork.h>
+ EOF
+ ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
+! { (eval echo configure:4479: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+ ac_err=`grep -v '^ *+' conftest.out`
+ if test -z "$ac_err"; then
+ rm -rf conftest*
+***************
+*** 4492,4509 ****
+ fi
+
+ echo $ac_n "checking for working vfork""... $ac_c" 1>&6
+! echo "configure:4496: checking for working vfork" >&5
+ if eval "test \"`echo '$''{'ac_cv_func_vfork_works'+set}'`\" = set"; then
+ echo $ac_n "(cached) $ac_c" 1>&6
+ else
+ if test "$cross_compiling" = yes; then
+ echo $ac_n "checking for vfork""... $ac_c" 1>&6
+! echo "configure:4502: checking for vfork" >&5
+ if eval "test \"`echo '$''{'ac_cv_func_vfork'+set}'`\" = set"; then
+ echo $ac_n "(cached) $ac_c" 1>&6
+ else
+ cat > conftest.$ac_ext <<EOF
+! #line 4507 "configure"
+ #include "confdefs.h"
+ /* System header to define __stub macros and hopefully few prototypes,
+ which can conflict with char vfork(); below. */
+--- 4500,4517 ----
+ fi
+
+ echo $ac_n "checking for working vfork""... $ac_c" 1>&6
+! echo "configure:4504: checking for working vfork" >&5
+ if eval "test \"`echo '$''{'ac_cv_func_vfork_works'+set}'`\" = set"; then
+ echo $ac_n "(cached) $ac_c" 1>&6
+ else
+ if test "$cross_compiling" = yes; then
+ echo $ac_n "checking for vfork""... $ac_c" 1>&6
+! echo "configure:4510: checking for vfork" >&5
+ if eval "test \"`echo '$''{'ac_cv_func_vfork'+set}'`\" = set"; then
+ echo $ac_n "(cached) $ac_c" 1>&6
+ else
+ cat > conftest.$ac_ext <<EOF
+! #line 4515 "configure"
+ #include "confdefs.h"
+ /* System header to define __stub macros and hopefully few prototypes,
+ which can conflict with char vfork(); below. */
+***************
+*** 4526,4532 ****
+
+ ; return 0; }
+ EOF
+! if { (eval echo configure:4530: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+ rm -rf conftest*
+ eval "ac_cv_func_vfork=yes"
+ else
+--- 4534,4540 ----
+
+ ; return 0; }
+ EOF
+! if { (eval echo configure:4538: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+ rm -rf conftest*
+ eval "ac_cv_func_vfork=yes"
+ else
+***************
+*** 4547,4553 ****
+
+ else
+ cat > conftest.$ac_ext <<EOF
+! #line 4551 "configure"
+ #include "confdefs.h"
+ /* Thanks to Paul Eggert for this test. */
+ #include <stdio.h>
+--- 4555,4561 ----
+
+ else
+ cat > conftest.$ac_ext <<EOF
+! #line 4559 "configure"
+ #include "confdefs.h"
+ /* Thanks to Paul Eggert for this test. */
+ #include <stdio.h>
+***************
+*** 4642,4648 ****
+ }
+ }
+ EOF
+! if { (eval echo configure:4646: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
+ then
+ ac_cv_func_vfork_works=yes
+ else
+--- 4650,4656 ----
+ }
+ }
+ EOF
+! if { (eval echo configure:4654: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
+ then
+ ac_cv_func_vfork_works=yes
+ else
+***************
+*** 4665,4676 ****
+ fi
+
+ echo $ac_n "checking for popen""... $ac_c" 1>&6
+! echo "configure:4669: checking for popen" >&5
+ if eval "test \"`echo '$''{'ac_cv_func_popen'+set}'`\" = set"; then
+ echo $ac_n "(cached) $ac_c" 1>&6
+ else
+ cat > conftest.$ac_ext <<EOF
+! #line 4674 "configure"
+ #include "confdefs.h"
+ /* System header to define __stub macros and hopefully few prototypes,
+ which can conflict with char popen(); below. */
+--- 4673,4684 ----
+ fi
+
+ echo $ac_n "checking for popen""... $ac_c" 1>&6
+! echo "configure:4677: checking for popen" >&5
+ if eval "test \"`echo '$''{'ac_cv_func_popen'+set}'`\" = set"; then
+ echo $ac_n "(cached) $ac_c" 1>&6
+ else
+ cat > conftest.$ac_ext <<EOF
+! #line 4682 "configure"
+ #include "confdefs.h"
+ /* System header to define __stub macros and hopefully few prototypes,
+ which can conflict with char popen(); below. */
+***************
+*** 4693,4699 ****
+
+ ; return 0; }
+ EOF
+! if { (eval echo configure:4697: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+ rm -rf conftest*
+ eval "ac_cv_func_popen=yes"
+ else
+--- 4701,4707 ----
+
+ ; return 0; }
+ EOF
+! if { (eval echo configure:4705: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+ rm -rf conftest*
+ eval "ac_cv_func_popen=yes"
+ else
+***************
+*** 4724,4735 ****
+ # systems (unless it is set already), whether it will be needed or not.
+
+ echo $ac_n "checking for caddr_t""... $ac_c" 1>&6
+! echo "configure:4728: checking for caddr_t" >&5
+ if eval "test \"`echo '$''{'ac_cv_type_caddr_t'+set}'`\" = set"; then
+ echo $ac_n "(cached) $ac_c" 1>&6
+ else
+ cat > conftest.$ac_ext <<EOF
+! #line 4733 "configure"
+ #include "confdefs.h"
+ #include <sys/types.h>
+ #if STDC_HEADERS
+--- 4732,4743 ----
+ # systems (unless it is set already), whether it will be needed or not.
+
+ echo $ac_n "checking for caddr_t""... $ac_c" 1>&6
+! echo "configure:4736: checking for caddr_t" >&5
+ if eval "test \"`echo '$''{'ac_cv_type_caddr_t'+set}'`\" = set"; then
+ echo $ac_n "(cached) $ac_c" 1>&6
+ else
+ cat > conftest.$ac_ext <<EOF
+! #line 4741 "configure"
+ #include "confdefs.h"
+ #include <sys/types.h>
+ #if STDC_HEADERS
+***************
+*** 4869,4874 ****
+--- 4877,4885 ----
+ ;;
+ Linux* )
+ cat $srcdir/cf/lib_sh_linux.in >>Makefile.in
++ ;;
++ SCO* )
++ cat $srcdir/cf/lib_sh_sco.in >>Makefile.in
+ ;;
+ * )
+ cat $srcdir/cf/lib_sh.in >>Makefile.in
+diff -cbNr plplot-980407/doc/Makefile plplot-980407-new/doc/Makefile
+*** plplot-980407/doc/Makefile Tue Apr 7 20:02:59 1998
+--- plplot-980407-new/doc/Makefile Thu May 7 18:46:10 1998
+***************
+*** 44,50 ****
+ default: info dvi
+
+ info:
+! emacs -batch -l buildinfo.el
+ cp plplot.info $(HOME)/info
+ @echo "PLPLOT info file created and moved to info directory."
+
+--- 44,50 ----
+ default: info dvi
+
+ info:
+! xemacs -batch -l buildinfo.el
+ cp plplot.info $(HOME)/info
+ @echo "PLPLOT info file created and moved to info directory."
+
+diff -cbNr plplot-980407/drivers/plbuf.c plplot-980407-new/drivers/plbuf.c
+*** plplot-980407/drivers/plbuf.c Tue Apr 7 20:03:08 1998
+--- plplot-980407-new/drivers/plbuf.c Thu May 7 18:23:54 1998
+***************
+*** 615,623 ****
+--- 615,626 ----
+ break;
+
+ default:
++ pldebug("plbuf_control", "Unrecognized command %d, previous %d\n", c, c_old);
++ /* jc: modified for pldebug
+ fprintf(stderr,
+ "plbuf_control: Unrecognized command %d, previous %d\n",
+ c, c_old);
++ */
+ }
+ c_old = c;
+ }
+diff -cbNr plplot-980407/drivers/tk.c plplot-980407-new/drivers/tk.c
+*** plplot-980407/drivers/tk.c Tue Apr 7 20:03:09 1998
+--- plplot-980407-new/drivers/tk.c Thu May 7 18:23:54 1998
+***************
+*** 94,100 ****
+ #include <fcntl.h>
+ #include <errno.h>
+ #include <signal.h>
+!
+ #ifdef PLD_dp
+ #include <dp.h>
+ #endif
+--- 94,101 ----
+ #include <fcntl.h>
+ #include <errno.h>
+ #include <signal.h>
+! #include <sys/wait.h> // jc: waitpid
+! extern pid_t vfork(void); // jc:
+ #ifdef PLD_dp
+ #include <dp.h>
+ #endif
+***************
+*** 224,229 ****
+--- 225,231 ----
+ pls->dev_flush = 1; /* Handle our own flushes */
+ pls->dev_fill0 = 1; /* Handle solid fills */
+ pls->dev_fill1 = 1; /* Handle pattern fills */
++ pls->server_nokill = 1; /* jc: dont kill if ^C */
+
+ /* Specify buffer size if not yet set (can be changed by -bufmax option). */
+ /* A small buffer works best for socket communication */
+***************
+*** 704,709 ****
+--- 706,717 ----
+ /* Instantiate a TCL interpreter, and get rid of the exec command */
+
+ dev->interp = Tcl_CreateInterp();
++ #if (TCL_MAJOR_VERSION == 7 && TCL_MINOR_VERSION > 4 )
++ if (Tcl_Init(dev->interp) != TCL_OK) { // jc:
++ fprintf(stderr, "%s\n", dev->interp->result);
++ abort_session(pls, "Unable to initialize Tcl");
++ }
++ #endif
+ tcl_cmd(pls, "rename exec {}");
+
+ /* Initialize top level window */
+***************
+*** 720,725 ****
+--- 728,734 ----
+ char name[80];
+ sprintf(name, "_%s_%02d", pls->program, pls->ipls);
+ Tcl_SetVar(dev->interp, "dp", "0", TCL_GLOBAL_ONLY);
++ Tcl_SetVar2(dev->interp, "env", "DISPLAY", getenv("DISPLAY"), TCL_GLOBAL_ONLY); // jc: tk_init need this
+ dev->updatecmd = "update";
+ if (pltk_toplevel(&dev->w, dev->interp, pls->FileName, name, name))
+ abort_session(pls, "Unable to create top-level window");
+***************
+*** 1092,1097 ****
+--- 1101,1119 ----
+ argv[i++] = "-e"; /* Startup script */
+ argv[i++] = "plserver_init";
+
++ /* jc: Haaaaa. This is it! Without the next two statements, control is either
++ * in tk or octave, because tcl/tk was in interative mode (I think).
++ * This had the inconvenient of having to press the enter key or cliking a
++ * mouse button in the plot window after every plot.
++ *
++ * This couldn't be done with
++ * Tcl_SetVar(dev->interp, "tcl_interactive", "0", TCL_GLOBAL_ONLY);
++ * after plserver has been launched? It doesnt work, hoewever.
++ */
++
++ argv[i++] = "-file"; /* Startup file */
++ argv[i++] = "/dev/null";
++
+ if (pls->auto_path != NULL) {
+ argv[i++] = "-auto_path"; /* Additional directory(s) */
+ argv[i++] = pls->auto_path; /* to autoload */
+***************
+*** 1294,1299 ****
+--- 1316,1322 ----
+ bg = pls->cmap0[0].b | (pls->cmap0[0].g << 8) | (pls->cmap0[0].r << 16);
+ if (bg > 0) {
+ sprintf(command, "$plwidget configure -bg #%06x", bg);
++ sprintf(command, "$plwidget configure -plbg #%06x", bg); // jc:
+ server_cmd( pls, command, 0 );
+ }
+
+***************
+*** 1966,1972 ****
+ return 1;
+ }
+ #else
+! Tk_Init( interp );
+ #endif
+
+ Tcl_VarEval(interp, wcmd, (char *) NULL);
+--- 1989,1998 ----
+ return 1;
+ }
+ #else
+! if (Tk_Init( interp )) { // jc: if added
+! fprintf(stderr,"tk_init:%s\n", interp->result); // jc:
+! return 1;
+! }
+ #endif
+
+ Tcl_VarEval(interp, wcmd, (char *) NULL);
+diff -cbNr plplot-980407/drivers/xwin.c plplot-980407-new/drivers/xwin.c
+*** plplot-980407/drivers/xwin.c Tue Apr 7 20:03:10 1998
+--- plplot-980407-new/drivers/xwin.c Thu May 7 18:23:54 1998
+***************
+*** 933,938 ****
+--- 933,942 ----
+
+ /* Window title */
+
++ if (plsc->plwindow){ // jc:
++ sprintf(header, "%s", plsc->plwindow);
++ }
++ else
+ sprintf(header, "PLplot");
+
+ /* Window creation */
+diff -cbNr plplot-980407/examples/c/x17c.c plplot-980407-new/examples/c/x17c.c
+*** plplot-980407/examples/c/x17c.c Tue Apr 7 20:03:14 1998
+--- plplot-980407-new/examples/c/x17c.c Thu May 7 18:23:54 1998
+***************
+*** 1,8 ****
+! /* $Id: x17c.c,v 1.6 1998/04/07 17:34:52 furnish Exp $
+ * $Log: x17c.c,v $
+- * Revision 1.6 1998/04/07 17:34:52 furnish
+- * Fixed comment bug which annoyed fussy C compiler.
+- *
+ * Revision 1.5 1995/06/01 21:40:14 mjl
+ * All C demo files: changed file inclusion to use quotes instead of angle
+ * brackets so that dependencies are retained during development.
+--- 1,9 ----
+! /* jc: This is a much reworked version of x17c.c, a non-working demo
+! * on the distribution.
+! */
+!
+! /* $Id: x17c.c,v 1.5 1995/06/01 21:40:14 mjl Exp $
+ * $Log: x17c.c,v $
+ * Revision 1.5 1995/06/01 21:40:14 mjl
+ * All C demo files: changed file inclusion to use quotes instead of angle
+ * brackets so that dependencies are retained during development.
+***************
+*** 21,27 ****
+ * Preliminary stab at a strip chart demo (doesn't work yet).
+ */
+
+! /* Plots a simple stripchart.
+ * Eventually I want a really cool demo here: slowly evolving plots of
+ * say density and temperature. These only need to get updated every so
+ * often. And then at the bottom some strip charts of energy or such
+--- 22,28 ----
+ * Preliminary stab at a strip chart demo (doesn't work yet).
+ */
+
+! /* Plots a simple stripchart with four pens.
+ * Eventually I want a really cool demo here: slowly evolving plots of
+ * say density and temperature. These only need to get updated every so
+ * often. And then at the bottom some strip charts of energy or such
+***************
+*** 29,72 ****
+ */
+
+ #include "plcdemos.h"
+!
+! /* Data declarations for stripcharts. */
+!
+! typedef struct {
+! PLINT npts, nptsmax;
+! PLFLT *x, *y;
+! PLFLT xmin, xmax, ymin, ymax, xjump, xlen;
+!
+! char *xspec, *yspec, *labx, *laby, *labtop;
+! PLINT colbox, colline, collab;
+! } PLStrip;
+!
+! static int sid; /* strip id number */
+! static PLStrip *strip[100]; /* Array of pointers */
+! static PLStrip *stripc; /* current strip chart */
+!
+! /* Create 1d stripchart */
+!
+! void
+! plstripc(PLINT *id, char *xspec, char *yspec,
+! PLFLT xmin, PLFLT xmax, PLFLT xjump, PLFLT ymin, PLFLT ymax,
+! PLINT colbox, PLINT colline, PLINT collab,
+! char *labx, char *laby, char *labtop);
+!
+! /* Generates a complete stripchart plot. */
+!
+! void
+! plstrip_gen(PLStrip *strip);
+!
+! /* Add a point to a stripchart. */
+!
+! void
+! plstripa(PLINT id, PLFLT x, PLFLT y);
+!
+! /* Deletes and releases memory used by a stripchart. */
+!
+! void
+! plstripd(PLINT id);
+
+ /*--------------------------------------------------------------------------*\
+ * main program
+--- 30,36 ----
+ */
+
+ #include "plcdemos.h"
+! #include <poll.h>
+
+ /*--------------------------------------------------------------------------*\
+ * main program
+***************
+*** 75,114 ****
+ int
+ main(int argc, char *argv[])
+ {
+! PLINT id, n, nsteps = 1000;
+! PLFLT y, ymin, ymax;
+! PLFLT t, tmin, tmax, tjump, dt;
+! PLINT colbox, collab, colline;
+!
+! fprintf(stderr, "Sorry, this demo not yet in working order\n");
+! exit(1);
+
+ /* plplot initialization */
+ /* Parse and process command line arguments */
+
+ (void) plParseOpts(&argc, argv, PL_PARSE_FULL);
+
+! plSetOpt("db", "");
+ plSetOpt("np", "");
+
+- /* Initialize plplot */
+-
+- plinit();
+-
+- /* Create strip chart */
+-
+ /* User sets up plot completely except for window and data
+ * Eventually settings in place when strip chart is created will be
+ * remembered so that multiple strip charts can be used simultaneously.
+ */
+
+- pladv(0);
+-
+- /* For now just a standard viewport */
+-
+- plvsta();
+- plcol(4);
+-
+ /* Specify some reasonable defaults for ymin and ymax */
+ /* The plot will grow automatically if needed (but not shrink) */
+
+--- 39,65 ----
+ int
+ main(int argc, char *argv[])
+ {
+! PLINT id1, id2, n, autoy, acc, nsteps = 1000;
+! PLFLT y1, y2, y3, y4, ymin, ymax, xlab, ylab;
+! PLFLT t, tmin, tmax, tjump, dt, noise;
+! PLINT colbox, collab, colline[4], styline[4];
+! char *legline[4], toplab[20];
+
+ /* plplot initialization */
+ /* Parse and process command line arguments */
+
+ (void) plParseOpts(&argc, argv, PL_PARSE_FULL);
+
+! // If db is used the plot is much more smooth. However, because of the
+! // async X behaviour, one does not have a real-time scripcharter.
+! // plSetOpt("db", "");
+ plSetOpt("np", "");
+
+ /* User sets up plot completely except for window and data
+ * Eventually settings in place when strip chart is created will be
+ * remembered so that multiple strip charts can be used simultaneously.
+ */
+
+ /* Specify some reasonable defaults for ymin and ymax */
+ /* The plot will grow automatically if needed (but not shrink) */
+
+***************
+*** 120,328 ****
+ /* This can accomodate adaptive timesteps */
+
+ tmin = 0.;
+! tmax = 100.;
+! tjump = 25.;
+
+ /* Axes options same as plbox. */
+ /* Only automatic tick generation and label placement allowed */
+ /* Eventually I'll make this fancier */
+
+ colbox = 1;
+- colline = 4;
+ collab = 3;
+
+! plstripc(&id, "bcnst", "bcnstv",
+ tmin, tmax, tjump, ymin, ymax,
+! colbox, colline, collab,
+! "t", "d", "displacement vs time");
+
+ /* This is to represent a loop over time */
+ /* Let's try a random walk process */
+
+! y = 0.0;
+ dt = 0.1;
+- for (n = 0; n < nsteps; n++) {
+- t = n * dt;
+- y = y + rand();
+
+! plstripa(id, t, y);
+ }
+
+ /* Destroy strip chart and it's memory */
+
+! plstripd(id);
+!
+ plend();
+ exit(0);
+- }
+-
+- /*--------------------------------------------------------------------------*\
+- * plstripc
+- *
+- * Create 1d stripchart.
+- \*--------------------------------------------------------------------------*/
+-
+- void
+- plstripc(PLINT *id, char *xspec, char *yspec,
+- PLFLT xmin, PLFLT xmax, PLFLT xjump, PLFLT ymin, PLFLT ymax,
+- PLINT colbox, PLINT colline, PLINT collab,
+- char *labx, char *laby, char *labtop)
+- {
+- int i;
+-
+- /* Get a free strip id and allocate it */
+-
+- for (i = 0; i < 100; i++) {
+- if (strip[i] == NULL)
+- break;
+- }
+-
+- if (i == 0) {
+- fprintf(stderr, "plstripc: Cannot create new strip chart\n");
+- *id = -1;
+- return;
+- }
+- else {
+- sid = *id = i;
+- strip[sid] = (PLStrip *) malloc((size_t) sizeof(PLStrip));
+- if (strip[sid] == NULL)
+- plexit("plstripc: Out of memory.");
+-
+- memset((char *) strip[sid], 0, sizeof(PLStrip));
+- }
+-
+- /* Fill up the struct with all relevant info */
+-
+- stripc = strip[sid];
+-
+- stripc->npts = 0;
+- stripc->nptsmax = 100;
+- stripc->x = (PLFLT *) malloc((size_t) sizeof(PLFLT) * stripc->nptsmax);;
+- stripc->y = (PLFLT *) malloc((size_t) sizeof(PLFLT) * stripc->nptsmax);;
+- if (stripc->x == NULL || stripc->y == NULL)
+- plexit("plstripc: Out of memory.");
+-
+- stripc->xmin = xmin;
+- stripc->xmax = xmax;
+- stripc->ymin = ymin;
+- stripc->ymax = ymax;
+- stripc->xjump = xjump;
+- stripc->xlen = xmax - xmin;
+- stripc->xspec = xspec;
+- stripc->yspec = yspec;
+- stripc->labx = labx;
+- stripc->laby = laby;
+- stripc->labtop = labtop;
+- stripc->colbox = colbox;
+- stripc->colline = colline;
+- stripc->collab = collab;
+-
+- /* Generate the plot */
+-
+- plstrip_gen(stripc);
+- }
+-
+- /*--------------------------------------------------------------------------*\
+- * plstrip_gen
+- *
+- * Generates a complete stripchart plot. Used either initially or
+- * during rescaling.
+- \*--------------------------------------------------------------------------*/
+-
+- void
+- plstrip_gen(PLStrip *strip)
+- {
+-
+- /* Set up window */
+-
+- plwind(strip->xmin, strip->xmax, strip->ymin, strip->ymax);
+-
+- /* Draw box */
+-
+- plcol(strip->colbox);
+- plbox(strip->xspec, 0.0, 0, strip->yspec, 0.0, 0);
+-
+- plcol(strip->collab);
+- pllab(strip->labx, strip->laby, strip->labtop);
+-
+- if (strip->npts > 0) {
+- plcol(strip->colline);
+- plline(strip->npts, strip->x, strip->y);
+- }
+- }
+-
+- /*--------------------------------------------------------------------------*\
+- * plstripa
+- *
+- * Add a point to a stripchart.
+- * Allocates memory and rescales as necessary.
+- \*--------------------------------------------------------------------------*/
+-
+- void
+- plstripa(PLINT id, PLFLT x, PLFLT y)
+- {
+- int i, istart;
+-
+- stripc = strip[id];
+-
+- /* Add new point, allocating memory if necessary */
+-
+- if (++stripc->npts > stripc->nptsmax) {
+- stripc->nptsmax += 32;
+- stripc->x = (PLFLT *) realloc((void *) stripc->x, stripc->nptsmax);
+- stripc->y = (PLFLT *) realloc((void *) stripc->y, stripc->nptsmax);
+- }
+- stripc->x[stripc->npts-1] = x;
+- stripc->y[stripc->npts-1] = y;
+-
+- stripc->xmax = x;
+- stripc->ymax = MAX(y, stripc->ymax);
+- stripc->ymin = MIN(y, stripc->ymin);
+-
+- /* Now either plot new point or regenerate plot */
+-
+- if (stripc->xmax - stripc->xmin < stripc->xlen) {
+- plP_movwor(stripc->x[stripc->npts-2], stripc->y[stripc->npts-2]);
+- plP_drawor(stripc->x[stripc->npts-1], stripc->y[stripc->npts-1]);
+- }
+- else {
+-
+- /* Regenerating plot */
+- /* First push back the x scale */
+-
+- stripc->xmin -= stripc->xjump;
+- stripc->xmax -= stripc->xjump;
+- istart = 0;
+- while (stripc->x[istart] - stripc->xjump < 0.)
+- istart++;
+-
+- stripc->npts -= istart;
+- for (i = 0; i < stripc->npts; i++) {
+- stripc->x[i] = stripc->x[i+istart];
+- stripc->y[i] = stripc->y[i+istart];
+- }
+-
+- stripc->xmin = stripc->x[0];
+- stripc->xmax = stripc->x[stripc->npts];
+-
+- /* Now do the real work */
+-
+- plstrip_gen(stripc);
+- }
+- }
+-
+- /*--------------------------------------------------------------------------*\
+- * plstripd
+- *
+- * Deletes and releases memory used by a stripchart.
+- \*--------------------------------------------------------------------------*/
+-
+- void
+- plstripd(PLINT id)
+- {
+- stripc = strip[id];
+-
+- free((void *) stripc->x);
+- free((void *) stripc->y);
+- free((void *) stripc);
+ }
+--- 71,148 ----
+ /* This can accomodate adaptive timesteps */
+
+ tmin = 0.;
+! tmax = 10.;
+! tjump = 0.3; // percentage of plot to jump
+
+ /* Axes options same as plbox. */
+ /* Only automatic tick generation and label placement allowed */
+ /* Eventually I'll make this fancier */
+
+ colbox = 1;
+ collab = 3;
++ styline[0] = colline[0] = 2; // pens color and line style
++ styline[1] = colline[1] = 3;
++ styline[2] = colline[2] = 4;
++ styline[3] = colline[3] = 5;
++
++ legline[0] = "sum"; // pens legend
++ legline[1] = "sin";
++ legline[2] = "sin*noi";
++ legline[3] = "sin+noi";
++
++ xlab = 0.; ylab = 0.25; // legend position
++
++ autoy = 0; // autoscale y
++ acc = 1; // dont scrip, accumulate
++
++ /* Initialize plplot */
+
+! plinit();
+! pladv(0);
+! plvsta();
+!
+! plstripc(&id1, "bcnst", "bcnstv",
+ tmin, tmax, tjump, ymin, ymax,
+! xlab, ylab,
+! autoy, acc,
+! colbox, collab,
+! colline, styline, legline,
+! "t", "", "Strip chart demo");
+!
+! autoy = 0; // autoscale y
+! acc = 1; // accumulate
+
+ /* This is to represent a loop over time */
+ /* Let's try a random walk process */
+
+! y1 = y2 = y3 = y4 = 0.0;
+ dt = 0.1;
+
+! for (n = 0; n < nsteps; n++) {
+! poll(0,0,10); // wait a little (10 ms) to simulate time elapsing
+! t = (double)n * dt;
+! noise = drand48() - 0.5;
+! y1 = y1 + noise;
+! y2 = sin(t*3.1415926/18.);
+! y3 = y2 * noise;
+! y4 = y2 + noise/3.;
+!
+! // there is no need for all pens to have the same number of points
+! // or beeing equally time spaced.
+!
+! if (n%2)
+! plstripa(id1, 0, t, y1);
+! if (n%3)
+! plstripa(id1, 1, t, y2);
+! if (n%4)
+! plstripa(id1, 2, t, y3);
+! if (n%5)
+! plstripa(id1, 3, t, y4);
+ }
+
+ /* Destroy strip chart and it's memory */
+
+! plstripd(id1);
+ plend();
+ exit(0);
+ }
+diff -cbNr plplot-980407/examples/c/x18c.c plplot-980407-new/examples/c/x18c.c
+*** plplot-980407/examples/c/x18c.c Tue Apr 7 20:03:14 1998
+--- plplot-980407-new/examples/c/x18c.c Thu May 7 18:23:54 1998
+***************
+*** 121,128 ****
+
+ void test_poly(int k)
+ {
+! float *x, *y, *z;
+! float theta, phi;
+ int i, j;
+ float pi, two_pi;
+ int draw[][4] = { { 1, 1, 1, 1 },
+--- 121,128 ----
+
+ void test_poly(int k)
+ {
+! PLFLT *x, *y, *z;
+! PLFLT theta, phi;
+ int i, j;
+ float pi, two_pi;
+ int draw[][4] = { { 1, 1, 1, 1 },
+diff -cbNr plplot-980407/include/plplot.h plplot-980407-new/include/plplot.h
+*** plplot-980407/include/plplot.h Tue Apr 7 20:03:34 1998
+--- plplot-980407-new/include/plplot.h Thu May 7 16:31:22 1998
+***************
+*** 546,551 ****
+--- 546,554 ----
+ #define plssym c_plssym
+ #define plstar c_plstar
+ #define plstart c_plstart
++ #define plstripa c_plstripa
++ #define plstripc c_plstripc
++ #define plstripd c_plstripd
+ #define plstyl c_plstyl
+ #define plsvpa c_plsvpa
+ #define plsxax c_plsxax
+***************
+*** 656,661 ****
+--- 659,667 ----
+ #define c_plssym plssym
+ #define c_plstar plstar
+ #define c_plstart plstart
++ #define c_plstripa plstripa
++ #define c_plstripc plstripc
++ #define c_plstripd plstripd
+ #define c_plstyl plstyl
+ #define c_plsvpa plsvpa
+ #define c_plsxax plsxax
+***************
+*** 1239,1244 ****
+--- 1245,1271 ----
+
+ void
+ c_plstart(const char *devname, PLINT nx, PLINT ny);
++
++ /* Create 1d stripchart */
++
++ void
++ c_plstripc(PLINT *id, char *xspec, char *yspec,
++ PLFLT xmin, PLFLT xmax, PLFLT xjump, PLFLT ymin, PLFLT ymax,
++ PLFLT xlpos, PLFLT ylpos,
++ PLINT y_ascl, PLINT acc,
++ PLINT colbox, PLINT collab,
++ PLINT colline[], PLINT styline[], char *legline[],
++ char *labx, char *laby, char *labtop);
++
++ /* Add a point to a stripchart. */
++
++ void
++ c_plstripa(PLINT id, PLINT pen, PLFLT x, PLFLT y);
++
++ /* Deletes and releases memory used by a stripchart. */
++
++ void
++ c_plstripd(PLINT id);
+
+ /* Set up a new line style */
+
+diff -cbNr plplot-980407/src/plargs.c plplot-980407-new/src/plargs.c
+*** plplot-980407/src/plargs.c Tue Apr 7 20:03:43 1998
+--- plplot-980407-new/src/plargs.c Thu May 7 18:23:54 1998
+***************
+*** 176,181 ****
+--- 176,183 ----
+
+ See plrender.c for examples of actual usage. */
+
++ #include <stdio.h> // jc: popen
++ #include <string.h> // jc: strdup
+ #include "plplotP.h"
+ #include <ctype.h>
+
+***************
+*** 1803,1809 ****
+ static int
+ opt_plwindow(char *opt, char *optarg, void *client_data)
+ {
+! plsc->plwindow = optarg;
+ return 0;
+ }
+
+--- 1805,1813 ----
+ static int
+ opt_plwindow(char *opt, char *optarg, void *client_data)
+ {
+!
+! // jc: plsc->plwindow = optarg;
+! plsc->plwindow = strdup(optarg); // jc: somehow the original string is lost
+ return 0;
+ }
+
+diff -cbNr plplot-980407/src/plctrl.c plplot-980407-new/src/plctrl.c
+*** plplot-980407/src/plctrl.c Tue Apr 7 20:03:44 1998
+--- plplot-980407-new/src/plctrl.c Thu May 7 18:23:54 1998
+***************
+*** 83,89 ****
+ don't know where it should go, put it here.
+ */
+
+! #define DEBUG
+
+ #include "plplotP.h"
+
+--- 83,89 ----
+ don't know where it should go, put it here.
+ */
+
+! int readlink (char *path, char *buf, int bufsiz); // jc:
+
+ #include "plplotP.h"
+
+diff -cbNr plplot-980407/src/plstripc.c plplot-980407-new/src/plstripc.c
+*** plplot-980407/src/plstripc.c Thu Jan 1 00:00:00 1970
+--- plplot-980407-new/src/plstripc.c Thu May 7 18:23:54 1998
+***************
+*** 0 ****
+--- 1,354 ----
++ /* jc: This is a much reworked version of x17c.c, a non-working demo
++ * on the distribution.
++ *
++ * ToDo: better way of clearing plot. search for `plvsta'.
++ */
++
++ /* $Id: x17c.c,v 1.5 1995/06/01 21:40:14 mjl Exp $
++ * $Log: x17c.c,v $
++ * Revision 1.5 1995/06/01 21:40:14 mjl
++ * All C demo files: changed file inclusion to use quotes instead of angle
++ * brackets so that dependencies are retained during development.
++ *
++ * Revision 1.4 1995/04/12 08:19:02 mjl
++ * Changes to all C demos: now include "plcdemos.h" to get all startup
++ * definitions and includes that are useful to share between them.
++ *
++ * Revision 1.3 1995/03/16 23:18:59 mjl
++ * All example C programs: changed plParseInternalOpts() call to plParseOpts().
++ *
++ * Revision 1.2 1994/08/05 09:28:42 mjl
++ * Put in an early bail-out since it's not working yet.
++ *
++ * Revision 1.1 1994/04/08 12:08:54 mjl
++ * Preliminary stab at a strip chart demo (doesn't work yet).
++ */
++
++ /* Plots a simple stripchart.
++ * Eventually I want a really cool demo here: slowly evolving plots of
++ * say density and temperature. These only need to get updated every so
++ * often. And then at the bottom some strip charts of energy or such
++ * that are continually updated.
++ */
++
++ #include "plplotP.h"
++ #include "plplot.h"
++
++ /* Data declarations for stripcharts. */
++
++ #define PEN 4
++
++ typedef struct {
++ PLFLT xmin, xmax, ymin, ymax, xjump, xlen;
++ PLFLT wxmin, wxmax, wymin, wymax; // FIXME - some redundancy might exist
++ char *xspec, *yspec, *labx, *laby, *labtop;
++ PLINT y_ascl, acc, colbox, collab;
++ PLFLT xlpos, ylpos;
++ PLFLT *x[PEN], *y[PEN];
++ PLINT npts[PEN], nptsmax[PEN];
++ PLINT colline[PEN], styline[PEN];
++ char *legline[PEN];
++ } PLStrip;
++
++ static int sid; /* strip id number */
++ static PLStrip *strip[100]; /* Array of pointers */
++ static PLStrip *stripc; /* current strip chart */
++
++ /* Generates a complete stripchart plot. */
++
++ static void
++ plstrip_gen(PLStrip *strip);
++
++ /* draw legend */
++
++ static void
++ plstrip_legend(PLStrip *strip, int flag);
++
++ char *strdup(char *);
++ /*--------------------------------------------------------------------------*\
++ * plstripc
++ *
++ * Create 1d stripchart.
++ \*--------------------------------------------------------------------------*/
++
++ void
++ plstripc(PLINT *id, char *xspec, char *yspec,
++ PLFLT xmin, PLFLT xmax, PLFLT xjump, PLFLT ymin, PLFLT ymax,
++ PLFLT xlpos, PLFLT ylpos,
++ PLINT y_ascl, PLINT acc,
++ PLINT colbox, PLINT collab,
++ PLINT *colline, PLINT *styline, char *legline[],
++ char *labx, char *laby, char *labtop)
++ {
++ int i;
++
++ /* Get a free strip id and allocate it */
++
++ for (i = 0; i < 100; i++)
++ if (strip[i] == NULL)
++ break;
++
++ if (i == 100) {
++ plabort("plstripc: Cannot create new strip chart");
++ *id = -1;
++ return;
++ }
++ else {
++ sid = *id = i;
++ strip[sid] = (PLStrip *) calloc(1, (size_t) sizeof(PLStrip));
++ if (strip[sid] == NULL) {
++ plabort("plstripc: Out of memory.");
++ *id = -1;
++ return;
++ }
++ }
++
++ /* Fill up the struct with all relevant info */
++
++ stripc = strip[sid];
++
++ for (i=0; i<PEN; i++) {
++ stripc->npts[i] = 0;
++ stripc->nptsmax[i] = 100;
++ stripc->colline[i] = colline[i];
++ stripc->styline[i] = styline[i];
++ stripc->legline[i] = strdup(legline[i]); // strdup() is needed because value must persist after call has finished
++ stripc->x[i] = (PLFLT *) malloc((size_t) sizeof(PLFLT) * stripc->nptsmax[i]);;
++ stripc->y[i] = (PLFLT *) malloc((size_t) sizeof(PLFLT) * stripc->nptsmax[i]);;
++ if (stripc->x[i] == NULL || stripc->y[i] == NULL) {
++ plabort("plstripc: Out of memory.");
++ plstripd(sid);
++ *id = -1;
++ return;
++ }
++ }
++
++ stripc->xlpos = xlpos; // legend position [0..1]
++ stripc->ylpos = ylpos;
++ stripc->xmin = xmin; // initial bounding box
++ stripc->xmax = xmax;
++ stripc->ymin = ymin;
++ stripc->ymax = ymax;
++ stripc->xjump = xjump; // jump x step(%) when x attains xmax (xmax is then set to xmax+xjump)
++ stripc->xlen = xmax - xmin; // lenght of x scale
++ stripc->y_ascl = y_ascl; // autoscale y between x jump scale
++ stripc->acc = acc; // accumulate plot (not really stripchart)
++ stripc->xspec = strdup(xspec); // x axis specification
++ stripc->yspec = strdup(yspec); // strdup() is needed because value must persist after call has finished
++ stripc->labx = strdup(labx); // x label
++ stripc->laby = strdup(laby);
++ stripc->labtop = strdup(labtop); // title
++ stripc->colbox = colbox; // box color
++ stripc->collab = collab; // label color
++
++ /* Generate the plot */
++
++ plstrip_gen(stripc);
++ plstrip_legend(stripc,1);
++ }
++
++ void plstrip_legend(PLStrip *stripc, int first)
++ {
++ int i;
++ PLFLT sc, dy;
++
++ // draw legend
++
++ plgchr(&sc, &dy);
++ sc = dy = dy/100;
++ plwind(-0.01, 1.01, -0.01, 1.01);
++ for (i=0; i<PEN; i++) {
++ if (stripc->npts[i] || first) {
++ plcol(stripc->colline[i]); pllsty(stripc->styline[i]);
++ pljoin(stripc->xlpos, stripc->ylpos - sc, stripc->xlpos + 0.1, stripc->ylpos - sc);
++ plcol(stripc->collab);
++ plptex(stripc->xlpos + 0.11, stripc->ylpos - sc, 0., 0., 0, stripc->legline[i]);sc += dy;
++ }
++ }
++ plwind(stripc->xmin, stripc->xmax, stripc->ymin, stripc->ymax);
++ plflush();
++ }
++
++ /*--------------------------------------------------------------------------*\
++ * plstrip_gen
++ *
++ * Generates a complete stripchart plot. Used either initially or
++ * during rescaling.
++ \*--------------------------------------------------------------------------*/
++ PLFLT oxm,oxM, oym,oyM;
++ void
++ plstrip_gen(PLStrip *strip)
++ {
++ int i;
++ PLFLT x[]={0.,1.,1.,0.}, y[]={0.,0.,1.,1.};
++
++ /* Set up window */
++
++ /* dont know how to clear only one subwindow. Any hints?) */
++
++ // plbop();
++ // pleop();
++ // pladv(0);
++
++ // what about this way?
++
++ plvpor(0,1,0,1);
++ plwind(0,1,0,1);
++ plcol(0);plpsty(0);
++ plfill(4, &x[0], &y[0]);
++ plvsta();
++
++ /* Draw box and same window dimensions */
++ strip->wxmin=strip->xmin; strip->wxmax=strip->xmax;
++ strip->wymin=strip->ymin; strip->wymax=strip->ymax; // FIXME - can exist some redundancy here
++
++ plwind(strip->xmin, strip->xmax, strip->ymin, strip->ymax);
++
++ pllsty(1);
++ plcol(strip->colbox);
++ plbox(strip->xspec, 0.0, 0, strip->yspec, 0.0, 0);
++
++ plcol(strip->collab);
++ pllab(strip->labx, strip->laby, strip->labtop);
++
++ for (i=0; i<PEN; i++) {
++ if (strip->npts[i] > 0) {
++ plcol(strip->colline[i]);pllsty(strip->styline[i]);
++ plline(strip->npts[i], strip->x[i], strip->y[i]);
++ }
++ }
++
++ plstrip_legend(strip,0);
++ }
++
++ /*--------------------------------------------------------------------------*\
++ * plstripa
++ *
++ * Add a point to a stripchart.
++ * Allocates memory and rescales as necessary.
++ \*--------------------------------------------------------------------------*/
++
++ void
++ plstripa(PLINT id, PLINT p, PLFLT x, PLFLT y)
++ {
++ int j, yasc=0, istart;
++
++ if (p >= PEN) {
++ plabort("Non existent pen");
++ return;
++ }
++
++ if (strip[id] == NULL) {
++ plabort("Non existent stripchart");
++ return;
++ }
++
++ stripc = strip[id];
++
++ /* Add new point, allocating memory if necessary */
++
++ if (++stripc->npts[p] > stripc->nptsmax[p]) {
++ stripc->nptsmax[p] += 32;
++ stripc->x[p] = (PLFLT *) realloc((void *) stripc->x[p], sizeof(PLFLT)*stripc->nptsmax[p]);
++ stripc->y[p] = (PLFLT *) realloc((void *) stripc->y[p], sizeof(PLFLT)*stripc->nptsmax[p]);
++ if (stripc->x[p] == NULL || stripc->y[p] == NULL) {
++ plabort("plstripc: Out of memory.");
++ plstripd(id);
++ return;
++ }
++ }
++
++ stripc->x[p][stripc->npts[p]-1] = x;
++ stripc->y[p][stripc->npts[p]-1] = y;
++
++ // if ( x > stripc->xmax)
++ stripc->xmax = x;
++
++ if (stripc->y_ascl == 1 && (y > stripc->ymax || y < stripc->ymin))
++ yasc=1;
++
++ stripc->ymax = MAX(y, stripc->ymax);
++ stripc->ymin = MIN(y, stripc->ymin);
++
++ /* Now either plot new point or regenerate plot */
++
++ if (stripc->xmax - stripc->xmin < stripc->xlen) {
++ if( yasc == 0) {
++
++ // If user has changed subwindow, make shure we have the correct one
++ plvsta();
++ plwind(stripc->wxmin, stripc->wxmax, stripc->wymin, stripc->wymax); // FIXME - can exist some redundancy here
++
++ plcol(stripc->colline[p]); pllsty(stripc->styline[p]);
++ plP_movwor(stripc->x[p][stripc->npts[p]-2], stripc->y[p][stripc->npts[p]-2]);
++ plP_drawor(stripc->x[p][stripc->npts[p]-1], stripc->y[p][stripc->npts[p]-1]);
++ plflush();
++ }
++ else {
++ stripc->xmax = stripc->xmin + stripc->xlen;
++ plstrip_gen(stripc);
++ }
++ }
++ else {
++ /* Regenerating plot */
++ if (stripc->acc == 0) {
++ for (j=0; j<PEN; j++) {
++ if (stripc->npts[j] > 0) {
++ istart = 0;
++ while (stripc->x[j][istart] < stripc->xmin + stripc->xlen*stripc->xjump)
++ istart++;
++
++ stripc->npts[j] = stripc->npts[j] - istart;
++ /* make it faster
++ for (i = 0; i < stripc->npts[j]; i++) {
++ stripc->x[j][i] = stripc->x[j][i+istart];
++ stripc->y[j][i] = stripc->y[j][i+istart];
++ }
++ */
++ memcpy( &stripc->x[j][0], &stripc->x[j][istart], (stripc->npts[j])*sizeof(PLFLT));
++ memcpy( &stripc->y[j][0], &stripc->y[j][istart], (stripc->npts[j])*sizeof(PLFLT));
++ }
++ }
++ } else
++ stripc->xlen = stripc->xlen * (1 + stripc->xjump);
++
++ stripc->xmin = stripc->x[p][0];
++ stripc->xmax = stripc->xmax + stripc->xlen*stripc->xjump;
++
++ plstrip_gen(stripc);
++ }
++ }
++
++ /*--------------------------------------------------------------------------*\
++ * plstripd
++ *
++ * Deletes and releases memory used by a stripchart.
++ \*--------------------------------------------------------------------------*/
++
++ void
++ plstripd(PLINT id)
++ {
++ int i;
++ stripc = strip[id];
++
++ if (stripc == NULL) {
++ plwarn("No such stripchart");
++ return;
++ }
++
++ for (i=0; i<PEN; i++) {
++ if (stripc->npts[i]) {
++ free((void *) stripc->x[i]);
++ free((void *) stripc->y[i]);
++ free(stripc->legline[i]);
++ }
++ }
++
++ free(stripc->xspec);
++ free(stripc->yspec);
++ free(stripc->labx);
++ free(stripc->laby);
++ free(stripc->labtop);
++ free((void *) stripc);
++ strip[id] = NULL;
++ }
+diff -cbNr plplot-980407/src/plvpor.c plplot-980407-new/src/plvpor.c
+*** plplot-980407/src/plvpor.c Tue Apr 7 20:03:46 1998
+--- plplot-980407-new/src/plvpor.c Thu May 7 18:23:54 1998
+***************
+*** 111,125 ****
+--- 111,137 ----
+ case 11:
+ plbox("bclnst", (PLFLT) 0.0, 0, "abcnstv", (PLFLT) 0.0, 0);
+ break;
++ case 12:
++ plbox("bclgnst", (PLFLT) 0.0, 0, "abcgnstv", (PLFLT) 0.0, 0);
++ break;
+ case 20:
+ plbox("bcnst", (PLFLT) 0.0, 0, "bclnstv", (PLFLT) 0.0, 0);
+ break;
+ case 21:
+ plbox("bcnst", (PLFLT) 0.0, 0, "abclnstv", (PLFLT) 0.0, 0);
+ break;
++ case 22:
++ plbox("bcngst", (PLFLT) 0.0, 0, "abcglnstv", (PLFLT) 0.0, 0);
++ break;
+ case 30:
+ plbox("bclnst", (PLFLT) 0.0, 0, "bclnstv", (PLFLT) 0.0, 0);
+ break;
++ case 31:
++ plbox("bclnst", (PLFLT) 0.0, 0, "abclnstv", (PLFLT) 0.0, 0);
++ break;
++ case 32:
++ plbox("bclngst", (PLFLT) 0.0, 0, "abcglnstv", (PLFLT) 0.0, 0);
++ break;
+ default:
+ plwarn("plenv: Invalid axis argument");
+ }
diff --git a/debian/plplot-dev.README.Debian b/debian/plplot-dev.README.Debian
new file mode 100644
index 0000000..b9d0fe6
--- /dev/null
+++ b/debian/plplot-dev.README.Debian
@@ -0,0 +1,24 @@
+plplot-dev for DEBIAN
+----------------------
+
+To link with plplot, specify:
+
+ -lplplotdX -L/usr/X11R6/lib -lX11 -lm
+ for X support alone (xwin driver)
+ -lplplotdtk -ltk8.0 -ltcl8.0 -lMatrix -L/usr/X11R6/lib -lX11 -lm
+ for Tk support (tk driver)
+
+To link with the C++ library, specify also:
+
+ -lPLcxx
+
+The package was compiled with floating point type DOUBLE. You have to
+use the definition
+
+ #define PL_DOUBLE
+
+and use PLFLT as floating point type everywhere in your code.
+
+
+Rafael Laboissiere <rafael at icp.inpg.fr>, Tue, 16 Jun 1998 20:14:20 +0200
+
diff --git a/debian/plplot-dev.dirs b/debian/plplot-dev.dirs
new file mode 100644
index 0000000..da07fdd
--- /dev/null
+++ b/debian/plplot-dev.dirs
@@ -0,0 +1,2 @@
+usr/include
+usr/lib
diff --git a/debian/plplot-dev.files b/debian/plplot-dev.files
new file mode 100644
index 0000000..be6cff4
--- /dev/null
+++ b/debian/plplot-dev.files
@@ -0,0 +1,9 @@
+usr/lib/libPLcxx.so
+usr/lib/libplplotdtk.a
+usr/lib/libplplotdX.a
+usr/lib/libPLcxx.a
+usr/lib/libplplotdX.so
+usr/lib/libplplotdtk.so
+usr/lib/libMatrix.so
+usr/lib/libMatrix.a
+usr/include
diff --git a/debian/plplot-doc.README.Debian b/debian/plplot-doc.README.Debian
new file mode 100644
index 0000000..8826423
--- /dev/null
+++ b/debian/plplot-doc.README.Debian
@@ -0,0 +1,13 @@
+plplot-doc for DEBIAN
+----------------------
+
+This package contains documentation for PLplot, a scientific plotting
+library, in PostScript and info formats. Also included are several
+examples of code in C, C++, Fortran, Tcl/Tk, and Python. Almost
+everything is under /usr/doc/plplot.
+
+See file /usr/doc/plplot/README.Debian for additional information.
+
+Rafael Laboissiere <rafael at icp.inpg.fr>, Fri Nov 13 02:50:16 CET 1998
+
+
diff --git a/debian/plplot-doc.compress b/debian/plplot-doc.compress
new file mode 100644
index 0000000..a24fc86
--- /dev/null
+++ b/debian/plplot-doc.compress
@@ -0,0 +1,9 @@
+#! /bin/sh
+# compress (debhelper file) for plplot package
+# Written by Rafael Laboissiere <rafael at icp.inpg.fr>
+# on Mon, 22 Jun 1998 19:56:26 +0200
+
+find usr/doc -type f \
+ ! -name "copyright" ! -name "*.tcl" ! -name "tk??" \
+ ! -name "*.py" ! -name "xtkpy" ! -name "pytkdemo"
+
diff --git a/debian/plplot-doc.files b/debian/plplot-doc.files
new file mode 100644
index 0000000..08b82ef
--- /dev/null
+++ b/debian/plplot-doc.files
@@ -0,0 +1,3 @@
+usr/doc/plplot/FAQ
+usr/doc/plplot/examples
+usr/doc/plplot/plplot.ps.gz
diff --git a/debian/plplot-tcl.README.Debian b/debian/plplot-tcl.README.Debian
new file mode 100644
index 0000000..cabd65f
--- /dev/null
+++ b/debian/plplot-tcl.README.Debian
@@ -0,0 +1,14 @@
+plplot-tcl for DEBIAN
+----------------------
+
+Contains Tcl/Tk bindings for PLplot, a scientific plotting library.
+
+Programs for interactive use of PLplot, as well as some utilities for
+converting PLplot meta files are also included.
+
+See file /usr/doc/plplot/README.Debian for additional information.
+
+Rafael Laboissiere <rafael at icp.inpg.fr>, Fri Nov 13 02:51:13 CET 1998
+
+
+
diff --git a/debian/plplot-tcl.dirs b/debian/plplot-tcl.dirs
new file mode 100644
index 0000000..3530780
--- /dev/null
+++ b/debian/plplot-tcl.dirs
@@ -0,0 +1 @@
+usr/lib/tcl8.0
diff --git a/debian/plplot-tcl.files b/debian/plplot-tcl.files
new file mode 100644
index 0000000..a4b9aca
--- /dev/null
+++ b/debian/plplot-tcl.files
@@ -0,0 +1,13 @@
+usr/bin/plrender
+usr/bin/plserver
+usr/bin/plm2gif
+usr/bin/plpr
+usr/bin/pltcl
+usr/man/man1/plrender.1
+usr/man/man1/plserver.1
+usr/man/man1/plm2gif.1
+usr/man/man1/plpr.1
+usr/man/man1/pltcl.1
+usr/lib/tcl8.0
+
+
diff --git a/debian/plplot.dirs b/debian/plplot.dirs
new file mode 100644
index 0000000..eea63d6
--- /dev/null
+++ b/debian/plplot.dirs
@@ -0,0 +1,3 @@
+usr/lib
+usr/lib/plplot
+usr/lib/python1.5
diff --git a/debian/plpr.1 b/debian/plpr.1
new file mode 100644
index 0000000..fefed7d
--- /dev/null
+++ b/debian/plpr.1
@@ -0,0 +1,25 @@
+.\" -*- nroff -*-
+.TH PLPR 1
+.SH NAME
+plpr \- converts PLplot metafile to something the printer will understand
+.SH SYNOPSIS
+.B plpr
+.I "file"
+.SH "DESCRIPTION"
+This manual page documents briefly the
+.BR plpr ,
+command.
+This manual page was written for the Debian GNU/Linux distribution
+because the original program does not have a manual page.
+.PP
+.B plpr
+Takes the named metafile and converts it to something your printer
+will understand. This will be improved later to handle multiple
+printers and printer settings. Only intended for use from the
+plplot/TK driver! It deletes the named metafile after converting to
+the proper type so this is not suitable for general use.
+.SH "SEE ALSO"
+See /usr/doc/plplot/plplot.ps.gz for more details.
+.SH AUTHOR
+This manual page was written by Rafael Laboissiere <rafael at icp.inpg.fr>,
+for the Debian GNU/Linux system (but may be used by others).
diff --git a/debian/plrender.1 b/debian/plrender.1
new file mode 100644
index 0000000..d053ef8
--- /dev/null
+++ b/debian/plrender.1
@@ -0,0 +1,23 @@
+.\" -*- nroff -*-
+.TH PLRENDER 1
+.SH NAME
+plrender \- render a PLplot metafile
+.SH SYNOPSIS
+.B plrender
+.I "file [file ...]"
+.SH DESCRIPTION
+This manual page documents briefly the
+.BR plrender
+command.
+This manual page was written for the Debian GNU/Linux distribution
+because the original program does not have a manual page.
+.PP
+.B plrender
+is a program that renders files in PLplot metafile format, written by
+the metafile driver, which is one of the drivers available for PLplot.
+At least one file must be given as argument.
+.SH "SEE ALSO"
+See /usr/doc/plplot/plplot.ps.gz for more details.
+.SH AUTHOR
+This manual page was written by Rafael Laboissiere <rafael at icp.inpg.fr>,
+for the Debian GNU/Linux system (but may be used by others).
diff --git a/debian/plserver.1 b/debian/plserver.1
new file mode 100644
index 0000000..0b19d62
--- /dev/null
+++ b/debian/plserver.1
@@ -0,0 +1,28 @@
+.\" -*- nroff -*-
+.TH PLSERVER 1
+.SH NAME
+plserver \- PLplot graphics server
+.SH SYNOPSIS
+.B plserver
+.I "[args]"
+.SH "DESCRIPTION"
+This manual page documents briefly the
+.BR plserver ,
+command.
+This manual page was written for the Debian GNU/Linux distribution
+because the original program does not have a manual page.
+.PP
+.B plserver
+is just a front-end to the pltkMain() function. Structured along the
+preferred lines for extended wish'es. It typically runs as a child
+process from the PLplot TK driver to render output. Can use either TK
+send or Tcl-DP RPC for communication, depending on how it is invoked.
+.PP
+Note that plserver can be used the same way as wish or dpwish, as it
+contains the functionality of each of these (except the -notk Tcl-DP
+command-line option is not supported).
+.SH "SEE ALSO"
+See /usr/doc/plplot/plplot.ps.gz for more details.
+.SH AUTHOR
+This manual page was written by Rafael Laboissiere <rafael at icp.inpg.fr>,
+for the Debian GNU/Linux system (but may be used by others).
diff --git a/debian/pltcl.1 b/debian/pltcl.1
new file mode 100644
index 0000000..51ad904
--- /dev/null
+++ b/debian/pltcl.1
@@ -0,0 +1,21 @@
+.\" -*- nroff -*-
+.TH PLTCL 1
+.SH NAME
+pltcl \- Tcl interface to PLplot
+.SH SYNOPSIS
+.B pltcl
+.SH "DESCRIPTION"
+This manual page documents briefly the
+.BR pltcl
+command.
+This manual page was written for the Debian GNU/Linux distribution
+because the original program does not have a manual page.
+.PP
+.B plrender
+is the main program for Tcl nterface to PLplot. Allows interpretive
+execution of plotting primitives without regard to output driver.
+.SH "SEE ALSO"
+See /usr/doc/plplot/plplot.ps.gz for more details.
+.SH AUTHOR
+This manual page was written by Rafael Laboissiere <rafael at icp.inpg.fr>,
+for the Debian GNU/Linux system (but may be used by others).
diff --git a/debian/pltek.1 b/debian/pltek.1
new file mode 100644
index 0000000..025a548
--- /dev/null
+++ b/debian/pltek.1
@@ -0,0 +1,22 @@
+.\" -*- nroff -*-
+.TH PLTEK 1
+.SH NAME
+pltek \- review a Tektronix vector file.
+.SH SYNOPSIS
+.B pltek
+.I "file"
+.SH "DESCRIPTION"
+This manual page documents briefly the
+.BR pltek
+command.
+This manual page was written for the Debian GNU/Linux distribution
+because the original program does not have a manual page.
+.PP
+.B pltek
+is a program that review a Tektronix vector file whose name is given
+as argument.
+.SH "SEE ALSO"
+See /usr/doc/plplot/plplot.ps.gz for more details.
+.SH AUTHOR
+This manual page was written by Rafael Laboissiere <rafael at icp.inpg.fr>,
+for the Debian GNU/Linux system (but may be used by others).
diff --git a/debian/postinst b/debian/postinst
new file mode 100644
index 0000000..3e5174b
--- /dev/null
+++ b/debian/postinst
@@ -0,0 +1,24 @@
+#!/bin/sh
+#
+# postinst script for the Debian GNU/Linux plplot package
+#
+# Written by Rafael Laboissiere <rafael at icp.inpg.fr>
+# on Fri Nov 13 02:54:30 CET 1998
+
+set -e
+
+case "$1" in
+ configure)
+ ldconfig
+ install-info --quiet --section Math PLplot \
+ --description="A scientific plotting package" \
+ /usr/info/plplot.info.gz
+ ;;
+ abort-upgrade|abort-remove|abort-deconfigure)
+ ;;
+ *)
+ echo "postinst called with unknown argument \`$1'" >&2
+ ;;
+esac
+
+exit 0
diff --git a/debian/postrm b/debian/postrm
new file mode 100644
index 0000000..d496265
--- /dev/null
+++ b/debian/postrm
@@ -0,0 +1,26 @@
+#!/bin/sh
+#
+# postinst script for the Debian GNU/Linux plplot package
+#
+# Written by Rafael Laboissiere <rafael at icp.inpg.fr>
+# on Fri Nov 13 02:54:30 CET 1998
+
+set -e
+
+case "$1" in
+ remove|purge)
+ install-info --quiet --remove plplot
+ ;;
+
+ upgrade)
+ ;;
+
+ failed-upgrade|abort-install|abort-upgrade|disappear)
+ ;;
+
+ *)
+ echo "postrm called with unknown argument \`$1'" >&2
+ exit 0
+ ;;
+esac
+
diff --git a/debian/python-exec-header b/debian/python-exec-header
new file mode 100644
index 0000000..4f0800a
--- /dev/null
+++ b/debian/python-exec-header
@@ -0,0 +1 @@
+#! /usr/bin/python
diff --git a/debian/python-plplot.README.Debian b/debian/python-plplot.README.Debian
new file mode 100644
index 0000000..b69bd55
--- /dev/null
+++ b/debian/python-plplot.README.Debian
@@ -0,0 +1,16 @@
+python-plplot for DEBIAN
+------------------------
+
+Contains a module with Python bindings for PLplot, a scientific
+plotting library.
+
+********** WARNING *************
+THIS PACKAGE IS NOT WORKING WITH PYTHON 1.5. I WILL SOON APPLY A
+PATCH FOUND AT http://www.geog.ubc.ca/~phil/python/plplot.html TO
+SOLVE THE PROBLEM.
+
+Sorry for any inconvenience.
+*******************************
+
+Rafael Laboissiere <rafael at icp.inpg.fr>, Tue, Tue Oct 13 19:43:41 CEST 1998
+
diff --git a/debian/python-plplot.dirs b/debian/python-plplot.dirs
new file mode 100644
index 0000000..0936234
--- /dev/null
+++ b/debian/python-plplot.dirs
@@ -0,0 +1,2 @@
+usr/lib/python1.5
+usr/lib/python1.5/site-packages
diff --git a/debian/python-plplot.files b/debian/python-plplot.files
new file mode 100644
index 0000000..621814d
--- /dev/null
+++ b/debian/python-plplot.files
@@ -0,0 +1 @@
+usr/lib/python1.5/site-packages
diff --git a/debian/rules b/debian/rules
new file mode 100755
index 0000000..dc6fee5
--- /dev/null
+++ b/debian/rules
@@ -0,0 +1,161 @@
+#!/usr/bin/make -f
+# -*- Makefile -*-
+# Made with the aid of dh_make, by Craig Small
+# Sample debian/rules that uses debhelper. GNU copyright 1997 by Joey Hess.
+# This version is for a hypothetical package that builds an
+# architecture-dependant package, as well as an architecture-independant
+# package.
+# Modified by Rafael Laboissere <rafael at icp.inpg.fr> on 1998/06/12
+# for the plplot package
+
+# Uncomment this to turn on verbose mode.
+#export DH_VERBOSE=1
+
+major_version=$(shell expr `pwd` : '.*-\([0-9]*\)\.[0-9]*')
+minor_version=$(shell expr `pwd` : '.*-[0-9]*\.\([0-9]*\)')
+version=$(major_version).$(minor_version)
+
+debbase := $(shell pwd)/debian
+debtmp := $(debbase)/tmp
+
+build: build-stamp
+build-stamp:
+ dh_testdir
+ ( cd cf ; \
+ autoconf ; \
+ mv configure .. )
+# Build first bare libraries (no Tcl/Tk) and save them
+ ./configure --prefix=/usr --enable-tcl=no --enable-tk=no \
+ --enable-cxx=no --enable-python=no \
+ --with-double
+ make
+ cp tmp/libplplotdX.{a,so}* debian
+# Now build the normal ones
+ make clean
+ ./configure --prefix=/usr --with-double
+# Save the generated Makefile, as it contains the right references to /usr
+ cp tmp/Makefile $(debbase)/Makefile.save
+ make
+ cp tmp/libplplotdtk.{a,so}* debian
+ touch build-stamp
+
+clean:
+ dh_testdir
+ dh_testroot
+ rm -f build-stamp
+ -$(MAKE) clean
+ rm -f configure confdefs.h config.log \
+ $(debbase)/libplplot* $(debbase)/Makefile.save
+ dh_clean
+
+install: install-stamp
+install-stamp: build-stamp
+ dh_testdir
+ dh_testroot
+ dh_clean -k
+# The `usr/lib/python1.5' argument to dh_installdirs is necessary
+# because the python installation procedure tests for its existence
+ dh_installdirs -a -i usr/lib/python1.5
+
+ ./configure --prefix=$(debtmp)/usr --with-double
+ cp tmp/libMatrix.so.$(version) $(debtmp)/usr/lib
+ ( cd $(debtmp)/usr/lib ; \
+ ln -fs libMatrix.so.$(version) libMatrix.so.$(major_version) ; \
+ ln -fs libMatrix.so.$(major_version) libMatrix.so )
+ make install
+
+ cp doc/plplot.ps.gz $(debtmp)/usr/doc/plplot
+ cp doc/plplot.info.gz $(debtmp)/usr/info
+# Replaces the right Makefile in examples directory
+ mv $(debbase)/Makefile.save $(debtmp)/usr/doc/plplot/examples/Makefile
+# Put the right Debian python command in python scripts
+# Suggested by Mathias Klose <doko at cs.tu-berlin.de>
+# Special fix for x16.py (Grmpf...)
+ ( cd $(debtmp)/usr/doc/plplot/examples/python ; \
+ for i in * ; do \
+ cp $$i TMP ; \
+ sed -e 's,^#!.*python.*,#! /usr/bin/python,' < TMP > $$i ; \
+ chmod +x $$i ; \
+ done ; \
+ cp x16.py TMP ; \
+ cat $(debbase)/python-exec-header TMP > x16.py ; \
+ rm TMP )
+# Idem for the Tk scripts
+# Has to make scripts executable, so that permissions are right in the
+# source package (suggested by Paul Slootman <paul at wau.mis.ah.nl> )
+ chmod +x $(debbase)/fix-tk-path.pl
+ ( for i in $(debtmp)/usr/doc/plplot/examples/tk/tk* ; do \
+ cp $$i TMP ; \
+ $(debbase)/fix-tk-path.pl < TMP > $$i ; \
+ chmod +x $$i ; \
+ done ; \
+ rm TMP )
+# Fix symbolic links in examples directory
+ ( cd $(debtmp)/usr/doc/plplot/examples ; \
+ for i in c c++ f77 python tcl tk ; do \
+ rm -f $$i/Makefile ; \
+ ln -fs ../Makefile $$i/Makefile ; \
+ done )
+# Fix permission for plcolor.tcl and tkdemos.tcl
+ chmod -x $(debtmp)/usr/lib/tcl8.0/plplot/plcolor.tcl \
+ $(debtmp)/usr/doc/plplot/examples/tk/tkdemos.tcl
+# Move library files and create links
+ mv $(debbase)/libplplot*.{a,so.$(version).0} $(debtmp)/usr/lib
+ ( cd $(debtmp)/usr/lib ; \
+ for lib in libplplotdX libplplotdtk ; do \
+ rm -f $$lib.so.$(version) ; \
+ ln -fs $$lib.so.$(version).0 $$lib.so.$(major_version) ; \
+ ln -fs $$lib.so.$(major_version) $$lib.so ; \
+ done )
+
+ ( cd $(debtmp)/usr/doc/plplot ; \
+ mv CHANGES changelog ; \
+ rm -f Copyright COPYING.LIB mklinks README.local )
+
+# Install man pages by hand
+ mkdir -p $(debtmp)/usr/man/man1
+ cp $(debbase)/*.1 $(debtmp)/usr/man/man1
+
+
+ dh_movefiles
+# Do not know why dh_movefiles does not delete empty directories
+ ( cd $(debtmp)/usr ; \
+ rm -rf doc/plplot/examples \
+ lib/python1.5 lib/tcl8.0 include )
+ touch install-stamp
+
+# Build architecture-independent files here.
+binary-indep: build install
+ dh_testdir -i
+ dh_testroot -i
+ dh_installdocs -i
+ dh_installchangelogs -i
+ dh_compress -i
+ dh_fixperms -i
+ dh_suidregister -i
+ dh_installdeb -i
+ dh_gencontrol -i
+ dh_md5sums -i
+ dh_builddeb -i
+
+binary-arch: build install
+ dh_testdir -a
+ dh_testroot -a
+ dh_installdocs -a
+ dh_installchangelogs -a
+ dh_strip -a
+ dh_compress -a
+ dh_fixperms -a
+ dh_suidregister -a
+ dh_installdeb -a
+ dh_shlibdeps -a --no-package=python-plplot
+ dh_gencontrol -a
+ dh_makeshlibs -a
+ dh_md5sums -a
+ dh_builddeb -a
+
+source diff:
+ @echo >&2 'source and diff are obsolete - use dpkg-source -b'; false
+
+binary: binary-indep binary-arch
+.PHONY: build clean binary-indep binary-arch binary
diff --git a/drivers/plbuf.c b/drivers/plbuf.c
index fc97c5d..f340205 100644
--- a/drivers/plbuf.c
+++ b/drivers/plbuf.c
@@ -615,9 +615,12 @@ plbuf_control(PLStream *pls, U_CHAR c)
break;
default:
+ pldebug("plbuf_control", "Unrecognized command %d, previous %d\n", c, c_old);
+/* jc: modified for pldebug
fprintf(stderr,
"plbuf_control: Unrecognized command %d, previous %d\n",
c, c_old);
+*/
}
c_old = c;
}
diff --git a/drivers/tk.c b/drivers/tk.c
index 828df8d..f886be0 100644
--- a/drivers/tk.c
+++ b/drivers/tk.c
@@ -94,7 +94,8 @@
#include <fcntl.h>
#include <errno.h>
#include <signal.h>
-
+#include <sys/wait.h> // jc: waitpid
+extern pid_t vfork(void); // jc:
#ifdef PLD_dp
#include <dp.h>
#endif
@@ -224,6 +225,7 @@ init(PLStream *pls)
pls->dev_flush = 1; /* Handle our own flushes */
pls->dev_fill0 = 1; /* Handle solid fills */
pls->dev_fill1 = 1; /* Handle pattern fills */
+ pls->server_nokill = 1; /* jc: dont kill if ^C */
/* Specify buffer size if not yet set (can be changed by -bufmax option). */
/* A small buffer works best for socket communication */
@@ -704,6 +706,12 @@ tk_start(PLStream *pls)
/* Instantiate a TCL interpreter, and get rid of the exec command */
dev->interp = Tcl_CreateInterp();
+#if (TCL_MAJOR_VERSION == 7 && TCL_MINOR_VERSION > 4 )
+ if (Tcl_Init(dev->interp) != TCL_OK) { // jc:
+ fprintf(stderr, "%s\n", dev->interp->result);
+ abort_session(pls, "Unable to initialize Tcl");
+ }
+#endif
tcl_cmd(pls, "rename exec {}");
/* Initialize top level window */
@@ -720,6 +728,7 @@ tk_start(PLStream *pls)
char name[80];
sprintf(name, "_%s_%02d", pls->program, pls->ipls);
Tcl_SetVar(dev->interp, "dp", "0", TCL_GLOBAL_ONLY);
+ Tcl_SetVar2(dev->interp, "env", "DISPLAY", getenv("DISPLAY"), TCL_GLOBAL_ONLY); // jc: tk_init need this
dev->updatecmd = "update";
if (pltk_toplevel(&dev->w, dev->interp, pls->FileName, name, name))
abort_session(pls, "Unable to create top-level window");
@@ -1092,6 +1101,19 @@ launch_server(PLStream *pls)
argv[i++] = "-e"; /* Startup script */
argv[i++] = "plserver_init";
+/* jc: Haaaaa. This is it! Without the next two statements, control is either
+ * in tk or octave, because tcl/tk was in interative mode (I think).
+ * This had the inconvenient of having to press the enter key or cliking a
+ * mouse button in the plot window after every plot.
+ *
+ * This couldn't be done with
+ * Tcl_SetVar(dev->interp, "tcl_interactive", "0", TCL_GLOBAL_ONLY);
+ * after plserver has been launched? It doesnt work, hoewever.
+ */
+
+ argv[i++] = "-file"; /* Startup file */
+ argv[i++] = "/dev/null";
+
if (pls->auto_path != NULL) {
argv[i++] = "-auto_path"; /* Additional directory(s) */
argv[i++] = pls->auto_path; /* to autoload */
@@ -1294,6 +1316,7 @@ plwindow_init(PLStream *pls)
bg = pls->cmap0[0].b | (pls->cmap0[0].g << 8) | (pls->cmap0[0].r << 16);
if (bg > 0) {
sprintf(command, "$plwidget configure -bg #%06x", bg);
+ sprintf(command, "$plwidget configure -plbg #%06x", bg); // jc:
server_cmd( pls, command, 0 );
}
@@ -1966,7 +1989,10 @@ pltk_toplevel(Tk_Window *w, Tcl_Interp *interp,
return 1;
}
#else
- Tk_Init( interp );
+ if (Tk_Init( interp )) { // jc: if added
+ fprintf(stderr,"tk_init:%s\n", interp->result); // jc:
+ return 1;
+ }
#endif
Tcl_VarEval(interp, wcmd, (char *) NULL);
diff --git a/drivers/xwin.c b/drivers/xwin.c
index 34191d9..323c333 100644
--- a/drivers/xwin.c
+++ b/drivers/xwin.c
@@ -933,6 +933,10 @@ InitMain(PLStream *pls)
/* Window title */
+ if (plsc->plwindow){ // jc:
+ sprintf(header, "%s", plsc->plwindow);
+ }
+ else
sprintf(header, "PLplot");
/* Window creation */
diff --git a/examples/c/x17c.c b/examples/c/x17c.c
index ad7ca73..8c13a3d 100644
--- a/examples/c/x17c.c
+++ b/examples/c/x17c.c
@@ -1,8 +1,9 @@
-/* $Id: x17c.c,v 1.6 1998/04/07 17:34:52 furnish Exp $
+/* jc: This is a much reworked version of x17c.c, a non-working demo
+ * on the distribution.
+ */
+
+/* $Id: x17c.c,v 1.5 1995/06/01 21:40:14 mjl Exp $
* $Log: x17c.c,v $
- * Revision 1.6 1998/04/07 17:34:52 furnish
- * Fixed comment bug which annoyed fussy C compiler.
- *
* Revision 1.5 1995/06/01 21:40:14 mjl
* All C demo files: changed file inclusion to use quotes instead of angle
* brackets so that dependencies are retained during development.
@@ -21,7 +22,7 @@
* Preliminary stab at a strip chart demo (doesn't work yet).
*/
-/* Plots a simple stripchart.
+/* Plots a simple stripchart with four pens.
* Eventually I want a really cool demo here: slowly evolving plots of
* say density and temperature. These only need to get updated every so
* often. And then at the bottom some strip charts of energy or such
@@ -29,44 +30,7 @@
*/
#include "plcdemos.h"
-
-/* Data declarations for stripcharts. */
-
-typedef struct {
- PLINT npts, nptsmax;
- PLFLT *x, *y;
- PLFLT xmin, xmax, ymin, ymax, xjump, xlen;
-
- char *xspec, *yspec, *labx, *laby, *labtop;
- PLINT colbox, colline, collab;
-} PLStrip;
-
-static int sid; /* strip id number */
-static PLStrip *strip[100]; /* Array of pointers */
-static PLStrip *stripc; /* current strip chart */
-
-/* Create 1d stripchart */
-
-void
-plstripc(PLINT *id, char *xspec, char *yspec,
- PLFLT xmin, PLFLT xmax, PLFLT xjump, PLFLT ymin, PLFLT ymax,
- PLINT colbox, PLINT colline, PLINT collab,
- char *labx, char *laby, char *labtop);
-
-/* Generates a complete stripchart plot. */
-
-void
-plstrip_gen(PLStrip *strip);
-
-/* Add a point to a stripchart. */
-
-void
-plstripa(PLINT id, PLFLT x, PLFLT y);
-
-/* Deletes and releases memory used by a stripchart. */
-
-void
-plstripd(PLINT id);
+#include <poll.h>
/*--------------------------------------------------------------------------*\
* main program
@@ -75,40 +39,27 @@ plstripd(PLINT id);
int
main(int argc, char *argv[])
{
- PLINT id, n, nsteps = 1000;
- PLFLT y, ymin, ymax;
- PLFLT t, tmin, tmax, tjump, dt;
- PLINT colbox, collab, colline;
-
- fprintf(stderr, "Sorry, this demo not yet in working order\n");
- exit(1);
+ PLINT id1, id2, n, autoy, acc, nsteps = 1000;
+ PLFLT y1, y2, y3, y4, ymin, ymax, xlab, ylab;
+ PLFLT t, tmin, tmax, tjump, dt, noise;
+ PLINT colbox, collab, colline[4], styline[4];
+ char *legline[4], toplab[20];
/* plplot initialization */
/* Parse and process command line arguments */
(void) plParseOpts(&argc, argv, PL_PARSE_FULL);
- plSetOpt("db", "");
+// If db is used the plot is much more smooth. However, because of the
+// async X behaviour, one does not have a real-time scripcharter.
+// plSetOpt("db", "");
plSetOpt("np", "");
-/* Initialize plplot */
-
- plinit();
-
-/* Create strip chart */
-
/* User sets up plot completely except for window and data
* Eventually settings in place when strip chart is created will be
* remembered so that multiple strip charts can be used simultaneously.
*/
- pladv(0);
-
-/* For now just a standard viewport */
-
- plvsta();
- plcol(4);
-
/* Specify some reasonable defaults for ymin and ymax */
/* The plot will grow automatically if needed (but not shrink) */
@@ -120,209 +71,78 @@ main(int argc, char *argv[])
/* This can accomodate adaptive timesteps */
tmin = 0.;
- tmax = 100.;
- tjump = 25.;
+ tmax = 10.;
+ tjump = 0.3; // percentage of plot to jump
/* Axes options same as plbox. */
/* Only automatic tick generation and label placement allowed */
/* Eventually I'll make this fancier */
colbox = 1;
- colline = 4;
collab = 3;
+ styline[0] = colline[0] = 2; // pens color and line style
+ styline[1] = colline[1] = 3;
+ styline[2] = colline[2] = 4;
+ styline[3] = colline[3] = 5;
+
+ legline[0] = "sum"; // pens legend
+ legline[1] = "sin";
+ legline[2] = "sin*noi";
+ legline[3] = "sin+noi";
- plstripc(&id, "bcnst", "bcnstv",
+ xlab = 0.; ylab = 0.25; // legend position
+
+ autoy = 0; // autoscale y
+ acc = 1; // dont scrip, accumulate
+
+/* Initialize plplot */
+
+ plinit();
+ pladv(0);
+ plvsta();
+
+ plstripc(&id1, "bcnst", "bcnstv",
tmin, tmax, tjump, ymin, ymax,
- colbox, colline, collab,
- "t", "d", "displacement vs time");
+ xlab, ylab,
+ autoy, acc,
+ colbox, collab,
+ colline, styline, legline,
+ "t", "", "Strip chart demo");
+
+ autoy = 0; // autoscale y
+ acc = 1; // accumulate
/* This is to represent a loop over time */
/* Let's try a random walk process */
- y = 0.0;
+ y1 = y2 = y3 = y4 = 0.0;
dt = 0.1;
- for (n = 0; n < nsteps; n++) {
- t = n * dt;
- y = y + rand();
- plstripa(id, t, y);
+ for (n = 0; n < nsteps; n++) {
+ poll(0,0,10); // wait a little (10 ms) to simulate time elapsing
+ t = (double)n * dt;
+ noise = drand48() - 0.5;
+ y1 = y1 + noise;
+ y2 = sin(t*3.1415926/18.);
+ y3 = y2 * noise;
+ y4 = y2 + noise/3.;
+
+ // there is no need for all pens to have the same number of points
+ // or beeing equally time spaced.
+
+ if (n%2)
+ plstripa(id1, 0, t, y1);
+ if (n%3)
+ plstripa(id1, 1, t, y2);
+ if (n%4)
+ plstripa(id1, 2, t, y3);
+ if (n%5)
+ plstripa(id1, 3, t, y4);
}
/* Destroy strip chart and it's memory */
- plstripd(id);
-
+ plstripd(id1);
plend();
exit(0);
}
-
-/*--------------------------------------------------------------------------*\
- * plstripc
- *
- * Create 1d stripchart.
-\*--------------------------------------------------------------------------*/
-
-void
-plstripc(PLINT *id, char *xspec, char *yspec,
- PLFLT xmin, PLFLT xmax, PLFLT xjump, PLFLT ymin, PLFLT ymax,
- PLINT colbox, PLINT colline, PLINT collab,
- char *labx, char *laby, char *labtop)
-{
- int i;
-
-/* Get a free strip id and allocate it */
-
- for (i = 0; i < 100; i++) {
- if (strip[i] == NULL)
- break;
- }
-
- if (i == 0) {
- fprintf(stderr, "plstripc: Cannot create new strip chart\n");
- *id = -1;
- return;
- }
- else {
- sid = *id = i;
- strip[sid] = (PLStrip *) malloc((size_t) sizeof(PLStrip));
- if (strip[sid] == NULL)
- plexit("plstripc: Out of memory.");
-
- memset((char *) strip[sid], 0, sizeof(PLStrip));
- }
-
-/* Fill up the struct with all relevant info */
-
- stripc = strip[sid];
-
- stripc->npts = 0;
- stripc->nptsmax = 100;
- stripc->x = (PLFLT *) malloc((size_t) sizeof(PLFLT) * stripc->nptsmax);;
- stripc->y = (PLFLT *) malloc((size_t) sizeof(PLFLT) * stripc->nptsmax);;
- if (stripc->x == NULL || stripc->y == NULL)
- plexit("plstripc: Out of memory.");
-
- stripc->xmin = xmin;
- stripc->xmax = xmax;
- stripc->ymin = ymin;
- stripc->ymax = ymax;
- stripc->xjump = xjump;
- stripc->xlen = xmax - xmin;
- stripc->xspec = xspec;
- stripc->yspec = yspec;
- stripc->labx = labx;
- stripc->laby = laby;
- stripc->labtop = labtop;
- stripc->colbox = colbox;
- stripc->colline = colline;
- stripc->collab = collab;
-
-/* Generate the plot */
-
- plstrip_gen(stripc);
-}
-
-/*--------------------------------------------------------------------------*\
- * plstrip_gen
- *
- * Generates a complete stripchart plot. Used either initially or
- * during rescaling.
-\*--------------------------------------------------------------------------*/
-
-void
-plstrip_gen(PLStrip *strip)
-{
-
-/* Set up window */
-
- plwind(strip->xmin, strip->xmax, strip->ymin, strip->ymax);
-
-/* Draw box */
-
- plcol(strip->colbox);
- plbox(strip->xspec, 0.0, 0, strip->yspec, 0.0, 0);
-
- plcol(strip->collab);
- pllab(strip->labx, strip->laby, strip->labtop);
-
- if (strip->npts > 0) {
- plcol(strip->colline);
- plline(strip->npts, strip->x, strip->y);
- }
-}
-
-/*--------------------------------------------------------------------------*\
- * plstripa
- *
- * Add a point to a stripchart.
- * Allocates memory and rescales as necessary.
-\*--------------------------------------------------------------------------*/
-
-void
-plstripa(PLINT id, PLFLT x, PLFLT y)
-{
- int i, istart;
-
- stripc = strip[id];
-
-/* Add new point, allocating memory if necessary */
-
- if (++stripc->npts > stripc->nptsmax) {
- stripc->nptsmax += 32;
- stripc->x = (PLFLT *) realloc((void *) stripc->x, stripc->nptsmax);
- stripc->y = (PLFLT *) realloc((void *) stripc->y, stripc->nptsmax);
- }
- stripc->x[stripc->npts-1] = x;
- stripc->y[stripc->npts-1] = y;
-
- stripc->xmax = x;
- stripc->ymax = MAX(y, stripc->ymax);
- stripc->ymin = MIN(y, stripc->ymin);
-
-/* Now either plot new point or regenerate plot */
-
- if (stripc->xmax - stripc->xmin < stripc->xlen) {
- plP_movwor(stripc->x[stripc->npts-2], stripc->y[stripc->npts-2]);
- plP_drawor(stripc->x[stripc->npts-1], stripc->y[stripc->npts-1]);
- }
- else {
-
-/* Regenerating plot */
-/* First push back the x scale */
-
- stripc->xmin -= stripc->xjump;
- stripc->xmax -= stripc->xjump;
- istart = 0;
- while (stripc->x[istart] - stripc->xjump < 0.)
- istart++;
-
- stripc->npts -= istart;
- for (i = 0; i < stripc->npts; i++) {
- stripc->x[i] = stripc->x[i+istart];
- stripc->y[i] = stripc->y[i+istart];
- }
-
- stripc->xmin = stripc->x[0];
- stripc->xmax = stripc->x[stripc->npts];
-
-/* Now do the real work */
-
- plstrip_gen(stripc);
- }
-}
-
-/*--------------------------------------------------------------------------*\
- * plstripd
- *
- * Deletes and releases memory used by a stripchart.
-\*--------------------------------------------------------------------------*/
-
-void
-plstripd(PLINT id)
-{
- stripc = strip[id];
-
- free((void *) stripc->x);
- free((void *) stripc->y);
- free((void *) stripc);
-}
diff --git a/examples/c/x18c.c b/examples/c/x18c.c
index 566adb8..ba55b6e 100644
--- a/examples/c/x18c.c
+++ b/examples/c/x18c.c
@@ -121,8 +121,8 @@ main(int argc, char *argv[])
void test_poly(int k)
{
- float *x, *y, *z;
- float theta, phi;
+ PLFLT *x, *y, *z;
+ PLFLT theta, phi;
int i, j;
float pi, two_pi;
int draw[][4] = { { 1, 1, 1, 1 },
diff --git a/include/plplot.h b/include/plplot.h
index 7fc8eb3..13a7038 100644
--- a/include/plplot.h
+++ b/include/plplot.h
@@ -546,6 +546,9 @@ typedef struct {
#define plssym c_plssym
#define plstar c_plstar
#define plstart c_plstart
+#define plstripa c_plstripa
+#define plstripc c_plstripc
+#define plstripd c_plstripd
#define plstyl c_plstyl
#define plsvpa c_plsvpa
#define plsxax c_plsxax
@@ -656,6 +659,9 @@ typedef struct {
#define c_plssym plssym
#define c_plstar plstar
#define c_plstart plstart
+#define c_plstripa plstripa
+#define c_plstripc plstripc
+#define c_plstripd plstripd
#define c_plstyl plstyl
#define c_plsvpa plsvpa
#define c_plsxax plsxax
@@ -1240,6 +1246,27 @@ c_plstar(PLINT nx, PLINT ny);
void
c_plstart(const char *devname, PLINT nx, PLINT ny);
+/* Create 1d stripchart */
+
+void
+c_plstripc(PLINT *id, char *xspec, char *yspec,
+ PLFLT xmin, PLFLT xmax, PLFLT xjump, PLFLT ymin, PLFLT ymax,
+ PLFLT xlpos, PLFLT ylpos,
+ PLINT y_ascl, PLINT acc,
+ PLINT colbox, PLINT collab,
+ PLINT colline[], PLINT styline[], char *legline[],
+ char *labx, char *laby, char *labtop);
+
+/* Add a point to a stripchart. */
+
+void
+c_plstripa(PLINT id, PLINT pen, PLFLT x, PLFLT y);
+
+/* Deletes and releases memory used by a stripchart. */
+
+void
+c_plstripd(PLINT id);
+
/* Set up a new line style */
void
diff --git a/src/plargs.c b/src/plargs.c
index 903ae2e..60c883a 100644
--- a/src/plargs.c
+++ b/src/plargs.c
@@ -176,6 +176,8 @@ and the Massachusetts Institute of Technology, Cambridge, Massachusetts.
See plrender.c for examples of actual usage. */
+#include <stdio.h> // jc: popen
+#include <string.h> // jc: strdup
#include "plplotP.h"
#include <ctype.h>
@@ -1803,7 +1805,9 @@ opt_plserver(char *opt, char *optarg, void *client_data)
static int
opt_plwindow(char *opt, char *optarg, void *client_data)
{
- plsc->plwindow = optarg;
+
+// jc: plsc->plwindow = optarg;
+ plsc->plwindow = strdup(optarg); // jc: somehow the original string is lost
return 0;
}
diff --git a/src/plctrl.c b/src/plctrl.c
index 272fe97..8dd9d72 100644
--- a/src/plctrl.c
+++ b/src/plctrl.c
@@ -83,7 +83,7 @@
don't know where it should go, put it here.
*/
-#define DEBUG
+int readlink (char *path, char *buf, int bufsiz); // jc:
#include "plplotP.h"
diff --git a/src/plstripc.c b/src/plstripc.c
new file mode 100644
index 0000000..9f84a7d
--- /dev/null
+++ b/src/plstripc.c
@@ -0,0 +1,354 @@
+/* jc: This is a much reworked version of x17c.c, a non-working demo
+ * on the distribution.
+ *
+ * ToDo: better way of clearing plot. search for `plvsta'.
+ */
+
+/* $Id: x17c.c,v 1.5 1995/06/01 21:40:14 mjl Exp $
+ * $Log: x17c.c,v $
+ * Revision 1.5 1995/06/01 21:40:14 mjl
+ * All C demo files: changed file inclusion to use quotes instead of angle
+ * brackets so that dependencies are retained during development.
+ *
+ * Revision 1.4 1995/04/12 08:19:02 mjl
+ * Changes to all C demos: now include "plcdemos.h" to get all startup
+ * definitions and includes that are useful to share between them.
+ *
+ * Revision 1.3 1995/03/16 23:18:59 mjl
+ * All example C programs: changed plParseInternalOpts() call to plParseOpts().
+ *
+ * Revision 1.2 1994/08/05 09:28:42 mjl
+ * Put in an early bail-out since it's not working yet.
+ *
+ * Revision 1.1 1994/04/08 12:08:54 mjl
+ * Preliminary stab at a strip chart demo (doesn't work yet).
+*/
+
+/* Plots a simple stripchart.
+ * Eventually I want a really cool demo here: slowly evolving plots of
+ * say density and temperature. These only need to get updated every so
+ * often. And then at the bottom some strip charts of energy or such
+ * that are continually updated.
+ */
+
+#include "plplotP.h"
+#include "plplot.h"
+
+/* Data declarations for stripcharts. */
+
+#define PEN 4
+
+typedef struct {
+ PLFLT xmin, xmax, ymin, ymax, xjump, xlen;
+ PLFLT wxmin, wxmax, wymin, wymax; // FIXME - some redundancy might exist
+ char *xspec, *yspec, *labx, *laby, *labtop;
+ PLINT y_ascl, acc, colbox, collab;
+ PLFLT xlpos, ylpos;
+ PLFLT *x[PEN], *y[PEN];
+ PLINT npts[PEN], nptsmax[PEN];
+ PLINT colline[PEN], styline[PEN];
+ char *legline[PEN];
+} PLStrip;
+
+static int sid; /* strip id number */
+static PLStrip *strip[100]; /* Array of pointers */
+static PLStrip *stripc; /* current strip chart */
+
+/* Generates a complete stripchart plot. */
+
+static void
+plstrip_gen(PLStrip *strip);
+
+/* draw legend */
+
+static void
+plstrip_legend(PLStrip *strip, int flag);
+
+char *strdup(char *);
+/*--------------------------------------------------------------------------*\
+ * plstripc
+ *
+ * Create 1d stripchart.
+\*--------------------------------------------------------------------------*/
+
+void
+plstripc(PLINT *id, char *xspec, char *yspec,
+ PLFLT xmin, PLFLT xmax, PLFLT xjump, PLFLT ymin, PLFLT ymax,
+ PLFLT xlpos, PLFLT ylpos,
+ PLINT y_ascl, PLINT acc,
+ PLINT colbox, PLINT collab,
+ PLINT *colline, PLINT *styline, char *legline[],
+ char *labx, char *laby, char *labtop)
+{
+ int i;
+
+/* Get a free strip id and allocate it */
+
+ for (i = 0; i < 100; i++)
+ if (strip[i] == NULL)
+ break;
+
+ if (i == 100) {
+ plabort("plstripc: Cannot create new strip chart");
+ *id = -1;
+ return;
+ }
+ else {
+ sid = *id = i;
+ strip[sid] = (PLStrip *) calloc(1, (size_t) sizeof(PLStrip));
+ if (strip[sid] == NULL) {
+ plabort("plstripc: Out of memory.");
+ *id = -1;
+ return;
+ }
+ }
+
+/* Fill up the struct with all relevant info */
+
+ stripc = strip[sid];
+
+ for (i=0; i<PEN; i++) {
+ stripc->npts[i] = 0;
+ stripc->nptsmax[i] = 100;
+ stripc->colline[i] = colline[i];
+ stripc->styline[i] = styline[i];
+ stripc->legline[i] = strdup(legline[i]); // strdup() is needed because value must persist after call has finished
+ stripc->x[i] = (PLFLT *) malloc((size_t) sizeof(PLFLT) * stripc->nptsmax[i]);;
+ stripc->y[i] = (PLFLT *) malloc((size_t) sizeof(PLFLT) * stripc->nptsmax[i]);;
+ if (stripc->x[i] == NULL || stripc->y[i] == NULL) {
+ plabort("plstripc: Out of memory.");
+ plstripd(sid);
+ *id = -1;
+ return;
+ }
+ }
+
+ stripc->xlpos = xlpos; // legend position [0..1]
+ stripc->ylpos = ylpos;
+ stripc->xmin = xmin; // initial bounding box
+ stripc->xmax = xmax;
+ stripc->ymin = ymin;
+ stripc->ymax = ymax;
+ stripc->xjump = xjump; // jump x step(%) when x attains xmax (xmax is then set to xmax+xjump)
+ stripc->xlen = xmax - xmin; // lenght of x scale
+ stripc->y_ascl = y_ascl; // autoscale y between x jump scale
+ stripc->acc = acc; // accumulate plot (not really stripchart)
+ stripc->xspec = strdup(xspec); // x axis specification
+ stripc->yspec = strdup(yspec); // strdup() is needed because value must persist after call has finished
+ stripc->labx = strdup(labx); // x label
+ stripc->laby = strdup(laby);
+ stripc->labtop = strdup(labtop); // title
+ stripc->colbox = colbox; // box color
+ stripc->collab = collab; // label color
+
+/* Generate the plot */
+
+ plstrip_gen(stripc);
+ plstrip_legend(stripc,1);
+}
+
+void plstrip_legend(PLStrip *stripc, int first)
+{
+ int i;
+ PLFLT sc, dy;
+
+ // draw legend
+
+ plgchr(&sc, &dy);
+ sc = dy = dy/100;
+ plwind(-0.01, 1.01, -0.01, 1.01);
+ for (i=0; i<PEN; i++) {
+ if (stripc->npts[i] || first) {
+ plcol(stripc->colline[i]); pllsty(stripc->styline[i]);
+ pljoin(stripc->xlpos, stripc->ylpos - sc, stripc->xlpos + 0.1, stripc->ylpos - sc);
+ plcol(stripc->collab);
+ plptex(stripc->xlpos + 0.11, stripc->ylpos - sc, 0., 0., 0, stripc->legline[i]);sc += dy;
+ }
+ }
+ plwind(stripc->xmin, stripc->xmax, stripc->ymin, stripc->ymax);
+ plflush();
+}
+
+/*--------------------------------------------------------------------------*\
+ * plstrip_gen
+ *
+ * Generates a complete stripchart plot. Used either initially or
+ * during rescaling.
+\*--------------------------------------------------------------------------*/
+PLFLT oxm,oxM, oym,oyM;
+void
+plstrip_gen(PLStrip *strip)
+{
+ int i;
+ PLFLT x[]={0.,1.,1.,0.}, y[]={0.,0.,1.,1.};
+
+/* Set up window */
+
+/* dont know how to clear only one subwindow. Any hints?) */
+
+// plbop();
+// pleop();
+// pladv(0);
+
+// what about this way?
+
+ plvpor(0,1,0,1);
+ plwind(0,1,0,1);
+ plcol(0);plpsty(0);
+ plfill(4, &x[0], &y[0]);
+ plvsta();
+
+/* Draw box and same window dimensions */
+strip->wxmin=strip->xmin; strip->wxmax=strip->xmax;
+strip->wymin=strip->ymin; strip->wymax=strip->ymax; // FIXME - can exist some redundancy here
+
+ plwind(strip->xmin, strip->xmax, strip->ymin, strip->ymax);
+
+ pllsty(1);
+ plcol(strip->colbox);
+ plbox(strip->xspec, 0.0, 0, strip->yspec, 0.0, 0);
+
+ plcol(strip->collab);
+ pllab(strip->labx, strip->laby, strip->labtop);
+
+ for (i=0; i<PEN; i++) {
+ if (strip->npts[i] > 0) {
+ plcol(strip->colline[i]);pllsty(strip->styline[i]);
+ plline(strip->npts[i], strip->x[i], strip->y[i]);
+ }
+ }
+
+ plstrip_legend(strip,0);
+}
+
+/*--------------------------------------------------------------------------*\
+ * plstripa
+ *
+ * Add a point to a stripchart.
+ * Allocates memory and rescales as necessary.
+\*--------------------------------------------------------------------------*/
+
+void
+plstripa(PLINT id, PLINT p, PLFLT x, PLFLT y)
+{
+ int j, yasc=0, istart;
+
+ if (p >= PEN) {
+ plabort("Non existent pen");
+ return;
+ }
+
+ if (strip[id] == NULL) {
+ plabort("Non existent stripchart");
+ return;
+ }
+
+ stripc = strip[id];
+
+/* Add new point, allocating memory if necessary */
+
+ if (++stripc->npts[p] > stripc->nptsmax[p]) {
+ stripc->nptsmax[p] += 32;
+ stripc->x[p] = (PLFLT *) realloc((void *) stripc->x[p], sizeof(PLFLT)*stripc->nptsmax[p]);
+ stripc->y[p] = (PLFLT *) realloc((void *) stripc->y[p], sizeof(PLFLT)*stripc->nptsmax[p]);
+ if (stripc->x[p] == NULL || stripc->y[p] == NULL) {
+ plabort("plstripc: Out of memory.");
+ plstripd(id);
+ return;
+ }
+ }
+
+ stripc->x[p][stripc->npts[p]-1] = x;
+ stripc->y[p][stripc->npts[p]-1] = y;
+
+// if ( x > stripc->xmax)
+ stripc->xmax = x;
+
+ if (stripc->y_ascl == 1 && (y > stripc->ymax || y < stripc->ymin))
+ yasc=1;
+
+ stripc->ymax = MAX(y, stripc->ymax);
+ stripc->ymin = MIN(y, stripc->ymin);
+
+/* Now either plot new point or regenerate plot */
+
+ if (stripc->xmax - stripc->xmin < stripc->xlen) {
+ if( yasc == 0) {
+
+// If user has changed subwindow, make shure we have the correct one
+plvsta();
+plwind(stripc->wxmin, stripc->wxmax, stripc->wymin, stripc->wymax); // FIXME - can exist some redundancy here
+
+ plcol(stripc->colline[p]); pllsty(stripc->styline[p]);
+ plP_movwor(stripc->x[p][stripc->npts[p]-2], stripc->y[p][stripc->npts[p]-2]);
+ plP_drawor(stripc->x[p][stripc->npts[p]-1], stripc->y[p][stripc->npts[p]-1]);
+ plflush();
+ }
+ else {
+ stripc->xmax = stripc->xmin + stripc->xlen;
+ plstrip_gen(stripc);
+ }
+ }
+ else {
+/* Regenerating plot */
+ if (stripc->acc == 0) {
+ for (j=0; j<PEN; j++) {
+ if (stripc->npts[j] > 0) {
+ istart = 0;
+ while (stripc->x[j][istart] < stripc->xmin + stripc->xlen*stripc->xjump)
+ istart++;
+
+ stripc->npts[j] = stripc->npts[j] - istart;
+ /* make it faster
+ for (i = 0; i < stripc->npts[j]; i++) {
+ stripc->x[j][i] = stripc->x[j][i+istart];
+ stripc->y[j][i] = stripc->y[j][i+istart];
+ }
+ */
+ memcpy( &stripc->x[j][0], &stripc->x[j][istart], (stripc->npts[j])*sizeof(PLFLT));
+ memcpy( &stripc->y[j][0], &stripc->y[j][istart], (stripc->npts[j])*sizeof(PLFLT));
+ }
+ }
+ } else
+ stripc->xlen = stripc->xlen * (1 + stripc->xjump);
+
+ stripc->xmin = stripc->x[p][0];
+ stripc->xmax = stripc->xmax + stripc->xlen*stripc->xjump;
+
+ plstrip_gen(stripc);
+ }
+}
+
+/*--------------------------------------------------------------------------*\
+ * plstripd
+ *
+ * Deletes and releases memory used by a stripchart.
+\*--------------------------------------------------------------------------*/
+
+void
+plstripd(PLINT id)
+{
+ int i;
+ stripc = strip[id];
+
+ if (stripc == NULL) {
+ plwarn("No such stripchart");
+ return;
+ }
+
+ for (i=0; i<PEN; i++) {
+ if (stripc->npts[i]) {
+ free((void *) stripc->x[i]);
+ free((void *) stripc->y[i]);
+ free(stripc->legline[i]);
+ }
+ }
+
+ free(stripc->xspec);
+ free(stripc->yspec);
+ free(stripc->labx);
+ free(stripc->laby);
+ free(stripc->labtop);
+ free((void *) stripc);
+ strip[id] = NULL;
+}
diff --git a/src/plvpor.c b/src/plvpor.c
index 2eb769f..58efbe5 100644
--- a/src/plvpor.c
+++ b/src/plvpor.c
@@ -111,15 +111,27 @@ c_plenv(PLFLT xmin, PLFLT xmax, PLFLT ymin, PLFLT ymax,
case 11:
plbox("bclnst", (PLFLT) 0.0, 0, "abcnstv", (PLFLT) 0.0, 0);
break;
+ case 12:
+ plbox("bclgnst", (PLFLT) 0.0, 0, "abcgnstv", (PLFLT) 0.0, 0);
+ break;
case 20:
plbox("bcnst", (PLFLT) 0.0, 0, "bclnstv", (PLFLT) 0.0, 0);
break;
case 21:
plbox("bcnst", (PLFLT) 0.0, 0, "abclnstv", (PLFLT) 0.0, 0);
break;
+ case 22:
+ plbox("bcngst", (PLFLT) 0.0, 0, "abcglnstv", (PLFLT) 0.0, 0);
+ break;
case 30:
plbox("bclnst", (PLFLT) 0.0, 0, "bclnstv", (PLFLT) 0.0, 0);
break;
+ case 31:
+ plbox("bclnst", (PLFLT) 0.0, 0, "abclnstv", (PLFLT) 0.0, 0);
+ break;
+ case 32:
+ plbox("bclngst", (PLFLT) 0.0, 0, "abcglnstv", (PLFLT) 0.0, 0);
+ break;
default:
plwarn("plenv: Invalid axis argument");
}
diff --git a/utils/pltek.c b/utils/pltek.c
index 290d13d..695ce14 100644
--- a/utils/pltek.c
+++ b/utils/pltek.c
@@ -110,7 +110,11 @@ main(int argc, char *argv[])
oldpage = ipage;
printf("Page %d/%d> ", ipage, npage);
- gets(ibuf);
+ /* Changed by Rafael Laboissiere <rafael at icp.inpg.fr>
+ on Fri Oct 9 17:13:59 CEST 1998
+ gcc 2.7.2.3 deprecates the use of gets */
+ /* gets(ibuf); */
+ fgets(ibuf,128,stdin);
c = ibuf[0];
/* User input a page number or a return */
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/debian-science/packages/plplot.git
More information about the debian-science-commits
mailing list