diff --git a/.cvsignore b/.cvsignore index 5af3217..233a161 100644 --- a/.cvsignore +++ b/.cvsignore @@ -1 +1 @@ -abe-1_0.tar.gz +abe-1.1.tar.gz diff --git a/abe-1.0-datapath.patch b/abe-1.0-datapath.patch deleted file mode 100644 index d889a47..0000000 --- a/abe-1.0-datapath.patch +++ /dev/null @@ -1,55 +0,0 @@ ---- abe-1_0/src/Sound.h.path 2003-02-19 08:10:28.000000000 +0200 -+++ abe-1_0/src/Sound.h 2003-08-01 01:13:36.000000000 +0300 -@@ -3,7 +3,7 @@ - - #include "Main.h" - --#define SOUND_DIR "sounds" -+#define SOUND_DIR "/usr/share/abe/sounds" - - #define DOOR_SOUND 0 - #define OBJECT_SOUND 1 ---- abe-1_0/src/Image.h.path 2003-04-12 21:16:13.000000000 +0300 -+++ abe-1_0/src/Image.h 2003-08-01 01:13:36.000000000 +0300 -@@ -5,7 +5,7 @@ - #include - #include "Main.h" - --#define IMAGES_DIR "images" -+#define IMAGES_DIR "/usr/share/abe/images" - - extern SDL_Surface *title, *score_image; - extern SDL_Surface *tom[13]; ---- abe-1_0/src/Map.h.path 2003-03-23 08:13:28.000000000 +0200 -+++ abe-1_0/src/Map.h 2003-08-01 01:13:36.000000000 +0300 -@@ -4,7 +4,7 @@ - #include "Main.h" - - // Where to store the map files (no ending /) --#define MAPS_DIR "maps" -+#define MAPS_DIR "/usr/share/abe/maps" - - // Throttle the game speed at 25 fps (for fast machines) - #define FPS_THROTTLE 30 ---- abe-1_0/src/MapIO.h.path 2003-02-25 02:39:17.000000000 +0200 -+++ abe-1_0/src/MapIO.h 2003-08-01 01:13:36.000000000 +0300 -@@ -6,7 +6,7 @@ - #include "SDL_endian.h" - - // Where to store the map files (no ending /) --#define MAPS_DIR "maps" -+#define MAPS_DIR "/usr/share/abe/maps" - - void saveMap(); - int loadMap(int drawMap); ---- abe-1_0/src/Game.h.path 2003-08-01 02:00:05.000000000 +0300 -+++ abe-1_0/src/Game.h 2003-08-01 02:00:35.000000000 +0300 -@@ -19,7 +19,7 @@ - - #define SPRING_JUMP 30 - --#define SAVEGAME_DIR "savegame" -+#define SAVEGAME_DIR ".abe" - - #define MAX_HEALTH 100 - diff --git a/abe-1.0-gcc4.patch b/abe-1.0-gcc4.patch deleted file mode 100644 index 472d392..0000000 --- a/abe-1.0-gcc4.patch +++ /dev/null @@ -1,18 +0,0 @@ ---- abe-1_0/src/Monster.c.gcc4 2005-04-11 18:53:41.041488498 +0300 -+++ abe-1_0/src/Monster.c 2005-04-11 19:03:18.791039043 +0300 -@@ -563,13 +563,13 @@ - } - - void allocFireCustom(LiveMonster *live) { -- if(((int*)live->custom = (int*)malloc(sizeof(int))) == NULL) { -+ if((live->custom = (int*)malloc(sizeof(int))) == NULL) { - fprintf(stderr, "Out of memory when trying to allocate custom storage for fire column.\n"); - } - } - - void allocEndGameCustom(LiveMonster *live) { -- if(((int*)live->custom = (int*)malloc(sizeof(int))) == NULL) { -+ if((live->custom = (int*)malloc(sizeof(int))) == NULL) { - fprintf(stderr, "Out of memory when trying to allocate custom storage for end game.\n"); - } - *((int*)(live->custom)) = 0; diff --git a/abe-1.0-misc-fixes.patch b/abe-1.0-misc-fixes.patch deleted file mode 100644 index 15fd17a..0000000 --- a/abe-1.0-misc-fixes.patch +++ /dev/null @@ -1,32 +0,0 @@ ---- abe-1_0/src/Menu.c.miscfix 2003-04-12 22:19:36.000000000 +0300 -+++ abe-1_0/src/Menu.c 2005-04-11 19:15:53.247710332 +0300 -@@ -102,6 +102,8 @@ - int isEnabled(int n) { - if(n == SOUND_ENABLED || n == MUSIC_ENABLED) - return sound_loaded; -+ else -+ return 0; - } - - void saveSettings() { ---- abe-1_0/src/Image.c.miscfix 2005-04-11 19:15:53.243710955 +0300 -+++ abe-1_0/src/Image.c 2005-04-11 19:15:53.247710332 +0300 -@@ -15,7 +15,7 @@ - int image_count; - int img_brick, img_rock, img_back, img_key, img_door, img_door2, img_key, img_smash, img_smash2, img_smash3, img_smash4; - int img_water, img_spring, img_spring2, img_spider, img_spider2, img_health; --int img_balloon[3], img_gem[2], img_bullet[4], img_slide_left[3], img_slide_right[3], img_slideback; -+int img_balloon[3], img_gem[3], img_bullet[4], img_slide_left[3], img_slide_right[3], img_slideback; - int alphacount = 0; - int alphas[256]; - ---- abe-1_0/src/Image.h.miscfix 2005-04-11 19:16:36.931909063 +0300 -+++ abe-1_0/src/Image.h 2005-04-11 19:16:43.940817642 +0300 -@@ -36,6 +36,6 @@ - // known image indexes - extern int img_brick, img_rock, img_back, img_key, img_door, img_door2, img_key, img_smash, img_smash2, img_smash3, img_smash4; - extern int img_water, img_spring, img_spring2, img_spider, img_spider2, img_health; --extern int img_balloon[3], img_gem[2], img_bullet[4], img_slide_left[3], img_slide_right[3], img_slideback; -+extern int img_balloon[3], img_gem[3], img_bullet[4], img_slide_left[3], img_slide_right[3], img_slideback; - - #endif diff --git a/abe-1.0-tmppath.patch b/abe-1.0-tmppath.patch deleted file mode 100644 index 0ba467e..0000000 --- a/abe-1.0-tmppath.patch +++ /dev/null @@ -1,11 +0,0 @@ ---- abe-1_0/src/Image.c.tmppath 2003-04-12 21:16:13.000000000 +0300 -+++ abe-1_0/src/Image.c 2003-08-03 20:01:33.000000000 +0300 -@@ -305,7 +305,7 @@ - int block = 0; - - image_count = 0; -- sprintf(tmp_path, "%s%s%s", IMAGES_DIR, PATH_SEP, "tmp.bmp"); -+ sprintf(tmp_path, "%s%s%s", getenv("HOME") , PATH_SEP, ".abetmp.bmp"); - - sprintf(path, "%s%s%s", IMAGES_DIR, PATH_SEP, "images.tar"); - fprintf(stderr, "Opening %s for reading.\n", path); diff --git a/abe.spec b/abe.spec index 1eed9e6..4348f4f 100644 --- a/abe.spec +++ b/abe.spec @@ -1,17 +1,13 @@ Name: abe -Version: 1.0 -Release: 6%{?dist} +Version: 1.1 +Release: 1%{?dist} Summary: Scrolling, platform-jumping, ancient pyramid exploring game Group: Amusements/Games License: GPL URL: http://abe.sourceforge.net/ -Source0: http://download.sourceforge.net/abe/abe-1_0.tar.gz +Source0: http://dl.sourceforge.net/abe/abe-1.1.tar.gz Source1: %{name}.png -Patch0: %{name}-%{version}-datapath.patch -Patch1: %{name}-%{version}-tmppath.patch -Patch2: %{name}-%{version}-gcc4.patch -Patch3: %{name}-%{version}-misc-fixes.patch BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) BuildRequires: SDL-devel >= 1.2.3, SDL_mixer-devel >= 1.2.3 @@ -22,29 +18,22 @@ A scrolling, platform-jumping, key-collecting, ancient pyramid exploring game, vaguely in the style of similar games for the Commodore+4. %prep -%setup -q -n %{name}-1_0 -# Abe assumes it runs from its build directory and thus assumes everything -# is writable there etc.. ugh: -# Hardcode /usr/share/abe/ paths -%patch0 -p1 -b .datapath -# Write temporary image files into home directory, not data directory -%patch1 -p1 -b .tmppath -%patch2 -p1 -b .gcc4 -%patch3 -p1 -b .miscfix +%setup -q %build -%configure +%configure --with-data-dir=%{_datadir}/%{name} make %{?_smp_mflags} %install rm -rf $RPM_BUILD_ROOT +make DESTDIR=$RPM_BUILD_ROOT install + +# make install does not copy the game data files. mkdir -p $RPM_BUILD_ROOT/%{_datadir}/%{name} mkdir -p $RPM_BUILD_ROOT/%{_datadir}/applications/ mkdir -p $RPM_BUILD_ROOT/%{_datadir}/pixmaps/ -mkdir -p $RPM_BUILD_ROOT/%{_bindir} cp -p -r images maps sounds $RPM_BUILD_ROOT/%{_datadir}/%{name} install -p -m 644 %{SOURCE1} $RPM_BUILD_ROOT/%{_datadir}/pixmaps/ -install -p -m 755 %{name} $RPM_BUILD_ROOT/%{_bindir}/ cat << EOF > %{name}.desktop [Desktop Entry] @@ -74,6 +63,9 @@ rm -rf $RPM_BUILD_ROOT %{_datadir}/pixmaps/* %changelog +* Sat Mar 4 2006 Wart 1.1-1 +- Update to 1.1 + * Sat Mar 4 2006 Wart 1.0-6 - rebuild for FC5 diff --git a/sources b/sources index 8b0da11..41b001f 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -a7e44d5e605b2d32fffdf46f019f7119 abe-1_0.tar.gz +5537920e1746708e1a631d84d3500f5c abe-1.1.tar.gz