diff options
author | twinaphex | 2015-03-06 11:34:29 +0100 |
---|---|---|
committer | twinaphex | 2015-03-06 11:34:29 +0100 |
commit | 917a47e022495be79c60328a7ae60f5c25b3b298 (patch) | |
tree | c4842e080e29b048c88b078e88fb063c421a1229 | |
parent | 40dabc0b86e98a2f9b754692bd98404d038f6bce (diff) | |
download | pcsx_rearmed-917a47e022495be79c60328a7ae60f5c25b3b298.tar.gz pcsx_rearmed-917a47e022495be79c60328a7ae60f5c25b3b298.tar.bz2 pcsx_rearmed-917a47e022495be79c60328a7ae60f5c25b3b298.zip |
Create linux-portable target
-rw-r--r-- | Makefile.libretro | 22 |
1 files changed, 17 insertions, 5 deletions
diff --git a/Makefile.libretro b/Makefile.libretro index d566e23..2210e9c 100644 --- a/Makefile.libretro +++ b/Makefile.libretro @@ -20,8 +20,12 @@ CC_AS ?= $(CC) CFLAGS ?= TARGET_NAME := pcsx_rearmed - +LIBM := -lm +LIBZ := -lz +LIBPTHREAD := -lpthread +LIBDL := -ldl MMAP_WIN32=0 +EXTRA_LDFLAGS = # Unix ifeq ($(platform), unix) @@ -29,6 +33,15 @@ ifeq ($(platform), unix) fpic := -fPIC SHARED := -shared -Wl,--version-script=libretro/link.T +else ifeq ($(platform), linux-portable) + TARGET := $(TARGET_NAME)_libretro.so + fpic := -fPIC -nostdlib + EXTRA_LDFLAGS += -fPIC -nostdlib + LIBM := + LIBZ := + LIBPTHREAD := + LIBDL := + SHARED := -shared -Wl,--version-script=libretro/link.T # OS X else ifeq ($(platform), osx) TARGET := $(TARGET_NAME)_libretro.dylib @@ -175,12 +188,11 @@ CFLAGS += -fPIC ifeq ($(platform),win) MAIN_LDLIBS += -lws2_32 else ifneq ($(platform),qnx) - LDLIBS += -lpthread - MAIN_LDLIBS += -ldl + LDLIBS += $(LIBPHTREAD) + MAIN_LDLIBS += $(LIBDL) endif MAIN_LDFLAGS += -shared -MAIN_LDLIBS += -lm -lz -EXTRA_LDFLAGS = +MAIN_LDLIBS += $(LIBM) $(LIBZ) TARGET ?= libretro.so PLATFORM = libretro |