summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 7f788bb)
raw | patch | inline | side by side (parent: 7f788bb)
author | Sebastian Harl <sh@tokkee.org> | |
Mon, 8 Jun 2009 18:25:16 +0000 (20:25 +0200) | ||
committer | Sebastian Harl <sh@tokkee.org> | |
Mon, 8 Jun 2009 18:25:16 +0000 (20:25 +0200) |
This patch lets octave scripts use the variable nargin instead of
length(argv); the latter does not work reliably when no command line arguments
have been specified.
length(argv); the latter does not work reliably when no command line arguments
have been specified.
debian/changelog | patch | blob | history | |
debian/control | patch | blob | history | |
debian/patches/00list | [new file with mode: 0644] | patch | blob |
debian/patches/octave-nargin.dpatch | [new file with mode: 0755] | patch | blob |
debian/rules | patch | blob | history |
diff --git a/debian/changelog b/debian/changelog
index 47a17bc891e0a35e2337411f77b6ef65471ceeea..eac04c4307c5e27664b980d1b4786f31cf7cb63a 100644 (file)
--- a/debian/changelog
+++ b/debian/changelog
* debian/patches:
- Removed dcraw-m.dpatch - merged upstream.
- Removed octave3.0.dpatch - merged upstream.
+ - Added octave-nargin.dpatch - this patch lets octave scripts use the
+ variable nargin instead of length(argv); the latter does not work
+ reliably when no command line arguments have been specified.
* Removed debian/pfsglview.1 - included upstream.
* debian/control:
- Added libmagick++-dev as an option to the libmagick++9-dev build
- Use ${octave:Depends} and octave3.0-depends instead of explicitly
depending on octave3.0.
- -- Sebastian Harl <tokkee@debian.org> Mon, 08 Jun 2009 15:06:18 +0200
+ -- Sebastian Harl <tokkee@debian.org> Mon, 08 Jun 2009 20:20:59 +0200
pfstools (1.6.4-2) unstable; urgency=low
diff --git a/debian/control b/debian/control
index e4d6f8bb27902188f0c976c9dad5358574a8a332..c27130c34e1cc6d0d5d0062f832a64be66d750ab 100644 (file)
--- a/debian/control
+++ b/debian/control
Priority: optional
Maintainer: Debian PhotoTools Maintainers <pkg-phototools-devel@lists.alioth.debian.org>
Uploaders: Sebastian Harl <tokkee@debian.org>
-Build-Depends: debhelper (>= 5), dpkg-dev (>= 1.14.6), gfortran, autotools-dev, libqt3-mt-dev, libmagick++-dev | libmagick++9-dev, libtiff4-dev, libopenexr-dev, libnetpbm10-dev, octave3.0-headers, texlive-latex-base, freeglut3-dev
+Build-Depends: debhelper (>= 5), dpkg-dev (>= 1.14.6), dpatch, gfortran, autotools-dev, libqt3-mt-dev, libmagick++-dev | libmagick++9-dev, libtiff4-dev, libopenexr-dev, libnetpbm10-dev, octave3.0-headers, texlive-latex-base, freeglut3-dev
Standards-Version: 3.8.1
Homepage: http://pfstools.sourceforge.net/
Vcs-Git: git://git.debian.org/git/pkg-phototools/pfstools.git
diff --git a/debian/patches/00list b/debian/patches/00list
--- /dev/null
+++ b/debian/patches/00list
@@ -0,0 +1,2 @@
+octave-nargin.dpatch
+
diff --git a/debian/patches/octave-nargin.dpatch b/debian/patches/octave-nargin.dpatch
--- /dev/null
@@ -0,0 +1,43 @@
+#! /bin/sh /usr/share/dpatch/dpatch-run
+## octave-nargin.dpatch by Sebastian Harl <tokkee@debian.org>
+##
+## DP: Use nargin instead of length(argv).
+## DP:
+## DP: length(argv) does not work reliably when no arguments are passed to
+## DP: some octave script.
+
+@DPATCH@
+
+--- a/src/octave/pfsoctavelum
++++ b/src/octave/pfsoctavelum
+@@ -29,7 +29,7 @@
+
+ #fprintf( stderr, "l = %d\n", length( argv ) );
+
+-if( length( argv ) != 1 )
++if( nargin != 1 )
+ error( "Expecting exactly one parameter with octave code to be execuded" );
+ endif
+
+--- a/src/octave/pfsoctavergb
++++ b/src/octave/pfsoctavergb
+@@ -29,7 +29,7 @@
+
+ #fprintf( stderr, "l = %d\n", length( argv ) );
+
+-if( length( argv ) != 1 )
++if( nargin != 1 )
+ error( "Expecting exactly one parameter with octave code to be execuded" );
+ endif
+
+--- a/src/octave/pfsstat
++++ b/src/octave/pfsstat
+@@ -29,7 +29,7 @@
+
+ #fprintf( stderr, "l = %d\n", length( argv ) );
+
+-if( length( argv ) != 0 )
++if( nargin != 0 )
+ error( "Expecting no parameters" );
+ endif
+
diff --git a/debian/rules b/debian/rules
index ffb12542adecc9328e07909ccb5822aeaf6801fb..eceb35eb57e70b43abac8b8879da7203d50e3e0f 100755 (executable)
--- a/debian/rules
+++ b/debian/rules
endif
include /usr/share/octave/debian/defs.make
+include /usr/share/dpatch/dpatch.make
confflags = --host=$(DEB_HOST_GNU_TYPE) \
--build=$(DEB_BUILD_GNU_TYPE) \
# These libraries are not available / unusable in Debian.
confflags += --disable-jpeghdr --disable-gdal
-config.status: configure
+config.status: configure $(DPATCH_STAMPFN)
dh_testdir
for file in config.guess config.sub; do \
touch build-stamp
-clean:
+clean: unpatch
dh_testdir
dh_testroot
rm -f build-stamp