rpms/tremulous/devel tremulous-1.1.0-syslibs.patch, 1.1, 1.2 tremulous.spec, 1.3, 1.4

Hans de Goede (jwrdegoede) fedora-extras-commits at redhat.com
Wed Sep 26 21:07:52 UTC 2007


Author: jwrdegoede

Update of /cvs/extras/rpms/tremulous/devel
In directory cvs-int.fedora.redhat.com:/tmp/cvs-serv11864

Modified Files:
	tremulous-1.1.0-syslibs.patch tremulous.spec 
Log Message:
* Wed Sep 26 2007 Hans de Goede <j.w.r.degoede at hhs.nl> 1.1.0-5
- Update syslibs patch to make the system libjpeg use tremulous' Malloc and
  Free functions, instead of the libc ones


tremulous-1.1.0-syslibs.patch:

Index: tremulous-1.1.0-syslibs.patch
===================================================================
RCS file: /cvs/extras/rpms/tremulous/devel/tremulous-1.1.0-syslibs.patch,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -r1.1 -r1.2
--- tremulous-1.1.0-syslibs.patch	5 Sep 2006 11:34:55 -0000	1.1
+++ tremulous-1.1.0-syslibs.patch	26 Sep 2007 21:07:49 -0000	1.2
@@ -1,164 +1,116 @@
---- tremulous/tremulous-1.1.0-src/Makefile.syslibs	2006-03-21 23:28:25.000000000 +0100
-+++ tremulous/tremulous-1.1.0-src/Makefile	2006-08-25 11:51:03.000000000 +0200
-@@ -97,6 +97,10 @@
- USE_OPENAL=1
- endif
- 
-+ifndef USE_SYSTEM_JPEG
-+USE_SYSTEM_JPEG=1
-+endif
+diff -up /dev/null tremulous-1.1.0-src/src/renderer/jpeg_memsrc.h
+--- /dev/null	2007-09-26 21:33:53.271006802 +0200
++++ tremulous-1.1.0-src/src/renderer/jpeg_memsrc.h	2007-09-26 22:46:39.000000000 +0200
+@@ -0,0 +1,5 @@
++#include <stdio.h>
++#include <jpeglib.h>
 +
- ifndef USE_OPENAL_DLOPEN
- USE_OPENAL_DLOPEN=0
- endif
-@@ -178,7 +182,7 @@
-   endif
-   endif
++void jpeg_memory_src (j_decompress_ptr cinfo, const JOCTET * buffer,
++  size_t bufsize);
+diff -up tremulous-1.1.0-src/src/renderer/tr_image.c.syslibs tremulous-1.1.0-src/src/renderer/tr_image.c
+--- tremulous-1.1.0-src/src/renderer/tr_image.c.syslibs	2006-01-05 05:00:54.000000000 +0100
++++ tremulous-1.1.0-src/src/renderer/tr_image.c	2007-09-26 22:46:39.000000000 +0200
+@@ -31,9 +31,13 @@ Foundation, Inc., 51 Franklin St, Fifth 
+  * You may also wish to include "jerror.h".
+  */
  
--  BASE_CFLAGS = -Wall -fno-strict-aliasing -Wimplicit -Wstrict-prototypes -pipe
-+  BASE_CFLAGS = 
++#ifdef USE_SYSTEM_JPEG
++#include <jpeglib.h>
++#include "jpeg_memsrc.h"
++#else
+ #define JPEG_INTERNALS
+ #include "../jpeg-6/jpeglib.h"
+-
++#endif
  
