r4928 - in packages/trunk/freecol/debian: . patches

Vincent Fourmond fourmond at alioth.debian.org
Fri Dec 14 00:02:22 UTC 2007


Author: fourmond
Date: 2007-12-14 00:02:22 +0000 (Fri, 14 Dec 2007)
New Revision: 4928

Added:
   packages/trunk/freecol/debian/patches/30-language-option.dpatch
Modified:
   packages/trunk/freecol/debian/
   packages/trunk/freecol/debian/changelog
   packages/trunk/freecol/debian/patches/00list
   packages/trunk/freecol/debian/patches/20-freecol-executable.dpatch
Log:
[freecol] committing the long gone -4 release


Property changes on: packages/trunk/freecol/debian
___________________________________________________________________
Name: svn-bp:tagsUrl
   + svn+ssh://svn.debian.org/svn/pkg-games/packages/tags/freecol

Modified: packages/trunk/freecol/debian/changelog
===================================================================
--- packages/trunk/freecol/debian/changelog	2007-12-13 21:33:32 UTC (rev 4927)
+++ packages/trunk/freecol/debian/changelog	2007-12-14 00:02:22 UTC (rev 4928)
@@ -1,8 +1,10 @@
-freecol (0.7.2-4) UNRELEASED; urgency=low
+freecol (0.7.2-4) unstable; urgency=low
 
-  * NOT RELEASED YET
+  * Pull upstream revision 3270 to add a --default-locale option
+  * Used this option to detect when LC_MESSAGES is different from
+    LC_CTYPE (Closes: #450944)
 
- -- Vincent Fourmond <fourmond at debian.org>  Thu, 22 Nov 2007 19:56:08 +0100
+ -- Vincent Fourmond <fourmond at debian.org>  Mon, 26 Nov 2007 20:25:41 +0100
 
 freecol (0.7.2-3) unstable; urgency=low
 

Modified: packages/trunk/freecol/debian/patches/00list
===================================================================
--- packages/trunk/freecol/debian/patches/00list	2007-12-13 21:33:32 UTC (rev 4927)
+++ packages/trunk/freecol/debian/patches/00list	2007-12-14 00:02:22 UTC (rev 4928)
@@ -1,4 +1,5 @@
 10-fix-jar-path
 15-fix-jar-manifest
 20-freecol-executable
-25-change-save-dir
\ No newline at end of file
+25-change-save-dir
+30-language-option
\ No newline at end of file

Modified: packages/trunk/freecol/debian/patches/20-freecol-executable.dpatch
===================================================================
--- packages/trunk/freecol/debian/patches/20-freecol-executable.dpatch	2007-12-13 21:33:32 UTC (rev 4927)
+++ packages/trunk/freecol/debian/patches/20-freecol-executable.dpatch	2007-12-14 00:02:22 UTC (rev 4928)
@@ -7,8 +7,8 @@
 @DPATCH@
 diff -urNad freecol-0.7.2~/src/freecol freecol-0.7.2/src/freecol
 --- freecol-0.7.2~/src/freecol	1970-01-01 01:00:00.000000000 +0100
-+++ freecol-0.7.2/src/freecol	2007-10-26 20:48:10.000000000 +0200
-@@ -0,0 +1,16 @@
++++ freecol-0.7.2/src/freecol	2007-11-26 20:47:51.000000000 +0100
+@@ -0,0 +1,22 @@
 +#!/bin/sh
 +
 +# Script 'greatly inspired' from the one of jabref
@@ -22,6 +22,12 @@
 +JAVA=${JAVA_HOME}/jre/bin/java
 +fi
 +
++# We test if LC_MESSAGES is different from LC_CTYPE, if that is the case,
++# 
++if [ "$LC_CTYPE" != "$LC_MESSAGES" -a "$LC_MESSAGES" ]; then
++    lang_argument="--default-locale=$LC_MESSAGES"
++fi
++
 +export JAVA=${JAVA:=java}
 +exec $JAVA -Xmx128M -jar /usr/share/java/freecol.jar --freecol-data \
-+    /usr/share/games/freecol "$@"
++    /usr/share/games/freecol $lang_argument "$@"

Added: packages/trunk/freecol/debian/patches/30-language-option.dpatch
===================================================================
--- packages/trunk/freecol/debian/patches/30-language-option.dpatch	                        (rev 0)
+++ packages/trunk/freecol/debian/patches/30-language-option.dpatch	2007-12-14 00:02:22 UTC (rev 4928)
@@ -0,0 +1,39 @@
+#! /bin/sh /usr/share/dpatch/dpatch-run
+## 30-language-option.dpatch by  <fourmond at debian.org>
+##
+## All lines beginning with `## DP:' are a description of the patch.
+## DP: No description.
+
+ at DPATCH@
+diff -urNad freecol-0.7.2~/src/net/sf/freecol/FreeCol.java freecol-0.7.2/src/net/sf/freecol/FreeCol.java
+--- freecol-0.7.2~/src/net/sf/freecol/FreeCol.java	2007-11-26 20:24:01.000000000 +0100
++++ freecol-0.7.2/src/net/sf/freecol/FreeCol.java	2007-11-26 20:24:01.000000000 +0100
+@@ -521,6 +521,19 @@
+                 }
+                 
+                 windowed = true;
++            } else if (args[i].length() > 16 && args[i].substring(0, 16).equals("--default-locale")) {
++                if (args[i].charAt(16) == '=') {
++                    // slightly ugly: strip encoding from LC_MESSAGES
++                    String languageID = args[i].substring(17);
++                    int index = languageID.indexOf('.');
++                    if (index > 0) {
++                        languageID = languageID.substring(0, index);
++                    }
++                    Locale.setDefault(LanguageOption.getLocale(languageID));
++                } else {
++                    printUsage();
++                    System.exit(0);
++                }
+             } else if (args[i].equals("--no-sound")) {
+                 sound = false;
+             } else if (args[i].equals("--no-memory-check")) {
+@@ -655,6 +668,8 @@
+         System.out.println("  runs FreeCol in windowed mode instead of full screen mode");
+         System.out.println("--load-savegame SAVEGAME_FILE");
+         System.out.println("  loads the given savegame.");
++        System.out.println("--default-locale=LANGUAGE[_COUNTRY[_VARIANT]]");
++        System.out.println("  sets the default locale.");
+         System.out.println("--splash[=SPLASH_IMAGE_FILE]");
+         System.out.println("  displays a splash screen while loading the game");
+         System.out.println("--no-sound");


Property changes on: packages/trunk/freecol/debian/patches/30-language-option.dpatch
___________________________________________________________________
Name: svn:executable
   + *




More information about the Pkg-games-commits mailing list