[fenix] 35/127: Make fxc and fxi return proper values to signal errors in Linux. Added patch and unpatch targets to debian/rules for developers comfort.
Peter Pentchev
roam at ringlet.net
Thu Dec 17 14:39:33 UTC 2015
This is an automated email from the git hooks/post-receive script.
roam-guest pushed a commit to branch master
in repository fenix.
commit f2768bad7e5bdb83e7eb5ba6b872c88e6d069bd6
Author: Miriam Ruiz <miriam at debian.org>
Date: Tue Jul 31 14:25:12 2007 +0000
Make fxc and fxi return proper values to signal errors in Linux.
Added patch and unpatch targets to debian/rules for developers comfort.
---
debian/changelog | 1 +
debian/patches/fxc_return_values.patch | 38 ++++++++++++++++++++++++++++++++++
debian/patches/fxi_return_values.patch | 21 +++++++++++++++++++
debian/patches/series | 2 ++
debian/rules | 6 ++++++
5 files changed, 68 insertions(+)
diff --git a/debian/changelog b/debian/changelog
index e0c3602..2d65769 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -6,6 +6,7 @@ fenix (0.92a.dfsg1-1) UNRELEASED; urgency=low
* Added support for reading programs from stdin in the interpreter.
* Added fenix binary to compile and execute a game on the fly.
* Put everything in a single package.
+ * Make fxc and fxi return proper values to signal errors in Linux.
[ Cyril Brulebois ]
* Added XS-Vcs-Svn and XS-Vcs-Browser fields in the control file.
diff --git a/debian/patches/fxc_return_values.patch b/debian/patches/fxc_return_values.patch
new file mode 100644
index 0000000..6b97a20
--- /dev/null
+++ b/debian/patches/fxc_return_values.patch
@@ -0,0 +1,38 @@
+diff -ruN fenix-0.92a.dfsg1.orig/fxc/src/main.c fenix-0.92a.dfsg1/fxc/src/main.c
+--- fenix-0.92a.dfsg1.orig/fxc/src/main.c 2007-07-31 13:59:25.000000000 +0000
++++ fenix-0.92a.dfsg1/fxc/src/main.c 2007-07-31 14:02:05.000000000 +0000
+@@ -260,7 +260,7 @@
+ {
+ fprintf (stderr, MSG_TOO_MANY_FILES) ;
+ fprintf (stderr, "\n") ;
+- return 0 ;
++ return -2 ;
+ }
+ filename = argv[i] ;
+ }
+@@ -271,7 +271,7 @@
+ fprintf (stderr, MSG_USING, argv[0]) ;
+ fprintf (stderr, MSG_OPTION_D) ;
+ fprintf (stderr, MSG_OPTIONS) ;
+- return 0 ;
++ return -1 ;
+ }
+
+ if (*outname)
+@@ -330,7 +330,7 @@
+ if (!file_exists(stubname))
+ {
+ compile_error (_("Can't open stub file %s"), stubname);
+- return -1;
++ return -3;
+ }
+ }
+ }
+@@ -355,6 +355,6 @@
+ /* destroy error messages list */
+ err_destroyErrorTable() ;
+
+- return 1 ;
++ return 0 ;
+ }
+
diff --git a/debian/patches/fxi_return_values.patch b/debian/patches/fxi_return_values.patch
new file mode 100644
index 0000000..63cfa00
--- /dev/null
+++ b/debian/patches/fxi_return_values.patch
@@ -0,0 +1,21 @@
+diff -ruN fenix-0.92a.dfsg1.orig/fxi/src/main.c fenix-0.92a.dfsg1/fxi/src/main.c
+--- fenix-0.92a.dfsg1.orig/fxi/src/main.c 2007-07-31 13:59:25.000000000 +0000
++++ fenix-0.92a.dfsg1/fxi/src/main.c 2007-07-31 14:03:36.000000000 +0000
+@@ -302,7 +302,7 @@
+ "agreement (GNU GPL version 2 or later).\n"
+ "See COPYING for license details.\n"),
+ argv[0]) ;
+- return 0 ;
++ return -1 ;
+ }
+ }
+
+@@ -340,7 +340,7 @@
+ if (!dcb_load(dcbname))
+ {
+ gr_error (_("'%s': file does not exist or it's not a DCB version %d file or compatible"), filename, DCB_VERSION >> 8) ;
+- return -1 ;
++ return -2 ;
+ }
+ }
+ }
diff --git a/debian/patches/series b/debian/patches/series
index 093fa73..ceaffe3 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -8,4 +8,6 @@ fxc_nosdlinit.patch
common_stdfiles.patch
fxc_output.patch
fxi_input.patch
+fxc_return_values.patch
+fxi_return_values.patch
0.92a_to_cvs-20070713.1513.patch
diff --git a/debian/rules b/debian/rules
index 184587a..1f7874d 100755
--- a/debian/rules
+++ b/debian/rules
@@ -18,6 +18,12 @@ endif
CFLAGS += -DUSE_GETTEXT
+patch:
+ QUILT_PATCHES=debian/patches quilt push -a || test $$? = 2
+
+unpatch:
+ QUILT_PATCHES=debian/patches quilt pop -a -f || test $$? = 2
+
config.status: configure
dh_testdir
$(MAKE) -f /usr/share/quilt/quilt.make patch
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-games/fenix.git
More information about the Pkg-games-commits
mailing list