Package: xjump
Severity: wishlist
Tags: patch

Hi,

The dpatch patch management system has been deprecated for some time. The
Lintian currently flags use of dpatch packages as an error. The new 3.0
packaging format is an improved version which, among other things, contains
patch management built-in. For more information, see:

    http://wiki.debian.org/Projects/DebSrc3.0

I had some free time; see attached patch to migrate to new package
format. Note that all files in debian/patches/* are canocalized to
*.patch.

Let me know if there is anything that needs adjusting or if it is ok
to upload this version in a NMU in case you are working on other
issues needing attention.

Thanks,
Jari

>From b2b7780f1bfe52eff28abddb19e793161cd53a87 Mon Sep 17 00:00:00 2001
From: Jari Aalto <jari.aa...@cante.net>
Date: Thu, 12 Apr 2012 12:10:47 +0300
Subject: [PATCH] format-3.0
Organization: Private
Content-Type: text/plain; charset="utf-8"
Content-Transfer-Encoding: 8bit

Signed-off-by: Jari Aalto <jari.aa...@cante.net>
---
 debian/changelog                                   |   14 ++++++++
 debian/compat                                      |    2 +-
 debian/control                                     |    8 ++---
 debian/copyright                                   |    2 +-
 debian/patches/00list                              |    5 ---
 debian/patches/01_overflow.dpatch                  |   33 -----------------
 debian/patches/01_overflow.patch                   |   16 +++++++++
 debian/patches/02_fix_repeat.dpatch                |   38 --------------------
 debian/patches/02_fix_repeat.patch                 |   19 ++++++++++
 ...ce_warnings.dpatch => 03_source_warnings.patch} |   21 ++---------
 ...ags.dpatch => 04_makefile_respect_cflags.patch} |   21 ++---------
 ...5_unneded_deps.dpatch => 05_unneded_deps.patch} |    8 ++---
 debian/patches/series                              |    5 +++
 debian/postinst                                    |    4 ++-
 debian/postrm                                      |    4 ++-
 debian/prerm                                       |    5 ++-
 debian/rules                                       |   13 ++++---
 debian/source/format                               |    1 +
 18 files changed, 86 insertions(+), 133 deletions(-)
 delete mode 100644 debian/patches/00list
 delete mode 100644 debian/patches/01_overflow.dpatch
 create mode 100644 debian/patches/01_overflow.patch
 delete mode 100644 debian/patches/02_fix_repeat.dpatch
 create mode 100644 debian/patches/02_fix_repeat.patch
 rename debian/patches/{03_source_warnings.dpatch => 03_source_warnings.patch} (72%)
 rename debian/patches/{04_makefile_respect_cflags.dpatch => 04_makefile_respect_cflags.patch} (70%)
 rename debian/patches/{05_unneded_deps.dpatch => 05_unneded_deps.patch} (66%)
 create mode 100644 debian/patches/series
 mode change 100644 => 100755 debian/postinst
 mode change 100644 => 100755 debian/postrm
 mode change 100644 => 100755 debian/prerm
 create mode 100644 debian/source/format

diff --git a/debian/changelog b/debian/changelog
index e22abaa..86ac818 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,3 +1,17 @@
+xjump (2.7.5-6.1) unstable; urgency=low
+
+  * Non-maintainer upload.
+  * Remove deprecated dpatch and upgrade to packaging format "3.0 quilt".
+  * Update to Standards-Version to 3.9.3 and debhelper to 9.
+  * Add build-arch and build-indep targets to rules file.
+  * Fix dh_desktop-is-deprecated (Lintian).
+  * Fix description-synopsis-starts-with-article (Lintian).
+  * Fix copyright-refers-to-symlink-license (Lintian).
+  * Fix maintainer-script-without-set-e *{rm,inst} (Lintian).
+  * Fix desktop-entry-contains-encoding-key (Lintian).
+
+ -- Jari Aalto <jari.aa...@cante.net>  Thu, 12 Apr 2012 12:07:54 +0300
+
 xjump (2.7.5-6) unstable; urgency=low
 
   * Build-depend on x11proto-core-dev instead of deprecated x-dev,
diff --git a/debian/compat b/debian/compat
index 7f8f011..ec63514 100644
--- a/debian/compat
+++ b/debian/compat
@@ -1 +1 @@
-7
+9
diff --git a/debian/control b/debian/control
index 504109a..4a09a0a 100644
--- a/debian/control
+++ b/debian/control
@@ -2,13 +2,13 @@ Source: xjump
 Section: games
 Priority: optional
 Maintainer: Samuel Mimram <smim...@debian.org>
-Build-Depends: debhelper (>= 7.0.0), dpatch, libx11-dev, libxpm-dev, libxt-dev, x11proto-core-dev, libxaw7-dev
-Standards-Version: 3.8.0
+Build-Depends: debhelper (>= 9), libx11-dev, libxpm-dev, libxt-dev, x11proto-core-dev, libxaw7-dev
+Standards-Version: 3.9.3
 
 Package: xjump
 Architecture: any
-Depends: ${shlibs:Depends}
-Description: A jumping game for X
+Depends: ${misc:Depends}, ${shlibs:Depends}
+Description: jumping game for X
  The epitome of addictive and pointless games, xjump is simply a game
  where one jumps from one platform to a higher platform, over and over. If
  you can't keep up with the pace of jumping, the floor swallows you up and
diff --git a/debian/copyright b/debian/copyright
index 96b5556..a3cae6a 100644
--- a/debian/copyright
+++ b/debian/copyright
@@ -10,4 +10,4 @@ Software Foundation; either version 2, or (at your option) any later
 version without ANY WARRANTIES.
 
 For the full terms of the GPL on a Debian/GNU system, please refer to
-/usr/share/common-licenses/GPL.
+/usr/share/common-licenses/GPL-2.
diff --git a/debian/patches/00list b/debian/patches/00list
deleted file mode 100644
index 6c61e14..0000000
--- a/debian/patches/00list
+++ /dev/null
@@ -1,5 +0,0 @@
-01_overflow
-02_fix_repeat
-03_source_warnings
-04_makefile_respect_cflags
-05_unneded_deps
diff --git a/debian/patches/01_overflow.dpatch b/debian/patches/01_overflow.dpatch
deleted file mode 100644
index b6eece7..0000000
--- a/debian/patches/01_overflow.dpatch
+++ /dev/null
@@ -1,33 +0,0 @@
-#! /bin/sh -e
-## 01_overflow.dpatch by Joshua Kwan <jo...@triplehelix.org>
-##
-## All lines beginning with `## DP:' are a description of the patch.
-## DP: fix possible buffer overflow in highscore recording
-
-if [ $# -ne 1 ]; then
-    echo >&2 "`basename $0`: script expects -patch|-unpatch as argument"
-    exit 1
-fi
-case "$1" in
-    -patch) patch -f --no-backup-if-mismatch -p1 < $0;;
-    -unpatch) patch -f --no-backup-if-mismatch -R -p1 < $0;;
-    *)
-        echo >&2 "`basename $0`: script expects -patch|-unpatch as argument"
-        exit 1;;
-esac
-
-exit 0
-
---- a/record.c	1997-11-07 23:41:40.000000000 -0800
-+++ b/record.c	2003-05-26 16:18:23.000000000 -0700
-@@ -122,8 +122,8 @@
-     if( i > 0 )
-       name[i] = '\0';
-     else
--      strcpy( name,pw->pw_name );
--
-+      /* Prevent any sort of overflow */
-+      sprintf (name, "%.31s", pw->pw_name);
-   }
- 
-   return name;
diff --git a/debian/patches/01_overflow.patch b/debian/patches/01_overflow.patch
new file mode 100644
index 0000000..a8ec42b
--- /dev/null
+++ b/debian/patches/01_overflow.patch
@@ -0,0 +1,16 @@
+From: Joshua Kwan <jo...@triplehelix.org>
+Subject: fix possible buffer overflow in highscore recording
+
+--- a/record.c	1997-11-07 23:41:40.000000000 -0800
++++ b/record.c	2003-05-26 16:18:23.000000000 -0700
+@@ -122,8 +122,8 @@
+     if( i > 0 )
+       name[i] = '\0';
+     else
+-      strcpy( name,pw->pw_name );
+-
++      /* Prevent any sort of overflow */
++      sprintf (name, "%.31s", pw->pw_name);
+   }
+ 
+   return name;
diff --git a/debian/patches/02_fix_repeat.dpatch b/debian/patches/02_fix_repeat.dpatch
deleted file mode 100644
index 9b6184c..0000000
--- a/debian/patches/02_fix_repeat.dpatch
+++ /dev/null
@@ -1,38 +0,0 @@
-#! /bin/sh -e
-## 02_fix_repeat.dpatch by Joshua Kwan <jo...@triplehelix.org>
-##
-## All lines beginning with `## DP:' are a description of the patch.
-## DP: fix autorepeat. repeat_off overall doesn't really make a 
-## difference at all. kept simplified due to possible further fixing by 
-## upstream.
-
-if [ $# -ne 1 ]; then
-    echo >&2 "`basename $0`: script expects -patch|-unpatch as argument"
-    exit 1
-fi
-case "$1" in
-    -patch) patch -f --no-backup-if-mismatch -p1 < $0;;
-    -unpatch) patch -f --no-backup-if-mismatch -R -p1 < $0;;
-    *)
-        echo >&2 "`basename $0`: script expects -patch|-unpatch as argument"
-        exit 1;;
-esac
-
-exit 0
-
---- a/main.c	1999-08-19 20:47:44.000000000 -0700
-+++ b/main.c	2003-05-26 17:17:39.000000000 -0700
-@@ -102,11 +103,13 @@
- 
- static void repeat_off( void )
- {
-+#if 0
-   if( Repeat_mode ){
-     XGetKeyboardControl( Disp,&Keyboard );
-     XAutoRepeatOff( Disp );
-     Repeat_mode = 0;
-   }
-+#endif
- }
- 
- 
diff --git a/debian/patches/02_fix_repeat.patch b/debian/patches/02_fix_repeat.patch
new file mode 100644
index 0000000..ecb2a33
--- /dev/null
+++ b/debian/patches/02_fix_repeat.patch
@@ -0,0 +1,19 @@
+From: Joshua Kwan <jo...@triplehelix.org>
+Subject: fix autorepeat. repeat_off overall doesn't really make a 
+
+--- a/main.c	1999-08-19 20:47:44.000000000 -0700
++++ b/main.c	2003-05-26 17:17:39.000000000 -0700
+@@ -102,11 +103,13 @@
+ 
+ static void repeat_off( void )
+ {
++#if 0
+   if( Repeat_mode ){
+     XGetKeyboardControl( Disp,&Keyboard );
+     XAutoRepeatOff( Disp );
+     Repeat_mode = 0;
+   }
++#endif
+ }
+ 
+ 
diff --git a/debian/patches/03_source_warnings.dpatch b/debian/patches/03_source_warnings.patch
similarity index 72%
rename from debian/patches/03_source_warnings.dpatch
rename to debian/patches/03_source_warnings.patch
index c917245..2951c96 100644
--- a/debian/patches/03_source_warnings.dpatch
+++ b/debian/patches/03_source_warnings.patch
@@ -1,22 +1,5 @@
-#! /bin/sh -e
-## 03_source_warnings.dpatch by Joshua Kwan <jo...@triplehelix.org>
-##
-## All lines beginning with `## DP:' are a description of the patch.
-## DP: make it work with ircd-hybrid package out of the box, other settings
-
-if [ $# -ne 1 ]; then
-    echo >&2 "`basename $0`: script expects -patch|-unpatch as argument"
-    exit 1
-fi
-case "$1" in
-    -patch) patch -f --no-backup-if-mismatch -p1 < $0;;
-    -unpatch) patch -f --no-backup-if-mismatch -R -p1 < $0;;
-    *)
-        echo >&2 "`basename $0`: script expects -patch|-unpatch as argument"
-        exit 1;;
-esac
-
-exit 0
+From: Joshua Kwan <jo...@triplehelix.org>
+Subject: make it work with ircd-hybrid package out of the box, other settings
 
 --- a/main.c	1999-08-19 20:47:44.000000000 -0700
 +++ b/main.c	2003-05-26 17:03:55.000000000 -0700