-   ifeq ($(USE_OPENAL),1)
-     BASE_CFLAGS += -DUSE_OPENAL=1
-@@ -191,6 +195,10 @@
-     BASE_CFLAGS += -DUSE_CODEC_VORBIS=1
-   endif
+ static void LoadBMP( const char *name, byte **pic, int *width, int *height );
+ static void LoadTGA( const char *name, byte **pic, int *width, int *height );
+@@ -1399,6 +1403,11 @@ static void LoadJPG( const char *filenam
+   unsigned char *out;
+   byte	*fbuffer;
+   byte  *buf;
++  size_t bufsize;
++#ifdef USE_SYSTEM_JPEG
++  int i,j;
++  byte *inptr, *outptr;
++#endif
  
-+  ifeq ($(USE_SYSTEM_JPEG),1)
-+    BASE_CFLAGS += -DUSE_SYSTEM_JPEG=1
-+  endif
-+
-   ifeq ($(USE_SDL),1)
-     BASE_CFLAGS += -DUSE_SDL_VIDEO=1 -DUSE_SDL_SOUND=1 $(shell sdl-config --cflags)
-     GL_CFLAGS =
-@@ -253,6 +261,10 @@
-     CLIENT_LDFLAGS += -lvorbisfile -lvorbis -logg
-   endif
+   /* In this example we want to open the input file before doing anything else,
+    * so that the setjmp() error recovery below can assume the file is open.
+@@ -1406,7 +1415,7 @@ static void LoadJPG( const char *filenam
+    * requires it in order to read binary files.
+    */
  
-+  ifeq ($(USE_SYSTEM_JPEG),1)
-+    CLIENT_LDFLAGS += -ljpeg
-+  endif
-+
-   ifeq ($(ARCH),x86)
-     # linux32 make ...
-     BASE_CFLAGS += -m32
-@@ -842,41 +854,6 @@
-   $(B)/client/l_script.o \
-   $(B)/client/l_struct.o \
-   \
--  $(B)/client/jcapimin.o \
--  $(B)/client/jchuff.o   \
--  $(B)/client/jcinit.o \
--  $(B)/client/jccoefct.o  \
--  $(B)/client/jccolor.o \
--  $(B)/client/jfdctflt.o \
--  $(B)/client/jcdctmgr.o \
--  $(B)/client/jcphuff.o \
--  $(B)/client/jcmainct.o \
--  $(B)/client/jcmarker.o \
--  $(B)/client/jcmaster.o \
--  $(B)/client/jcomapi.o \
--  $(B)/client/jcparam.o \
--  $(B)/client/jcprepct.o \
--  $(B)/client/jcsample.o \
--  $(B)/client/jdapimin.o \
--  $(B)/client/jdapistd.o \
--  $(B)/client/jdatasrc.o \
--  $(B)/client/jdcoefct.o \
--  $(B)/client/jdcolor.o \
--  $(B)/client/jddctmgr.o \
--  $(B)/client/jdhuff.o \
--  $(B)/client/jdinput.o \
--  $(B)/client/jdmainct.o \
--  $(B)/client/jdmarker.o \
--  $(B)/client/jdmaster.o \
--  $(B)/client/jdpostct.o \
--  $(B)/client/jdsample.o \
--  $(B)/client/jdtrans.o \
--  $(B)/client/jerror.o \
--  $(B)/client/jidctflt.o \
--  $(B)/client/jmemmgr.o \
--  $(B)/client/jmemnobs.o \
--  $(B)/client/jutils.o \
--  \
-   $(B)/client/tr_animation.o \
-   $(B)/client/tr_backend.o \
-   $(B)/client/tr_bsp.o \
-@@ -899,7 +876,47 @@
-   $(B)/client/tr_shadows.o \
-   $(B)/client/tr_sky.o \
-   $(B)/client/tr_surface.o \
--  $(B)/client/tr_world.o \
-+  $(B)/client/tr_world.o
+-  ri.FS_ReadFile ( ( char * ) filename, (void **)&fbuffer);
++  bufsize = ri.FS_ReadFile ( ( char * ) filename, (void **)&fbuffer);
+   if (!fbuffer) {
+ 	return;
+   }
+@@ -1424,8 +1433,11 @@ static void LoadJPG( const char *filenam
+   jpeg_create_decompress(&cinfo);
+ 
+   /* Step 2: specify data source (eg, a file) */
+-
++#ifdef USE_SYSTEM_JPEG
++  jpeg_memory_src(&cinfo, fbuffer, bufsize);
++#else /* ???????? */
+   jpeg_stdio_src(&cinfo, fbuffer);
++#endif
+ 
+   /* Step 3: read file parameters with jpeg_read_header() */
+ 
+@@ -1468,7 +1480,7 @@ static void LoadJPG( const char *filenam
+   }
+ 
+   memcount = pixelcount * 4;
+-  row_stride = cinfo.output_width * cinfo.output_components;
++  row_stride = cinfo.output_width * 4;
+ 
+   out = ri.Malloc(memcount);
+ 
+@@ -1489,6 +1501,21 @@ static void LoadJPG( const char *filenam
+ 	buf = ((out+(row_stride*cinfo.output_scanline)));
+ 	buffer = &buf;
+     (void) jpeg_read_scanlines(&cinfo, buffer, 1);
++#ifdef USE_SYSTEM_JPEG
++    /* we have RGB data, we need to expand this out to ARGB */
++    inptr = buf + cinfo.output_width * 3 - 1;
++    outptr = buf + row_stride - 1;
 +
-+ifneq ($(USE_SYSTEM_JPEG),1)
-+  Q3OBJ += \
-+    $(B)/client/jcapimin.o \
-+    $(B)/client/jchuff.o   \
-+    $(B)/client/jcinit.o \
-+    $(B)/client/jccoefct.o  \
-+    $(B)/client/jccolor.o \
-+    $(B)/client/jfdctflt.o \
-+    $(B)/client/jcdctmgr.o \
-+    $(B)/client/jcphuff.o \
-+    $(B)/client/jcmainct.o \
-+    $(B)/client/jcmarker.o \
-+    $(B)/client/jcmaster.o \
-+    $(B)/client/jcomapi.o \
-+    $(B)/client/jcparam.o \
-+    $(B)/client/jcprepct.o \
-+    $(B)/client/jcsample.o \
-+    $(B)/client/jdapimin.o \
-+    $(B)/client/jdapistd.o \
-+    $(B)/client/jdatasrc.o \
-+    $(B)/client/jdcoefct.o \
-+    $(B)/client/jdcolor.o \
-+    $(B)/client/jddctmgr.o \
-+    $(B)/client/jdhuff.o \
-+    $(B)/client/jdinput.o \
-+    $(B)/client/jdmainct.o \
-+    $(B)/client/jdmarker.o \
-+    $(B)/client/jdmaster.o \
-+    $(B)/client/jdpostct.o \
-+    $(B)/client/jdsample.o \
-+    $(B)/client/jdtrans.o \
-+    $(B)/client/jerror.o \
-+    $(B)/client/jidctflt.o \
-+    $(B)/client/jmemmgr.o \
-+    $(B)/client/jmemnobs.o \
-+    $(B)/client/jutils.o
-+else
-+Q3OBJ += $(B)/client/jpeg_memsrc.o
-+endif
++    for (i = 0; i < cinfo.output_width; i++) {
++      /* endian dependent? maybe for big endian this must be done after the
++         color/pixel copy? */
++      *outptr-- = 255;
++      for (j = 0; j < 3; j++) {
++        JOCTET color = *inptr--;
++        *outptr-- = color;
++      }
++    }
++#endif
+   }
+   
+   buf = out;
+@@ -1608,6 +1635,8 @@ boolean empty_output_buffer (j_compress_
+ }
  
- ifeq ($(ARCH),x86)
-   Q3OBJ += $(B)/client/vm_x86.o
-@@ -1056,6 +1073,7 @@
- $(B)/client/l_script.o : $(BLIBDIR)/l_script.c; $(DO_BOT_CC)
- $(B)/client/l_struct.o : $(BLIBDIR)/l_struct.c; $(DO_BOT_CC)
  
-+ifneq ($(USE_SYSTEM_JPEG),1)
- $(B)/client/jcapimin.o : $(JPDIR)/jcapimin.c; $(DO_CC)
- $(B)/client/jchuff.o : $(JPDIR)/jchuff.c; $(DO_CC)
- $(B)/client/jcinit.o : $(JPDIR)/jcinit.c; $(DO_CC)
-@@ -1091,6 +1109,7 @@
- $(B)/client/jmemmgr.o : $(JPDIR)/jmemmgr.c; $(DO_CC)
- $(B)/client/jmemnobs.o : $(JPDIR)/jmemnobs.c; $(DO_CC)  $(GL_CFLAGS) $(MINGW_CFLAGS)
- $(B)/client/jutils.o : $(JPDIR)/jutils.c; $(DO_CC)
-+endif
++#ifndef USE_SYSTEM_JPEG
++
+ /*
+  * Compression initialization.
+  * Before calling this, all parameters and a data destination must be set up.
+@@ -1699,6 +1728,8 @@ jpeg_write_scanlines (j_compress_ptr cin
+   return row_ctr;
+ }
  
- $(B)/client/tr_bsp.o : $(RDIR)/tr_bsp.c; $(DO_CC)  $(GL_CFLAGS)
- $(B)/client/tr_animation.o : $(RDIR)/tr_animation.c; $(DO_CC)  $(GL_CFLAGS)
-@@ -1100,6 +1119,7 @@
- $(B)/client/tr_flares.o : $(RDIR)/tr_flares.c; $(DO_CC)  $(GL_CFLAGS)
- $(B)/client/tr_font.o : $(RDIR)/tr_font.c; $(DO_CC)   $(GL_CFLAGS)
- $(B)/client/tr_image.o : $(RDIR)/tr_image.c; $(DO_CC)   $(GL_CFLAGS) $(MINGW_CFLAGS)
-+$(B)/client/jpeg_memsrc.o : $(RDIR)/jpeg_memsrc.c; $(DO_CC)   $(GL_CFLAGS)
- $(B)/client/tr_init.o : $(RDIR)/tr_init.c; $(DO_CC)    $(GL_CFLAGS)
- $(B)/client/tr_light.o : $(RDIR)/tr_light.c; $(DO_CC)  $(GL_CFLAGS)
- $(B)/client/tr_main.o : $(RDIR)/tr_main.c; $(DO_CC)   $(GL_CFLAGS)
---- /dev/null	2006-08-25 12:00:12.687785000 +0200
-+++ tremulous/tremulous-1.1.0-src/src/renderer/jpeg_memsrc.c	2006-08-25 11:51:03.000000000 +0200
++#endif
++
+ /*
+  * Terminate destination --- called by jpeg_finish_compress
+  * after all data has been written.  Usually needs to flush buffer.
+diff -up /dev/null tremulous-1.1.0-src/src/renderer/jpeg_memsrc.c
+--- /dev/null	2007-09-26 21:33:53.271006802 +0200
++++ tremulous-1.1.0-src/src/renderer/jpeg_memsrc.c	2007-09-26 22:46:39.000000000 +0200
 @@ -0,0 +1,163 @@
 +/*
 +* memsrc.c
@@ -323,111 +275,205 @@
 +src->pub.next_input_byte = buffer;
 +src->pub.bytes_in_buffer = bufsize;
 +}
---- /dev/null	2006-08-25 12:00:12.687785000 +0200
-+++ tremulous/tremulous-1.1.0-src/src/renderer/jpeg_memsrc.h	2006-08-25 11:51:03.000000000 +0200
-@@ -0,0 +1,5 @@
-+#include <stdio.h>
-+#include <jpeglib.h>
-+
-+void jpeg_memory_src (j_decompress_ptr cinfo, const JOCTET * buffer,
-+  size_t bufsize);
---- tremulous/tremulous-1.1.0-src/src/renderer/tr_image.c.syslibs	2006-01-05 05:00:54.000000000 +0100
-+++ tremulous/tremulous-1.1.0-src/src/renderer/tr_image.c	2006-08-25 14:31:12.000000000 +0200
-@@ -31,9 +31,13 @@
-  * You may also wish to include "jerror.h".
+diff -up tremulous-1.1.0-src/src/jpeg-6/jmemnobs.c.syslibs tremulous-1.1.0-src/src/jpeg-6/jmemnobs.c
+--- tremulous-1.1.0-src/src/jpeg-6/jmemnobs.c.syslibs	2007-09-26 22:47:34.000000000 +0200
++++ tremulous-1.1.0-src/src/jpeg-6/jmemnobs.c	2007-09-26 22:47:47.000000000 +0200
+@@ -15,10 +15,23 @@
+  * Note that the max_memory_to_use option is ignored by this implementation.
   */
  
 +#ifdef USE_SYSTEM_JPEG
++#include <stdio.h>
++#include <stdlib.h>
 +#include <jpeglib.h>
-+#include "jpeg_memsrc.h"
++
++#undef GLOBAL
++#define GLOBAL
++#define FAR
++
++typedef void * backing_store_ptr;
++
 +#else
  #define JPEG_INTERNALS
- #include "../jpeg-6/jpeglib.h"
--
+ #include "jinclude.h"
+ #include "jpeglib.h"
+ #include "jmemsys.h"		/* import the system-dependent declarations */
 +#endif
  
- static void LoadBMP( const char *name, byte **pic, int *width, int *height );
- static void LoadTGA( const char *name, byte **pic, int *width, int *height );
-@@ -1399,6 +1403,11 @@
-   unsigned char *out;
-   byte	*fbuffer;
-   byte  *buf;
-+  size_t bufsize;
+ #include "../renderer/tr_local.h"
+ 
+@@ -83,7 +96,13 @@ GLOBAL void
+ jpeg_open_backing_store (j_common_ptr cinfo, backing_store_ptr info,
+ 			 long total_bytes_needed)
+ {
 +#ifdef USE_SYSTEM_JPEG
-+  int i,j;
-+  byte *inptr, *outptr;
++  fprintf(stderr,
++    "jmemnobs.c: jpeg_open_backing_store() call, this should never happen!\n");
++  exit(1);
++#else
+   ERREXIT(cinfo, JERR_NO_BACKING_STORE);
 +#endif
+ }
  
-   /* In this example we want to open the input file before doing anything else,
-    * so that the setjmp() error recovery below can assume the file is open.
-@@ -1406,7 +1415,7 @@
-    * requires it in order to read binary files.
-    */
- 
--  ri.FS_ReadFile ( ( char * ) filename, (void **)&fbuffer);
-+  bufsize = ri.FS_ReadFile ( ( char * ) filename, (void **)&fbuffer);
-   if (!fbuffer) {
- 	return;
-   }
-@@ -1424,8 +1433,11 @@
-   jpeg_create_decompress(&cinfo);
  
-   /* Step 2: specify data source (eg, a file) */
--
-+#ifdef USE_SYSTEM_JPEG
-+  jpeg_memory_src(&cinfo, fbuffer, bufsize);
-+#else /* ???????? */
-   jpeg_stdio_src(&cinfo, fbuffer);
-+#endif
+diff -up tremulous-1.1.0-src/Makefile.syslibs tremulous-1.1.0-src/Makefile
+--- tremulous-1.1.0-src/Makefile.syslibs	2006-03-21 23:28:25.000000000 +0100
++++ tremulous-1.1.0-src/Makefile	2007-09-26 22:50:38.000000000 +0200
+@@ -97,6 +97,10 @@ ifndef USE_OPENAL
+ USE_OPENAL=1
+ endif
  
-   /* Step 3: read file parameters with jpeg_read_header() */
++ifndef USE_SYSTEM_JPEG
++USE_SYSTEM_JPEG=1
++endif
++
+ ifndef USE_OPENAL_DLOPEN
+ USE_OPENAL_DLOPEN=0
+ endif
+@@ -178,7 +182,7 @@ ifeq ($(PLATFORM),linux)
+   endif
+   endif
  
-@@ -1468,7 +1480,7 @@
-   }
+-  BASE_CFLAGS = -Wall -fno-strict-aliasing -Wimplicit -Wstrict-prototypes -pipe
++  BASE_CFLAGS = 
  
-   memcount = pixelcount * 4;
--  row_stride = cinfo.output_width * cinfo.output_components;
-+  row_stride = cinfo.output_width * 4;
+   ifeq ($(USE_OPENAL),1)
+     BASE_CFLAGS += -DUSE_OPENAL=1
+@@ -191,6 +195,10 @@ ifeq ($(PLATFORM),linux)
+     BASE_CFLAGS += -DUSE_CODEC_VORBIS=1
+   endif
  
-   out = ri.Malloc(memcount);
++  ifeq ($(USE_SYSTEM_JPEG),1)
++    BASE_CFLAGS += -DUSE_SYSTEM_JPEG=1
++  endif
++
+   ifeq ($(USE_SDL),1)
+     BASE_CFLAGS += -DUSE_SDL_VIDEO=1 -DUSE_SDL_SOUND=1 $(shell sdl-config --cflags)
+     GL_CFLAGS =
+@@ -253,6 +261,10 @@ ifeq ($(PLATFORM),linux)
+     CLIENT_LDFLAGS += -lvorbisfile -lvorbis -logg
+   endif
  
-@@ -1489,6 +1501,21 @@
- 	buf = ((out+(row_stride*cinfo.output_scanline)));
- 	buffer = &buf;
-     (void) jpeg_read_scanlines(&cinfo, buffer, 1);
-+#ifdef USE_SYSTEM_JPEG
-+    /* we have RGB data, we need to expand this out to ARGB */
-+    inptr = buf + cinfo.output_width * 3 - 1;
-+    outptr = buf + row_stride - 1;
++  ifeq ($(USE_SYSTEM_JPEG),1)
++    CLIENT_LDFLAGS += -ljpeg
++  endif
 +
-+    for (i = 0; i < cinfo.output_width; i++) {
-+      /* endian dependent? maybe for big endian this must be done after the
-+         color/pixel copy? */
-+      *outptr-- = 255;
-+      for (j = 0; j < 3; j++) {
-+        JOCTET color = *inptr--;
-+        *outptr-- = color;
-+      }
-+    }
-+#endif
-   }
-   
-   buf = out;
-@@ -1608,6 +1635,8 @@
- }
+   ifeq ($(ARCH),x86)
+     # linux32 make ...
+     BASE_CFLAGS += -m32
+@@ -842,40 +854,7 @@ Q3OBJ = \
+   $(B)/client/l_script.o \
+   $(B)/client/l_struct.o \
+   \
+-  $(B)/client/jcapimin.o \
+-  $(B)/client/jchuff.o   \
+-  $(B)/client/jcinit.o \
+-  $(B)/client/jccoefct.o  \
+-  $(B)/client/jccolor.o \
+-  $(B)/client/jfdctflt.o \
+-  $(B)/client/jcdctmgr.o \
+-  $(B)/client/jcphuff.o \
+-  $(B)/client/jcmainct.o \
+-  $(B)/client/jcmarker.o \
+-  $(B)/client/jcmaster.o \
+-  $(B)/client/jcomapi.o \
+-  $(B)/client/jcparam.o \
+-  $(B)/client/jcprepct.o \
+-  $(B)/client/jcsample.o \
+-  $(B)/client/jdapimin.o \
+-  $(B)/client/jdapistd.o \
+-  $(B)/client/jdatasrc.o \
+-  $(B)/client/jdcoefct.o \
+-  $(B)/client/jdcolor.o \
+-  $(B)/client/jddctmgr.o \
+-  $(B)/client/jdhuff.o \
+-  $(B)/client/jdinput.o \
+-  $(B)/client/jdmainct.o \
+-  $(B)/client/jdmarker.o \
+-  $(B)/client/jdmaster.o \
+-  $(B)/client/jdpostct.o \
+-  $(B)/client/jdsample.o \
+-  $(B)/client/jdtrans.o \
+-  $(B)/client/jerror.o \
+-  $(B)/client/jidctflt.o \
+-  $(B)/client/jmemmgr.o \
+   $(B)/client/jmemnobs.o \
+-  $(B)/client/jutils.o \
+   \
+   $(B)/client/tr_animation.o \
+   $(B)/client/tr_backend.o \
+@@ -899,7 +878,46 @@ Q3OBJ = \
+   $(B)/client/tr_shadows.o \
+   $(B)/client/tr_sky.o \
+   $(B)/client/tr_surface.o \
+-  $(B)/client/tr_world.o \
++  $(B)/client/tr_world.o
++
++ifneq ($(USE_SYSTEM_JPEG),1)
++  Q3OBJ += \
++    $(B)/client/jcapimin.o \
++    $(B)/client/jchuff.o   \
++    $(B)/client/jcinit.o \
++    $(B)/client/jccoefct.o  \
++    $(B)/client/jccolor.o \
++    $(B)/client/jfdctflt.o \
++    $(B)/client/jcdctmgr.o \
++    $(B)/client/jcphuff.o \
++    $(B)/client/jcmainct.o \
++    $(B)/client/jcmarker.o \
++    $(B)/client/jcmaster.o \
++    $(B)/client/jcomapi.o \
++    $(B)/client/jcparam.o \
++    $(B)/client/jcprepct.o \
++    $(B)/client/jcsample.o \
++    $(B)/client/jdapimin.o \
++    $(B)/client/jdapistd.o \
++    $(B)/client/jdatasrc.o \
++    $(B)/client/jdcoefct.o \
++    $(B)/client/jdcolor.o \
++    $(B)/client/jddctmgr.o \
++    $(B)/client/jdhuff.o \
++    $(B)/client/jdinput.o \
++    $(B)/client/jdmainct.o \
++    $(B)/client/jdmarker.o \
++    $(B)/client/jdmaster.o \
++    $(B)/client/jdpostct.o \
++    $(B)/client/jdsample.o \
++    $(B)/client/jdtrans.o \
++    $(B)/client/jerror.o \
++    $(B)/client/jidctflt.o \
++    $(B)/client/jmemmgr.o \
++    $(B)/client/jutils.o
++else
++Q3OBJ += $(B)/client/jpeg_memsrc.o
++endif
  
