Ticket #378: quake3-io2306.patch
| File quake3-io2306.patch, 9.4 KB (added by jstressman, 3 years ago) |
|---|
-
code/botlib/botlib.h
diff -urb --exclude=.svn quake3-io2306/code/botlib/botlib.h quake3-io2306-jstressman/code/botlib/botlib.h
old new 170 170 typedef struct botlib_import_s 171 171 { 172 172 //print messages from the bot library 173 void (QDECL *Print)(int type, char *fmt, ...) __attribute__ ((format (printf, 2, 3))); 173 // void (QDECL *Print)(int type, char *fmt, ...) __attribute__ ((format (printf, 2, 3))); 174 void (QDECL *Print)(int type, char *fmt, ...); 174 175 //trace a bbox through the world 175 176 void (*Trace)(bsp_trace_t *trace, vec3_t start, vec3_t mins, vec3_t maxs, vec3_t end, int passent, int contentmask); 176 177 //trace a bbox against a specific entity -
code/qcommon/net_ip.c
diff -urb --exclude=.svn quake3-io2306/code/qcommon/net_ip.c quake3-io2306-jstressman/code/qcommon/net_ip.c
old new 73 73 # include <sys/types.h> 74 74 # include <sys/time.h> 75 75 # include <unistd.h> 76 # if !defined(__sun) && !defined(__sgi) 76 # if !defined(__sun) && !defined(__sgi) && !defined(__HAIKU__) 77 77 # include <ifaddrs.h> 78 78 # endif 79 79 … … 132 132 133 133 #define MAX_IPS 32 134 134 135 #ifdef __HAIKU__ 136 typedef uint8_t sa_family_t; 137 #endif 138 135 139 typedef struct 136 140 { 137 141 char ifname[IF_NAMESIZE]; -
code/qcommon/q_platform.h
diff -urb --exclude=.svn quake3-io2306/code/qcommon/q_platform.h quake3-io2306-jstressman/code/qcommon/q_platform.h
old new 35 35 36 36 #else 37 37 38 #if (defined _M_IX86 || defined __i386__) && !defined(C_ONLY) 38 #if (defined _M_IX86 || defined __i386__) && !defined(C_ONLY) && !defined(__HAIKU__) 39 39 #define id386 1 40 40 #else 41 41 #define id386 0 … … 229 229 230 230 #endif 231 231 232 233 //================================================================= HAIKU === 234 235 #ifdef __HAIKU__ 236 237 #define OS_STRING "haiku" 238 #define ID_INLINE inline 239 #define PATH_SEP '/' 240 #define ARCH_STRING "i386" 241 #define Q3_LITTLE_ENDIAN 242 #define DLL_EXT ".so" 243 244 #endif 245 246 232 247 //=================================================================== BSD === 233 248 234 249 #if defined(__FreeBSD__) || defined(__OpenBSD__) || defined(__NetBSD__) -
code/renderer/tr_image_pcx.c
diff -urb --exclude=.svn quake3-io2306/code/renderer/tr_image_pcx.c quake3-io2306-jstressman/code/renderer/tr_image_pcx.c
old new 45 45 unsigned short palette_type; 46 46 unsigned short hscreensize, vscreensize; 47 47 char filler[54]; 48 unsigned char data[];48 unsigned char *data; 49 49 } pcx_t; 50 50 51 51 void R_LoadPCX ( const char *filename, byte **pic, int *width, int *height) -
code/renderer/tr_public.h
diff -urb --exclude=.svn quake3-io2306/code/renderer/tr_public.h quake3-io2306-jstressman/code/renderer/tr_public.h
old new 106 106 // 107 107 typedef struct { 108 108 // print message on the local console 109 void (QDECL *Printf)( int printLevel, const char *fmt, ...) __attribute__ ((format (printf, 2, 3))); 109 // void (QDECL *Printf)( int printLevel, const char *fmt, ...) __attribute__ ((format (printf, 2, 3))); 110 void (QDECL *Printf)( int printLevel, const char *fmt, ...); 110 111 111 112 // abort the game 112 void (QDECL *Error)( int errorLevel, const char *fmt, ...) __attribute__ ((noreturn, format (printf, 2, 3))); 113 // void (QDECL *Error)( int errorLevel, const char *fmt, ...) __attribute__ ((noreturn, format (printf, 2, 3))); 114 void (QDECL *Error)( int errorLevel, const char *fmt, ...); 113 115 114 116 // milliseconds should only be used for profiling, never 115 117 // for anything game related. Get time from the refdef -
code/sys/sys_main.c
diff -urb --exclude=.svn quake3-io2306/code/sys/sys_main.c quake3-io2306-jstressman/code/sys/sys_main.c
old new 31 31 #include <ctype.h> 32 32 #include <errno.h> 33 33 34 #ifdef __HAIKU__ 35 #define SIGIOT SIGABRT 36 #endif 37 34 38 #ifndef DEDICATED 35 39 #ifdef USE_LOCAL_HEADERS 36 40 # include "SDL.h" -
code/sys/sys_unix.c
diff -urb --exclude=.svn quake3-io2306/code/sys/sys_unix.c quake3-io2306-jstressman/code/sys/sys_unix.c
old new 39 39 #include <fenv.h> 40 40 #include <sys/wait.h> 41 41 42 #ifdef __HAIKU__ 43 #define SIGIOT SIGABRT 44 #endif 45 42 46 qboolean stdinIsATTY; 43 47 44 48 // Used to determine where to store user-specific files -
code/tools/lcc/etc/lcc.c
diff -urb --exclude=.svn quake3-io2306/code/tools/lcc/etc/lcc.c quake3-io2306-jstressman/code/tools/lcc/etc/lcc.c
old new 48 48 extern int suffix(char *, char *[], int); 49 49 extern char *tempname(char *); 50 50 51 #if ndef __sun51 #if !defined(__sun) && !defined(__HAIKU__) 52 52 extern int getpid(void); 53 53 #endif 54 54 … … 279 279 #else 280 280 281 281 #define _P_WAIT 0 282 #if ndef __sun282 #if !defined(__sun) && !defined(__HAIKU__) 283 283 extern int fork(void); 284 284 #endif 285 285 extern int wait(int *); -
code/ui/ui_shared.h
diff -urb --exclude=.svn quake3-io2306/code/ui/ui_shared.h quake3-io2306-jstressman/code/ui/ui_shared.h
old new 354 354 void (*getBindingBuf)( int keynum, char *buf, int buflen ); 355 355 void (*setBinding)( int keynum, const char *binding ); 356 356 void (*executeText)(int exec_when, const char *text ); 357 void (*Error)(int level, const char *error, ...) __attribute__ ((noreturn, format (printf, 2, 3))); 358 void (*Print)(const char *msg, ...) __attribute__ ((format (printf, 1, 2))); 357 // void (*Error)(int level, const char *error, ...) __attribute__ ((noreturn, format (printf, 2, 3))); 358 // void (*Print)(const char *msg, ...) __attribute__ ((format (printf, 1, 2))); 359 void (*Error)(int level, const char *error, ...); 360 void (*Print)(const char *msg, ...); 359 361 void (*Pause)(qboolean b); 360 362 int (*ownerDrawWidth)(int ownerDraw, float scale); 361 363 sfxHandle_t (*registerSound)(const char *name, qboolean compressed); -
Makefile
diff -urb --exclude=.svn quake3-io2306/Makefile quake3-io2306-jstressman/Makefile
old new 396 396 else # ifeq Linux 397 397 398 398 ############################################################################# 399 # SETUP AND BUILD -- HAIKU 400 ############################################################################# 401 402 ## Defaults 403 LIB=lib 404 405 INSTALL=install 406 MKDIR=mkdir 407 408 ifeq ($(PLATFORM),haiku) 409 410 BASE_CFLAGS = -Wall -fno-strict-aliasing -Wimplicit -Wstrict-prototypes \ 411 -pipe -DUSE_ICON $(shell sdl-config --cflags) 412 413 ifeq ($(USE_OPENAL),1) 414 BASE_CFLAGS += -DUSE_OPENAL 415 ifeq ($(USE_OPENAL_DLOPEN),1) 416 BASE_CFLAGS += -DUSE_OPENAL_DLOPEN 417 endif 418 endif 419 420 ifeq ($(USE_CURL),1) 421 BASE_CFLAGS += -DUSE_CURL 422 ifeq ($(USE_CURL_DLOPEN),1) 423 BASE_CFLAGS += -DUSE_CURL_DLOPEN 424 endif 425 endif 426 427 ifeq ($(USE_CODEC_VORBIS),1) 428 BASE_CFLAGS += -DUSE_CODEC_VORBIS 429 endif 430 431 OPTIMIZE = -O3 -ffast-math -funroll-loops -fomit-frame-pointer 432 433 ifeq ($(ARCH),i386) 434 OPTIMIZE = -O3 -march=i586 -fomit-frame-pointer -ffast-math \ 435 -funroll-loops -falign-loops=2 -falign-jumps=2 \ 436 -falign-functions=2 -fstrength-reduce 437 HAVE_VM_COMPILED=true 438 endif 439 440 ifneq ($(HAVE_VM_COMPILED),true) 441 BASE_CFLAGS += -DNO_VM_COMPILED 442 endif 443 444 SHLIBEXT=so 445 SHLIBCFLAGS=-fPIC 446 SHLIBLDFLAGS=-shared $(LDFLAGS) 447 448 THREAD_LDFLAGS=-lpthread 449 LDFLAGS=-lnetwork 450 451 CLIENT_LDFLAGS=$(shell sdl-config --libs) -lGL 452 453 ifeq ($(USE_OPENAL),1) 454 ifneq ($(USE_OPENAL_DLOPEN),1) 455 CLIENT_LDFLAGS += -lopenal 456 endif 457 endif 458 459 ifeq ($(USE_CURL),1) 460 ifneq ($(USE_CURL_DLOPEN),1) 461 CLIENT_LDFLAGS += -lcurl 462 endif 463 endif 464 465 ifeq ($(USE_CODEC_VORBIS),1) 466 CLIENT_LDFLAGS += -lvorbisfile -lvorbis -logg 467 endif 468 469 ifeq ($(ARCH),i386) 470 # linux32 make ... 471 BASE_CFLAGS += -m32 472 LDFLAGS+=-m32 473 endif 474 475 DEBUG_CFLAGS = $(BASE_CFLAGS) -g -O0 476 RELEASE_CFLAGS=$(BASE_CFLAGS) -DNDEBUG $(OPTIMIZE) 477 478 else # ifeq Haiku 479 480 ############################################################################# 399 481 # SETUP AND BUILD -- MAC OS X 400 482 ############################################################################# 401 483 … … 828 910 SHLIBLDFLAGS=-shared 829 911 830 912 endif #Linux 913 endif #Haiku 831 914 endif #darwin 832 915 endif #mingw32 833 916 endif #FreeBSD … … 989 1072 990 1073 BASE_CFLAGS += -DPRODUCT_VERSION=\\\"$(VERSION)\\\" 991 1074 BASE_CFLAGS += -Wformat=2 -Wno-format-zero-length -Wformat-security -Wno-format-nonliteral 992 BASE_CFLAGS += -Wstrict-aliasing=2 -Wmissing-format-attribute993 BASE_CFLAGS += -Wdisabled-optimization1075 #BASE_CFLAGS += -Wstrict-aliasing=2 -Wmissing-format-attribute 1076 #BASE_CFLAGS += -Wdisabled-optimization 994 1077 BASE_CFLAGS += -Werror-implicit-function-declaration 995 1078 996 1079 ifeq ($(V),1)
