(Makefile) Updates - should compile on both Win32 and Linux now

This commit is contained in:
Twinaphex 2012-08-18 16:58:45 +02:00
parent 00d98cee9c
commit 44f01e7f0a

View File

@ -18,6 +18,17 @@ else ifneq ($(findstring win,$(shell uname -a)),)
endif endif
endif endif
# system platform
system_platform = unix
ifeq ($(shell uname -a),)
EXE_EXT = .exe
system_platform = win
else ifneq ($(findstring Darwin,$(shell uname -a)),)
system_platform = osx
else ifneq ($(findstring MINGW,$(shell uname -a)),)
system_platform = win
endif
ifeq ($(platform), unix) ifeq ($(platform), unix)
TARGET := libretro.so TARGET := libretro.so
fpic := -fPIC fpic := -fPIC
@ -41,19 +52,19 @@ else ifeq ($(platform), ps3)
AR = $(CELL_SDK)/host-win32/ppu/bin/ppu-lv2-ar.exe AR = $(CELL_SDK)/host-win32/ppu/bin/ppu-lv2-ar.exe
PLATFORM_DEFINES := -D__CELLOS_LV2 -DALT_RENDER PLATFORM_DEFINES := -D__CELLOS_LV2 -DALT_RENDER
else ifeq ($(platform), psl1ght) else ifeq ($(platform), psl1ght)
TARGET := libretro_psl1ght.a TARGET := libretro_psl1ght.a$(EXE_EXT)
CC = $(PS3DEV)/ppu/bin/ppu-gcc CC = $(PS3DEV)/ppu/bin/ppu-gcc$(EXE_EXT)
AR = $(PS3DEV)/ppu/bin/ppu-ar AR = $(PS3DEV)/ppu/bin/ppu-ar$(EXE_EXT)
PLATFORM_DEFINES := -D__CELLOS_LV2 -DALT_RENDER PLATFORM_DEFINES := -D__CELLOS_LV2 -DALT_RENDER
else ifeq ($(platform), xenon) else ifeq ($(platform), xenon)
TARGET := libretro_xenon360.a TARGET := libretro_xenon360.a
CC = xenon-gcc CC = xenon-gcc$(EXE_EXT)
AR = xenon-ar AR = xenon-ar$(EXE_EXT)
PLATFORM_DEFINES := -D__LIBXENON__ -DALT_RENDER PLATFORM_DEFINES := -D__LIBXENON__ -DALT_RENDER
else ifeq ($(platform), wii) else ifeq ($(platform), wii)
TARGET := libretro_wii.a TARGET := libretro_wii.a
CC = $(DEVKITPPC)/bin/powerpc-eabi-gcc CC = $(DEVKITPPC)/bin/powerpc-eabi-gcc$(EXE_EXT)
AR = $(DEVKITPPC)/bin/powerpc-eabi-ar AR = $(DEVKITPPC)/bin/powerpc-eabi-ar$(EXE_EXT)
PLATFORM_DEFINES := -DGEKKO -mrvl -mcpu=750 -meabi -mhard-float -DALT_RENDER PLATFORM_DEFINES := -DGEKKO -mrvl -mcpu=750 -meabi -mhard-float -DALT_RENDER
else else
TARGET := retro.dll TARGET := retro.dll