+ ifeq ($(ARCH),x86)
+   Q3OBJ += $(B)/client/vm_x86.o
+@@ -1056,6 +1074,7 @@ $(B)/client/l_precomp.o : $(BLIBDIR)/l_p
+ $(B)/client/l_script.o : $(BLIBDIR)/l_script.c; $(DO_BOT_CC)
+ $(B)/client/l_struct.o : $(BLIBDIR)/l_struct.c; $(DO_BOT_CC)
  
-+#ifndef USE_SYSTEM_JPEG
-+
- /*
-  * Compression initialization.
-  * Before calling this, all parameters and a data destination must be set up.
-@@ -1699,6 +1728,8 @@
-   return row_ctr;
- }
++ifneq ($(USE_SYSTEM_JPEG),1)
+ $(B)/client/jcapimin.o : $(JPDIR)/jcapimin.c; $(DO_CC)
+ $(B)/client/jchuff.o : $(JPDIR)/jchuff.c; $(DO_CC)
+ $(B)/client/jcinit.o : $(JPDIR)/jcinit.c; $(DO_CC)
+@@ -1089,8 +1108,9 @@ $(B)/client/jdtrans.o : $(JPDIR)/jdtrans
+ $(B)/client/jerror.o : $(JPDIR)/jerror.c; $(DO_CC) $(GL_CFLAGS) $(MINGW_CFLAGS)
+ $(B)/client/jidctflt.o : $(JPDIR)/jidctflt.c; $(DO_CC)
+ $(B)/client/jmemmgr.o : $(JPDIR)/jmemmgr.c; $(DO_CC)
+-$(B)/client/jmemnobs.o : $(JPDIR)/jmemnobs.c; $(DO_CC)  $(GL_CFLAGS) $(MINGW_CFLAGS)
+ $(B)/client/jutils.o : $(JPDIR)/jutils.c; $(DO_CC)
++endif
++$(B)/client/jmemnobs.o : $(JPDIR)/jmemnobs.c; $(DO_CC)  $(GL_CFLAGS) $(MINGW_CFLAGS)
  
-+#endif
-+
- /*
-  * Terminate destination --- called by jpeg_finish_compress
-  * after all data has been written.  Usually needs to flush buffer.
+ $(B)/client/tr_bsp.o : $(RDIR)/tr_bsp.c; $(DO_CC)  $(GL_CFLAGS)
+ $(B)/client/tr_animation.o : $(RDIR)/tr_animation.c; $(DO_CC)  $(GL_CFLAGS)
+@@ -1100,6 +1120,7 @@ $(B)/client/tr_curve.o : $(RDIR)/tr_curv
+ $(B)/client/tr_flares.o : $(RDIR)/tr_flares.c; $(DO_CC)  $(GL_CFLAGS)
+ $(B)/client/tr_font.o : $(RDIR)/tr_font.c; $(DO_CC)   $(GL_CFLAGS)
+ $(B)/client/tr_image.o : $(RDIR)/tr_image.c; $(DO_CC)   $(GL_CFLAGS) $(MINGW_CFLAGS)
++$(B)/client/jpeg_memsrc.o : $(RDIR)/jpeg_memsrc.c; $(DO_CC)   $(GL_CFLAGS)
+ $(B)/client/tr_init.o : $(RDIR)/tr_init.c; $(DO_CC)    $(GL_CFLAGS)
+ $(B)/client/tr_light.o : $(RDIR)/tr_light.c; $(DO_CC)  $(GL_CFLAGS)
+ $(B)/client/tr_main.o : $(RDIR)/tr_main.c; $(DO_CC)   $(GL_CFLAGS)


Index: tremulous.spec
===================================================================
RCS file: /cvs/extras/rpms/tremulous/devel/tremulous.spec,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -r1.3 -r1.4
--- tremulous.spec	24 Sep 2007 20:18:58 -0000	1.3
+++ tremulous.spec	26 Sep 2007 21:07:49 -0000	1.4
@@ -1,6 +1,6 @@
 Name:           tremulous
 Version:        1.1.0
-Release:        4%{?dist}
+Release:        5%{?dist}
 Summary:        First Person Shooter game based on the Quake 3 engine
 Group:          Amusements/Games
 License:        GPLv2+
@@ -43,11 +43,12 @@
 
 %prep
 %setup -q -n %{name}-%{version}-src
-%patch -p2 -z .syslibs
+%patch -p1 -z .syslibs
 
 # Rip out the jpeg sources and the SDL and freealut headers and use the
 # system versions instead
-rm -rf src/jpeg-6 src/SDL12 src/AL
+mv src/jpeg-6/jmemnobs.c .; rm src/jpeg-6/*; mv jmemnobs.c src/jpeg-6
+rm -r src/SDL12 src/AL
 
 
 %build
@@ -56,7 +57,8 @@
 make %{?_smp_mflags} \
     OPTIMIZE="$RPM_OPT_FLAGS -fno-strict-aliasing -ffast-math" \
     DEFAULT_BASEDIR=%{_datadir}/%{name} USE_CODEC_VORBIS=1 \
-    BUILD_GAME_SO=0 GENERATE_DEPENDENCIES=0 CROSS_COMPILING=1
+    USE_LOCAL_HEADERS=0 BUILD_GAME_SO=0 GENERATE_DEPENDENCIES=0 \
+    CROSS_COMPILING=1
 
 
 %install
@@ -104,6 +106,10 @@
 
 
 %changelog
+* Wed Sep 26 2007 Hans de Goede <j.w.r.degoede at hhs.nl> 1.1.0-5
+- Update syslibs patch to make the system libjpeg use tremulous' Malloc and
+  Free functions, instead of the libc ones
+
 * Mon Sep 24 2007 Hans de Goede <j.w.r.degoede at hhs.nl> 1.1.0-4
 - Use opengl-games-utils wrapper to show error dialog when DRI is missing
 




More information about the fedora-extras-commits mailing list