[Pkg-octave-commit] rev 58 - tags/packages trunk/packages trunk/packages/statdataml trunk/packages/statdataml/debian

Rafael Laboissiere rafael@costa.debian.org
Sat, 12 Feb 2005 23:15:24 +0100


Author: rafael
Date: 2005-02-12 23:15:23 +0100 (Sat, 12 Feb 2005)
New Revision: 58

Added:
   tags/packages/statdataml/
   trunk/packages/statdataml/
   trunk/packages/statdataml/debian/
   trunk/packages/statdataml/debian/README.Debian
   trunk/packages/statdataml/debian/changelog
   trunk/packages/statdataml/debian/compat
   trunk/packages/statdataml/debian/control
   trunk/packages/statdataml/debian/copyright
   trunk/packages/statdataml/debian/get-oct-cfg.sh
   trunk/packages/statdataml/debian/octave-deps
   trunk/packages/statdataml/debian/octave-map-assign.patch
   trunk/packages/statdataml/debian/r-cran-statdataml.postinst
   trunk/packages/statdataml/debian/r-cran-statdataml.postrm
   trunk/packages/statdataml/debian/regression-test.sh
   trunk/packages/statdataml/debian/rules
   trunk/packages/statdataml/debian/watch
Log:
Initial import of package statdataml


Added: trunk/packages/statdataml/debian/README.Debian
===================================================================
--- trunk/packages/statdataml/debian/README.Debian	2005-02-12 22:01:36 UTC (rev 57)
+++ trunk/packages/statdataml/debian/README.Debian	2005-02-12 22:15:23 UTC (rev 58)
@@ -0,0 +1,11 @@
+statdataml for Debian
+---------------------
+
+The source package statdataml produces two separate packages:
+
+    r-cran-statdataml : contains the library for R
+    octave-statdatml  : contains the Octave scripts and functions
+
+
+ -- Rafael Laboissiere <rafael@debian.org>, Wed Sep 10 18:09:42 CEST 2003
+

