rpms/d1x/devel d1x-gcc43.patch, NONE, 1.1 d1x-post-rebirth-fixes.patch, 1.1, 1.2 d1x-use-reg-save-in-sw.patch, 1.1, 1.2 d1x.spec, 1.2, 1.3

Hans de Goede jwrdegoede at rpmfusion.org
Wed Jul 23 16:03:46 CEST 2008


Author: jwrdegoede

Update of /cvs/nonfree/rpms/d1x/devel
In directory se02.es.rpmfusion.net:/tmp/cvs-serv32564

Modified Files:
	d1x-post-rebirth-fixes.patch d1x-use-reg-save-in-sw.patch 
	d1x.spec 
Added Files:
	d1x-gcc43.patch 
Log Message:
* Wed Jul 23 2008 Hans de Goede <j.w.r.degoede at hhs.nl> 1.43-6
- Release bump for rpmfusion build


d1x-gcc43.patch:

--- NEW FILE d1x-gcc43.patch ---
diff -up d1x/main/ipclient.cpp~ d1x/main/ipclient.cpp
--- d1x/main/ipclient.cpp~	2008-07-23 15:53:27.000000000 +0200
+++ d1x/main/ipclient.cpp	2008-07-23 15:53:27.000000000 +0200
@@ -2,6 +2,8 @@
  * ipclient.cpp - udp/ip client code
  * added 2000/02/07 Matt Mueller
  */
