[gap-guava] 08/08: Imported Debian patch 3.12+ds-1
Jerome Benoit
calculus-guest at moszumanska.debian.org
Thu Sep 11 20:58:32 UTC 2014
This is an automated email from the git hooks/post-receive script.
calculus-guest pushed a commit to branch master
in repository gap-guava.
commit be95700fe66533215fe91a25b2cd37c3b78b868d
Author: Jerome Benoit <calculus at rezozer.net>
Date: Thu Sep 11 22:38:38 2014 +0200
Imported Debian patch 3.12+ds-1
---
debian/changelog | 30 ++
debian/clean | 23 +
debian/compat | 2 +-
debian/control | 46 +-
debian/control.in | 16 -
debian/copyright | 105 ++--
debian/gap-guava-bin.install | 1 +
debian/gap-guava.dirs | 1 +
debian/gap-guava.doc-base | 20 +
debian/gap-guava.docs | 3 +
debian/gap-guava.install | 7 +-
debian/gap-guava.lintian-overrides | 1 +
debian/makedoc.g | 5 +
.../patches/debianization-bug-761052-gapdoc.patch | 18 +
debian/patches/debianization.patch | 113 ++++
debian/patches/hadamard-bugfix.patch | 12 -
debian/patches/series | 5 +-
.../upstream-configure_machinery-refreshment.patch | 174 ++++++
debian/patches/upstream-fix-warnings.patch | 590 +++++++++++++++++++++
debian/repack | 126 +++++
debian/rules | 29 +-
debian/source/format | 1 +
debian/source/lintian-overrides | 1 +
debian/source/options | 2 +
debian/watch | 4 +
25 files changed, 1226 insertions(+), 109 deletions(-)
diff --git a/debian/changelog b/debian/changelog
index 57dad0c..ac89542 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,3 +1,33 @@
+gap-guava (3.12+ds-1) unstable; urgency=medium
+
+ * New upstream version (Closes: #493694).
+ * New maintainer (Closes: #760345).
+ * Debianization:
+ - debian/copyright in DEP-5 format, bump;
+ - debian/control:
+ - debhelper build-dep to >= 9, bump;
+ - Standards Version 3.9.5, bump;
+ - Vcs-* headers, refresh.
+ - debian/source, format 3.0 (quilt), bump;
+ - debian/watch file;
+ - debian/repack, repack script to clean up and gain size;
+ - debian/rules:
+ - full and minal dh integration;
+ - get-orig-source uscan based target which downloads the currently
+ packaged upstream tarball and repacks it;
+ - default target which basically queries package status with uscan
+ -- output in DEHS format;
+ - gpg-signature check support, neutralize;
+ - rename source package gap-guava for consistency;
+ - split into architecture independent and dependent packages:
+ - gap-guava contains architecture independent material,
+ this is the historical package;
+ - gap-guava-bin architecture dependent material, not (yet)
+ an multi-arch package as gap is not (yet) multi-arch;
+ * Minor, cosmetic fixes submitted to the upstream maintainers.
+
+ -- Jerome Benoit <calculus at rezozer.net> Thu, 11 Sep 2014 20:48:40 +0000
+
guava (3.6-2) unstable; urgency=low
* Fix bug in HadamardMat on power of 2 inputs.
diff --git a/debian/clean b/debian/clean
new file mode 100644
index 0000000..264e881
--- /dev/null
+++ b/debian/clean
@@ -0,0 +1,23 @@
+src/ctjhai/README.ctjhai
+src/leon/aclocal.m4
+src/leon/configure
+src/leon/install-sh
+src/leon/missing
+src/leon/src/leon_config.h.in
+src/leon/src/leon_config.h
+src/leon/doc/leon_guava_manual.log
+src/leon/doc/leon_guava_manual.pdf
+doc/chap*.txt
+doc/chap*.html
+doc/chooser.html
+doc/guava.{tex,aux,out,brf,toc,log,bbl,blg,ind,idx,ilg}
+doc/guava.pnr
+doc/manual.{six,lab}
+doc/manual.pdf
+doc/lefttoc.css
+doc/manual.{css,js}
+doc/nocolorprompt.css
+doc/ragged.css
+doc/rainbow.js
+doc/times.css
+doc/toggless.{css,js}
diff --git a/debian/compat b/debian/compat
index 7ed6ff8..ec63514 100644
--- a/debian/compat
+++ b/debian/compat
@@ -1 +1 @@
-5
+9
diff --git a/debian/control b/debian/control
index 775e9e1..e2ad98d 100644
--- a/debian/control
+++ b/debian/control
@@ -1,18 +1,38 @@
-Source: guava
+Source: gap-guava
Section: math
Priority: optional
-Maintainer: Tim Abbott <tabbott at mit.edu>
-Build-Depends: cdbs (>= 0.4.23-1.1), autotools-dev, debhelper (>= 5), quilt, patchutils (>= 0.2.25), cdbs (>= 0.4.27), gap-dev
-Standards-Version: 3.8.0
-Vcs-Git: git://git.debian.org/debian-science/packages/guava.git
-Vcs-Browser: http://git.debian.org/?p=debian-science/packages/guava.git;a=summary
+Maintainer: Debian Science Maintainers <debian-science-maintainers at lists.alioth.debian.org>
+Uploaders: Jerome Benoit <calculus at rezozer.net>
+Build-Depends:
+ debhelper (>= 9), autoconf, automake,
+ gap (>=4r7p5), gap-dev (>=4r7p5), gap-gapdoc,
+ texlive-latex-recommended, texlive-fonts-recommended, texlive-latex-extra
+Standards-Version: 3.9.5
+Homepage: http://www.gap-system.org/Packages/guava.html
+Vcs-Git: git://anonscm.debian.org/debian-science/packages/gap-guava.git
+Vcs-Browser: http://anonscm.debian.org/gitweb/?p=debian-science/packages/gap-guava.git
Package: gap-guava
-Section: math
-Architecture: any
-Depends: ${shlibs:Depends}, ${misc:Depends}
Provides: gap-pkg-guava
-Description: Coding theory library for GAP
- GUAVA is a package that implements coding theory algorithms in GAP.
- Codes can be created and manipulated and information about codes can
- be calculated.
+Architecture: all
+Depends: ${misc:Depends}, gap-guava-bin, gap (>=4r7p5)
+Description: coding theory library for GAP
+ GAP is a system for computational discrete algebra with particular
+ emphasis on computational group theory, but which has already proved
+ useful also in other areas.
+ .
+ This GAP package brings to GAP computing with error-correcting codes.
+
+Package: gap-guava-bin
+Provides: gap-pkg-guava-bin
+Architecture: any
+Depends: ${misc:Depends}, ${shlibs:Depends}, gap (>=4r7p5)
+Description: coding theory library for GAP (arch-dep files)
+ GAP is a system for computational discrete algebra with particular
+ emphasis on computational group theory, but which has already proved
+ useful also in other areas.
+ .
+ This GAP package brings to GAP computing with error-correcting codes.
+ .
+ This Debian package contains the architecture-dependent files for the
+ gap-guava Debian package.
diff --git a/debian/control.in b/debian/control.in
deleted file mode 100644
index e7e1d66..0000000
--- a/debian/control.in
+++ /dev/null
@@ -1,16 +0,0 @@
-Source: guava
-Section: math
-Priority: optional
-Maintainer: Tim Abbott <tabbott at mit.edu>
-Build-Depends: @cdbs@, gap-dev
-Standards-Version: 3.8.0
-
-Package: gap-guava
-Section: math
-Architecture: any
-Depends: ${shlibs:Depends}, ${misc:Depends}
-Provides: gap-pkg-guava
-Description: Coding theory library for GAP
- GUAVA is a package that implements coding theory algorithms in GAP.
- Codes can be created and manipulated and information about codes can
- be calculated.
diff --git a/debian/copyright b/debian/copyright
index 87912b1..ad4eeb8 100644
--- a/debian/copyright
+++ b/debian/copyright
@@ -1,55 +1,50 @@
-This package was debianized by Tim Abbott <tabbott at mit.edu> in 2008.
-
-It was downloaded from http://sage.math.washington.edu/home/wdj/guava/
-
-Upstream Authors: David Joyner (wdjoyner at gmail.com)
- Jeffrey S. Leon
- Jasper Cramwinckel
- Erik Roijackers
- Reinald Baart
- Eric Minkes
- Cen Tjhai
- Robert Miller
- Tom Boothby
-
-Copyright (C) 2003-2008 David Joyner (wdjoyner at gmail.com),
- Jeffrey S. Leon,
- Jasper Cramwinckel,
- Erik Roijackers,
- Reinald Baart,
- Eric Minkes,
- Cen Tjhai,
- Robert Miller,
- Tom Boothby
-
-License:
-
- This package is free software; you can redistribute it and/or
- modify it under the terms of the GNU General Public License as
- published by the Free Software Foundation; either version 2 or
- version 3 of the License.
-
- This package 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 General Public License for more details.
-
- You should have received a copy of the GNU General Public License
- along with this package; if not, write to the Free Software
- Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
-
-On Debian systems, the complete text of the GNU General
-Public License can be found in `/usr/share/common-licenses/GPL'.
-
-The Debian packaging is (C) 2008, Tim Abbott <tabbott at mit.edu> and is
-licensed under the GPL, see above.
-
-The documentation for Guava (doc/) is distributed under the GNU Free
-Documentation License (GFDL):
-
- Permission is granted to copy, distribute and/or modify this document
- under the terms of the GNU Free Documentation License, Version 1.2
- or any later version published by the Free Software Foundation;
- with no Invariant Sections, no Front-Cover Texts, and no Back-Cover Texts.
- A copy of the license is included in the section entitled "GNU
- Free Documentation License".
+Format: http://www.debian.org/doc/packaging-manuals/copyright-format/1.0
+Upstream-Name: guava package for GAP
+Upstream-Contact: Joe Fields <fieldsj1 at southernct.edu>
+Source: http://www.gap-system.org/Packages/guava.html
+Comment:
+ The upstream source tarball is repacked to drop off the regenarated
+ material, mainly the documentation, to substantially reduce the size.
+
+Files: *
+Copyright: The GUAVA Group
+ 2009,2012 Joe Fields
+ 2007 Robert L. Miller
+ Tom Boothby
+ 2004 David Joyner
+ Cen Tjhai
+ Jasper Cramwinckel
+ Erik Roijackers
+ Reinald Baart
+ Eric Minkes
+ Lea Ruscio
+ 1992-2003 Jasper Cramwinckel
+ Erik Roijackers
+ Reinald Baart
+ Eric Minkes
+ Lea Ruscio
+ Jeffrey Leon
+License: GPL-2+
+
+Files: debian/*
+Copyright:
+ 2014 Jerome Benoit <calculus at rezozer.net>
+ 2008 Tim Abbott <tabbott at mit.edu>
+License: GPL-2+
+
+License: GPL-2+
+ This package is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
+ .
+ This package 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 General Public License for more details.
+ .
+ You should have received a copy of the GNU General Public License
+ along with this package. If not, see <http://www.gnu.org/licenses/>.
+ .
+ On Debian systems, the complete text of the GNU General
+ Public License version 2 can be found in "/usr/share/common-licenses/GPL-2".
diff --git a/debian/gap-guava-bin.install b/debian/gap-guava-bin.install
new file mode 100644
index 0000000..596b4de
--- /dev/null
+++ b/debian/gap-guava-bin.install
@@ -0,0 +1 @@
+usr/lib/*/gap/pkg/guava/bin
diff --git a/debian/gap-guava.dirs b/debian/gap-guava.dirs
new file mode 100644
index 0000000..981bae6
--- /dev/null
+++ b/debian/gap-guava.dirs
@@ -0,0 +1 @@
+usr/lib/gap/pkg/guava/bin
diff --git a/debian/gap-guava.doc-base b/debian/gap-guava.doc-base
new file mode 100644
index 0000000..b9baec7
--- /dev/null
+++ b/debian/gap-guava.doc-base
@@ -0,0 +1,20 @@
+Document: gap-guava
+Title: A GAP4 Package for computing with error-correcting codes
+Author:
+ Jasper Cramwinckel
+ Erik Roijackers
+ Reinald Baart
+ Eric Minkes
+ Lea Ruscio
+ Robert L Miller
+ Tom Boothby
+ Cen Tjhai
+ David Joyner
+ Joe Fields
+Abstract:
+ The GUAVA GAP package contains many functions that allow one to perform
+ computations relevant to the theory of error-correcting codes.
+Section: Science/Mathematics
+
+Format: pdf
+Files: /usr/share/doc/gap-guava/doc/manual.pdf
diff --git a/debian/gap-guava.docs b/debian/gap-guava.docs
new file mode 100644
index 0000000..96e2f85
--- /dev/null
+++ b/debian/gap-guava.docs
@@ -0,0 +1,3 @@
+README.guava
+src/ctjhai/README.ctjhai
+src/leon/doc/leon_guava_manual.pdf
diff --git a/debian/gap-guava.install b/debian/gap-guava.install
index 7d1c9eb..0e458bd 100644
--- a/debian/gap-guava.install
+++ b/debian/gap-guava.install
@@ -1,6 +1,5 @@
+*.g *.tst /usr/share/gap/pkg/guava
lib /usr/share/gap/pkg/guava
-doc /usr/share/gap/pkg/guava
tbl /usr/share/gap/pkg/guava
-bin /usr/lib/gap/pkg/guava
-*.g /usr/share/gap/pkg/guava
-
+doc/*.txt doc/*.html doc/manual.six doc/manual.pdf usr/share/gap/pkg/guava/doc
+doc/manual.css doc/manual.js usr/share/gap/pkg/guava/doc
diff --git a/debian/gap-guava.lintian-overrides b/debian/gap-guava.lintian-overrides
new file mode 100644
index 0000000..4e29d61
--- /dev/null
+++ b/debian/gap-guava.lintian-overrides
@@ -0,0 +1 @@
+package-contains-empty-directory
diff --git a/debian/makedoc.g b/debian/makedoc.g
new file mode 100644
index 0000000..c0c7231
--- /dev/null
+++ b/debian/makedoc.g
@@ -0,0 +1,5 @@
+# debian/makedoc.g -- GAP script
+SetPackagePath("guava",".");
+LoadPackage("guava");;
+MakeGAPDocDoc("doc","guava",[],"guava");
+CopyHTMLStyleFiles("doc");
diff --git a/debian/patches/debianization-bug-761052-gapdoc.patch b/debian/patches/debianization-bug-761052-gapdoc.patch
new file mode 100644
index 0000000..4f446ea
--- /dev/null
+++ b/debian/patches/debianization-bug-761052-gapdoc.patch
@@ -0,0 +1,18 @@
+Description: debianization -- workaround around gapdoc bug
+ Meant to workaround bug #761052: to avoid inhomogeneity among the
+ different type of generated documents, the so called Jr part of
+ the faulty BibTeX's name (section 18 in btxdoc.pdf) is removed.
+Author: Jerome Benoit <calculus at rezozer.net>
+Last-Update: 2014-09-10
+
+--- a/doc/guava.bib
++++ b/doc/guava.bib
+@@ -215,7 +215,7 @@
+ }
+
+ @ARTICLE{TSSFC04,
+- author = {R. Tanner and D. Sridhara and A. Sridharan and T. Fuja and D. Costello{, Jr.}},
++ author = {R. Tanner and D. Sridhara and A. Sridharan and T. Fuja and D. Costello},
+ title = {{LDPC} Block and Convolutional Codes Based on Circulant Matrices},
+ journal = {IEEE Trans. Inform. Theory},
+ volume = {50},
diff --git a/debian/patches/debianization.patch b/debian/patches/debianization.patch
new file mode 100644
index 0000000..488bc79
--- /dev/null
+++ b/debian/patches/debianization.patch
@@ -0,0 +1,113 @@
+Description: debianization
+ Meant to maintain a minimal debian/rules, to fix annoying
+ warnings, to address Debian specific stuff in general.
+Author: Jerome Benoit <calculus at rezozer.net>
+Last-Update: 2014-09-06
+
+--- a/Makefile.in
++++ b/Makefile.in
+@@ -1,21 +1,26 @@
++DEB_BUILD_GNU_TYPE=@DEB_BUILD_GNU_TYPE@
+ GAPPATH=@GAPPATH@
+ GAPARCH=@GAPARCH@
++CGAP = /usr/bin/gap
+ CC = gcc
+-CFLAGS = -O2
++##CFLAGS = -O2
+ SRCDIR = ./src/leon
+ CJSRCDIR= ./src/ctjhai
+-BINDIR = bin/$(GAPARCH)
++LIBDIR=/usr/lib/$(DEB_BUILD_GNU_TYPE)
++BINDIR=$(LIBDIR)/gap/pkg/guava/bin
+ #GAP_PATH=../..
+ #PKG_PATH=.
+ #SRCDISTFILE=guava
+
+-targets: default
++PDFTEX=pdftex -no-shell-escape -interaction batchmode
+
+-default: bindir minimum-weight leonconv desauto install
++CFLAGS += -Wno-unused-result
+
+-# this target creates a bin-directory
+-bindir:
+- if test ! -d $(BINDIR); then mkdir -p $(BINDIR); fi
++default: build doc
++
++build: minimum-weight leonconv desauto
++
++doc: src/ctjhai/README.ctjhai src/leon/doc/leon_guava_manual.pdf doc/manual.pdf
+
+ minimum-weight: $(CJSRCDIR)/minimum-weight.o $(CJSRCDIR)/minimum-weight-gf2.o $(CJSRCDIR)/minimum-weight-gf3.o $(CJSRCDIR)/popcount.o
+ $(CC) $(LDFLAGS) -o $(CJSRCDIR)/minimum-weight \
+@@ -40,22 +45,30 @@
+ popcount.o: $(CJSRCDIR)/popcount.c $(CJSRCDIR)/popcount.h $(CJSRCDIR)/config.h $(CJSRCDIR)/types.h
+ $(CC) -c -O3 -Wall -I $(CJSRCDIR) $(CJSRCDIR)/popcount.c
+
++src/ctjhai/README.ctjhai: src/ctjhai/README
++ cp -l $< $@
++
++src/leon/doc/leon_guava_manual.pdf: src/leon/doc/manual.tex
++ $(PDFTEX) -jobname $(basename $(@F)) -output-directory $(@D) $<
++
++doc/manual.pdf:
++ cat debian/makedoc.g | $(CGAP) -A -q -T > /dev/null
+
+ install:
+- ( cp ./src/leonconv $(BINDIR) )
+- ( cp $(SRCDIR)/desauto $(BINDIR) )
+- ( cp $(CJSRCDIR)/minimum-weight $(BINDIR) )
+- ( cp $(SRCDIR)/wtdist $(BINDIR) )
++ if test ! -d $(DESTDIR)/$(BINDIR); then mkdir -p $(DESTDIR)/$(BINDIR); fi
++ ( cp ./src/leonconv $(DESTDIR)/$(BINDIR) )
++ ( cp $(CJSRCDIR)/minimum-weight $(DESTDIR)/$(BINDIR) )
++ ( cd $(SRCDIR); $(MAKE) install BINDIR="$(BINDIR)"; )
++ ( cd $(DESTDIR)/$(BINDIR); ln -sf leon/desauto )
++ ( cd $(DESTDIR)/$(BINDIR); ln -sf leon/wtdist )
+
+ clean:
+- -( cd $(BINDIR); rm -f *.o )
+ -( cd src && make clean )
+ -( cd $(CJSRCDIR) && rm -f minimum-weight *.o)
+ -( cd $(SRCDIR) && make clean )
+
+ distclean: clean
+ ( rm -rf bin )
+- ( mkdir bin )
+ ( rm -f Makefile Makefile-*)
+ -( cd src && make distclean )
+ -( cd src/leon && make distclean )
+--- a/configure
++++ b/configure
+@@ -59,6 +59,7 @@
+ rm -f Makefile Makefile$CONFIGSUFFIX
+ . $GAPPATH/sysinfo.gap$CONFIGSUFFIX
+ sed \
++ -e 's|@DEB_BUILD_GNU_TYPE@|'$(dpkg-architecture -qDEB_BUILD_GNU_TYPE)'|g' \
+ -e 's|@GAPPATH@|'$GAPPATH'|g' \
+ -e 's/@GAPARCH@/'$GAParch'/g' \
+ Makefile.in > Makefile$CONFIGSUFFIX
+--- a/src/leon/Makefile.in
++++ b/src/leon/Makefile.in
+@@ -7,6 +7,9 @@
+ LINKNAME = -o
+ OBJ = o
+ OBJS = setstab cent inter desauto generate commut cjrndper orblist fndelt compgrp orbdes randobj wtdist
++BINDIR ?= ../../bin
++
++COMPOPT += -Wno-unused-result
+
+ all: $(OBJS)
+ #
+@@ -183,6 +186,11 @@
+ wtdist.$(OBJ) : $(SRCDIR)/group.h $(SRCDIR)/extname.h $(SRCDIR)/groupio.h $(SRCDIR)/errmesg.h $(SRCDIR)/field.h $(SRCDIR)/readdes.h $(SRCDIR)/storage.h $(SRCDIR)/token.h $(SRCDIR)/util.h $(SRCDIR)/wt.h $(SRCDIR)/swt.h $(SRCDIR)/wtdist.c
+ $(COMPILE) $(COMPOPT) $(INCLUDES) $(SRCDIR)/wtdist.c
+
++install:
++ if test ! -d $(DESTDIR)/$(BINDIR); then mkdir -p $(DESTDIR)/$(BINDIR); fi
++ if test ! -d $(DESTDIR)/$(BINDIR)/leon; then mkdir -p $(DESTDIR)/$(BINDIR)/leon; fi
++ ( for p in $(OBJS); do cp $$p $(DESTDIR)/$(BINDIR)/leon ; done )
++
+ clean:
+ rm -f *.o $(OBJS)
+
diff --git a/debian/patches/hadamard-bugfix.patch b/debian/patches/hadamard-bugfix.patch
deleted file mode 100644
index 59e6cd3..0000000
--- a/debian/patches/hadamard-bugfix.patch
+++ /dev/null
@@ -1,12 +0,0 @@
-diff -ur /tmp/guava-3.6/lib/matrices.gi foo/guava3.6/lib/matrices.gi
---- a/lib/matrices.gi 2008-06-20 16:14:59.000000000 -0400
-+++ b/lib/matrices.gi 2008-06-28 14:54:56.000000000 -0400
-@@ -157,6 +157,8 @@
- local result, had, i, j, N;
- if n mod 2 = 0 then
- N:=n/2;
-+ elif n = 1 then
-+ N :=1;
- else
- Error("The Hadamard matrix of order ",n," does not exist");
- fi;
diff --git a/debian/patches/series b/debian/patches/series
index ed60ae2..5764411 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -1 +1,4 @@
-hadamard-bugfix.patch
+upstream-configure_machinery-refreshment.patch
+upstream-fix-warnings.patch
+debianization.patch
+debianization-bug-761052-gapdoc.patch
diff --git a/debian/patches/upstream-configure_machinery-refreshment.patch b/debian/patches/upstream-configure_machinery-refreshment.patch
new file mode 100644
index 0000000..7fe3703
--- /dev/null
+++ b/debian/patches/upstream-configure_machinery-refreshment.patch
@@ -0,0 +1,174 @@
+Description: upstream configure machinery refreshment
+ Refresh the configure machinery as provided within
+ the source tarball; ideally, an autotools machinery
+ may be implemented from scratch, and even more.
+Origin: debian
+Author: Jerome Benoit <calculus at rezozer.net>
+Last-Update: 2014-09-05
+
+--- a/configure
++++ b/configure
+@@ -15,29 +15,38 @@
+ shift
+ done
+
+-if [ x"$GAPPATH" = "x" ]; then
++if [ x"$GAPPATH" = "x" ]; then
+ GAPPATH=../..
+- echo "Using ../.. as default GAPPATH"
++ echo "Using ../.. as default GAPPATH"
+ fi
+
+ if [ x"$CONFIGNAME" = "x" ]; then
+ CONFIGNAME="default64"
+ if [ ! -e $GAPPATH/sysinfo.gap-$CONFIGNAME ]; then
+ CONFIGNAME="default32"
+- fi
++ if [ ! -e $GAPPATH/sysinfo.gap-$CONFIGNAME ]; then
++ CONFIGNAME="UNKNOWN"
++ fi
++ fi
+ fi
+
+-if [ ! -e $GAPPATH/sysinfo.gap-$CONFIGNAME ]; then
++if [ x"$CONFIGNAME" != "xUNKNOWN" ]; then
++ CONFIGSUFFIX="-$CONFIGNAME"
++else
++ CONFIGSUFFIX=""
++fi
++
++if [ ! -e $GAPPATH/sysinfo.gap$CONFIGSUFFIX ]; then
++ echo
++ echo "No file $GAPPATH/sysinfo.gap$CONFIGSUFFIX found."
+ echo
+- echo "No file "$GAPPATH"/sysinfo.gap-"$CONFIGNAME" found."
+- echo
+ echo "Usage: ./configure [GAPPATH] [CONFIGNAME=confnam]"
+ echo " where GAPPATH is a path to your GAP installation"
+ echo " and confnam is the name of the GAP configuration to use."
+ echo " (The default for GAPPATH is \"../..\" and default confignam"
+ echo " is \"default64\" if it exists, otherwise \"default32\".)"
+ echo
+- echo Either your GAPPATH is incorrect or the GAP it is pointing to
++ echo "Either your GAPPATH is incorrect or the GAP it is pointing to"
+ echo "is not properly compiled (do \"./configure ; make\" there first)."
+ echo
+ echo Aborting... No Makefile is generated.
+@@ -45,14 +54,17 @@
+ exit 1
+ fi
+
+-echo "Using config in "$GAPPATH"/sysinfo.gap-"$CONFIGNAME
++echo "Using config in $GAPPATH/sysinfo.gap$CONFIGSUFFIX"
+
+-rm -f Makefile Makefile-$CONFIGNAME
+-. $GAPPATH/sysinfo.gap-$CONFIGNAME
+-GAParchprot="$GAParch"
+-echo GAPPATH=$GAPPATH >Makefile-$CONFIGNAME
+-echo CONFIGNAME=$CONFIGNAME >>Makefile-$CONFIGNAME
+-cat Makefile.in | sed -e "s/@GAPARCH@/$GAParchprot/g" | sed -e "s/@CONFIGNAME@/$CONFIGNAME/g" >>Makefile-$CONFIGNAME
+-ln -s Makefile-$CONFIGNAME Makefile
+-echo "Created ./Makefile-"$CONFIGNAME" with link from ./Makefile"
++rm -f Makefile Makefile$CONFIGSUFFIX
++. $GAPPATH/sysinfo.gap$CONFIGSUFFIX
++sed \
++ -e 's|@GAPPATH@|'$GAPPATH'|g' \
++ -e 's/@GAPARCH@/'$GAParch'/g' \
++ Makefile.in > Makefile$CONFIGSUFFIX
++
++if [ x"$CONFIGNAME" != "xUNKNOWN" ]; then
++ ln -s Makefile$CONFIGSUFFIX Makefile
++ echo "Created ./Makefile$CONFIGSUFFIX with link from ./Makefile"
++fi
+
+--- a/Makefile.in
++++ b/Makefile.in
+@@ -1,5 +1,6 @@
+-CC = gcc
++GAPPATH=@GAPPATH@
+ GAPARCH=@GAPARCH@
++CC = gcc
+ CFLAGS = -O2
+ SRCDIR = ./src/leon
+ CJSRCDIR= ./src/ctjhai
+@@ -17,15 +18,15 @@
+ if test ! -d $(BINDIR); then mkdir -p $(BINDIR); fi
+
+ minimum-weight: $(CJSRCDIR)/minimum-weight.o $(CJSRCDIR)/minimum-weight-gf2.o $(CJSRCDIR)/minimum-weight-gf3.o $(CJSRCDIR)/popcount.o
+- $(CC) -o $(CJSRCDIR)/minimum-weight \
++ $(CC) $(LDFLAGS) -o $(CJSRCDIR)/minimum-weight \
+ $(CJSRCDIR)/minimum-weight.o $(CJSRCDIR)/minimum-weight-gf2.o \
+ $(CJSRCDIR)/minimum-weight-gf3.o $(CJSRCDIR)/popcount.o -lm
+
+ leonconv:
+- cd ./src; $(MAKE) CC="$(CC)" CFLAGS="$(CFLAGS)";
++ cd ./src; $(MAKE) CC="$(CC)" CPPFLAGS="$(CPPFLAGS)" CFLAGS="$(CFLAGS)" LDFLAGS="$(LDFLAGS)";
+
+ desauto:
+- cd $(SRCDIR); ./configure; $(MAKE) CC="$(CC)" CFLAGS="$(CFLAGS)";
++ cd $(SRCDIR); autoreconf --install --force || true ; ./configure; $(MAKE) CC="$(CC)" CPPFLAGS="$(CPPFLAGS)" CFLAGS="$(CFLAGS)" LDFLAGS="$(LDFLAGS)";
+
+ minimum-weight.o: $(CJSRCDIR)/minimum-weight.c $(CJSRCDIR)/minimum-weight-gf2.h $(CJSRCDIR)/minimum-weight-gf3.h $(CJSRCDIR)/popcount.h $(CJSRCDIR)/config.h $(CJSRCDIR)/types.h
+ $(CC) -c -O3 -Wall -I $(CJSRCDIR) $(CJSRCDIR)/minimum-weight.c
+@@ -47,18 +48,18 @@
+ ( cp $(SRCDIR)/wtdist $(BINDIR) )
+
+ clean:
+- ( cd $(BINDIR); rm -f *.o )
+- ( cd src && make clean )
+- ( cd $(CJSRCDIR) && rm -f minimum-weight *.o)
+- ( cd $(SRCDIR) && make clean )
++ -( cd $(BINDIR); rm -f *.o )
++ -( cd src && make clean )
++ -( cd $(CJSRCDIR) && rm -f minimum-weight *.o)
++ -( cd $(SRCDIR) && make clean )
+
+ distclean: clean
+ ( rm -rf bin )
+ ( mkdir bin )
+ ( rm -f Makefile Makefile-*)
+- ( cd src && make distclean )
+- ( cd src/leon && make distclean )
+- ( cd doc && rm -f *.aux *.log *.dvi *.ps)
++ -( cd src && make distclean )
++ -( cd src/leon && make distclean )
++ -( cd doc && rm -f *.aux *.log *.dvi *.ps)
+
+ # for GAP distribution
+ src_dist:
+--- a/src/leon/configure.in
++++ b/src/leon/configure.in
+@@ -1,7 +1,7 @@
+ AC_INIT(leon,1.0)
+ AC_CONFIG_SRCDIR(src/group.h)
+ AM_INIT_AUTOMAKE
+-AM_CONFIG_HEADER(src/leon_config.h)
++AC_CONFIG_HEADERS([src/leon_config.h])
+ AC_CHECK_SIZEOF(int)
+
+ AC_PROG_INSTALL
+--- a/src/Makefile
++++ b/src/Makefile
+@@ -14,7 +14,7 @@
+ cd leon make
+
+ leonconv: leonconv.c
+- $(CC) $(CFLAGS) -o leonconv leonconv.c
++ $(CC) $(CPPFLAGS) $(CFLAGS) $(LDFLAGS) -o leonconv leonconv.c
+
+ $(SUBDIRS):
+ $(MAKE) --directory=$@
+--- a/src/leon/Makefile.in
++++ b/src/leon/Makefile.in
+@@ -1,9 +1,9 @@
+ COMPILE = gcc
+ CFLAGS = -O2
+ SRCDIR = ./src
+-COMPOPT = -c -O2
++COMPOPT = $(CPPFLAGS) -c -O2
+ INCLUDES =
+-LINKOPT = -v
++LINKOPT = $(LDFLAGS) -v
+ LINKNAME = -o
+ OBJ = o
+ OBJS = setstab cent inter desauto generate commut cjrndper orblist fndelt compgrp orbdes randobj wtdist
diff --git a/debian/patches/upstream-fix-warnings.patch b/debian/patches/upstream-fix-warnings.patch
new file mode 100644
index 0000000..6658dcd
--- /dev/null
+++ b/debian/patches/upstream-fix-warnings.patch
@@ -0,0 +1,590 @@
+Description: fixes for upstream source warnings
+ Fix warnings emitted by gcc when the package builds;
+ meant to be submitted to the upstream maintainer.
+Origin: debian
+Author: Jerome Benoit <calculus at rezozer.net>
+Last-Update: 2014-09-06
+
+--- a/src/leonconv.c
++++ b/src/leonconv.c
+@@ -1,7 +1,5 @@
+-#include <stdio.h>
+-#if !defined(__APPLE__)
+-#include <malloc.h>
+-#endif
++#include <stdlib.h>
++#include <stdio.h>
+
+ FILE *in, *out;
+
+--- a/src/leon/src/errmesg.h
++++ b/src/leon/src/errmesg.h
+@@ -2,33 +2,33 @@
+ #define ERRMESG
+
+ extern BOOLEAN isValidName(
+- char *name) /* The name to be checked for validity. */
++ const char *name) /* The name to be checked for validity. */
+ ;
+
+ extern void errorMessage(
+- char *file, /* The file in which the error occured. */
++ const char *file, /* The file in which the error occured. */
+ int line, /* The line before which the error occured. */
+- char *function, /* The function in which the error occured. */
+- char *message) /* The message to be printed. It will be
++ const char *function, /* The function in which the error occured. */
++ const char *message) /* The message to be printed. It will be
+ prefixed by "Error: ". */
+ ;
+
+ extern void errorMessage1i(
+- char *file, /* The file in which the error occured. */
++ const char *file, /* The file in which the error occured. */
+ int line, /* The line before which the error occured. */
+- char *function, /* The function in which the error occured. */
+- char *message1, /* The first part of the error message. */
++ const char *function, /* The function in which the error occured. */
++ const char *message1, /* The first part of the error message. */
+ Unsigned intParm, /* The integer variable part of the message. */
+- char *message2) /* The second part of the error message. */
++ const char *message2) /* The second part of the error message. */
+ ;
+
+ extern void errorMessage1s(
+- char *file, /* The file in which the error occured. */
++ const char *file, /* The file in which the error occured. */
+ int line, /* The line before which the error occured. */
+- char *function, /* The function in which the error occured. */
+- char *message1, /* The first part of the error message. */
+- char *strParm, /* The integer variable part of the message. */
+- char *message2) /* The second part of the error message. */
++ const char *function, /* The function in which the error occured. */
++ const char *message1, /* The first part of the error message. */
++ const char *strParm, /* The integer variable part of the message. */
++ const char *message2) /* The second part of the error message. */
+ ;
+
+ #endif
+--- a/src/leon/src/errmesg.c
++++ b/src/leon/src/errmesg.c
+@@ -14,7 +14,7 @@
+ /*-------------------------- isValidName ----------------------------------*/
+
+ BOOLEAN isValidName(
+- char *name) /* The name to be checked for validity. */
++ const char *name) /* The name to be checked for validity. */
+ {
+ Unsigned i;
+
+@@ -32,10 +32,10 @@
+ /*-------------------------- errorMessage ---------------------------------*/
+
+ void errorMessage(
+- char *file, /* The file in which the error occured. */
++ const char *file, /* The file in which the error occured. */
+ int line, /* The line before which the error occured. */
+- char *function, /* The function in which the error occured. */
+- char *message) /* The message to be printed. It will be
++ const char *function, /* The function in which the error occured. */
++ const char *message) /* The message to be printed. It will be
+ prefixed by "Error: ". */
+ {
+ printf( "\n\n Error: %s\n"
+@@ -48,12 +48,12 @@
+ /*-------------------------- errorMessage1i -------------------------------*/
+
+ void errorMessage1i(
+- char *file, /* The file in which the error occured. */
++ const char *file, /* The file in which the error occured. */
+ int line, /* The line before which the error occured. */
+- char *function, /* The function in which the error occured. */
+- char *message1, /* The first part of the error message. */
++ const char *function, /* The function in which the error occured. */
++ const char *message1, /* The first part of the error message. */
+ Unsigned intParm, /* The integer variable part of the message. */
+- char *message2) /* The second part of the error message. */
++ const char *message2) /* The second part of the error message. */
+ {
+ printf( "\n\n Error: %s%u%s\n"
+ " Program was executing function %s (line %d in file %s).",
+@@ -65,12 +65,12 @@
+ /*-------------------------- errorMessage1s -------------------------------*/
+
+ void errorMessage1s(
+- char *file, /* The file in which the error occured. */
++ const char *file, /* The file in which the error occured. */
+ int line, /* The line before which the error occured. */
+- char *function, /* The function in which the error occured. */
+- char *message1, /* The first part of the error message. */
+- char *strParm, /* The integer variable part of the message. */
+- char *message2) /* The second part of the error message. */
++ const char *function, /* The function in which the error occured. */
++ const char *message1, /* The first part of the error message. */
++ const char *strParm, /* The integer variable part of the message. */
++ const char *message2) /* The second part of the error message. */
+ {
+ printf( "\n\n Error: %s%s%s\n"
+ " Program was executing function %s (line %d in file %s).",
+--- a/src/leon/src/cdesauto.c
++++ b/src/leon/src/cdesauto.c
+@@ -39,28 +39,28 @@
+
+
+ static BOOLEAN matrix01AutoProperty(
+- Permutation *s )
++ const Permutation *const s )
+ {
+ return isMatrix01Isomorphism( DD, DD, s, FALSE);
+ }
+
+
+ static BOOLEAN matrix01IsoProperty(
+- Permutation *s )
++ const Permutation *const s )
+ {
+ return isMatrix01Isomorphism( DD_L, DD_R, s, FALSE);
+ }
+
+
+ static BOOLEAN codeAutoProperty(
+- Permutation *s )
++ const Permutation *const s )
+ {
+ return isCodeIsomorphism( CC, CC, s);
+ }
+
+
+ static BOOLEAN codeIsoProperty(
+- Permutation *s )
++ const Permutation *const s )
+ {
+ return isCodeIsomorphism( CC_L, CC_R, s);
+ }
+@@ -379,7 +379,7 @@
+ else
+ ptsNotInLambda = TRUE;
+ if ( ptsInLambda && ptsNotInLambda ) {
+- reducingRefn.refn.family = family;
++ reducingRefn.refn.family = (RefinementFamily *)(family);
+ reducingRefn.refn.refnParm[0].intParm = cellNo;
+ reducingRefn.priority = 1;
+ return reducingRefn;
+@@ -598,7 +598,7 @@
+ /* If we can split the same cell as before using a different intersection
+ count, do so immediately (priority 1). */
+ if ( listSize > 0 ) {
+- reducingRefn.refn.family = family;
++ reducingRefn.refn.family = (RefinementFamily *)(family);
+ reducingRefn.refn.refnParm[0].intParm = opposingCell;
+ reducingRefn.refn.refnParm[1].intParm = 0;
+ reducingRefn.refn.refnParm[2].intParm = list[listSize--];
+@@ -644,7 +644,7 @@
+ reducingRefn.refn.refnParm[1].intParm = processingCell;
+ reducingRefn.refn.refnParm[2].intParm = UpsilonStack->degree + 1;
+ rowVsColRefine( family->familyParm, reducingRefn.refn.refnParm,
+- UpsilonStack);
++ (PartitionStack *const)(UpsilonStack));
+
+ /* If no splitting occured of opposing cell via processing cell is
+ possible, nonZeroCount will be 1. If this occurs, skip to the next
+@@ -672,7 +672,7 @@
+ list[++listSize] = nonZeroPosition[k];
+
+ /* Finally return the first entry on the list. */
+- reducingRefn.refn.family = family;
++ reducingRefn.refn.family = (RefinementFamily *)(family);
+ reducingRefn.refn.refnParm[0].intParm = opposingCell;
+ reducingRefn.refn.refnParm[1].intParm = processingCell;
+ reducingRefn.refn.refnParm[2].intParm = list[listSize--];
+--- a/src/leon/src/cmatauto.c
++++ b/src/leon/src/cmatauto.c
+@@ -41,28 +41,28 @@
+ static BOOLEAN informCols;
+
+ static BOOLEAN matrix01AutoProperty(
+- Permutation *s )
++ const Permutation *const s )
+ {
+ return isMatrix01Isomorphism( MM, MM, s, checkMonomialProperty);
+ }
+
+
+ static BOOLEAN matrix01IsoProperty(
+- Permutation *s )
++ const Permutation *const s )
+ {
+ return isMatrix01Isomorphism( MM_L, MM_R, s, checkMonomialProperty);
+ }
+
+
+ static BOOLEAN codeAutoProperty(
+- Permutation *s )
++ const Permutation *const s )
+ {
+ return isCodeIsomorphism( CC, CC, s);
+ }
+
+
+ static BOOLEAN codeIsoProperty(
+- Permutation *s )
++ const Permutation *const s )
+ {
+ return isCodeIsomorphism( CC_L, CC_R, s);
+ }
+@@ -449,7 +449,7 @@
+ else
+ ptsNotInLambda = TRUE;
+ if ( ptsInLambda && ptsNotInLambda ) {
+- reducingRefn.refn.family = family;
++ reducingRefn.refn.family = (RefinementFamily *)(family);
+ reducingRefn.refn.refnParm[0].intParm = cellNo;
+ reducingRefn.priority = 1;
+ return reducingRefn;
+@@ -694,7 +694,7 @@
+ /* If we can split the same cell as before using a different weighted
+ sum, do so immediately (priority 1). */
+ if ( listSize > 0 ) {
+- reducingRefn.refn.family = family;
++ reducingRefn.refn.family = (RefinementFamily *)(family);
+ reducingRefn.refn.refnParm[0].intParm = opposingCell;
+ reducingRefn.refn.refnParm[1].intParm = 0;
+ reducingRefn.refn.refnParm[2].intParm = list[listSize--];
+@@ -740,7 +740,7 @@
+ reducingRefn.refn.refnParm[1].intParm = processingCell;
+ reducingRefn.refn.refnParm[2].intParm = UNKNOWN;
+ dummySplit = gRowVsColRefine( family->familyParm, reducingRefn.refn.refnParm,
+- UpsilonStack);
++ (PartitionStack *const)(UpsilonStack));
+
+ /* If no splitting occured of opposing cell via processing cell is
+ possible, nonZeroCount will be 1. If this occurs, skip to the next
+@@ -768,7 +768,7 @@
+ list[++listSize] = nonZeroPosition[k];
+
+ /* Finally return the first entry on the list. */
+- reducingRefn.refn.family = family;
++ reducingRefn.refn.family = (RefinementFamily *)(family);
+ reducingRefn.refn.refnParm[0].intParm = opposingCell;
+ reducingRefn.refn.refnParm[1].intParm = processingCell;
+ reducingRefn.refn.refnParm[2].intParm = list[listSize--];
+--- a/src/leon/src/randschr.c
++++ b/src/leon/src/randschr.c
+@@ -150,7 +150,7 @@
+
+ static void randomizeGen(
+ const Unsigned genListLength, /* The length of the list genList. */
+- const Permutation *const genList[], /* The list of (generating) perms. */
++ const Permutation *const *genList, /* The list of (generating) perms. */
+ const Unsigned count1, /* The minimum word length, as above. */
+ const Unsigned count2, /* The maximum word length, as above. */
+ Permutation *const randGen) /* The old and new quasi-random elt. */
+@@ -159,7 +159,7 @@
+ wordLength = count1 +
+ ( (count2 > count1) ? randInteger( 0, count2-count1) : 0);
+ for ( i = 1 ; i <= wordLength ; ++i )
+- rightMultiply( randGen, genList[ randInteger(1,genListLength) ]);
++ rightMultiply( randGen, *(genList + randInteger(1,genListLength)) );
+ }
+
+
+@@ -375,7 +375,7 @@
+ (trueGroupOrder.noOfFactors == UNKNOWN ||
+ !factEqual( G->order, &trueGroupOrder)) ) {
+
+- randomizeGen( noOfOriginalGens, originalGen,
++ randomizeGen( noOfOriginalGens, (const Permutation *const *)(originalGen),
+ rOptions.minWordLengthIncrement,
+ rOptions.maxWordLengthIncrement, randGen);
+ if ( factorGroupElt( G, randGen, h, &finalLevel) )
+--- a/src/leon/src/ccent.c
++++ b/src/leon/src/ccent.c
+@@ -26,7 +26,7 @@
+ /* Forward declarations of functions. */
+ static RefinementMapping centRefine;
+ static ReducChkFn isCentReducible;
+-static void initializeCentRefine( Permutation *e);
++static void initializeCentRefine( const Permutation *const e);
+ static Partition *cycleLengthPartn(
+ const Permutation *const e,
+ UnsignedS *const cycleLen,
+@@ -158,7 +158,7 @@
+
+ /* Centralizer refinement. */
+ CCC_e.refine = centRefine;
+- CCC_e.familyParm[0].ptrParm = e;
++ CCC_e.familyParm[0].ptrParm = (Permutation *)(e);
+ refnFamList[refnCount] = &CCC_e;
+ reducChkList[refnCount] = isCentReducible;
+ specialRefinement[refnCount] = NULL;
+@@ -288,8 +288,8 @@
+
+ /* Centralizer refinement. */
+ CCC_ef.refine = centRefine;
+- CCC_ef.familyParm_L[0].ptrParm = e;
+- CCC_ef.familyParm_R[0].ptrParm = f;
++ CCC_ef.familyParm_L[0].ptrParm = (Permutation *)(e);
++ CCC_ef.familyParm_R[0].ptrParm = (Permutation *)(f);
+ refnFamList[refnCount] = &CCC_ef;
+ reducChkList[refnCount] = isCentReducible;
+ specialRefinement[refnCount] = NULL;
+@@ -411,7 +411,7 @@
+ eCyclePartn = NULL;
+ if ( centPartnCount > 0 ) {
+ ex[centPartnCount+1] = NULL;
+- eCyclePartn = multipleCycleLengthPartn( ex);
++ eCyclePartn = multipleCycleLengthPartn((const Permutation *const *)(ex));
+ }
+ else
+ eCyclePartn = NULL;
+@@ -457,7 +457,7 @@
+
+ static struct {
+ Unsigned elementCount;
+- Permutation *element[17];
++ const Permutation * element[17];
+ RefnListEntry **hashTable[17];
+ RefnListEntry *refnList[17];
+ RefnListEntry *freeListHeader[17];
+@@ -473,7 +473,7 @@
+
+ /*-------------------------- initializeCentRefine -------------------------*/
+
+-static void initializeCentRefine( Permutation *e)
++static void initializeCentRefine( const Permutation *const e)
+ {
+ int i;
+
+@@ -841,7 +841,7 @@
+ if ( minPriority == ULONG_MAX )
+ reducingRefn.priority = IRREDUCIBLE;
+ else {
+- reducingRefn.refn.family = family;
++ reducingRefn.refn.family = (RefinementFamily *)(family);
+ reducingRefn.refn.refnParm[0].intParm = minPosition->i;
+ reducingRefn.refn.refnParm[1].intParm = minPosition->j;
+ reducingRefn.priority = thisPriority;
+--- a/src/leon/src/copy.h
++++ b/src/leon/src/copy.h
+@@ -2,11 +2,11 @@
+ #define COPY
+
+ extern Permutation *copyOfPermutation(
+- Permutation *oldPerm) /* The permutation to be copied. */
++ const Permutation *const oldPerm) /* The permutation to be copied. */
+ ;
+
+ extern PermGroup *copyOfPermGroup(
+- PermGroup *oldGroup) /* The group being copied. */
++ const PermGroup *const oldGroup) /* The group being copied. */
+ ;
+
+ #endif
+--- a/src/leon/src/copy.c
++++ b/src/leon/src/copy.c
+@@ -24,7 +24,7 @@
+ word field is not supported. */
+
+ Permutation *copyOfPermutation(
+- Permutation *oldPerm) /* The permutation to be copied. */
++ const Permutation *const oldPerm) /* The permutation to be copied. */
+ {
+ Unsigned pt;
+ Permutation *newPerm = allocPermutation();
+@@ -64,7 +64,7 @@
+ of the generators of the old group is modified. */
+
+ PermGroup *copyOfPermGroup(
+- PermGroup *oldGroup) /* The group being copied. */
++ const PermGroup *const oldGroup) /* The group being copied. */
+ {
+ Unsigned i, level, pt;
+ Permutation *oldGen, *newGen, *previousGen, *temp;
+--- a/src/leon/src/randgrp.c
++++ b/src/leon/src/randgrp.c
+@@ -65,7 +65,7 @@
+ stabilizer in the group of a designated number of base points. */
+
+ Word *randGroupWord(
+- PermGroup *G,
++ const PermGroup *const G,
+ Unsigned atLevel)
+ {
+ Word *w = newTrivialWord();
+@@ -93,7 +93,7 @@
+ in. */
+
+ Permutation *randGroupPerm(
+- PermGroup *G,
++ const PermGroup *const G,
+ Unsigned atLevel)
+ {
+ Permutation *randPerm = newIdentityPerm( G->degree);
+--- a/src/leon/src/randgrp.h
++++ b/src/leon/src/randgrp.h
+@@ -11,12 +11,12 @@
+ ;
+
+ extern Word *randGroupWord(
+- PermGroup *G,
++ const PermGroup *const G,
+ Unsigned atLevel)
+ ;
+
+ extern Permutation *randGroupPerm(
+- PermGroup *G,
++ const PermGroup *const G,
+ Unsigned atLevel)
+ ;
+
+--- a/src/leon/src/orbrefn.c
++++ b/src/leon/src/orbrefn.c
+@@ -765,7 +765,7 @@
+ if ( minPriority == ULONG_MAX )
+ reducingRefn.priority = IRREDUCIBLE;
+ else {
+- reducingRefn.refn.family = family;
++ reducingRefn.refn.family = (RefinementFamily *)(family);
+ reducingRefn.refn.refnParm[0].intParm = minPosition->i;
+ reducingRefn.refn.refnParm[1].intParm = minPosition->j;
+ reducingRefn.priority = thisPriority;
+--- a/src/leon/src/csetstab.c
++++ b/src/leon/src/csetstab.c
+@@ -281,7 +281,7 @@
+ else
+ ptsNotInLambda = TRUE;
+ if ( ptsInLambda && ptsNotInLambda ) {
+- reducingRefn.refn.family = family;
++ reducingRefn.refn.family = (RefinementFamily *)(family);
+ reducingRefn.refn.refnParm[0].intParm = cellNo;
+ reducingRefn.priority = 1;
+ return reducingRefn;
+--- a/src/leon/src/cparstab.c
++++ b/src/leon/src/cparstab.c
+@@ -277,7 +277,7 @@
+ cellSize[cellNo] ; ++position )
+ if ( Lambda->cellNumber[pointList[position]] !=
+ Lambda->cellNumber[pointList[position-1]] ) {
+- reducingRefn.refn.family = family;
++ reducingRefn.refn.family = (RefinementFamily *)(family);
+ reducingRefn.refn.refnParm[0].intParm = cellNo;
+ reducingRefn.refn.refnParm[1].intParm =
+ Lambda->cellNumber[pointList[position]];
+--- a/src/leon/src/cuprstab.c
++++ b/src/leon/src/cuprstab.c
+@@ -705,7 +705,7 @@
+ if ( minPriority == ULONG_MAX )
+ reducingRefn.priority = IRREDUCIBLE;
+ else {
+- reducingRefn.refn.family = family;
++ reducingRefn.refn.family = (RefinementFamily *)(family);
+ reducingRefn.refn.refnParm[0].intParm = minPosition->i;
+ reducingRefn.refn.refnParm[1].intParm = minPosition->j;
+ reducingRefn.priority = thisPriority;
+--- a/src/leon/src/relator.c
++++ b/src/leon/src/relator.c
+@@ -166,7 +166,7 @@
+ for ( i = 1 ; i <= symLength ; ++i ) {
+ ++addCount;
+ p = allocOccurenceOfGen();
+- p->r = r;
++ p->r = (Relator *)(r);
+ p->relLength = r->length;
+ p->level = r->level;
+ p->fRelStart = r->fRel + i;
+@@ -187,7 +187,7 @@
+ if ( i < r->length && priority >= shiftPriority[j] ) {
+ ++addCount;
+ p = allocOccurenceOfGen();
+- p->r = r;
++ p->r = (Relator *)(r);
+ p->relLength = r->length;
+ p->level = r->level;
+ p->fRelStart = r->fRel + i;
+@@ -337,7 +337,7 @@
+ Unsigned processCoincidence(
+ const PermGroup *const G,
+ DeductionQueue *deductionQueue,
+- const Permutation *const genHeader,
++ Permutation *const genHeader,
+ const Unsigned coset1,
+ const Unsigned coset2)
+ {
+@@ -480,7 +480,7 @@
+ DeductionQueue *deductionQueue,
+ const Unsigned level,
+ const Deduction *const deduc,
+- const Permutation *const genHeader)
++ Permutation *const genHeader)
+ {
+ OccurenceOfGen *occurence;
+ Unsigned count, fCos, bCos, newEntryCount = 0, degree = G->degree;
+@@ -557,7 +557,7 @@
+ const Unsigned level,
+ DeductionQueue *deductionQueue,
+ const Relator *const newRel,
+- const Permutation *const genHeader)
++ Permutation *const genHeader)
+ {
+ Unsigned i, pt, startingPos, count, fCos, bCos, newEntryCount = 0;
+ Unsigned **fPtr, **bPtr;
+--- a/src/leon/src/stcs.c
++++ b/src/leon/src/stcs.c
+@@ -717,7 +717,7 @@
+ for ( i = 1 , j = sGen.word.length ; i < j ; ++i , --j )
+ EXCHANGE( sGen.word.position[i], sGen.word.position[j] , temp);
+
+- sGen.word.position[++sGen.word.length] = gen;
++ sGen.word.position[++sGen.word.length] = (Permutation *)(gen);
+
+ for ( pt = gen->image[point] & NHB ; pt != basePt ;
+ pt = schreierVec[pt]->invImage[pt] & NHB )
+@@ -771,7 +771,7 @@
+ for ( i = 1 , j = sGen.word.length ; i < j ; ++i , --j )
+ EXCHANGE( sGen.word.position[i], sGen.word.position[j] , temp);
+
+- sGen.word.position[++sGen.word.length] = gen;
++ sGen.word.position[++sGen.word.length] = (Permutation *)(gen);
+
+ for ( pt = equivCoset[gen->image[point] & NHB] ; pt != basePt ;
+ pt = equivCoset[schreierVec[pt]->invImage[pt] & NHB] )
+--- a/src/leon/src/relator.h
++++ b/src/leon/src/relator.h
+@@ -52,7 +52,7 @@
+ extern Unsigned processCoincidence(
+ const PermGroup *const G,
+ DeductionQueue *deductionQueue,
+- const Permutation *const genHeader,
++ Permutation *const genHeader,
+ const Unsigned coset1,
+ const Unsigned coset2)
+ ;
+@@ -62,7 +62,7 @@
+ DeductionQueue *deductionQueue,
+ const Unsigned level,
+ const Deduction *const deduc,
+- const Permutation *const genHeader)
++ Permutation *const genHeader)
+ ;
+
+ extern Unsigned xTraceNewRelator(
+@@ -70,7 +70,7 @@
+ const Unsigned level,
+ DeductionQueue *deductionQueue,
+ const Relator *const newRel,
+- const Permutation *const genHeader)
++ Permutation *const genHeader)
+ ;
+
+ extern void makeDefinition(
+--- a/src/leon/src/setstab.c
++++ b/src/leon/src/setstab.c
+@@ -183,7 +183,7 @@
+ PointSet *Lambda, *Xi;
+ Partition *PLambda, *PXi;
+ BOOLEAN imageFlag = FALSE, imageFormatFlag = FALSE;
+- char ordUnord[] = "Ordered";
++ char ordUnord[10] = "Ordered\0\0";
+ char tempArg[8];
+ enum { SET_STAB, SET_IMAGE, PARTN_STAB, PARTN_IMAGE,
+ UPARTN_STAB, UPARTN_IMAGE} computationType = SET_STAB;
diff --git a/debian/repack b/debian/repack
new file mode 100755
index 0000000..b0e73dc
--- /dev/null
+++ b/debian/repack
@@ -0,0 +1,126 @@
+#!/bin/bash
+
+PACKAGE_NAME=gap-guava
+
+set -e
+set -u
+
+usage() {
+ echo "Usage: repack --upstream-version <ver> <downloaded file>"
+ exit 1
+ }
+
+if [ "$#" != "3" ]; then
+ usage
+fi
+if [ "$1" != "--upstream-version" ]; then
+ usage
+fi
+if [ ! -f "$3" ]; then
+ if [ -n "$3" ]; then
+ echo "$3 doesn't exist"
+ fi
+ usage
+fi
+UPSTREAM_VERSION="$2"
+UPSTREAM_TARBALLZZ="$3"
+
+DEBIAN_SUFFIX="+ds"
+####DEBIAN_ENCAPSULATEDFOLDERNAME="${PACKAGE_NAME}-usrc"
+
+DEBIAN_UVERSION=${UPSTREAM_VERSION}${DEBIAN_SUFFIX}
+DEBIAN_ROOTFOLDERNAME="${PACKAGE_NAME}-${DEBIAN_UVERSION}.orig"
+DEBIAN_TARBALLXZ="$(dirname $UPSTREAM_TARBALLZZ)/${PACKAGE_NAME}_${DEBIAN_UVERSION}.orig.tar.xz"
+
+REPACK_TMPDIR=`mktemp -d ./repackXXXXXX`
+REPACK_TMPDIR=$(readlink -f "$REPACK_TMPDIR")
+trap "/bin/rm -rf \"$REPACK_TMPDIR\"" QUIT INT EXIT
+
+message() {
+ echo
+ echo "-- -- $1"
+ echo
+ }
+
+message "Repackaging $UPSTREAM_TARBALLZZ"
+
+UPSTREAM_ROOTFOLDER="${REPACK_TMPDIR}/unpacked"
+mkdir "${UPSTREAM_ROOTFOLDER}"
+tar -C "${UPSTREAM_ROOTFOLDER}" -xf "${UPSTREAM_TARBALLZZ}" || unzip -d "${UPSTREAM_ROOTFOLDER}" "${UPSTREAM_TARBALLZZ}"
+if [ `ls -1 "${UPSTREAM_ROOTFOLDER}" | wc -l` -eq 1 ]; then
+ UPSTREAM_ROOTFOLDER="${UPSTREAM_ROOTFOLDER}/`ls -1 "${UPSTREAM_ROOTFOLDER}"`"
+fi
+
+DEBIAN_ROOTFOLDER="${REPACK_TMPDIR}/${DEBIAN_ROOTFOLDERNAME}"
+## repack
+####set -f
+REPACK_WORKING_FOLDER=$(pwd)
+cd "${UPSTREAM_ROOTFOLDER}"
+
+####. "${REPACK_WORKING_FOLDER}/debian/repack.local"
+## wipe out
+rm --verbose --force -- guavapage/guava.jpg
+rm --verbose --force -- guavapage/guava_light.jpg
+rm --verbose --force -- guavapage/guava.ps
+rm --verbose --force -- htm/chap*.html
+rmdir --verbose --ignore-fail-on-non-empty -- guavapage
+rmdir --verbose --ignore-fail-on-non-empty -- htm
+rm --verbose --force -- src/leon/doc/leon_guava_manual.pdf
+## mimic autoreconf clean up
+rm --verbose --force --recursive -- src/leon/autom4te.cache
+rm --verbose --force -- src/leon/src/leon_config.h.in
+rm --verbose --force -- src/leon/src/leon_config.h
+rm --verbose --force -- src/leon/install-sh
+rm --verbose --force -- src/leon/missing
+rm --verbose --force -- src/leon/aclocal.m4
+rm --verbose --force -- src/leon/config.guess
+rm --verbose --force -- src/leon/config.sub
+rm --verbose --force -- src/leon/configure
+## clean up
+rm --verbose --force -- doc/chap*.txt
+rm --verbose --force -- doc/chap*.html
+####rm --verbose --force -- doc/chooser.html
+rm --verbose --force -- doc/guava.{tex,aux,brf,toc,log,bbl,blg,ind,idx,ilg}
+rm --verbose --force -- doc/guava.pnr
+rm --verbose --force -- doc/manual.six
+rm --verbose --force -- doc/manual.pdf
+####rm --verbose --force -- doc/lefttoc.css
+####rm --verbose --force -- doc/manual.{css,js}
+####rm --verbose --force -- doc/nocolorprompt.css
+####rm --verbose --force -- doc/ragged.css
+####rm --verbose --force -- doc/rainbow.js
+####rm --verbose --force -- doc/times.css
+####rm --verbose --force -- doc/toggless.{css,js}
+#:
+
+cd ${REPACK_WORKING_FOLDER}
+set +f
+## end
+####if [ -n "${DEBIAN_ENCAPSULATEDFOLDERNAME}" ]; then
+#### mkdir "${DEBIAN_ROOTFOLDER}"
+#### mv "${UPSTREAM_ROOTFOLDER}" "${DEBIAN_ROOTFOLDER}/${DEBIAN_ENCAPSULATEDFOLDERNAME}"
+####else
+ mv "${UPSTREAM_ROOTFOLDER}" "${DEBIAN_ROOTFOLDER}"
+####fi
+
+REPACK_TARBALL="${REPACK_TMPDIR}/repacked.tar"
+REPACK_TARBALLXZ="${REPACK_TARBALL}.xz"
+( cd "${REPACK_TMPDIR}" && \
+ find -L "${DEBIAN_ROOTFOLDERNAME}" -xdev -type f -print | sort | \
+ tar -T- --owner=root --group=root --mode=a+rX --create --file "${REPACK_TARBALL}" \
+ )
+xz -9e < "${REPACK_TARBALL}" > "${REPACK_TARBALLXZ}"
+mv "${REPACK_TARBALLXZ}" "${DEBIAN_TARBALLXZ}"
+
+message "Testing ${DEBIAN_TARBALLXZ}"
+
+xz --verbose --test "${DEBIAN_TARBALLXZ}"
+
+message "Printing information about ${DEBIAN_TARBALLXZ}"
+
+xz --verbose --list "${DEBIAN_TARBALLXZ}"
+
+message "Quitting"
+
+##
+## eos
diff --git a/debian/rules b/debian/rules
index 1a4149d..b60ca46 100755
--- a/debian/rules
+++ b/debian/rules
@@ -1,13 +1,28 @@
#!/usr/bin/make -f
-include /usr/share/cdbs/1/rules/debhelper.mk
-include /usr/share/cdbs/1/class/makefile.mk
-include /usr/share/cdbs/1/rules/patchsys-quilt.mk
+CGAP=/usr/bin/gap
-debian/stamp-makefile-build: configure-guava
+DEB_BUILD_GNU_TYPE ?= $(shell dpkg-architecture -qDEB_BUILD_GNU_TYPE)
+DEB_BUILD_GAP_INFO_ARCH ?= $(shell echo 'Print(GAPInfo.Architecture);' | $(CGAP) -A -q -T)
-configure-guava:
+default:
+ @uscan --no-conf --dehs --report || true
+
+%:
+ dh $@
+
+override_dh_auto_configure:
./configure /usr/lib/gap
-DEB_MAKE_CLEAN_TARGET = distclean
-DEB_DH_LINK_ARGS += /usr/lib/gap/pkg/guava/bin /usr/share/gap/pkg/guava/bin
+override_dh_link:
+ dh_link -p gap-guava \
+ /usr/lib/gap/pkg/guava/bin /usr/share/gap/pkg/guava/bin \
+ /usr/share/gap/pkg/guava/doc /usr/share/doc/gap-guava/doc
+ dh_link -p gap-guava-bin \
+ /usr/lib/$(DEB_BUILD_GNU_TYPE)/gap/pkg/guava/bin /usr/lib/gap/pkg/guava/bin/$(DEB_BUILD_GAP_INFO_ARCH)
+
+override_dh_installchangelogs:
+ dh_installchangelogs --keep CHANGES.guava
+
+get-orig-source:
+ uscan --no-conf --download-current-version --verbose
diff --git a/debian/source/format b/debian/source/format
new file mode 100644
index 0000000..163aaf8
--- /dev/null
+++ b/debian/source/format
@@ -0,0 +1 @@
+3.0 (quilt)
diff --git a/debian/source/lintian-overrides b/debian/source/lintian-overrides
new file mode 100644
index 0000000..8b06cb1
--- /dev/null
+++ b/debian/source/lintian-overrides
@@ -0,0 +1 @@
+debian-watch-may-check-gpg-signature
diff --git a/debian/source/options b/debian/source/options
new file mode 100644
index 0000000..22a4de9
--- /dev/null
+++ b/debian/source/options
@@ -0,0 +1,2 @@
+compression = xz
+compression-level = 9
diff --git a/debian/watch b/debian/watch
new file mode 100644
index 0000000..8173a3e
--- /dev/null
+++ b/debian/watch
@@ -0,0 +1,4 @@
+version=3
+opts=dversionmangle=s/\+ds// \
+ftp://ftp.gap-system.org/pub/gap/gap4/tar.bz2/packages/guava-?([\d\.]+)\.tar\.bz2 \
+debian bash debian/repack
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/debian-science/packages/gap-guava.git
More information about the debian-science-commits
mailing list