]> pilppa.org Git - familiar-h63xx-build.git/blob - org.handhelds.familiar/packages/snes9x/snes9x-sdl-qpe-1.39/compile.patch
OE tree imported from monotone branch org.openembedded.oz354fam083 at revision 8b12e3...
[familiar-h63xx-build.git] / org.handhelds.familiar / packages / snes9x / snes9x-sdl-qpe-1.39 / compile.patch
1
2 #
3 # Patch managed by http://www.mn-logistik.de/unsupported/pxa250/patcher
4 #
5
6 --- snes9x-sdl-1.39/unix/svga.cpp~compile       2003-10-28 10:08:18.000000000 +0100
7 +++ snes9x-sdl-1.39/unix/svga.cpp       2004-01-19 21:29:07.000000000 +0100
8 @@ -48,7 +48,7 @@
9  #include <stdlib.h>
10  #include <signal.h>
11  
12 -#include "sdl.h"
13 +#include <SDL.h>
14  
15  #include "snes9x.h"
16  #include "memmap.h"
17 --- snes9x-sdl-1.39/unix/unix.cpp~compile       2003-10-28 22:09:02.000000000 +0100
18 +++ snes9x-sdl-1.39/unix/unix.cpp       2004-01-19 21:29:07.000000000 +0100
19 @@ -50,7 +50,7 @@
20  #include <sys/types.h>
21  #include <ctype.h>
22  #include <dirent.h>
23 -#include <sdl.h>
24 +#include <SDL.h>
25  #include "keydef.h"
26  
27  #undef USE_THREADS
28 --- /dev/null   1970-01-01 01:00:00.000000000 +0100
29 +++ snes9x-sdl-1.39/unzip/unzipP.h      2004-01-19 21:29:07.000000000 +0100
30 @@ -0,0 +1,124 @@
31 +#ifndef _UNZIPP_H_
32 +#define _UNZIPP_H_
33 +
34 +#include "unzip.h"
35 +
36 +#ifndef local
37 +#define local static
38 +#endif
39 +/* compile with -Dlocal if your debugger can't find static symbols */
40 +
41 +
42 +
43 +#if !defined(unix) && !defined(CASESENSITIVITYDEFAULT_YES) && \
44 +                      !defined(CASESENSITIVITYDEFAULT_NO)
45 +#define CASESENSITIVITYDEFAULT_NO
46 +#endif
47 +
48 +
49 +#ifndef UNZ_BUFSIZE
50 +#define UNZ_BUFSIZE (16384)
51 +#endif
52 +
53 +#ifndef UNZ_MAXFILENAMEINZIP
54 +#define UNZ_MAXFILENAMEINZIP (256)
55 +#endif
56 +
57 +#ifndef ALLOC
58 +#define ALLOC(size) (malloc(size))
59 +#endif
60 +#ifndef TRYFREE
61 +#define TRYFREE(p) {if (p) free(p);}
62 +#endif
63 +
64 +#define SIZECENTRALDIRITEM (0x2e)
65 +#define SIZEZIPLOCALHEADER (0x1e)
66 +
67 +
68 +/* I've found an old Unix (a SunOS 4.1.3_U1) without all SEEK_* defined.... */
69 +
70 +#ifndef SEEK_CUR
71 +#define SEEK_CUR    1
72 +#endif
73 +
74 +#ifndef SEEK_END
75 +#define SEEK_END    2
76 +#endif
77 +
78 +#ifndef SEEK_SET
79 +#define SEEK_SET    0
80 +#endif
81 +
82 +/* unz_file_info_interntal contain internal info about a file in zipfile */
83 +typedef struct unz_file_info_internal_s
84 +{
85 +    uLong           offset_curfile;    /* relative offset of local header 4
86 +                                        * bytes */
87 +}               unz_file_info_internal;
88 +
89 +
90 +/*
91 + * file_in_zip_read_info_s contain internal information about a file in
92 + * zipfile, when reading and decompress it
93 + */
94 +typedef struct
95 +{
96 +    char           *read_buffer;/* internal buffer for compressed data */
97 +    z_stream        stream;    /* zLib stream structure for inflate */
98 +
99 +    uLong           pos_in_zipfile;    /* position in byte on the zipfile,
100 +                                        * for fseek */
101 +    uLong           stream_initialised;        /* flag set if stream structure is
102 +                                        * initialised */
103 +
104 +    uLong           offset_local_extrafield;   /* offset of the local extra
105 +                                                * field */
106 +    uInt            size_local_extrafield;     /* size of the local extra
107 +                                                * field */
108 +    uLong           pos_local_extrafield;      /* position in the local
109 +                                                * extra field in read */
110 +
111 +    uLong           crc32;     /* crc32 of all data uncompressed */
112 +    uLong           crc32_wait;        /* crc32 we must obtain after decompress all */
113 +    uLong           rest_read_compressed;      /* number of byte to be
114 +                                                * decompressed */
115 +    uLong           rest_read_uncompressed;    /* number of byte to be
116 +                                                * obtained after decomp */
117 +    FILE           *file;      /* io structore of the zipfile */
118 +    uLong           compression_method;        /* compression method (0==store) */
119 +    uLong           byte_before_the_zipfile;   /* byte before the zipfile,
120 +                                                * (>0 for sfx) */
121 +}               file_in_zip_read_info_s;
122 +
123 +
124 +/*
125 + * unz_s contain internal information about the zipfile
126 + */
127 +typedef struct
128 +{
129 +    FILE           *file;      /* io structore of the zipfile */
130 +    unz_global_info gi;                /* public global information */
131 +    uLong           byte_before_the_zipfile;   /* byte before the zipfile,
132 +                                                * (>0 for sfx) */
133 +    uLong           num_file;  /* number of the current file in the zipfile */
134 +    uLong           pos_in_central_dir;        /* pos of the current file in the
135 +                                        * central dir */
136 +    uLong           current_file_ok;   /* flag about the usability of the
137 +                                        * current file */
138 +    uLong           central_pos;/* position of the beginning of the central
139 +                                * dir */
140 +
141 +    uLong           size_central_dir;  /* size of the central directory  */
142 +    uLong           offset_central_dir;        /* offset of start of central
143 +                                        * directory with respect to the
144 +                                        * starting disk number */
145 +
146 +    unz_file_info   cur_file_info;     /* public info about the current file
147 +                                        * in zip */
148 +    unz_file_info_internal cur_file_info_internal;     /* private info about it */
149 +    file_in_zip_read_info_s *pfile_in_zip_read;        /* structure about the
150 +                                                * current file if we are
151 +                                                * decompressing it */
152 +}               unz_s;
153 +
154 +#endif
155 --- snes9x-sdl-1.39/Makefile~compile    2003-10-28 16:49:50.000000000 +0100
156 +++ snes9x-sdl-1.39/Makefile    2004-01-19 21:31:53.000000000 +0100
157 @@ -53,12 +53,12 @@
158  
159  ifdef THREAD_SOUND
160  CPUDEFINES += -DUSE_THREADS
161 -EXTRALIBS += -lpthread -L/usr/local/lib -lcygipc
162 +EXTRALIBS += -lpthread -lcygipc
163  endif
164  
165  ifdef GLIDE
166  GLIDEOBJS = unix/glide.o
167 -GLIDEDEFINES = -DUSE_GLIDE -I/usr/include/glide
168 +GLIDEDEFINES = -DUSE_GLIDE
169  GLIDELIBS = -lglide2x
170  GLIDEDEPENDS=use_glide
171  GLIDENO_DEPENDS=no_glide
172 @@ -82,14 +82,12 @@
173  CC = gcc
174  NASM = nasm
175  
176 -INCLUDES=-I/usr/local/include
177 +INCLUDES=
178  
179  OPTIMISE= -D_ZAURUS -Os -ffast-math -fstrict-aliasing -fomit-frame-pointer -mcpu=strongarm1100 -mtune=strongarm1100
180  CCFLAGS = $(OPTIMISE) \
181 --I/opt/Qtopia/include/SDL \
182  -I. \
183  -Iunzip \
184 --Isdl \
185  -D__linux \
186  -DZLIB \
187  -DVAR_CYCLES \
188 @@ -114,7 +112,7 @@
189  
190  .SUFFIXES: .o .cpp .c .cc .h .m .i .S .asm .obj
191  
192 -LDLIBS = -L/opt/Qtopia/sharp/lib
193 +LDLIBS=
194  
195  ifdef GLIDE
196  all: offsets gsnes9x
197 @@ -146,7 +144,7 @@
198         $(RM) $(OPENGLNO_DEPENDS)
199  
200  snes9x: $(OBJECTS) 
201 -       $(CCC) $(INCLUDES) -o $@ $(OBJECTS) $(EXTRALIBS) -L/opt/QtPalmtop/lib/ -lSDL -lSDLmain $(LDLIBS) -lqpe -lqte -lpthread
202 +       $(CCC) $(INCLUDES) -o $@ $(OBJECTS) $(EXTRALIBS) $(LDLIBS) -lqpe -lqte -lpthread
203  
204  gsnes9x: $(OBJECTS) unix/x11.o unix/glide.o
205         $(CCC) $(INCLUDES) -o $@ $(OBJECTS) unix/x11.o unix/glide.o $(LDLIBS) $(GLIDELIBS) -lXext -lX11 -lXxf86dga -lXxf86vm $(EXTRALIBS) -lz -lm