+#include <string.h> 
+
 extern "C"{
 #include "mono.h"
 #include "key.h"
diff -up d1x/main/ipserver.cpp~ d1x/main/ipserver.cpp
--- d1x/main/ipserver.cpp~	2008-07-23 15:56:10.000000000 +0200
+++ d1x/main/ipserver.cpp	2008-07-23 15:56:10.000000000 +0200
@@ -4,6 +4,7 @@
  */
 
 #include <stdlib.h>
+#include <string.h>
 #include <sys/types.h>
 #include <sys/time.h>
 #include <signal.h>
diff -up d1x/2d/bitblt.c~ d1x/2d/bitblt.c
--- d1x/2d/bitblt.c~	2008-07-23 16:02:36.000000000 +0200
+++ d1x/2d/bitblt.c	2008-07-23 16:02:36.000000000 +0200
@@ -1026,7 +1026,7 @@ void gr_bm_ubitblt0x_rle(int w, int h, i
 
 // rescalling bitmaps, 10/14/99 Jan Bobrowski jb at wizard.ae.krakow.pl
 
-inline void scale_line(byte *in, byte *out, int ilen, int olen)
+void scale_line(byte *in, byte *out, int ilen, int olen)
 {
 	int a = olen/ilen, b = olen%ilen;
 	int c = 0, i;

d1x-post-rebirth-fixes.patch:

Index: d1x-post-rebirth-fixes.patch
===================================================================
RCS file: /cvs/nonfree/rpms/d1x/devel/d1x-post-rebirth-fixes.patch,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -r1.1 -r1.2
--- d1x-post-rebirth-fixes.patch	23 Jul 2008 12:51:50 -0000	1.1
+++ d1x-post-rebirth-fixes.patch	23 Jul 2008 14:03:46 -0000	1.2
@@ -1,7 +1,7 @@
-diff -ur d1x/main/game.c d1x.new/main/game.c
---- d1x/main/game.c	2006-08-22 07:37:31.000000000 +0200
-+++ d1x.new/main/game.c	2006-08-22 07:26:50.000000000 +0200
-@@ -552,7 +552,6 @@
+diff -up d1x/main/game.c.foo d1x/main/game.c
+--- d1x/main/game.c.foo	2008-07-23 15:33:30.000000000 +0200
++++ d1x/main/game.c	2008-07-23 15:34:07.000000000 +0200
+@@ -554,7 +554,6 @@ u_int32_t			VR_screen_mode		= 0;
  int			VR_render_width	= 0;
  int			VR_render_height	= 0;
  int			VR_render_mode		= VR_NONE;
@@ -9,7 +9,7 @@
  int			VR_low_res 			= 3;				// Default to low res
  int 			VR_show_hud = 1;
  int			VR_sensitivity     = 1;		// 0 - 2
-@@ -1109,16 +1108,15 @@
+@@ -1136,16 +1135,15 @@ void game_init_render_sub_buffers( int x
  
  
  // Sets up the canvases we will be rendering to
@@ -30,7 +30,7 @@
  
  		Game_window_w 		= render_w;
  		Game_window_h		= render_h;
-@@ -1181,12 +1179,6 @@
+@@ -1208,12 +1206,6 @@ void game_init_render_buffers(u_int32_t 
  int set_screen_mode(int sm)
  {
  stop_time();
@@ -43,7 +43,7 @@
  #ifdef EDITOR
  	if ( (sm==SCREEN_MENU) && (Screen_mode==SCREEN_EDITOR) )	{
  		gr_set_current_canvas( Canv_editor );
-@@ -1194,7 +1186,11 @@
+@@ -1221,7 +1213,11 @@ stop_time();
  	}
  #endif
  
@@ -54,12 +54,12 @@
 +		!((sm==SCREEN_MENU) &&
 +			(grd_curscreen->sc_mode != MENU_SCREEN_MODE)) ) {
  		gr_set_current_canvas( &VR_screen_pages[VR_current_page] );
+ //		if ( VR_use_paging )	gr_show_canvas( &VR_screen_pages[VR_current_page] );
  #ifdef OGL
- 		ogl_set_screen_mode();
-diff -ur d1x/main/game.h d1x.new/main/game.h
---- d1x/main/game.h	1999-11-21 14:00:08.000000000 +0100
-+++ d1x.new/main/game.h	2006-08-22 07:14:59.000000000 +0200
-@@ -435,7 +435,7 @@
+diff -up d1x/main/game.h.foo d1x/main/game.h
+--- d1x/main/game.h.foo	1999-11-21 14:00:08.000000000 +0100
++++ d1x/main/game.h	2008-07-23 15:34:07.000000000 +0200
+@@ -435,7 +435,7 @@ extern grs_canvas VR_screen_pages[2];	//
  extern grs_canvas VR_screen_sub_pages[2];	//  Two sub pages of VRAM if paging is available
  extern grs_canvas *VR_offscreen_menu;		// The offscreen data buffer for menus
  
@@ -68,10 +68,10 @@
  extern int maxfps;
  extern int use_nice_fps;
  extern int Allow_primary_cycle;
-diff -ur d1x/main/inferno.c d1x.new/main/inferno.c
---- d1x/main/inferno.c	2006-08-22 07:36:22.000000000 +0200
-+++ d1x.new/main/inferno.c	2006-08-22 07:14:48.000000000 +0200
-@@ -1329,13 +1329,9 @@
+diff -up d1x/main/inferno.c.foo d1x/main/inferno.c
+--- d1x/main/inferno.c.foo	2008-07-23 15:33:30.000000000 +0200
++++ d1x/main/inferno.c	2008-07-23 15:34:07.000000000 +0200
+@@ -1329,13 +1329,9 @@ int main(int argc,char **argv)
  //added on 12/14/98 by Matt Mueller - override res in d1x.ini with command line args
  		int i, argnum=INT_MAX;
  //end addition -MM
@@ -86,7 +86,7 @@
  //aren't #defines great? :)
  
  		SCREENMODE(320,100,0);
-@@ -1353,21 +1349,10 @@
+@@ -1353,21 +1349,10 @@ int main(int argc,char **argv)
  		SCREENMODE(1600,1200,0);
  //end addition -MM
  		
@@ -109,10 +109,10 @@
                  
  	}
  	{
-diff -ur d1x/main/menu.c d1x.new/main/menu.c
---- d1x/main/menu.c	2006-08-22 07:36:37.000000000 +0200
-+++ d1x.new/main/menu.c	2006-08-22 07:36:05.000000000 +0200
-@@ -226,12 +226,6 @@
+diff -up d1x/main/menu.c.foo d1x/main/menu.c
+--- d1x/main/menu.c.foo	2008-07-23 15:33:30.000000000 +0200
++++ d1x/main/menu.c	2008-07-23 15:34:07.000000000 +0200
+@@ -226,12 +226,6 @@ void create_main_menu(newmenu_item *m, i
  
  	set_screen_mode (SCREEN_MENU);
  	
@@ -125,7 +125,7 @@
  
  	ADD_ITEM(TXT_NEW_GAME,MENU_NEW_GAME,KEY_N);
  
-@@ -909,8 +903,6 @@
+@@ -909,8 +903,6 @@ void change_res()
  	u_int32_t modes[12];
  	int i = 0, mc = 0, num_presets = 0;
  	char customres[16];
@@ -134,7 +134,7 @@
  #ifdef GR_SUPPORTS_FULLSCREEN_TOGGLE
   int fullscreenc;
  #endif
-@@ -918,8 +910,6 @@
+@@ -918,8 +910,6 @@ void change_res()
   u_int32_t screen_mode = 0;
   int screen_width = 0;
   int screen_height = 0;
@@ -143,7 +143,7 @@
   
  	m[mc].type = NM_TYPE_RADIO; m[mc].text = "320x200"; m[mc].value = (Game_screen_mode == SM(320,200)); m[mc].group = 0; modes[mc] = SM(320,200); mc++;
  	m[mc].type = NM_TYPE_RADIO; m[mc].text = "640x480"; m[mc].value = (Game_screen_mode == SM(640,480)); m[mc].group = 0; modes[mc] = SM(640,480); mc++;
-@@ -980,18 +970,15 @@
+@@ -980,18 +970,15 @@ void change_res()
  	if (screen_height <= 0 || screen_width <= 0)
  		return;
  
@@ -169,7 +169,7 @@
          
  
          mprintf( (0, "\nInitializing palette system..." ));
-@@ -1005,7 +992,6 @@
+@@ -1005,7 +992,6 @@ void change_res()
    last_drawn_cockpit[0]=-1;
    last_drawn_cockpit[1]=-1;
     vr_reset_display();
@@ -177,10 +177,10 @@
  }
  
  
-diff -ur d1x/main/playsave.c d1x.new/main/playsave.c
---- d1x/main/playsave.c	2006-08-22 07:36:37.000000000 +0200
-+++ d1x.new/main/playsave.c	2006-08-22 07:29:46.000000000 +0200
-@@ -1394,10 +1394,19 @@
+diff -up d1x/main/playsave.c.foo d1x/main/playsave.c
+--- d1x/main/playsave.c.foo	2008-07-23 15:33:30.000000000 +0200
++++ d1x/main/playsave.c	2008-07-23 15:34:07.000000000 +0200
+@@ -1394,10 +1394,19 @@ int read_player_file()
  		kc_set_controls();
  	}
  

d1x-use-reg-save-in-sw.patch:

Index: d1x-use-reg-save-in-sw.patch
===================================================================
RCS file: /cvs/nonfree/rpms/d1x/devel/d1x-use-reg-save-in-sw.patch,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -r1.1 -r1.2
--- d1x-use-reg-save-in-sw.patch	23 Jul 2008 12:51:50 -0000	1.1
+++ d1x-use-reg-save-in-sw.patch	23 Jul 2008 14:03:46 -0000	1.2
@@ -1,7 +1,7 @@
-diff -ur d1x.orig/main/game.c d1x/main/game.c
---- d1x.orig/main/game.c	2006-09-23 21:58:59.000000000 +0200
-+++ d1x/main/game.c	2006-09-23 21:08:43.000000000 +0200
-@@ -4001,16 +4001,8 @@
+diff -up d1x/main/game.c.foo d1x/main/game.c
+--- d1x/main/game.c.foo	2008-07-23 15:37:03.000000000 +0200
++++ d1x/main/game.c	2008-07-23 15:37:17.000000000 +0200
+@@ -4026,16 +4026,8 @@ void ReadControls()
  					Function_mode=FMODE_EXIT;
  					break;
  
@@ -18,10 +18,10 @@
  
                                  //use function keys for window sizing
  
-diff -ur d1x.orig/main/menu.c d1x/main/menu.c
---- d1x.orig/main/menu.c	2006-09-23 21:58:49.000000000 +0200
-+++ d1x/main/menu.c	2006-09-23 21:54:24.000000000 +0200
-@@ -228,11 +228,6 @@
+diff -up d1x/main/menu.c.foo d1x/main/menu.c
+--- d1x/main/menu.c.foo	2008-07-23 15:37:03.000000000 +0200
++++ d1x/main/menu.c	2008-07-23 15:37:17.000000000 +0200
+@@ -228,11 +228,6 @@ void create_main_menu(newmenu_item *m, i
  	
  
  	ADD_ITEM(TXT_NEW_GAME,MENU_NEW_GAME,KEY_N);
@@ -33,7 +33,7 @@
    	ADD_ITEM(TXT_LOAD_GAME,MENU_LOAD_GAME,KEY_L);
  
  #ifdef NETWORK
-@@ -342,11 +337,7 @@
+@@ -342,11 +337,7 @@ void do_option ( int select) 
  			}
  			break;
  		case MENU_LOAD_GAME:
@@ -45,10 +45,10 @@
  			break;
  		#ifdef EDITOR
  		case MENU_EDITOR:
-diff -ur d1x.orig/main/playsave.c d1x/main/playsave.c
---- d1x.orig/main/playsave.c	2006-09-23 21:58:49.000000000 +0200
-+++ d1x/main/playsave.c	2006-09-23 22:04:50.000000000 +0200
-@@ -1474,9 +1474,8 @@
+diff -up d1x/main/playsave.c.foo d1x/main/playsave.c
+--- d1x/main/playsave.c.foo	2008-07-23 15:37:04.000000000 +0200
++++ d1x/main/playsave.c	2008-07-23 15:37:17.000000000 +0200
+@@ -1474,9 +1474,8 @@ int read_player_file()
  	if (fclose(file) && errno_ret==EZERO)
  		errno_ret = errno;
  
@@ -60,7 +60,7 @@
  		
  		Assert( N_SAVE_SLOTS == 10 );
  
-@@ -1485,11 +1484,15 @@
+@@ -1485,11 +1484,15 @@ int read_player_file()
  				state_save_old_game(i, saved_games[i].name, &saved_games[i].player, 
               		saved_games[i].difficulty_level, saved_games[i].primary_weapon, 
            			saved_games[i].secondary_weapon, saved_games[i].next_level_num );
@@ -78,11 +78,11 @@
  
  	filename[strlen(filename) - 4] = 0;
  	strcat(filename, ".plx");
-diff -ur d1x.orig/main/state.c d1x/main/state.c
---- d1x.orig/main/state.c	2006-09-23 21:58:59.000000000 +0200
-+++ d1x/main/state.c	2006-09-23 21:42:03.000000000 +0200
-@@ -277,8 +277,6 @@
- #endif
+diff -up d1x/main/state.c.foo d1x/main/state.c
+--- d1x/main/state.c.foo	2000-10-27 01:58:45.000000000 +0200
++++ d1x/main/state.c	2008-07-23 15:37:17.000000000 +0200
+@@ -274,8 +274,6 @@ static char rcsid[] = "$Id: state.c,v 1.
+ #include "gamefont.h"
  
  
 -#ifndef SHAREWARE
@@ -90,7 +90,7 @@
  #define STATE_VERSION 7
  #define STATE_COMPATIBLE_VERSION 6
  // 0 - Put DGSS (Descent Game State Save) id at tof.
-@@ -351,6 +349,7 @@
+@@ -348,6 +346,7 @@ void state_callback(int nitems,newmenu_i
  //	}	
  }
  
@@ -98,7 +98,7 @@
  void rpad_string( char * string, int max_chars )
  {
  	int i, end_found;
-@@ -365,6 +364,7 @@
+@@ -362,6 +361,7 @@ void rpad_string( char * string, int max
  	}
  	*string = 0;		// NULL terminate
  }
@@ -106,7 +106,7 @@
  
  int state_get_save_file(char * fname, char * dsc, int multi )
  {
-@@ -580,8 +580,11 @@
+@@ -577,8 +577,11 @@ int state_save_old_game(int slotnum, cha
  	fwrite( &temp_int, sizeof(int), 1, fp );
  
  // Save the mission info...
@@ -119,7 +119,7 @@
  //Save level info
  	temp_int = sg_player->level;
  	fwrite( &temp_int, sizeof(int), 1, fp );
-@@ -628,6 +631,7 @@
+@@ -625,6 +628,7 @@ int state_save_all(int between_levels)
  {
  	char filename[128], desc[DESC_LENGTH+1];
  
@@ -127,7 +127,7 @@
  	if ( Game_mode & GM_MULTI )	{
  #ifdef MULTI_SAVE
  		if ( FindArg( "-multisave" ) )
-@@ -637,6 +641,7 @@
+@@ -634,6 +638,7 @@ int state_save_all(int between_levels)
  			hud_message( MSGC_GAME_FEEDBACK, "Can't save in a multiplayer game!" );
  		return 0;
  	}
@@ -135,7 +135,7 @@
  
  	mprintf(( 0, "CL=%d, NL=%d\n", Current_level_num, Next_level_num ));
  	
-@@ -656,12 +661,14 @@
+@@ -653,12 +658,14 @@ int state_save_all_sub(char *filename, c
  	FILE * fp;
  	grs_canvas * cnv;
  
@@ -150,7 +150,7 @@
  
  	fp = fopen( filename, "wb" );
  	if ( !fp ) {
-@@ -727,7 +734,11 @@
+@@ -721,7 +728,11 @@ int state_save_all_sub(char *filename, c
  	fwrite( &between_levels, sizeof(int), 1, fp );
  
  // Save the mission info...
@@ -162,7 +162,7 @@
  
  //Save level info
  	fwrite( &Current_level_num, sizeof(int), 1, fp );
-@@ -927,15 +938,32 @@
+@@ -921,15 +932,32 @@ int state_restore_all_sub(char *filename
  // Read the mission info...
  	fread( mission, sizeof(char)*9, 1, fp );
  
@@ -195,7 +195,7 @@
  
  //Restore GameTime
  	fread( &GameTime, sizeof(fix), 1, fp );
-@@ -1133,6 +1161,3 @@
+@@ -1127,6 +1155,3 @@ RetryObjectLoading:
  
  	return 1;
  }


Index: d1x.spec
===================================================================
RCS file: /cvs/nonfree/rpms/d1x/devel/d1x.spec,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -r1.2 -r1.3
--- d1x.spec	23 Jul 2008 13:05:51 -0000	1.2
+++ d1x.spec	23 Jul 2008 14:03:46 -0000	1.3
@@ -45,6 +45,8 @@
 Patch37:        d1x-playerfile-compat.patch
 Patch38:        d1x-use-reg-save-in-sw.patch
 Patch39:        d1x-playerfile-compat-fix.patch
+# and patches added much later to keep things compiling with the latest gcc
+Patch40:        d1x-gcc43.patch
 URL:		http://d1x.warpcore.org/
 BuildRoot:	%{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
 BuildRequires:	SDL-devel >= 1.1
@@ -124,6 +126,8 @@
 %patch38 -p1
 %patch39 -p1
 
+%patch40 -p1
+
 
 %build
 mkdir -p lib



More information about the rpmfusion-commits mailing list