diff --git a/debian/patches/04_makefile_respect_cflags.dpatch b/debian/patches/04_makefile_respect_cflags.patch
similarity index 70%
rename from debian/patches/04_makefile_respect_cflags.dpatch
rename to debian/patches/04_makefile_respect_cflags.patch
index aed11ce..d953c0e 100644
--- a/debian/patches/04_makefile_respect_cflags.dpatch
+++ b/debian/patches/04_makefile_respect_cflags.patch
@@ -1,22 +1,5 @@
-#! /bin/sh -e
-## 04_makefile_respect_cflags.dpatch by Joshua Kwan <jo...@triplehelix.org>
-##
-## All lines beginning with `## DP:' are a description of the patch.
-## DP: make Makefile respect $(CFLAGS)
-
-if [ $# -ne 1 ]; then
-    echo >&2 "`basename $0`: script expects -patch|-unpatch as argument"
-    exit 1
-fi
-case "$1" in
-    -patch) patch -f --no-backup-if-mismatch -p1 < $0;;
-    -unpatch) patch -f --no-backup-if-mismatch -R -p1 < $0;;
-    *)
-        echo >&2 "`basename $0`: script expects -patch|-unpatch as argument"
-        exit 1;;
-esac
-
-exit 0
+From: Joshua Kwan <jo...@triplehelix.org>
+Subject: make Makefile respect $(CFLAGS)
 
 --- a/Makefile	2003-05-26 16:23:29.000000000 -0700
 +++ b/Makefile	2003-05-26 16:58:24.000000000 -0700
