diff --git a/libretro/Makefile.common b/libretro/Makefile.common index 1bcd8ab2b9..d492617f0f 100644 --- a/libretro/Makefile.common +++ b/libretro/Makefile.common @@ -17,6 +17,8 @@ INCFLAGS += \ -I$(CORE_DIR) \ -I$(COMMONDIR) \ -I$(CORE_DIR)/libretro \ + -I$(EXTDIR)/libadrenotools/lib/linkernsbypass \ + -I$(EXTDIR)/libadrenotools/include \ -I$(EXTDIR)/openxr \ -I$(EXTDIR)/glslang \ -I$(EXTDIR)/glslang-build \ @@ -566,6 +568,14 @@ SOURCES_CXX += $(COMMONDIR)/MemArenaPosix.cpp \ $(EXTDIR)/glslang/glslang/OSDependent/Unix/ossource.cpp endif + +ifeq ($(TARGET_ARCH),arm64) +SOURCES_CXX += \ + $(EXTDIR)/libadrenotools/src/driver.cpp \ + $(EXTDIR)/libadrenotools/lib/linkernsbypass/android_linker_ns.cpp \ + $(EXTDIR)/libadrenotools/lib/linkernsbypass/elf_soname_patcher.cpp +endif + SOURCES_CXX += \ $(COMMONDIR)/Render/Text/draw_text.cpp \ $(EXTDIR)/jpge/jpgd.cpp \ diff --git a/libretro/jni/Android.mk b/libretro/jni/Android.mk index 1d6e33b58a..f37ba11548 100644 --- a/libretro/jni/Android.mk +++ b/libretro/jni/Android.mk @@ -77,7 +77,7 @@ COREFLAGS += -DINLINE="inline" -DPPSSPP -DUSE_FFMPEG -DWITH_UPNP -DMOBILE_DEVICE LOCAL_SRC_FILES = $(SOURCES_CXX) $(SOURCES_C) $(ASMFILES) LOCAL_CPPFLAGS := -Wall -std=c++17 $(COREFLAGS) -DSPIRV_CROSS_EXCEPTIONS_TO_ASSERTIONS $(DEFINES) LOCAL_CFLAGS := -O2 -DANDROID $(COREFLAGS) $(DEFINES) -LOCAL_LDLIBS += -lz -llog -lGLESv2 -lEGL -latomic +LOCAL_LDLIBS += -lz -landroid -lGLESv2 -lOpenSLES -lEGL -ldl -llog -latomic LOCAL_STATIC_LIBRARIES += $(FFMPEGLIBS) include $(BUILD_SHARED_LIBRARY) diff --git a/libretro/jni/Application.mk b/libretro/jni/Application.mk index 4ed1b3142f..e3157b2500 100644 --- a/libretro/jni/Application.mk +++ b/libretro/jni/Application.mk @@ -2,4 +2,4 @@ NDK_TOOLCHAIN_VERSION ?= 4.8 APP_ABI := armeabi-v7a,arm64-v8a,x86 APP_STL := c++_static APP_GNUSTL_CPP_FEATURES := exceptions -APP_PLATFORM := android-9 +APP_PLATFORM := android-21