mirror of
https://github.com/ZDoom/raze-gles.git
synced 2024-12-24 10:40:46 +00:00
OS X: fix build under Leopard/Xcode 3.1.4
git-svn-id: https://svn.eduke32.com/eduke32@2432 1a8010ca-5511-0410-912e-c29ae57300e0
This commit is contained in:
parent
8b25714262
commit
92b49b6938
5 changed files with 29 additions and 12 deletions
|
@ -292,7 +292,7 @@ ifeq (1,$(RELEASE))
|
|||
endif
|
||||
endif
|
||||
ifeq ($(PLATFORM),DARWIN)
|
||||
cp -rf "Apple/bundles/EDuke32.app" "./"
|
||||
cp -RPf "Apple/bundles/EDuke32.app" "./"
|
||||
mkdir -p "EDuke32.app/Contents/MacOS"
|
||||
cp -f "eduke32$(EXESUFFIX)" "EDuke32.app/Contents/MacOS/"
|
||||
endif
|
||||
|
@ -306,7 +306,7 @@ ifeq (1,$(RELEASE))
|
|||
endif
|
||||
endif
|
||||
ifeq ($(PLATFORM),DARWIN)
|
||||
cp -rf "Apple/bundles/Mapster32.app" "./"
|
||||
cp -RPf "Apple/bundles/Mapster32.app" "./"
|
||||
mkdir -p "Mapster32.app/Contents/MacOS"
|
||||
cp -f "mapster32$(EXESUFFIX)" "Mapster32.app/Contents/MacOS/"
|
||||
endif
|
||||
|
|
|
@ -147,18 +147,24 @@ else
|
|||
W_NO_UNUSED_RESULT :=
|
||||
endif
|
||||
|
||||
W_STRICT_OVERFLOW := -Wstrict-overflow=1
|
||||
ifeq (3,$(GCC_MAJOR))
|
||||
W_STRICT_OVERFLOW :=
|
||||
endif
|
||||
ifeq ($(PLATFORM),DARWIN)
|
||||
ifeq (1,$(DARWIN9))
|
||||
W_STRICT_OVERFLOW :=
|
||||
endif
|
||||
endif
|
||||
|
||||
BASECFLAGS=$(debug) -W -Wall -Wimplicit -Werror-implicit-function-declaration \
|
||||
-funsigned-char -fno-strict-aliasing -DNO_GCC_BUILTINS -D_FORTIFY_SOURCE=2 \
|
||||
$(F_JUMP_TABLES) $(W_NO_UNUSED_RESULT) $(ARCH) \
|
||||
-Wextra #-Wwrite-strings -Waddress -Wlogical-op
|
||||
-Wextra $(W_STRICT_OVERFLOW) #-Wwrite-strings -Waddress -Wlogical-op
|
||||
ifeq ($(CC),clang)
|
||||
BASECFLAGS+= -Wno-unused-value -Wno-parentheses
|
||||
endif
|
||||
|
||||
ifneq (3,$(GCC_MAJOR))
|
||||
BASECFLAGS+= -Wstrict-overflow=1
|
||||
endif
|
||||
|
||||
ifneq (0,$(USE_LIBPNG))
|
||||
BASECFLAGS+= -DUSE_LIBPNG
|
||||
endif
|
||||
|
|
|
@ -95,11 +95,22 @@ ifeq ($(PLATFORM),LINUX)
|
|||
endif
|
||||
endif
|
||||
ifeq ($(PLATFORM),DARWIN)
|
||||
DARWINVERSION?=$(strip $(shell uname -r | cut -d . -f 1))
|
||||
ifeq (1,$(strip $(shell expr $(DARWINVERSION) \< 10)))
|
||||
DARWIN9 = 1
|
||||
endif
|
||||
|
||||
RENDERTYPE = SDL
|
||||
STDCPPLIB = -lstdc++
|
||||
BUILDCFLAGS += -DHAVE_INTTYPES #-fno-leading-underscore
|
||||
GTKCOMPAT32 = 0
|
||||
SDL_FRAMEWORK = 1
|
||||
|
||||
ifeq (1,$(DARWIN9))
|
||||
BUILDCFLAGS += -DDARWIN9
|
||||
F_JUMP_TABLES :=
|
||||
endif
|
||||
|
||||
ifeq (1,$(BUILD32_ON_64))
|
||||
BUILDCFLAGS += $(F_NO_STACK_PROTECTOR) -arch i386
|
||||
else
|
||||
|
|
|
@ -106,10 +106,10 @@ fi
|
|||
|
||||
# Duplicating .app bundles for debug build:
|
||||
# if [ -d "Mapster32.app" ]; then
|
||||
# cp "Mapster32.app" "Mapster32.debug.app"
|
||||
# cp -RP "Mapster32.app" "Mapster32.debug.app"
|
||||
# fi
|
||||
# if [ -d "EDuke32.app" ]; then
|
||||
# cp "EDuke32.app" "EDuke32.debug.app"
|
||||
# cp -RP "EDuke32.app" "EDuke32.debug.app"
|
||||
# fi
|
||||
|
||||
# Almost done...
|
||||
|
|
|
@ -179,15 +179,15 @@ int32_t MUSIC_Init(int32_t SoundCard, int32_t Address)
|
|||
|
||||
sz = (numargs+2)*sizeof(char *) + (c-command+1);
|
||||
sz = ((sz+pagesize-1)/pagesize)*pagesize;
|
||||
# ifdef NEDMALLOC
|
||||
#if defined(NEDMALLOC) || (defined(__APPLE__) && defined(DARWIN9))
|
||||
external_midi_argv = Bcalloc(1,sz+pagesize);
|
||||
if (!external_midi_argv)
|
||||
goto fallback;
|
||||
external_midi_argv = (char **)((intptr_t)external_midi_argv + (pagesize-(((intptr_t)external_midi_argv)&(pagesize-1))));
|
||||
# else
|
||||
#else
|
||||
if (posix_memalign((void **)&external_midi_argv, pagesize, sz))
|
||||
goto fallback;
|
||||
# endif
|
||||
#endif
|
||||
cmd = (char *)external_midi_argv + (numargs+2)*sizeof(char *);
|
||||
Bmemcpy(cmd, command, c-command+1);
|
||||
|
||||
|
|
Loading…
Reference in a new issue