diff --git a/debian/patches/05_unneded_deps.dpatch b/debian/patches/05_unneded_deps.patch
similarity index 66%
rename from debian/patches/05_unneded_deps.dpatch
rename to debian/patches/05_unneded_deps.patch
index d71b399..20c9bb2 100644
--- a/debian/patches/05_unneded_deps.dpatch
+++ b/debian/patches/05_unneded_deps.patch
@@ -1,10 +1,6 @@
-#! /bin/sh /usr/share/dpatch/dpatch-run
-## 05_unneded_deps.dpatch by Samuel Mimram <smim...@debian.org>
-##
-## All lines beginning with `## DP:' are a description of the patch.
-## DP: Remove unneeded dependencies on Xmu and Xext.
+From: Samuel Mimram <smim...@debian.org>
+Subject: Remove unneeded dependencies on Xmu and Xext.
 
-@DPATCH@
 diff -urNad xjump-2.7.5~/Makefile xjump-2.7.5/Makefile
 --- a/Makefile	2006-09-28 20:10:56.000000000 +0000
 +++ b/Makefile	2006-09-28 20:11:08.000000000 +0000
diff --git a/debian/patches/series b/debian/patches/series
new file mode 100644
index 0000000..06deab9
--- /dev/null
+++ b/debian/patches/series
@@ -0,0 +1,5 @@
+01_overflow.patch
+02_fix_repeat.patch
+03_source_warnings.patch
+04_makefile_respect_cflags.patch
+05_unneded_deps.patch
diff --git a/debian/postinst b/debian/postinst
old mode 100644
new mode 100755
index f1c7f25..3fd6af5
--- a/debian/postinst
+++ b/debian/postinst
@@ -1,4 +1,6 @@
-#!/bin/sh -e
+#!/bin/sh
+
+set -e
 
 if [ "$1" = configure ]; then
   if test -f /var/lib/games/xjump/record; then