Added: trunk/packages/statdataml/debian/changelog
===================================================================
--- trunk/packages/statdataml/debian/changelog	2005-02-12 22:01:36 UTC (rev 57)
+++ trunk/packages/statdataml/debian/changelog	2005-02-12 22:15:23 UTC (rev 58)
@@ -0,0 +1,125 @@
+statdataml (1.0.9-1) unstable; urgency=low
+
+  * New upstream release.
+  * debian/octave-map-assign.patch: Added this patch to fix a problem with
+    a call to assign in StatDataML/MatOct/readsdml.c_in.
+
+ -- Rafael Laboissiere <rafael@debian.org>  Sat, 20 Nov 2004 18:40:37 +0100
+
+statdataml (1.0.8-2) unstable; urgency=low
+
+  * Rebuilt with Octave 2.1.63.
+
+ -- Rafael Laboissiere <rafael@debian.org>  Fri, 19 Nov 2004 09:19:12 +0100
+
+statdataml (1.0.8-1) unstable; urgency=low
+
+  * New upstream release, built with the newest R packages (2.0.0).
+  * debian/control:
+    - Dropped dependency to dpatch.
+    - Updated URLs for both r-cran-statdataml and octave-statdataml packages.
+    - Updated Build-Depends to r-base-dev (>= 2.0.0).
+    - Updated Depends to r-base-core (>= 2.0.0).
+  * debian/copyright:
+    - Updated download URLs.
+  * debian/r-cran-statdataml.postinst, debian/r-cran-statdataml.postrm,
+    debian/watch: Added files suggested by Dirk Eddelbuettel
+    <edd@debian.org>.
+  * debian/rules:
+    - Do not use dpatch anymore.
+    - Added unpack rule for detaring both StatDataML_1.0-6 and _1.0-8
+      tarballs.  The first one contains the Octave part of the package.
+      The debian/octave-map-assign.patch is then applied.
+
+ -- Rafael Laboissiere <rafael@debian.org>  Sat,  9 Oct 2004 10:39:10 +0200
+
+statdataml (1.0.6-7) unstable; urgency=low
+
+  * debian/rules: Made the debian/get-oct-cfg.sh script executable.  This
+    will probably make the build daemons happier.
+  * Recompiled in unstable, so that the octave-statdataml package gets the
+    right dependency on libhdf5.
+
+ -- Rafael Laboissiere <rafael@debian.org>  Wed, 28 Apr 2004 22:40:49 +0200
+
+statdataml (1.0.6-6) unstable; urgency=low
+
+  * This is a bug fixing release before the release of the new upstream
+    version (1.0.7).
+  * debian/control:
+    - Changed descriptions of both binary packages.
+    - Added build-dependency on fort77, which allows building on m68k
+      (hopefully closes: #240284).
+
+ -- Rafael Laboissiere <rafael@debian.org>  Sat, 27 Mar 2004 09:20:39 +0100
+
+statdataml (1.0.6-5) unstable; urgency=low
+
+  * Rebuilt against newest octave2.1 package (2.1.57-1). This needed a
+    patch to be applied in order to have readsdml.cc compiled by
+    mkoctfile.  For some myterious reason, recent versions of Octave do
+    not allow operator [] applied Octave_map objects.
+  * debian/control: Build-depend on dpatch.
+  * debian/rules: Adjusted to use dpatch.
+  * debian/patches/00list, debian/patches/octave-map-assign.dpatch : New
+    files.
+
+ -- Rafael Laboissiere <rafael@debian.org>  Thu, 18 Mar 2004 21:52:55 +0100
+
+statdataml (1.0.6-4) unstable; urgency=low
+
+  * debian/control: Build-Depend on autoconf (closes: #212500).
+
+ -- Rafael Laboissiere <rafael@debian.org>  Wed, 24 Sep 2003 08:19:45 +0200
+
+statdataml (1.0.6-3) unstable; urgency=low
+
+  * Put the file readsdml.oct in a directory under /usr/lib, because it is
+    a binary, architecture-dependent file.  This is the reason the
+    octave-statdatml is "Arch: any".
+  * debian/get-oct-cfg.sh: Added this script to help getting the
+    configuration variables for Octave.
+  * debian/regression-test.sh: Remove temporary file at the end of the
+    script.
+
+ -- Rafael Laboissiere <rafael@debian.org>  Wed, 17 Sep 2003 08:50:56 +0200
+
+statdataml (1.0.6-2) unstable; urgency=low
+
+  * First official release of the Debian packages (closes: #201672).
+  * debian/rules:
+    - Added a regression test script to /usr/share/doc of both binary
+      packages.
+    - Added README.Debian to octave-statdataml.
+
+ -- Rafael Laboissiere <rafael@debian.org>  Thu, 11 Sep 2003 12:57:38 +0200
+
+statdataml (1.0.6-1) unstable; urgency=low
+
+  * debian/control: Make dependency of r-cran-statdataml on r-base-core |
+    r-base.
+
+ -- Rafael Laboissiere <rafael@debian.org>  Thu, 11 Sep 2003 12:14:57 +0200
+
+statdataml (1.0.6-0.pre.1) unstable; urgency=low
+
+  * New upstream release.
+  * debian/control:
+    - Split the binary package into Octave and R parts.  Make them
+      conflict with old package statdataml.
+    - Upgraded Standards-Version to 3.6.1.
+
+ -- Rafael Laboissiere <rafael@debian.org>  Wed, 10 Sep 2003 18:00:10 +0200
+
+statdataml (1.0.5-2) unstable; urgency=low
+
+  * Put Octave files in a specific directory under /usr/share/octave/site/m/.
+
+ -- Rafael Laboissiere <rafael@debian.org>  Wed, 16 Jul 2003 10:38:24 +0200
+
+statdataml (1.0.5-1) unstable; urgency=low
+
+  * Initial Release.
+
+ -- Rafael Laboissiere <rafael@debian.org>  Tue, 15 Jul 2003 21:00:59 +0200
+

Added: trunk/packages/statdataml/debian/compat
===================================================================
--- trunk/packages/statdataml/debian/compat	2005-02-12 22:01:36 UTC (rev 57)
+++ trunk/packages/statdataml/debian/compat	2005-02-12 22:15:23 UTC (rev 58)
@@ -0,0 +1 @@
+4

Added: trunk/packages/statdataml/debian/control
===================================================================
--- trunk/packages/statdataml/debian/control	2005-02-12 22:01:36 UTC (rev 57)
+++ trunk/packages/statdataml/debian/control	2005-02-12 22:15:23 UTC (rev 58)
@@ -0,0 +1,32 @@
+Source: statdataml
+Section: math
+Priority: optional
+Maintainer: Rafael Laboissiere <rafael@debian.org>
+Build-Depends: debhelper (>> 4.0.0), r-base-dev (>= 2.0.0), octave2.1-headers (>= 2.1.57), libxml2-dev, autoconf, fort77 [m68k]
+Build-Conflicts: libxml-dev
+Standards-Version: 3.6.1
+
+Package: r-cran-statdataml
+Architecture: any
+Depends: r-base-core (>= 2.0.0), r-cran-xml
+Conflicts: statdataml
+Replaces: statdataml
+Suggests: octave-statdataml
+Description: GNU R package for XML-based data exchange
+ This package provides the R implementation for the XML based data
+ exchange format StatDataML.
+ .
+ Homepage: http://cran.r-project.org/src/contrib/Descriptions/StatDataML.html
+
+Package: octave-statdataml
+Architecture: any
+Depends: ${octave:Depends}, ${shlibs:Depends}
+Conflicts: statdataml
+Replaces: statdataml
+Suggests: r-cran-statdataml
+Description: GNU Octave package for XML-based data exchange
+ This package provides the Octave implementation for the XML based
+ data exchange format StatDataML.
+ .
+ Homepage: http://www.omegahat.org/StatDataML/
+

Added: trunk/packages/statdataml/debian/copyright
===================================================================
--- trunk/packages/statdataml/debian/copyright	2005-02-12 22:01:36 UTC (rev 57)
+++ trunk/packages/statdataml/debian/copyright	2005-02-12 22:15:23 UTC (rev 58)
@@ -0,0 +1,18 @@
+This package was debianized by Rafael Laboissiere <rafael@debian.org> on
+Tue, 15 Jul 2003 21:00:59 +0200.
+
+It was downloaded from:
+    http://cran.r-project.org/src/contrib/Descriptions/StatDataML.html
+    http://www.omegahat.org/StatDataML/
+(The second URL contains the tarball for the Octave part of the package.)
+
+Upstream Authors:
+    Torsten Hothorn <Torsten.Hothorn@rzmail.uni-erlangen.de>
+    Friedrich Leisch <leisch@ci.tuwien.ac.at>
+    David Meyer <david.meyer@ci.tuwien.ac.at>
+
+Copyright:
+    StatDataML is released under the terms of the GNU General Public
+    License, version 2 or newer.
+
+    (For the complete text of the GPL, see /usr/share/common-licenses/GPL)

Added: trunk/packages/statdataml/debian/get-oct-cfg.sh
===================================================================
--- trunk/packages/statdataml/debian/get-oct-cfg.sh	2005-02-12 22:01:36 UTC (rev 57)
+++ trunk/packages/statdataml/debian/get-oct-cfg.sh	2005-02-12 22:15:23 UTC (rev 58)
@@ -0,0 +1,13 @@
+#!/bin/sh
+
+if test $# -ne 1 ; then
+  echo Usage: $0 configvar
+  exit 1
+fi
+
+OCTAVE=${OCTAVE:-octave}
+
+$OCTAVE --norc --silent <<EOF
+  t = octave_config_info;
+  disp (t.$1)
+EOF


Property changes on: trunk/packages/statdataml/debian/get-oct-cfg.sh
___________________________________________________________________
Name: svn:executable
   + *

Added: trunk/packages/statdataml/debian/octave-deps
===================================================================
--- trunk/packages/statdataml/debian/octave-deps	2005-02-12 22:01:36 UTC (rev 57)
+++ trunk/packages/statdataml/debian/octave-deps	2005-02-12 22:15:23 UTC (rev 58)
@@ -0,0 +1,64 @@
+#!/usr/bin/perl -w
+
+=head1 NAME
+
+dh_octave - calculates Octave dependencies
+
+=cut
+
+use strict;
+use File::Find;
+use Debian::Debhelper::Dh_Lib;
+
+=head1 SYNOPSIS
+
+B<dh_octave> [S<I<debhelper options>>]
+
+=head1 DESCRIPTION
+
+dh_octave is a debhelper program that is responsible for generating the
+${octave:Depends} substitutions and adding them to substvars files.
+
+If you use this program, your package should build-depend on octave.
+
+=cut
+
+init();
+
+my $octave = 'octave';
+
+# The current Octave version
+my $octave_major;
+my $octave_version = `$octave --version 2>&1`;
+if ("$octave_version" eq "") {
+	error("Octave is not installed, aborting. (Probably forgot to Build-Depend on octave.)");
+}
+elsif ($octave_version =~ m/version\s+(\d+)\.(\d+)\.(\d+)/) {
+	$octave = "octave$1.$2";
+	$octave_version = "$1.$2.$3";
+} else { 
+	error("Unable to parse octave version out of \"$octave_version\".");
+}
+
+
+foreach my $package (@{$dh{DOPACKAGES}}) {
+
+	delsubstvar($package, "octave:Depends");
+	addsubstvar($package, "octave:Depends", $octave, ">= $octave_version");
+
+}
+
+=head1 SEE ALSO
+
+L<debhelper(7)>
+
+This program is a part of debhelper.
+
+=head1 AUTHOR
+
+Rafael Laboissiere <rafael@debian.org>
+
+Most ideas borrowed from dh_python by Josselin Mouette <joss@debian.org>,
+who apparently took ideas from Brendan O'Dea <bod@debian.org>.
+
+=cut


Property changes on: trunk/packages/statdataml/debian/octave-deps
___________________________________________________________________
Name: svn:executable
   + *

Added: trunk/packages/statdataml/debian/octave-map-assign.patch
===================================================================
--- trunk/packages/statdataml/debian/octave-map-assign.patch	2005-02-12 22:01:36 UTC (rev 57)
+++ trunk/packages/statdataml/debian/octave-map-assign.patch	2005-02-12 22:15:23 UTC (rev 58)
@@ -0,0 +1,47 @@
+diff -Naur StatDataML/MatOct/readsdml.c_in statdataml-1.0.9/StatDataML/MatOct/readsdml.c_in
+--- StatDataML/MatOct/readsdml.c_in	2004-11-20 14:24:44.000000000 +0100
++++ statdataml-1.0.9/StatDataML/MatOct/readsdml.c_in	2004-11-21 02:16:48.000000000 +0100
+@@ -242,7 +242,6 @@
+ {
+   AttrStruct *Attr = NULL;
+   xmlChar    *Ptr;
+-  int        i     = 0;
+ 
+   /* allocate & initialise structure */
+   Attr = (AttrStruct *) _calloc (1,sizeof(AttrStruct));
+@@ -353,8 +352,7 @@
+   int         x,
+               chararray; /* flag, whether a cell-array has to be converted */
+ #endif
+-  char       *s, /* string-buffer */
+-             *split; /* for complex numbers: start-index of imaginary-part */
++  char       *s; /* string-buffer */
+ #ifdef matlab
+   _char     *buf;
+ 
+@@ -373,7 +371,6 @@
+               isna = 0; /* indicator whether tag is NA or not */
+ 
+   char       *defaultsep = "\n";
+-  int         one[1] = {1};
+   
+   _dataObject retval = NULL;
+ 
+@@ -1008,7 +1005,7 @@
+   while (Cur) {
+     /* 2.2.1. dimension - must be the first element ! */
+     if (!cmp(Cur->name, "dimension"))
+-      if (dim = GetDimensions(Cur->children))
++      if ((dim = GetDimensions(Cur->children)))
+         /* get dimnames of first dimension for possible structure data */
+ 	names = GetDimnames(dim, Cur->children->children);
+     
+@@ -1093,7 +1090,7 @@
+ 	S.assign("properties", *GetList (Cur->children->children));
+       else 
+ 	S.assign((char *) Cur->name,
+-		octave_value_list(std::string ((char *) Cur->children->content)));
++		octave_value(std::string ((char *) Cur->children->content)));
+ #endif
+     Cur = next (Cur);
+   }

Added: trunk/packages/statdataml/debian/r-cran-statdataml.postinst
===================================================================
--- trunk/packages/statdataml/debian/r-cran-statdataml.postinst	2005-02-12 22:01:36 UTC (rev 57)
+++ trunk/packages/statdataml/debian/r-cran-statdataml.postinst	2005-02-12 22:15:23 UTC (rev 58)
@@ -0,0 +1,24 @@
+#!/bin/sh
+#                                                       -*- makefile -*-
+# debian/postinst file for the Debian/GNU Linux r-cran-boot package
+# Copyright 2004 by Dirk Eddelbuettel <edd@debian.org>
+
+set -e
+
+#DEBHELPER#
+
+case "$1" in
+    configure)
+        if test -x /usr/bin/R; then
+            R CMD perl /usr/lib/R/share/perl/build-help.pl --htmllists
+        fi
+        ;;
+    abort-upgrade|abort-remove|abort-deconfigure)
+        ;;
+    *)
+        echo "postinst called with unknown argument \`$1'" >&2
+        ;;
+esac
+
+
+exit 0

