X-Git-Url: https://notaz.gp2x.de/cgi-bin/gitweb.cgi?p=pcsx_rearmed.git;a=blobdiff_plain;f=Makefile.libretro;h=cbebc5dfafced6115f408bd4a1bcae4ffc0a3e20;hp=ae95639f1a8d64c72a0e429ca47862d434051451;hb=581335b095ed820978d4c88f026abf462128eeb0;hpb=fb01e82a3453b4b068fde274a42df336e778d8d3 diff --git a/Makefile.libretro b/Makefile.libretro index ae95639f..cbebc5df 100644 --- a/Makefile.libretro +++ b/Makefile.libretro @@ -172,7 +172,9 @@ else endif CFLAGS += -fPIC -ifneq ($(platform),qnx) +ifeq ($(platform),win) + MAIN_LDLIBS += -lws2_32 +else ifneq ($(platform),qnx) LDLIBS += -lpthread MAIN_LDLIBS += -ldl endif @@ -180,6 +182,17 @@ MAIN_LDFLAGS += -shared MAIN_LDLIBS += -lm -lz EXTRA_LDFLAGS = +# try to autodetect stuff for the lazy +ifndef ARCH +ARCH = $(shell $(CC) -dumpmachine | awk -F- '{print $$1}') +endif +ifndef HAVE_NEON +HAVE_NEON = $(shell $(CC) -E -dD - < /dev/null 2> /dev/null | grep -q __ARM_NEON__ && echo 1 || echo 0) +endif +ifeq ($(shell ld -v 2> /dev/null | awk '{print $$1}'),GNU) +MAIN_LDFLAGS += -Wl,--no-undefined +endif + TARGET ?= libretro.so PLATFORM = libretro BUILTIN_GPU ?= peops