diff --git a/debian/postrm b/debian/postrm
old mode 100644
new mode 100755
index c7925ea..6ed1c21
--- a/debian/postrm
+++ b/debian/postrm
@@ -1,4 +1,6 @@
-#!/bin/sh -e
+#!/bin/sh
+
+set -e
 
 case "$1" in
  purge)
diff --git a/debian/prerm b/debian/prerm
old mode 100644
new mode 100755
index 4647988..1de95c8
--- a/debian/prerm
+++ b/debian/prerm
@@ -1,4 +1,7 @@
-#!/bin/sh -e
+#!/bin/sh
+
+set -e
+
 # Work around having to repackage the source by using a blank prerm
 
 exit 0
diff --git a/debian/rules b/debian/rules
index eef0fc8..5aa3d1c 100755
--- a/debian/rules
+++ b/debian/rules
@@ -1,14 +1,17 @@
 #!/usr/bin/make -f
 # Rewritten debian/rules for xjump by Joshua Kwan
 
-include /usr/share/dpatch/dpatch.make
 
-build: patch
+
+build-arch: build
+build-indep: build
+
+build:
 	dh_testdir
 	make CFLAGS="-O2 -g -Wall"
 	touch build
 
-clean: unpatch
+clean:
 	dh_testroot
 	dh_testdir
 	make clean
@@ -25,6 +28,8 @@ install: build
 	cp debian/themes/* debian/xjump/usr/share/games/xjump/
 	for i in debian/xjump/usr/share/games/xjump/*; do gzip -9 $$i; done
 	cp debian/xjump.desktop debian/xjump/usr/share/applications/
+	# Encoding is by default UTF-8
+	sed -i '/Encoding=/d' debian/xjump/usr/share/applications/xjump.desktop
 
 binary-indep:
 	dh_testdir
@@ -36,7 +41,7 @@ binary-arch: install
 	dh_installman debian/xjump.6
 	dh_installchangelogs
 	dh_installmenu
-	dh_desktop
+#	dh_desktop
 	dh_link
 	dh_strip
 	dh_compress
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)
-- 
1.7.9.5

Reply via email to