Added: trunk/packages/statdataml/debian/r-cran-statdataml.postrm
===================================================================
--- trunk/packages/statdataml/debian/r-cran-statdataml.postrm	2005-02-12 22:01:36 UTC (rev 57)
+++ trunk/packages/statdataml/debian/r-cran-statdataml.postrm	2005-02-12 22:15:23 UTC (rev 58)
@@ -0,0 +1,24 @@
+#!/bin/sh
+#                                                       -*- makefile -*-
+# debian/postrm file for the Debian/GNU Linux r-cran-boot package
+# Copyright 2004 by Dirk Eddelbuettel <edd@debian.org>
+
+set -e
+
+#DEBHELPER#
+
+case "$1" in
+    upgrade|remove|purge)
+        if test -x /usr/bin/R; then
+            R CMD perl /usr/lib/R/share/perl/build-help.pl --htmllists
+        fi
+        ;;
+    failed-upgrade|abort-install|abort-upgrade|disappear)
+        ;;
+    *)
+        echo "postrm called with unknown argument \`$1'" >&2
+        ;;
+esac
+
+
+exit 0

Added: trunk/packages/statdataml/debian/regression-test.sh
===================================================================
--- trunk/packages/statdataml/debian/regression-test.sh	2005-02-12 22:01:36 UTC (rev 57)
+++ trunk/packages/statdataml/debian/regression-test.sh	2005-02-12 22:15:23 UTC (rev 58)
@@ -0,0 +1,19 @@
+#!/bin/sh
+
+TMP=foo.xml
+
+octave <<EOF
+writesdml ([1,2;3,4], "$TMP")
+EOF
+
+R --no-save <<EOF
+library (StatDataML)
+readSDML ("$TMP")
+writeSDML (c(5,6,7,8), "$TMP")
+EOF
+
+octave <<EOF
+readsdml ("$TMP")
+EOF
+
+rm -f foo.xml


