summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMichael Sterrett <mr_bones_@gentoo.org>2011-02-11 03:01:06 +0000
committerMichael Sterrett <mr_bones_@gentoo.org>2011-02-11 03:01:06 +0000
commit956b0d04ee957719ce512081480596acf60f417f (patch)
treed10261fa5c7a6986fe14886ced35af87f26a8344
parentRemove old (diff)
downloadgentoo-2-956b0d04ee957719ce512081480596acf60f417f.tar.gz
gentoo-2-956b0d04ee957719ce512081480596acf60f417f.tar.bz2
gentoo-2-956b0d04ee957719ce512081480596acf60f417f.zip
add patches from Vitaly Minko for better user experience (bug #351672)
(Portage version: 2.1.9.25/cvs/Linux i686)
-rw-r--r--games-arcade/xrick/ChangeLog9
-rw-r--r--games-arcade/xrick/files/xrick-021212-exit.patch23
-rw-r--r--games-arcade/xrick/files/xrick-021212-fullscreen.patch21
-rw-r--r--games-arcade/xrick/xrick-021212-r1.ebuild5
4 files changed, 54 insertions, 4 deletions
diff --git a/games-arcade/xrick/ChangeLog b/games-arcade/xrick/ChangeLog
index f0ebf9057ee0..1308cd02a0d7 100644
--- a/games-arcade/xrick/ChangeLog
+++ b/games-arcade/xrick/ChangeLog
@@ -1,6 +1,11 @@
# ChangeLog for games-arcade/xrick
-# Copyright 1999-2010 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/games-arcade/xrick/ChangeLog,v 1.13 2010/09/20 15:50:01 mr_bones_ Exp $
+# Copyright 1999-2011 Gentoo Foundation; Distributed under the GPL v2
+# $Header: /var/cvsroot/gentoo-x86/games-arcade/xrick/ChangeLog,v 1.14 2011/02/11 03:01:06 mr_bones_ Exp $
+
+ 11 Feb 2011; Michael Sterrett <mr_bones_@gentoo.org>
+ xrick-021212-r1.ebuild, +files/xrick-021212-exit.patch,
+ +files/xrick-021212-fullscreen.patch:
+ add patches from Vitaly Minko for better user experience (bug #351672)
20 Sep 2010; Michael Sterrett <mr_bones_@gentoo.org>
xrick-021212-r1.ebuild:
diff --git a/games-arcade/xrick/files/xrick-021212-exit.patch b/games-arcade/xrick/files/xrick-021212-exit.patch
new file mode 100644
index 000000000000..4486a969b346
--- /dev/null
+++ b/games-arcade/xrick/files/xrick-021212-exit.patch
@@ -0,0 +1,23 @@
+diff -ur xrick-021212/src/sysjoy.c xrick-021212.patched/src/sysjoy.c
+--- xrick-021212/src/sysjoy.c 2010-10-23 00:33:33.000000000 +0400
++++ xrick-021212.patched/src/sysjoy.c 2010-10-23 00:42:25.000000000 +0400
+@@ -56,6 +56,7 @@
+ {
+ if (j)
+ SDL_JoystickClose(j);
++ j = NULL;
+ }
+
+ #endif /* ENABLE_JOYSTICK */
+diff -ur xrick-021212/src/xrick.c xrick-021212.patched/src/xrick.c
+--- xrick-021212/src/xrick.c 2010-10-23 00:33:33.000000000 +0400
++++ xrick-021212.patched/src/xrick.c 2010-10-23 00:40:47.000000000 +0400
+@@ -29,7 +29,7 @@
+ data_setpath("/usr/games/lib/xrick/data.zip");
+ game_run();
+ data_closepath();
+- sys_shutdown();
++ /* sys_shutdown is called via atexit */
+ return 0;
+ }
+
diff --git a/games-arcade/xrick/files/xrick-021212-fullscreen.patch b/games-arcade/xrick/files/xrick-021212-fullscreen.patch
new file mode 100644
index 000000000000..97271a33a28e
--- /dev/null
+++ b/games-arcade/xrick/files/xrick-021212-fullscreen.patch
@@ -0,0 +1,21 @@
+diff -ur xrick-021212/src/sysvid.c xrick-021212.patched/src/sysvid.c
+--- xrick-021212/src/sysvid.c 2002-12-24 16:33:43.000000000 +0300
++++ xrick-021212.patched/src/sysvid.c 2011-01-14 03:03:16.636668016 +0300
+@@ -145,10 +145,14 @@
+ IFDEBUG_VIDEO(sys_printf("xrick/video: SDL says, use these modes:\n"););
+ for (i = 0; modes[i]; i++) {
+ IFDEBUG_VIDEO(sys_printf(" %dx%d\n", modes[i]->w, modes[i]->h););
+- if (modes[i]->w <= modes[mode]->w && modes[i]->w >= SYSVID_WIDTH &&
+- modes[i]->h * SYSVID_WIDTH >= modes[i]->w * SYSVID_HEIGHT) {
++ if ((!fszoom && modes[i]->w <= modes[mode] &&
++ modes[i]->w >= SYSVID_WIDTH) ||
++ (fszoom && modes[i]->w > modes[mode]->w)) {
+ mode = i;
+- fszoom = modes[mode]->w / SYSVID_WIDTH;
++ if (modes[i]->h * SYSVID_WIDTH >= modes[i]->w * SYSVID_HEIGHT)
++ fszoom = modes[mode]->w / SYSVID_WIDTH;
++ else
++ fszoom = modes[mode]->h / SYSVID_HEIGHT;
+ }
+ }
+ if (fszoom != 0) {
diff --git a/games-arcade/xrick/xrick-021212-r1.ebuild b/games-arcade/xrick/xrick-021212-r1.ebuild
index 3571a4fdf740..c7ee9585bafe 100644
--- a/games-arcade/xrick/xrick-021212-r1.ebuild
+++ b/games-arcade/xrick/xrick-021212-r1.ebuild
@@ -1,6 +1,6 @@
-# Copyright 1999-2010 Gentoo Foundation
+# Copyright 1999-2011 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/games-arcade/xrick/xrick-021212-r1.ebuild,v 1.14 2010/09/20 15:50:01 mr_bones_ Exp $
+# $Header: /var/cvsroot/gentoo-x86/games-arcade/xrick/xrick-021212-r1.ebuild,v 1.15 2011/02/11 03:01:06 mr_bones_ Exp $
EAPI=2
inherit eutils games
@@ -24,6 +24,7 @@ src_unpack() {
}
src_prepare() {
+ epatch "${FILESDIR}"/${P}*.patch
sed -i \
-e "/^run from/d" \
-e "/data.zip/ s:the directory where xrick is:$(games_get_libdir)/${PN}.:" \