--- komi-1.04.orig/Makefile +++ komi-1.04/Makefile @@ -11,9 +11,9 @@ MANPATH=/usr/local/man/man6/ MIXER=-lSDL_mixer -SDL_LIB=$(shell sdl-config --static-libs) $(MIXER) +SDL_LIB=$(shell sdl-config --libs) $(MIXER) -CFLAGS=-Wall -pedantic -std=c99 -O2 \ +CFLAGS=-Wall -pedantic -std=c99 -g $(OPT) \ $(shell sdl-config --cflags) \ -DDATAPATH=\"$(DATAPATH)\" --- komi-1.04.orig/komi.6 +++ komi-1.04/komi.6 @@ -48,7 +48,6 @@ .TP \fB\-\-nosound\fR -.Sp Disable all sound effects. .TP --- komi-1.04.orig/komi.c +++ komi-1.04/komi.c @@ -242,6 +242,8 @@ { keymap.escape = 0; // So we don't respond to escape pressed in game. mousemap.button = 0; // Likewise for the mouse. + keymap.fire1 = 0; // Neither fire keys are likely to be down from game, + keymap.fire2 = 0; // but could be. manageevents(); @@ -297,6 +299,17 @@ { cleanexit(0); } + + if (keymap.fire1 || keymap.fire2) + { + keymap.fire1 = keymap.fire2 = 0; + SDL_ShowCursor(SDL_DISABLE); + game(); + SDL_ShowCursor(SDL_ENABLE); + setmaintitlebar(); + drawmenu(highlight_start, highlight_quit, highlight_shuffle); + } + if (mousemap.button) { if (abs(mousemap.clickx - STARTBUTTON_X) < start_title.pixelmap->w / 2 && abs(mousemap.clicky - STARTBUTTON_Y) < start_title.pixelmap->h / 2) @@ -420,7 +433,7 @@ SDL_UpdateRect(virtue, 0, 0, 0, 0); updatetitlebar(); - if (lives == 1 && givelastlifewarning && fullscreen) + if (lives == 1 && givelastlifewarning) { playsound(lastlife_sound); givelastlifewarning = 0; @@ -2875,8 +2888,10 @@ if (strlen(directory) + strlen(filename) >= sizeof(fullpath)) // Check for buffer overflow on fullpath { fprintf(stderr, "Fatal error while loading %s:\n", filename); - fprintf(stderr, "Size of directory name (%d chars) plus size of file name (%d chars)\n", strlen(directory), strlen(filename)); - fprintf(stderr, "is too long (over %d chars), and would cause a buffer overflow...\n", sizeof(fullpath) - 1); + fprintf(stderr, "Size of directory name (%u chars) plus size of file name (%u chars)\n", + (unsigned int) strlen(directory), (unsigned int) strlen(filename)); + fprintf(stderr, "is too long (over %u chars), and would cause a buffer overflow...\n", + (unsigned int) (sizeof(fullpath) - 1)); cleanexit(1); } strcpy(fullpath, directory); @@ -3276,8 +3291,10 @@ if (strlen(directory) + strlen(filename) >= sizeof(fullpath)) // Check for buffer overflow on fullpath { fprintf(stderr, "Error while saving %s:\n", filename); - fprintf(stderr, "Size of directory name (%d chars) plus size of file name (%d chars)\n", strlen(directory), strlen(filename)); - fprintf(stderr, "is too long (over %d chars), and would cause a buffer overflow...\n", sizeof(fullpath) - 1); + fprintf(stderr, "Size of directory name (%u chars) plus size of file name (%u chars)\n", + (unsigned int) strlen(directory), (unsigned int) strlen(filename)); + fprintf(stderr, "is too long (over %u chars), and would cause a buffer overflow...\n", + (unsigned int) (sizeof(fullpath) - 1)); return; } strcpy(fullpath, directory); @@ -3625,8 +3642,10 @@ if (strlen(directory) + strlen(filename) >= sizeof(fullpath)) // Check for buffer overflow on fullpath { fprintf(stderr, "Error while saving %s:\n", filename); - fprintf(stderr, "Size of directory name (%d chars) plus size of file name (%d chars)\n", strlen(directory), strlen(filename)); - fprintf(stderr, "is too long (over %d chars), and would cause a buffer overflow...\n", sizeof(fullpath) - 1); + fprintf(stderr, "Size of directory name (%u chars) plus size of file name (%u chars)\n", + (unsigned int) strlen(directory), (unsigned int) strlen(filename)); + fprintf(stderr, "is too long (over %u chars), and would cause a buffer overflow...\n", + (unsigned int) (sizeof(fullpath) - 1)); return; } strcpy(fullpath, directory); @@ -3662,8 +3681,10 @@ if (strlen(directory) + strlen(filename) >= sizeof(fullpath)) // Check for buffer overflow on fullpath { fprintf(stderr, "Error while loading %s:\n", filename); - fprintf(stderr, "Size of directory name (%d chars) plus size of file name (%d chars)\n", strlen(directory), strlen(filename)); - fprintf(stderr, "is too long (over %d chars), and would cause a buffer overflow...\n", sizeof(fullpath) - 1); + fprintf(stderr, "Size of directory name (%u chars) plus size of file name (%u chars)\n", + (unsigned int) strlen(directory), (unsigned int) strlen(filename)); + fprintf(stderr, "is too long (over %u chars), and would cause a buffer overflow...\n", + (unsigned int) (sizeof(fullpath) - 1)); return; } strcpy(fullpath, directory); @@ -3740,8 +3761,10 @@ if (strlen(directory) + strlen(filename) >= sizeof(fullpath)) // Check for buffer overflow on fullpath { fprintf(stderr, "Error while loading %s:\n", filename); - fprintf(stderr, "Size of directory name (%d chars) plus size of file name (%d chars)\n", strlen(directory), strlen(filename)); - fprintf(stderr, "is too long (over %d chars), and would cause a buffer overflow...\n", sizeof(fullpath) - 1); + fprintf(stderr, "Size of directory name (%u chars) plus size of file name (%u chars)\n", + (unsigned int) strlen(directory), (unsigned int) strlen(filename)); + fprintf(stderr, "is too long (over %u chars), and would cause a buffer overflow...\n", + (unsigned int) (sizeof(fullpath) - 1)); return 1; } strcpy(fullpath, directory); --- komi-1.04.orig/sprites.h +++ komi-1.04/sprites.h @@ -146,8 +146,10 @@ if (strlen(directory) + strlen(filename) >= sizeof(fullpath)) // Check for buffer overflow on fullpath { fprintf(stderr, "Fatal error while loading %s:\n", filename); - fprintf(stderr, "Size of directory name (%d chars) plus size of file name (%d chars)\n", strlen(directory), strlen(filename)); - fprintf(stderr, "is too long (over %d chars), and would cause a buffer overflow...\n", sizeof(fullpath) - 1); + fprintf(stderr, "Size of directory name (%u chars) plus size of file name (%u chars)\n", + (unsigned int) strlen(directory), (unsigned int) strlen(filename)); + fprintf(stderr, "is too long (over %u chars), and would cause a buffer overflow...\n", + (unsigned int) (sizeof(fullpath) - 1)); cleanexit(1); } strcpy(fullpath, directory); --- komi-1.04.orig/debian/komi.xpm +++ komi-1.04/debian/komi.xpm @@ -0,0 +1,40 @@ +/* XPM */ +static char * komi_xpm[] = { +"32 32 5 1", +" c None", +". c #000000", +"+ c #339966", +"@ c #33CC66", +"# c #EEEEEE", +" ", +" ", +" ", +" ", +" ...... ", +" ..++++++.. ", +" .+@@@@@@@@+. ", +" .@@@@@@@@@@@@. ", +" .@@...@@@@...@@. ", +" .@.....@@.....@. ", +" .@@.#.#.@@.#.#.@@. ", +" .@@.###.@@.###.@@. ", +" .@@@...@@@@...@@@. ", +" .+@@@@@@@@@@@@@@+. ", +" .@@@@@@@@@@@@@@. ", +" .@@@@@@@@@@@@. ", +" .@+@@@@@@@@@@+@. ", +" .+@@@+@@@@@@+@@@+. ", +" .+@@+@@@+@@+@@@+@@+. ", +" .+@@@+@+@@@@+@+@@@+. ", +" .+@@+@@@@@++@@@@@+@@+. ", +" .+@@@@@+@@@@@@+@@@@@+. ", +" .+@@@@@@@+@@+@@@@@@@+. ", +" .@@@@@@@@@@@@@@@@@@. ", +" .+@@@@@@@@@@@@@@@@+. ", +" .+@@@@@@@@@@@@@@+. ", +" ..+@@@@@@@@@@+.. ", +" ...++++++... ", +" ...... ", +" ", +" ", +" "}; --- komi-1.04.orig/debian/watch +++ komi-1.04/debian/watch @@ -0,0 +1,2 @@ +version=3 +http://sf.net/komi/komi-(.*)\.tar\.gz --- komi-1.04.orig/debian/menu +++ komi-1.04/debian/menu @@ -0,0 +1,3 @@ +?package(komi):needs="X11" section="Games/Action" \ + title="Komi" command="/usr/games/komi" \ + icon="/usr/share/pixmaps/komi.xpm" --- komi-1.04.orig/debian/dirs +++ komi-1.04/debian/dirs @@ -0,0 +1,4 @@ +usr/games +usr/share/games/komi +usr/share/menu +usr/share/pixmaps --- komi-1.04.orig/debian/rules +++ komi-1.04/debian/rules @@ -0,0 +1,71 @@ +#!/usr/bin/make -f + +export DH_VERBOSE=1 + +# These are used for cross-compiling and for saving the configure script +# from having to guess our platform (since we know it already) +DEB_HOST_GNU_TYPE ?= $(shell dpkg-architecture -qDEB_HOST_GNU_TYPE) +DEB_BUILD_GNU_TYPE ?= $(shell dpkg-architecture -qDEB_BUILD_GNU_TYPE) + +ifneq (,$(findstring noopt,$(DEB_BUILD_OPTIONS))) + OPT = -O0 +else + OPT = -O2 +endif + + +build: build-stamp + +build-arch: build-stamp + +# Compile package +build-stamp: + dh_testdir + $(MAKE) DATAPATH=/usr/share/games/komi/ OPT="$(OPT)" + touch build-stamp + +build-indep: + # No architechture independant packages. Nothing to do. + +# Clean up +clean: + dh_testdir + dh_testroot + rm -f build-stamp + + $(MAKE) clean + dh_clean + +# Install binary files into debian/komi +install: build + dh_testdir + dh_testroot + dh_prep + dh_installdirs + + mkdir -p debian/komi + dh_install debian/komi.xpm usr/share/pixmaps + $(MAKE) install BINPATH=$(CURDIR)/debian/komi/usr/games/ DATAPATH=$(CURDIR)/debian/komi/usr/share/games/komi/ MANPATH=$(CURDIR)/debian/komi/usr/share/man/man6/ + +# Build package +binary-arch: build install + dh_testdir + dh_testroot + dh_installchangelogs CHANGELOG.txt + dh_installdocs + dh_installmenu + dh_link + dh_strip + dh_compress + dh_fixperms + dh_installdeb + dh_shlibdeps + dh_gencontrol + dh_md5sums + dh_builddeb + +binary-indep: build-indep + +binary: binary-arch + +.PHONY: build build-arch build-indep clean binary-indep binary-arch binary install --- komi-1.04.orig/debian/compat +++ komi-1.04/debian/compat @@ -0,0 +1 @@ +8 --- komi-1.04.orig/debian/copyright +++ komi-1.04/debian/copyright @@ -0,0 +1,25 @@ +This package was debianized by Steve Kemp on +Sat, 9 Aug 2003 19:35:43 +0100. + +It was downloaded from http://komi.sourceforge.net/ + +Upstream Author: The upstream author for Komi is Allan Crossman + +Copyright (C) 2004 Allan Crossman + +This program 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 program 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 program; if not, write to the Free Software +Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + +The complete text of the GNU General Public License can be found +in /usr/share/common-licenses/GPL-2 file. --- komi-1.04.orig/debian/changelog +++ komi-1.04/debian/changelog @@ -0,0 +1,133 @@ +komi (1.04-5) unstable; urgency=low + + * Fixed problem in Makefile that caused komi to link against many libraries + unnecessarily, and in some cases causes komi to fail to build. Fixes + shlibdeps warnings. (Closes: #655803) + * Debian rules no longer ignores make clean error. Fixes lintian warning. + * Copyright file now refers to GPL-2, rather than symlink GPL. Fixes lintian + pedantic warning. + * Removed unused and outdated debian/komi.6. Continue to use upstream man + page. + * Fixed man page warnings. Fixes lintian warning. + * Fixed several printf format warnings on amd64 and other architectures. + * Description no longer starts with the article, "a". + * Removed unnecessary code from rules, and other misc cosmetic fixes + * Added build-arch and build-indep targets to rules. + * Rules file now respects DEB_BUILD_OPTIONS noopt and includes debugging + symbols for nostrip. + * Rules file now calls dh_prep instead of deprecated dh_clean -k. Fixes + lintian warning. + * Upgrade debhelper requirements and version compatibility to 8 + * Set debian/source/format to 1.0. Fixes lintian info warning. + * Set Standards-Version to 3.9.2 (no changes needed) + * Removed duplicate entries from changelog + + -- Brandon Barnes Wed, 18 Jan 2012 13:54:00 -0800 + +komi (1.04-4) unstable; urgency=low + + * Fixed watch file (Closes: #453575) + * Added pixmap to menu file + * Menu file uses section Games/Action instead of Games/Arcade. + Set Standards-Version to 3.8.0 + * Minor cleanup in control, dirs, and rules files + + -- Brandon Barnes Sat, 5 Jul 2008 10:43:00 -0700 + +komi (1.04-3) unstable; urgency=low + + * New maintainer (Closes: #390824) + * Mouse no longer required to play game from menu (that was silly). + * Now, you get a "last life" warning even when playing in windowed mode. + + -- Brandon Barnes Thu, 15 Feb 2007 23:46:00 -0800 + +komi (1.04-2) unstable; urgency=low + + * QA Upload. + * Set maintainer to Debian QA Group. + * Removed list of uploaders. + * Set Standards-Version to 3.7.2. + + -- Anibal Monsalve Salazar Mon, 23 Oct 2006 18:56:15 +1000 + +komi (1.04-1) unstable; urgency=low + + [ Gonéri Le Bouder ] + * new upstream release + * new watch file + * home site url in description + * compat 5 + + [ Alexander Schmehl ] + * removed WINDOWS.txt from docs + + -- Alexander Schmehl Wed, 29 Mar 2006 22:59:58 +0200 + +komi (1.03-5) unstable; urgency=medium + + * Fix Makefile so the game links to SDL dynamically, rather than + statically. Thanks to Thierry Reding for the diagnosis + patch. + (Closes: #349555) + + -- Steve Kemp Thurs, 22 Jan 2006 14:22:11 +0000 + +komi (1.03-4) unstable; urgency=low + + * Moved the project to the Alioth 'pkg-games' SVN repository. + http://wiki.debian.org/Games/SVN + * Updated the maintainer to the games-devel mailing list. + http://lists.alioth.debian.org/mailman/listinfo/pkg-games-devel + + -- Steve Kemp Sunday, 22 January 2006 10:48:06 +0000 + +komi (1.03-3) unstable; urgency=low + + * Build against libaa1-dev/libaa1 instead of aalib1. + (Closes: #320884) + + -- Steve Kemp Thu, 04 Aug 2005 15:48:55 +0000 + +komi (1.03-2) unstable; urgency=low + + * Updated standards version to 3.6.2 (no changes). + * Removed commented out debhelper lines from debian/rules + * Changed menu entry: + * Install to /usr/share/menu + * Moved to section 'Games/Arcade' + * Capitalise 'komi' + (Closes: #316280) + + -- Steve Kemp Fri, 01 Jul 2005 02:04:57 +0000 + +komi (1.03-1) unstable; urgency=low + + * New upstream release. + + -- Steve Kemp Mon, 12 Jul 2004 15:37:21 +0000 + +komi (1.01-1) unstable; urgency=low + + * Uploaded to the Debian archives. + (Closes: #257166) + * Changed maintainer address to my @debian.org email. + * Changed the saving of the preferences to the users home directory, + this will be folded in upstream for the next release :) + + -- Steve Kemp Fri, 2 Jul 2004 18:47:15 +0000 + +komi (0.8b-2) unstable; urgency=low + + * Move manpage into section 6. + * Updated manpage. + + -- Steve Kemp Fri, 11 Jun 2004 15:23:02 +0000 + +komi (0.8b-1) unstable; urgency=low + + * Initial package. + * Moved binary to /usr/games/komi + * Moved data to /usr/share/games/komi + * Added manpage. + + -- Steve Kemp Thurs, 10 Jun 2004 21:40:11 +0000 --- komi-1.04.orig/debian/docs +++ komi-1.04/debian/docs @@ -0,0 +1,2 @@ +TROUBLESHOOTING.txt +README.txt --- komi-1.04.orig/debian/control +++ komi-1.04/debian/control @@ -0,0 +1,17 @@ +Source: komi +Section: games +Maintainer: Brandon Barnes +Priority: optional +Build-Depends: debhelper (>= 8), libsdl-mixer1.2-dev, libsdl1.2-dev +Standards-Version: 3.9.2 +Homepage: http://komi.sf.net + +Package: komi +Architecture: any +Depends: ${shlibs:Depends}, ${misc:Depends} +Description: Single player arcade game with Komi the Space Frog! + Komi is a space frog, and your aim in this single player arcade + game is to feed him by capturing food with your giant tongue. + . + Avoid hitting the energy barriers and other nasties as you + try to eat all the food. --- komi-1.04.orig/debian/source/format +++ komi-1.04/debian/source/format @@ -0,0 +1 @@ +1.0