Property changes on: trunk/packages/statdataml/debian/regression-test.sh
___________________________________________________________________
Name: svn:executable
   + *

Added: trunk/packages/statdataml/debian/rules
===================================================================
--- trunk/packages/statdataml/debian/rules	2005-02-12 22:01:36 UTC (rev 57)
+++ trunk/packages/statdataml/debian/rules	2005-02-12 22:15:23 UTC (rev 58)
@@ -0,0 +1,94 @@
+#!/usr/bin/make -f
+# Sample debian/rules that uses debhelper.
+# GNU copyright 1997 to 1999 by Joey Hess.
+
+# Uncomment this to turn on verbose mode.
+#export DH_VERBOSE=1
+
+PACKAGE := statdataml
+
+rpkg    := r-cran-statdataml
+octpkg  := octave-statdataml
+debdir  := $(shell pwd)/debian/
+rlibdir := $(debdir)/$(rpkg)/usr/lib/R/library
+octdir  := $(debdir)/$(octpkg)
+octarch := $(octdir)$(shell chmod +x debian/get-oct-cfg.sh ; \
+                            debian/get-oct-cfg.sh localoctfiledir)/statdataml
+octfcn  := $(octdir)$(shell debian/get-oct-cfg.sh localfcnfiledir)/statdataml
+
+CFLAGS = -Wall -g
+
+ifneq (,$(findstring noopt,$(DEB_BUILD_OPTIONS)))
+	CFLAGS += -O0
+else
+	CFLAGS += -O2
+endif
+ifeq (,$(findstring nostrip,$(DEB_BUILD_OPTIONS)))
+	INSTALL_PROGRAM += -s
+endif
+
+all:
+	echo $(octarch)
+
+unpack: unpack-stamp
+unpack-stamp:
+	tar xfvz StatDataML_1.0-9.tar.gz
+#	tar xfvz StatDataML_1.0-6.tar.gz StatDataML/MatOct
+	( cd StatDataML ; patch -p1 < $(debdir)/octave-map-assign.patch )
+	touch unpack-stamp
+
+configure: configure-stamp
+configure-stamp: unpack-stamp
+	dh_testdir
+	( cd StatDataML/MatOct ; autoconf ; ./configure )
+	touch configure-stamp
+
+
+build: build-stamp
+build-stamp: configure-stamp
+	dh_testdir
+	( cd StatDataML/MatOct ; \
+          $(MAKE) CPPFLAGS=-I/usr/include/libxml2 LIBS=-lxml2 Octave )
+	touch build-stamp
+
+clean:
+	dh_testdir
+	dh_testroot
+	rm -f *-stamp
+	rm -rf StatDataML
+	dh_clean
+
+install: build
+	dh_testdir
+	dh_testroot
+	dh_clean -k
+
+	mkdir -p $(rlibdir)
+	R CMD INSTALL -c -l $(rlibdir) StatDataML/R/StatDataML
+	rm -f $(rlibdir)/R.css
+
+	mkdir -p $(octarch)
+	mkdir -p $(octfcn)
+	( cd StatDataML/MatOct/octave ; \
+	  cp *.oct $(octarch) ; cp *.m *.dtd $(octfcn) )
+
+# Build architecture-dependent files here.
+binary-arch: build install
+	dh_testdir
+	dh_testroot
+	dh_installchangelogs -a
+	chmod +x debian/regression-test.sh
+	dh_installdocs -A debian/README.Debian debian/regression-test.sh
+	dh_strip -a
+	dh_compress -a
+	dh_fixperms -a
+	dh_installdeb -a
+	dh_shlibdeps -a
+	chmod +x debian/octave-deps
+	debian/octave-deps -p$(octpkg)
+	dh_gencontrol -a
+	dh_md5sums -a
+	dh_builddeb -a
+
+binary: binary-arch
+.PHONY: build clean binary-arch binary install configure unpack


Property changes on: trunk/packages/statdataml/debian/rules
___________________________________________________________________
Name: svn:executable
   + *

Added: trunk/packages/statdataml/debian/watch
===================================================================
--- trunk/packages/statdataml/debian/watch	2005-02-12 22:01:36 UTC (rev 57)
+++ trunk/packages/statdataml/debian/watch	2005-02-12 22:15:23 UTC (rev 58)
@@ -0,0 +1,5 @@
+# format version number, currently 2; this line is compulsory!
+version=2
+
+# This is one format for an HTTP site, which is the same as the FTP format
+http://cran.r-project.org/src/contrib/StatDataML_([-0-9\.]*).tar.gz