debian/0000755000000000000000000000000011666262420007173 5ustar debian/amphetamine.manpages0000644000000000000000000000001611537547550013204 0ustar debian/amph.6 debian/changelog0000644000000000000000000002326311666262413011055 0ustar amphetamine (0.8.10-18) unstable; urgency=low * Use multiarch paths for libc6-dev includes (closes: #650468). -- Michael Gilbert Fri, 02 Dec 2011 18:41:07 -0500 amphetamine (0.8.10-17) unstable; urgency=low * Change build-depend to libc6-dev-i386 [amd64] (closes: #650468). * Install upstream changelog. * Add descriptions to patches. -- Michael Gilbert Thu, 01 Dec 2011 23:01:07 -0500 amphetamine (0.8.10-16) unstable; urgency=low * build-depend on libc6-dev-i386 (closes: #640554). * use -iquote and -Wno-write-strings build flags. * bump standards version to 3.9.2. -- Michael Gilbert Sun, 11 Sep 2011 18:18:38 -0400 amphetamine (0.8.10-15) unstable; urgency=low * adopt the package (closes: #544910). * set myself as an uploader. * set dm-upload-allowed. * bump standards version to 3.9.1. * convert to source format 3.0 and simplified debian/rules. * remove watch file since upstream no longer exists. -- Michael Gilbert Mon, 14 Mar 2011 22:25:57 -0400 amphetamine (0.8.10-14) unstable; urgency=low [ Gonéri Le Bouder ] * disable 000_gcc_m68k.diff that was forcing the use of gcc 4.1. amphetamine should build fine on m68k now with the default gcc (Closes: #479573) * clean the .pc/ directory -- Debian Games Team Sat, 09 Aug 2008 14:58:26 +0200 amphetamine (0.8.10-13) unstable; urgency=low [ Barry deFreese ] * Bump compat/debhelper to 5. * Add Hompage and vcs tags to debian/control. * Remove Homepage field from package description. * Fix make clean target for lintian warning. * Bump Standards Version to 3.7.3. + Menu policy transition. * Fix watch file (Closes: #456472). * Add desktop file. (Closes: #471254). + Add call to dh_desktop. * Replace 'pwd' with $(CURDIR) in rules. * Update Homepage URL. * Add myself to uploaders. [ Eddy Petrișor ] * fix Vcs-Svn URL to point to svn, not the incomplete ssh location. [ Jon Dowland ] * add debian/amphetamine.links, creating symlinks amphetamine -> amph for binaries and manpages (Closes: #471257). * update menu section to "Games/Action" for menu transition (thanks Linas Žvirblis). -- Barry deFreese Tue, 18 Mar 2008 14:09:19 -0400 amphetamine (0.8.10-12) unstable; urgency=high [ Sam Hocevar (Debian packages) ] * debian/patches/000_no_lxt.diff: + New patch. Removes useless -lXt link flag (Closes: #397558). -- Jon Dowland Thu, 12 Jul 2007 11:22:44 +0100 amphetamine (0.8.10-11) unstable; urgency=low [ Sam Hocevar ] * debian/patches/020_assumed_sizeof_long.diff: + New patch, courtesy of Darren Salt: fix wrong assumption that long is a 32 bit type (Closes: #380404). [ Eddy Petrișor ] * fixed watch file * added a link to the upstream homepage -- Sam Hocevar (Debian packages) Wed, 2 Aug 2006 11:11:24 +0200 amphetamine (0.8.10-10) unstable; urgency=low * debian/control: + Remove the amphetamine/amphetamine-data dependency loop. -- Sam Hocevar (Debian packages) Sat, 27 May 2006 09:30:09 +0200 amphetamine (0.8.10-9) unstable; urgency=low * Maintainer upload. * Acknowledge previous NMU (Closes: 346658). Thanks to Luk Claes. * Moved packaging to the Debian Games Team. * Use quilt for patch management. * debian/control: + Set policy to 3.7.2. + Build-depend on quilt. * debian/patches/010_newline.diff: + New patch from old diff.gz -- fix newlines at end of file. * debian/patches/000_data_path.diff: + New patch from old diff.gz -- fix shared data paths in makefile. * debian/patches/010_missing_headers.diff: + New patch from old diff.gz -- fix compilation warnings. * debian/patches/010_etc_dir.diff: + New patch from old diff.gz -- use /etc as the configuration directory. * debian/patches/010_bugs.diff: + New patch from old diff.gz -- fix various bugs. * debian/patches/000_gcc_m68k.diff: + New patch -- use g++-4.1 on m68k to work around a g++ bug (Closes: #363318). -- Sam Hocevar (Debian packages) Mon, 15 May 2006 11:54:38 -0500 amphetamine (0.8.10-8.1) unstable; urgency=high * Non-maintainer upload. * Split xlibs-dev build-dep (Closes: #346658). -- Luk Claes Sun, 15 Jan 2006 16:41:54 +0100 amphetamine (0.8.10-8) unstable; urgency=low * debian/control: + Set policy to 3.6.2.1. -- Sam Hocevar (Debian packages) Sat, 12 Nov 2005 14:18:21 +0100 amphetamine (0.8.10-7) unstable; urgency=low * Makefile: + Do not systematically strip the main binary (Closes: #230051). * src/Appl.cpp: + Fixed calculation of average time so that the monsters get their full timeslice after a pause (Closes: #226156). * src/ConstVal.cpp: + Fixed an uninitialised variable. -- Sam Hocevar (Debian packages) Tue, 27 Jan 2004 13:24:31 +0100 amphetamine (0.8.10-6) unstable; urgency=low * New maintainer (Closes: #226287). * debian/control: + Set policy to 3.6.1.0. + Slightly shortened the short description. -- Sam Hocevar (Debian packages) Tue, 27 Jan 2004 13:24:31 +0100 amphetamine (0.8.10-5) unstable; urgency=low * Orphaned the package. -- Joey Hess Mon, 5 Jan 2004 00:34:34 -0500 amphetamine (0.8.10-4) unstable; urgency=low * Rebuild with gcc 3.2 -- Joey Hess Wed, 12 Feb 2003 11:45:27 -0500 amphetamine (0.8.10-3) unstable; urgency=low * Updated copyright file. -- Joey Hess Sun, 25 Aug 2002 16:26:13 -0400 amphetamine (0.8.10-2) unstable; urgency=low * Debhelper v4. -- Joey Hess Thu, 13 Jun 2002 18:03:40 -0400 amphetamine (0.8.10-1) unstable; urgency=low * New upstream with improved endianness checks. * Added newlines at the end of more source files. -- Joey Hess Wed, 27 Mar 2002 12:14:13 -0500 amphetamine (0.8.9-3) unstable; urgency=low * Work around divide by zero problem that causes FPEs on alpha. Closes: #134825 -- Joey Hess Sun, 24 Feb 2002 16:12:49 -0500 amphetamine (0.8.9-2) unstable; urgency=low * Include missing string.h for memcpy in Surface.cpp. Closes: #127217 -- Joey Hess Mon, 31 Dec 2001 16:27:24 -0500 amphetamine (0.8.9-1) unstable; urgency=low * New upstream release. * Hacked File.hpp to probe for endianness . Pity this program does not use autoconf. * Look for data file in /usr/share, not /usr/lib -- Joey Hess Fri, 28 Dec 2001 16:07:28 -0500 amphetamine (0.8.8-7) unstable; urgency=low * Updated to the new sdl packages. Maybe it'll go into testing eventally. -- Joey Hess Fri, 12 Oct 2001 14:15:15 -0400 amphetamine (0.8.8-6) unstable; urgency=low * Fixed ia64(/gcc 3?) compile error, Closes: #110177 * Added newlines to the end of all source files, since gcc whines mightily about their lack. -- Joey Hess Sun, 26 Aug 2001 18:50:49 -0400 amphetamine (0.8.8-5) unstable; urgency=low * Update to sdl 1.2. -- Joey Hess Sun, 3 Jun 2001 18:31:05 -0400 amphetamine (0.8.8-4) unstable; urgency=low * Build with debhelper v3. -- Joey Hess Fri, 9 Feb 2001 17:59:18 -0800 amphetamine (0.8.8-3) unstable; urgency=low * Build with new SDL, Closes: #76133 -- Joey Hess Thu, 2 Nov 2000 16:09:24 -0800 amphetamine (0.8.8-2) unstable; urgency=low * Updated to use debhelper v2 (trivial). -- Joey Hess Mon, 25 Sep 2000 12:42:33 -0700 amphetamine (0.8.8-1) unstable; urgency=low * New upstream. -- Joey Hess Sat, 6 May 2000 20:08:31 -0700 amphetamine (0.8.7-4) unstable; urgency=low * Applied m68k build patch. * Since even with the patch it crashes on m68k, upload only to unstable. -- Joey Hess Mon, 17 Jan 2000 11:53:28 -0800 amphetamine (0.8.7-3) frozen unstable; urgency=low * Rebuilt with libsdl1.0, fixes missing libsdl dependancy, Closes: #55350 * Hm, this bug seems vaguly important to me, but the submitter did not flag it as such. Uploading to frozen, at the release manager's discretion -- I have no strong feelings either way, but a few people on IRC think it should go in. -- Joey Hess Sun, 16 Jan 2000 14:55:47 -0800 amphetamine (0.8.7-2) unstable; urgency=low * Removed libsdl0 from explicit dependancies; sdl now has proper shlibs stuff. -- Joey Hess Thu, 13 Jan 2000 00:15:09 -0800 amphetamine (0.8.7-1) unstable; urgency=low * New upstream. -- Joey Hess Tue, 11 Jan 2000 15:30:15 -0800 amphetamine (0.8.3-5) unstable; urgency=low * Built with libsdl1.0. * Wrote a man page for amph. -- Joey Hess Wed, 5 Jan 2000 15:50:52 -0800 amphetamine (0.8.3-4) unstable; urgency=low * Added build deps. -- Joey Hess Fri, 3 Dec 1999 23:36:44 -0800 amphetamine (0.8.3-3) unstable; urgency=low * Removed install-stamp, which can cause obscure problems. -- Joey Hess Thu, 30 Sep 1999 13:04:49 -0700 amphetamine (0.8.3-2) unstable; urgency=low * Depends on libsdl0, Closes: #46286 * Added man page, Closes: #46289 * Display error if unable to connect to X server, Closes: #46288 -- Joey Hess Thu, 30 Sep 1999 11:28:51 -0700 amphetamine (0.8.3-1) unstable; urgency=low * First release. * Modified to look for config files in /etc/apmhetamine/ -- Joey Hess Sun, 26 Sep 1999 01:38:25 -0700 debian/amphetamine.menu0000644000000000000000000000015211537546736012363 0ustar ?package(amphetamine):needs="x11" section="Games/Action" \ title="Amphetamine" command="/usr/games/amph" debian/compat0000644000000000000000000000000211537546736010405 0ustar 5 debian/amphetamine.links0000644000000000000000000000015211537546736012537 0ustar /usr/games/amph /usr/games/amphetamine /usr/share/man/man6/amph.6.gz /usr/share/man/man6/amphetamine.6.gz debian/source/0000755000000000000000000000000011537547017010500 5ustar debian/source/format0000644000000000000000000000001411537547017011706 0ustar 3.0 (quilt) debian/copyright0000644000000000000000000000377411537553235011145 0ustar This is a Debian prepackaged version of the game amphetamine. This package was put together by Joey Hess , using sources from: http://www.dataway.ch/~lukasl/amph/amph.html The file Gifload.cpp has the following copyright: /* * xgifload.c - based strongly on... * * gif2ras.c - Converts from a Compuserve GIF (tm) image to a Sun Raster image. * * Copyright (c) 1988, 1989 by Patrick J. Naughton * * Author: Patrick J. Naughton * naughton@wind.sun.com * * Permission to use, copy, modify, and distribute this software and its * documentation for any purpose and without fee is hereby granted, * provided that the above copyright notice appear in all copies and that * both that copyright notice and this permission notice appear in * supporting documentation. * * This file is provided AS IS with no warranties of any kind. The author * shall have no liability with respect to the infringement of copyrights, * trade secrets or any patents by this file or any part thereof. In no * event will the author be liable for any lost revenue or profits or * other special, indirect and consequential damages. Graphfil.hpp has the following copyright: ** Copyright (C) 1994 by Chris Laurel ** email: claurel@mr.net ** snail mail: Chris Laurel, 5700 W Lake St #208, St. Louis Park, MN 55416 ** ** 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. The remainder of amphetamine was written by Jonas Spillmann , and is is GPL'd. On Debian systems, the full text of the GPL can be found in /usr/share/common-licenses/GPL-2. debian/control0000644000000000000000000000175511666261076010614 0ustar Source: amphetamine Section: games Priority: optional Build-Depends: debhelper (>= 8), libxpm-dev, libsdl1.2-dev (>= 1.2.2-3.1), dpkg-dev (>= 1.9.0) Maintainer: Debian Games Team Uploaders: Sam Hocevar (Debian packages) , Barry deFreese , Michael Gilbert DM-Upload-Allowed: yes Standards-Version: 3.9.2 Homepage: http://homepage.hispeed.ch/loehrer/amph/amph.html Vcs-Svn: svn://svn.debian.org/svn/pkg-games/packages/trunk/amphetamine/ Vcs-Browser: http://svn.debian.org/wsvn/pkg-games/packages/trunk/amphetamine/?op=log Package: amphetamine Architecture: any Depends: amphetamine-data (>= 0.8.7-12), ${shlibs:Depends}, ${misc:Depends} Description: jump'n run game with unique visual effects Amphetamine is an exciting jump'n run game that offers some unique visual effects like colored lighting, fogging and coronas. You must fight eleven evil monsters with your magic weapons. debian/rules0000755000000000000000000000021311666045660010254 0ustar #!/usr/bin/make -f %: dh ${@} override_dh_auto_clean: rm -f changelog dh_auto_clean override_dh_auto_install: cp ChangeLog changelog debian/amphetamine.docs0000644000000000000000000000002611666045611012334 0ustar README NEWS changelog debian/amphetamine.postinst0000644000000000000000000000035311537546736013305 0ustar #! /bin/sh set -e DOCDIR="/usr/share/doc/amphetamine" if [ -d "$DOCDIR" -a ! -L "$DOCDIR" ]; then rmdir --ignore-fail-on-non-empty "$DOCDIR" if [ ! -d "$DOCDIR" ]; then ln -s amphetamine-data "$DOCDIR" fi fi #DEBHELPER# debian/amphetamine.install0000644000000000000000000000013711537551016013053 0ustar debian/amphetamine.desktop /usr/share/applications amph.xpm /usr/share/pixmaps amph /usr/games debian/amphetamine.desktop0000644000000000000000000000030511537546736013070 0ustar [Desktop Entry] Name=Amphetamine GenericName=Jump and Run game Comment=Fight evil monsters with your magic weapons. Type=Application Exec=amph Icon=amph Terminal=false Categories=Game;ActionGame; debian/amph.60000644000000000000000000000124011537546736010220 0ustar .TH AMPH 6 .SH NAME amph \- Exciting Jump'n run game that offers some unique visual effects .SH SYNOPSIS .B amph .I "[options]" .SH "DESCRIPTION" Amphetamine is an exciting Jump'n run game that offers some unique visual effects like colored lighting, fogging and coronas. You must fight eleven evil monsters with your magic weapons. .SH OPTIONS .TP .B \-\-help Show summary of options. .TP .B \-ns, \-\-nosound Disable sound. .TP .B \-f, \-\-fullscreen Try to run in DGA fullscreen mode. For this to work, you must be root. .TP .B \-v, \-\-version Display version infomation and exit. .SH AUTHOR This manual page was written by Joey Hess, for the Debian GNU/Linux system. debian/patches/0000755000000000000000000000000011666262036010625 5ustar debian/patches/010_etc_dir.diff0000644000000000000000000000737611666046413013464 0ustar description: use /etc/amphetamine for config files Index: amphetamine-0.8.10/src/ConstVal.cpp =================================================================== --- amphetamine-0.8.10.orig/src/ConstVal.cpp 2006-05-15 19:16:56.000000000 +0200 +++ amphetamine-0.8.10/src/ConstVal.cpp 2006-05-15 19:17:02.000000000 +0200 @@ -19,7 +19,7 @@ { char levelSetString[11] = "xxLevelSet"; char levelBkgndString[13] = "xxLevelBkgnd"; - FILE *paramFile = fopen(gSystem->QualifyDataDir(kParFileName), "r"); // by LL + FILE *paramFile = fopen(gSystem->QualifyEtcDir(kParFileName), "r"); // by LL gConst = new tConstValues; @@ -159,7 +159,7 @@ fclose(paramFile); // Hier sollte auch im Home Directory gesucht werden... - paramFile = gSystem->FindFile(gConst->kFileConfig); // by LL + paramFile = fopen(gSystem->QualifyEtcDir(gConst->kFileConfig), "r"); // by LL gConfigData->leftKey = GetLongConstant(paramFile, "LeftKey"); GetStringConstant(paramFile, "LeftKeyText", gConfigData->leftKeyText); @@ -212,6 +212,7 @@ char c = 0; short n; + key[0] = '\0'; fseek(f, 0, SEEK_SET); while (strcmp(key, constName)) { Index: amphetamine-0.8.10/src/Gui.cpp =================================================================== --- amphetamine-0.8.10.orig/src/Gui.cpp 2006-05-15 19:16:56.000000000 +0200 +++ amphetamine-0.8.10/src/Gui.cpp 2006-05-15 19:17:02.000000000 +0200 @@ -688,7 +688,7 @@ void CGUI::LoadMessages() { - FILE *f = fopen(gSystem->QualifyDataDir(kParFileName), "r"); // by LL + FILE *f = fopen(gSystem->QualifyEtcDir(kParFileName), "r"); // by LL char msgString[6] = "msgxx"; short n; @@ -724,7 +724,7 @@ void LoadGUIParameters() { - FILE *f = fopen(gSystem->QualifyDataDir(kParFileName), "r"); // by LL + FILE *f = fopen(gSystem->QualifyEtcDir(kParFileName), "r"); // by LL gGUIConst = new tGUIConstants; Index: amphetamine-0.8.10/src/System.cpp =================================================================== --- amphetamine-0.8.10.orig/src/System.cpp 2006-05-15 19:16:56.000000000 +0200 +++ amphetamine-0.8.10/src/System.cpp 2006-05-15 19:17:02.000000000 +0200 @@ -143,6 +143,14 @@ return tmp; } +char *CSystem::QualifyEtcDir(const char *fname) +{ + char *tmp = new char[strlen(etcDir)+strlen(fname)+2]; + sprintf(tmp, "%s/%s", etcDir, fname); + + return tmp; +} + void CSystem::GetHomeDir() { char *tmp; @@ -169,7 +177,9 @@ GetHomeDir(); dataDir = new char[strlen(INSTALL_DIR)+1]; strcpy(dataDir, INSTALL_DIR); - + etcDir = new char[strlen(ETC_DIR)+1]; + strcpy(etcDir, ETC_DIR); + char *logFileName = QualifyHomeDir(kLogFileName); logFile = fopen(logFileName, "w"); // by LL @@ -180,6 +190,8 @@ if ( SDL_Init(SDL_INIT_VIDEO|SDL_INIT_AUDIO) < 0 ) { MSG("SDL_Init_Failed."); MSG(SDL_GetError()); + /* Ouput to stdout too. */ + printf("SDL_Init_Failed: %s\n", SDL_GetError()); exit(1); } Index: amphetamine-0.8.10/src/System.hpp =================================================================== --- amphetamine-0.8.10.orig/src/System.hpp 2006-05-15 19:16:57.000000000 +0200 +++ amphetamine-0.8.10/src/System.hpp 2006-05-15 19:17:02.000000000 +0200 @@ -16,6 +16,10 @@ #define INSTALL_DIR "/usr/local/games/amph" #endif +#ifndef ETC_DIR +#define ETC_DIR "/etc/amphetamine" +#endif + #if SDL_BYTEORDER == SDL_LIL_ENDIAN #undef __BIG_ENDIAN__ #else @@ -76,6 +80,7 @@ RGBcolor *palColors; char *homeDir; char *dataDir; + char *etcDir; int workingSound; //"""""""""""""""" System Stuff @@ -107,8 +112,10 @@ void GetHomeDir(); char *QualifyDataDir(const char *fname); char *QualifyHomeDir(const char *fname); + char *QualifyEtcDir(const char *fname); void ScreenShot(); FILE *FindFile(const char *fname); }; #endif + debian/patches/010_newline.diff0000644000000000000000000002720211666046456013511 0ustar description: fix newlines Index: amphetamine-0.8.10/src/AmpHead.hpp =================================================================== --- amphetamine-0.8.10.orig/src/AmpHead.hpp 2002-03-25 11:38:15.000000000 +0100 +++ amphetamine-0.8.10/src/AmpHead.hpp 2006-05-15 19:08:52.000000000 +0200 @@ -185,4 +185,4 @@ #define MSG(message) if (logFile) fprintf(logFile, message); fflush(logFile) -#endif \ No newline at end of file +#endif Index: amphetamine-0.8.10/src/Appl.cpp =================================================================== --- amphetamine-0.8.10.orig/src/Appl.cpp 2002-03-25 12:47:49.000000000 +0100 +++ amphetamine-0.8.10/src/Appl.cpp 2006-05-15 19:08:52.000000000 +0200 @@ -404,4 +404,4 @@ if (preRenderQueue == remove) bulletList = bulletList->nextBullet; if (remove->nextBullet) remove->nextBullet->prevBullet = remove->prevBullet; if (remove->prevBullet) remove->prevBullet->nextBullet = remove->nextBullet; -}*/ \ No newline at end of file +}*/ Index: amphetamine-0.8.10/src/Appl.hpp =================================================================== --- amphetamine-0.8.10.orig/src/Appl.hpp 2002-03-24 09:49:09.000000000 +0100 +++ amphetamine-0.8.10/src/Appl.hpp 2006-05-15 19:08:52.000000000 +0200 @@ -102,4 +102,4 @@ }; -#endif \ No newline at end of file +#endif Index: amphetamine-0.8.10/src/Clut.hpp =================================================================== --- amphetamine-0.8.10.orig/src/Clut.hpp 2002-03-24 09:49:09.000000000 +0100 +++ amphetamine-0.8.10/src/Clut.hpp 2006-05-15 19:08:52.000000000 +0200 @@ -84,4 +84,4 @@ void SwapBlackWhite(Graphic_file *gf); -#endif \ No newline at end of file +#endif Index: amphetamine-0.8.10/src/ConstVal.cpp =================================================================== --- amphetamine-0.8.10.orig/src/ConstVal.cpp 2002-03-24 09:49:09.000000000 +0100 +++ amphetamine-0.8.10/src/ConstVal.cpp 2006-05-15 19:08:52.000000000 +0200 @@ -271,4 +271,5 @@ void GetStringConstant(FILE *f, char *constName, char *buffer) { GetValue(f, constName, buffer); -} \ No newline at end of file +} + Index: amphetamine-0.8.10/src/ConstVal.hpp =================================================================== --- amphetamine-0.8.10.orig/src/ConstVal.hpp 2002-03-24 09:49:09.000000000 +0100 +++ amphetamine-0.8.10/src/ConstVal.hpp 2006-05-15 19:08:52.000000000 +0200 @@ -160,4 +160,4 @@ short disableShapeModes; }; -#endif \ No newline at end of file +#endif Index: amphetamine-0.8.10/src/Creeper.hpp =================================================================== --- amphetamine-0.8.10.orig/src/Creeper.hpp 2002-03-24 09:49:09.000000000 +0100 +++ amphetamine-0.8.10/src/Creeper.hpp 2006-05-15 19:08:52.000000000 +0200 @@ -4,4 +4,4 @@ #include "Monster.hpp" -#endif \ No newline at end of file +#endif Index: amphetamine-0.8.10/src/Element.cpp =================================================================== --- amphetamine-0.8.10.orig/src/Element.cpp 2002-03-24 09:49:09.000000000 +0100 +++ amphetamine-0.8.10/src/Element.cpp 2006-05-15 19:08:52.000000000 +0200 @@ -373,4 +373,4 @@ CElement::Read(f); OnAllocate(); -} \ No newline at end of file +} Index: amphetamine-0.8.10/src/File.cpp =================================================================== --- amphetamine-0.8.10.orig/src/File.cpp 2002-03-24 09:49:09.000000000 +0100 +++ amphetamine-0.8.10/src/File.cpp 2006-05-15 19:08:52.000000000 +0200 @@ -26,4 +26,4 @@ long CFile::ReadData(void *data, long size) { return fread(data, size, 1, fileRef); -} \ No newline at end of file +} Index: amphetamine-0.8.10/src/Graphfil.hpp =================================================================== --- amphetamine-0.8.10.orig/src/Graphfil.hpp 2002-03-24 09:49:09.000000000 +0100 +++ amphetamine-0.8.10/src/Graphfil.hpp 2006-05-15 19:08:52.000000000 +0200 @@ -54,4 +54,4 @@ Graphic_file *LoadGIF(FILE *fp, char *fname ); Graphic_file *LoadPICTR(FILE *fp, char *fname ); -#endif \ No newline at end of file +#endif Index: amphetamine-0.8.10/src/Gui.cpp =================================================================== --- amphetamine-0.8.10.orig/src/Gui.cpp 2002-03-24 09:49:09.000000000 +0100 +++ amphetamine-0.8.10/src/Gui.cpp 2006-05-15 19:08:52.000000000 +0200 @@ -796,4 +796,5 @@ fclose(f); } - \ No newline at end of file + + Index: amphetamine-0.8.10/src/Gui.hpp =================================================================== --- amphetamine-0.8.10.orig/src/Gui.hpp 2002-03-24 09:49:09.000000000 +0100 +++ amphetamine-0.8.10/src/Gui.hpp 2006-05-15 19:08:52.000000000 +0200 @@ -183,4 +183,4 @@ void DisplayInfotext(short num); }; -#endif \ No newline at end of file +#endif Index: amphetamine-0.8.10/src/Item.cpp =================================================================== --- amphetamine-0.8.10.orig/src/Item.cpp 2002-03-24 09:49:09.000000000 +0100 +++ amphetamine-0.8.10/src/Item.cpp 2006-05-15 19:08:52.000000000 +0200 @@ -309,4 +309,4 @@ READDATA(pickedUp); READDATA(type); -} \ No newline at end of file +} Index: amphetamine-0.8.10/src/Item.hpp =================================================================== --- amphetamine-0.8.10.orig/src/Item.hpp 2002-03-24 11:10:24.000000000 +0100 +++ amphetamine-0.8.10/src/Item.hpp 2006-05-15 19:08:52.000000000 +0200 @@ -84,4 +84,4 @@ void Read(FILE *f); }; -#endif \ No newline at end of file +#endif Index: amphetamine-0.8.10/src/Level.hpp =================================================================== --- amphetamine-0.8.10.orig/src/Level.hpp 2002-03-24 09:49:09.000000000 +0100 +++ amphetamine-0.8.10/src/Level.hpp 2006-05-15 19:08:52.000000000 +0200 @@ -29,4 +29,4 @@ }; -#endif \ No newline at end of file +#endif Index: amphetamine-0.8.10/src/Main.cpp =================================================================== --- amphetamine-0.8.10.orig/src/Main.cpp 2002-03-24 09:49:09.000000000 +0100 +++ amphetamine-0.8.10/src/Main.cpp 2006-05-15 19:08:52.000000000 +0200 @@ -84,4 +84,4 @@ delete gApplication; return 0; -} \ No newline at end of file +} Index: amphetamine-0.8.10/src/Monster.cpp =================================================================== --- amphetamine-0.8.10.orig/src/Monster.cpp 2002-03-25 11:53:27.000000000 +0100 +++ amphetamine-0.8.10/src/Monster.cpp 2006-05-15 19:08:52.000000000 +0200 @@ -372,4 +372,4 @@ READDATA(health); if (dieFrame != -1) gApplication->Dequeue(&gApplication->collisionThingList, this); -} \ No newline at end of file +} Index: amphetamine-0.8.10/src/Monster.hpp =================================================================== --- amphetamine-0.8.10.orig/src/Monster.hpp 2002-03-24 09:49:09.000000000 +0100 +++ amphetamine-0.8.10/src/Monster.hpp 2006-05-15 19:08:52.000000000 +0200 @@ -86,4 +86,4 @@ -#endif \ No newline at end of file +#endif Index: amphetamine-0.8.10/src/Monstrxx.hpp =================================================================== --- amphetamine-0.8.10.orig/src/Monstrxx.hpp 2002-03-24 09:49:09.000000000 +0100 +++ amphetamine-0.8.10/src/Monstrxx.hpp 2006-05-15 19:08:52.000000000 +0200 @@ -123,4 +123,4 @@ void Read(FILE *f); }; -#endif \ No newline at end of file +#endif Index: amphetamine-0.8.10/src/ObjInfo.hpp =================================================================== --- amphetamine-0.8.10.orig/src/ObjInfo.hpp 2002-03-24 09:49:09.000000000 +0100 +++ amphetamine-0.8.10/src/ObjInfo.hpp 2006-05-15 19:08:52.000000000 +0200 @@ -97,4 +97,4 @@ tWeaponInfo *FindWeapon(short ref); }; -#endif \ No newline at end of file +#endif Index: amphetamine-0.8.10/src/Player.cpp =================================================================== --- amphetamine-0.8.10.orig/src/Player.cpp 2002-03-24 09:49:09.000000000 +0100 +++ amphetamine-0.8.10/src/Player.cpp 2006-05-15 19:08:52.000000000 +0200 @@ -527,4 +527,4 @@ READDATA(oxygen); READDATA(lastOxygenDecTime); -} \ No newline at end of file +} Index: amphetamine-0.8.10/src/Player.hpp =================================================================== --- amphetamine-0.8.10.orig/src/Player.hpp 2002-03-24 11:10:24.000000000 +0100 +++ amphetamine-0.8.10/src/Player.hpp 2006-05-15 19:08:52.000000000 +0200 @@ -81,4 +81,4 @@ }; -#endif \ No newline at end of file +#endif Index: amphetamine-0.8.10/src/Pltform.cpp =================================================================== --- amphetamine-0.8.10.orig/src/Pltform.cpp 2002-03-24 09:49:09.000000000 +0100 +++ amphetamine-0.8.10/src/Pltform.cpp 2006-05-15 19:08:52.000000000 +0200 @@ -276,4 +276,4 @@ fread(info, sizeof(tPlatformInfo), 1, f); OnAllocate(); -} \ No newline at end of file +} Index: amphetamine-0.8.10/src/ShapeDes.hpp =================================================================== --- amphetamine-0.8.10.orig/src/ShapeDes.hpp 2002-03-24 09:49:09.000000000 +0100 +++ amphetamine-0.8.10/src/ShapeDes.hpp 2006-05-15 19:08:52.000000000 +0200 @@ -376,4 +376,4 @@ }; -#endif \ No newline at end of file +#endif Index: amphetamine-0.8.10/src/ShapeLd.cpp =================================================================== --- amphetamine-0.8.10.orig/src/ShapeLd.cpp 2002-03-24 09:49:09.000000000 +0100 +++ amphetamine-0.8.10/src/ShapeLd.cpp 2006-05-15 19:08:52.000000000 +0200 @@ -93,4 +93,4 @@ height = backgroundPicture->height; return backgroundPicture->bitmap; -} \ No newline at end of file +} Index: amphetamine-0.8.10/src/SndSys.cpp =================================================================== --- amphetamine-0.8.10.orig/src/SndSys.cpp 2002-03-24 09:49:09.000000000 +0100 +++ amphetamine-0.8.10/src/SndSys.cpp 2006-05-15 19:08:52.000000000 +0200 @@ -132,4 +132,5 @@ playList->RemoveCurrent(); } } -} \ No newline at end of file +} + Index: amphetamine-0.8.10/src/SndSys.hpp =================================================================== --- amphetamine-0.8.10.orig/src/SndSys.hpp 2002-03-24 09:49:09.000000000 +0100 +++ amphetamine-0.8.10/src/SndSys.hpp 2006-05-15 19:08:52.000000000 +0200 @@ -99,4 +99,5 @@ }; -#endif \ No newline at end of file +#endif + Index: amphetamine-0.8.10/src/SoundList.hpp =================================================================== --- amphetamine-0.8.10.orig/src/SoundList.hpp 2002-03-24 09:49:09.000000000 +0100 +++ amphetamine-0.8.10/src/SoundList.hpp 2006-05-15 19:08:52.000000000 +0200 @@ -55,4 +55,4 @@ SoundState *first, *prev, *current; }; -#endif \ No newline at end of file +#endif Index: amphetamine-0.8.10/src/System.cpp =================================================================== --- amphetamine-0.8.10.orig/src/System.cpp 2002-03-25 10:31:27.000000000 +0100 +++ amphetamine-0.8.10/src/System.cpp 2006-05-15 19:08:52.000000000 +0200 @@ -554,4 +554,5 @@ delete [] tmp; return NULL; // failed -} \ No newline at end of file +} + Index: amphetamine-0.8.10/src/Thing.hpp =================================================================== --- amphetamine-0.8.10.orig/src/Thing.hpp 2002-03-24 17:16:00.000000000 +0100 +++ amphetamine-0.8.10/src/Thing.hpp 2006-05-15 19:08:52.000000000 +0200 @@ -64,4 +64,4 @@ }; -#endif \ No newline at end of file +#endif Index: amphetamine-0.8.10/src/Weapon.cpp =================================================================== --- amphetamine-0.8.10.orig/src/Weapon.cpp 2002-03-24 09:49:09.000000000 +0100 +++ amphetamine-0.8.10/src/Weapon.cpp 2006-05-15 19:08:52.000000000 +0200 @@ -467,4 +467,4 @@ READDATA(dx); READDATA(dy); -} \ No newline at end of file +} Index: amphetamine-0.8.10/src/Weapon.hpp =================================================================== --- amphetamine-0.8.10.orig/src/Weapon.hpp 2002-03-24 17:16:14.000000000 +0100 +++ amphetamine-0.8.10/src/Weapon.hpp 2006-05-15 19:08:52.000000000 +0200 @@ -152,4 +152,4 @@ short Shoot(double directionx, double directiony, double targetpos); }; -#endif \ No newline at end of file +#endif debian/patches/000_gcc_m68k.diff0000644000000000000000000000161711666046240013441 0ustar description: use gcc 4.1 for m68k build Index: amphetamine-0.8.10/Makefile =================================================================== --- amphetamine-0.8.10.orig/Makefile 2006-05-15 19:26:37.000000000 +0200 +++ amphetamine-0.8.10/Makefile 2006-05-15 19:34:04.000000000 +0200 @@ -13,6 +13,12 @@ SDL_HEADERS := $(shell $(SDL_CONFIG) --cflags) SDL_LIBS := $(shell $(SDL_CONFIG) --libs) +ifeq ($(shell uname -m), m68k) +GXX = g++-4.1 +else +GXX = g++ +endif + #======================================================= # You should not have to change anything below @@ -26,7 +32,7 @@ # makemake variables -LINKER := g++ +LINKER := $(GXX) DEPENDFLAGS := -g ${SEARCHDIRS} TOUCHHEADERS := ${MYCODEDIR}/*.h @@ -37,7 +43,7 @@ # C++ -CXX := g++ +CXX := $(GXX) CXXFLAGS = ${DEPENDFLAGS} -O9 -funroll-loops -fomit-frame-pointer -ffast-math -Wcast-align %.o : %.cpp debian/patches/010_missing_headers.diff0000644000000000000000000000071111666046440015201 0ustar description: include string.h Index: amphetamine-0.8.10/src/Surface.cpp =================================================================== --- amphetamine-0.8.10.orig/src/Surface.cpp 2006-05-15 19:10:49.000000000 +0200 +++ amphetamine-0.8.10/src/Surface.cpp 2006-05-15 19:11:01.000000000 +0200 @@ -3,6 +3,7 @@ #include "ShapeLd.hpp" #include "Clut.hpp" #include "ConstVal.hpp" +#include #include const short kNoCharSpace = 20; debian/patches/series0000644000000000000000000000021211633233760012031 0ustar 000_data_path.diff 000_no_lxt.diff 010_newline.diff 010_missing_headers.diff 010_etc_dir.diff 010_bugs.diff 020_assumed_sizeof_long.diff debian/patches/010_bugs.diff0000644000000000000000000000343511666046340013002 0ustar description: fix issues in collision detection Index: amphetamine-0.8.10/src/Appl.cpp =================================================================== --- amphetamine-0.8.10.orig/src/Appl.cpp 2006-05-15 19:16:56.000000000 +0200 +++ amphetamine-0.8.10/src/Appl.cpp 2006-05-15 19:17:02.000000000 +0200 @@ -183,7 +183,7 @@ firstPlayRound = 1; command = kCmdNoCommand; - syncTime = gSystem->GetTicks(); + syncTime = gSystem->GetTicks() - 20; aveTime = 20; while (command == kCmdNoCommand) { @@ -256,7 +256,7 @@ if (gSystem->KeyPressed(kKeyEscape)) { command = gGUI->RunUserInterface(kMainPage); - syncTime = gSystem->GetTicks(); + syncTime = gSystem->GetTicks() - aveTime; } if (command >= kSaveGameSlot0 && command <= kSaveGameSlot5) { Index: amphetamine-0.8.10/src/Object.cpp =================================================================== --- amphetamine-0.8.10.orig/src/Object.cpp 2006-05-15 19:18:21.000000000 +0200 +++ amphetamine-0.8.10/src/Object.cpp 2006-05-15 19:18:33.000000000 +0200 @@ -70,10 +70,13 @@ { if (ABS(forcex) > ABS(forcey)) { sx += SIGN(forcex); - sy += forcey / ABS(forcex); + if (forcex != 0) + sy += forcey / ABS(forcex); }else{ sy += SIGN(forcey); - sx += forcex / ABS(forcey); + /* Avoid SIGFE on alpha on divide by zero. -- JEH */ + if (forcey != 0) + sx += forcex / ABS(forcey); } } Index: amphetamine-0.8.10/src/Pltform.cpp =================================================================== --- amphetamine-0.8.10.orig/src/Pltform.cpp 2006-05-15 19:18:25.000000000 +0200 +++ amphetamine-0.8.10/src/Pltform.cpp 2006-05-15 19:18:33.000000000 +0200 @@ -136,7 +136,7 @@ short CPlatform::Forces() { - short collisionObject, collisionCode; + short collisionObject = 0, collisionCode; CObject *collObj; CObject::Forces(); debian/patches/000_data_path.diff0000644000000000000000000000460711666262036013772 0ustar description: use debian data paths Index: amphetamine/Makefile =================================================================== --- amphetamine.orig/Makefile 2011-12-02 18:48:23.000000000 -0500 +++ amphetamine/Makefile 2011-12-02 18:49:46.000000000 -0500 @@ -3,8 +3,9 @@ #=============== # Install Paths -PREFIX := /usr/local -INSTALL_DIR := ${PREFIX}/games/amph +PREFIX := /usr +INSTALL_DIR := ${PREFIX}/share/games/amphetamine +MULTIARCH := $(shell dpkg-architecture -qDEB_HOST_MULTIARCH) # Libraries USE_LIB_XPM := TRUE @@ -22,7 +23,7 @@ # Directories to search for header files -SEARCHDIRS := -I${MYCODEDIR} ${SDL_HEADERS} +SEARCHDIRS := -iquote . -I${MYCODEDIR} -I/usr/include/SDL -Wno-write-strings # makemake variables @@ -73,10 +74,9 @@ .PHONY : install install: amph - @./mkinstalldirs ${INSTALL_DIR} - @install -c ./amph ${INSTALL_DIR} - @strip ${INSTALL_DIR}/amph - @ln -s ${INSTALL_DIR}/amph ${PREFIX}/bin/amph + @./mkinstalldirs ${INSTALL_DIR} ${PREFIX}/games + @install -c ./amph ${PREFIX}/games +# @ln -s ${INSTALL_DIR}/amph ${PREFIX}/bin/amph # This is what makemake added @@ -194,7 +194,7 @@ ./src/Surface.o: ./src/AmpHead.hpp ./src/Clut.hpp ./src/ConstVal.hpp ./src/Graphfil.hpp ./src/Shape.hpp ./src/ShapeLd.hpp ./src/Surface.hpp ./src/System.hpp /usr/include/limits.h /usr/include/math.h /usr/include/stdio.h /usr/include/stdlib.h -./src/System.o: ./src/AmpHead.hpp ./src/Graphfil.hpp ./src/System.hpp /usr/include/X11/xpm.h /usr/include/fcntl.h /usr/include/limits.h /usr/include/math.h /usr/include/stdio.h /usr/include/stdlib.h /usr/include/string.h /usr/include/sys/stat.h /usr/include/sys/time.h /usr/include/sys/types.h /usr/include/unistd.h +./src/System.o: ./src/AmpHead.hpp ./src/Graphfil.hpp ./src/System.hpp /usr/include/X11/xpm.h /usr/include/fcntl.h /usr/include/limits.h /usr/include/math.h /usr/include/stdio.h /usr/include/stdlib.h /usr/include/string.h /usr/include/$(MULTIARCH)/sys/stat.h /usr/include/$(MULTIARCH)/sys/time.h /usr/include/$(MULTIARCH)/sys/types.h /usr/include/unistd.h ./src/Thing.o: ./src/AmpHead.hpp ./src/Appl.hpp ./src/Bullet.hpp ./src/ConstVal.hpp ./src/Element.hpp ./src/File.hpp ./src/Graphfil.hpp ./src/Level.hpp ./src/ObjInfo.hpp ./src/Object.hpp ./src/Pltform.hpp ./src/Shape.hpp ./src/ShapeLd.hpp ./src/Surface.hpp ./src/System.hpp ./src/Thing.hpp /usr/include/limits.h /usr/include/math.h /usr/include/stdio.h /usr/include/stdlib.h debian/patches/020_assumed_sizeof_long.diff0000644000000000000000000000531711666046540016105 0ustar description: use uint32_t in place of long for consistency --- amphetamine-0.8.10.orig/src/Shape.cpp +++ amphetamine-0.8.10/src/Shape.cpp @@ -56,12 +56,12 @@ */ #ifdef __OPT_MEM_ACCESS__ -#define GET_LONG(adr) *(unsigned long *)adr -#define SET_LONG(adr, l) *(unsigned long *)adr = l +#define GET_LONG(adr) *(uint32_t *)adr +#define SET_LONG(adr, l) *(uint32_t *)adr = l #else -#define GET_LONG(adr) ((long)((unsigned char *)(adr))[0] << 24) + ((long)((unsigned char *)(adr))[1] << 16) + ((long)((unsigned char *)(adr))[2] << 8) + ((long)((unsigned char *)(adr))[3]) +#define GET_LONG(adr) ((uint32_t)((unsigned char *)(adr))[0] << 24) + ((uint32_t)((unsigned char *)(adr))[1] << 16) + ((uint32_t)((unsigned char *)(adr))[2] << 8) + ((uint32_t)((unsigned char *)(adr))[3]) #define SET_LONG(adr, l) ((unsigned char *)adr)[0] = (unsigned char)((l) >> 24); \ ((unsigned char *)adr)[1] = (unsigned char)((l) >> 16); \ ((unsigned char *)adr)[2] = (unsigned char)((l) >> 8); \ @@ -116,7 +116,7 @@ { // store the location of this line start lineStartPtr = destPtr; - destPtr += sizeof( unsigned long ); + destPtr += sizeof( uint32_t ); // at the beginning of each row we are not in any run drawRunFlag = kFalse; @@ -160,7 +160,7 @@ // create the skip token //*( ( unsigned long * )destPtr ) = ( kSkipPixelsToken << 24 ) + runCounter; SET_LONG(destPtr, ( kSkipPixelsToken << 24 ) + runCounter); - destPtr += sizeof( unsigned long ); + destPtr += sizeof( uint32_t ); } // are we in a draw run @@ -179,7 +179,7 @@ // save the location of the token (so we can fill it in later) runTokenPtr = destPtr; - destPtr += sizeof( unsigned long ); + destPtr += sizeof( uint32_t ); // copy the pixel *destPtr = *srcPtr; @@ -215,7 +215,7 @@ // create the end of shape token SET_LONG(destPtr, kEndShapeToken << 24); - destPtr += sizeof( unsigned long ); + destPtr += sizeof( uint32_t ); // Resize the handle to match the real size of the shape //SetHandleSize( shapeHandle, destPtr - ( unsigned char * )( *shapeHandle ) ); @@ -280,7 +280,7 @@ // get a token tokenOp = GET_LONG(srcPtr ) >> 24; tokenData = GET_LONG(srcPtr ) & 0x00ffffff; - srcPtr += sizeof( unsigned long ); + srcPtr += sizeof( uint32_t ); // depending on the token switch( tokenOp ) @@ -435,7 +435,7 @@ // get a token tokenOp = GET_LONG(srcPtr) >> 24; tokenData = GET_LONG(srcPtr) & 0x00ffffff; - srcPtr += sizeof( unsigned long ); + srcPtr += sizeof( uint32_t ); // depending on the token switch( tokenOp ) debian/patches/000_no_lxt.diff0000644000000000000000000000077011666046265013351 0ustar description: don't link against Xt Index: amphetamine-0.8.10/Makefile =================================================================== --- amphetamine-0.8.10.orig/Makefile 2006-11-08 11:05:57.000000000 +0100 +++ amphetamine-0.8.10/Makefile 2006-11-08 11:06:01.000000000 +0100 @@ -69,7 +69,7 @@ LOADLIBES := -lm $(SDL_LIBS) ifeq ($(USE_LIB_XPM),TRUE) - LOADLIBES := $(LOADLIBES) -lXpm -lXt + LOADLIBES := $(LOADLIBES) -lXpm endif LDFLAGS = -L/usr/lib -L/usr/local/lib -L/usr/X11R6/lib