Files
Mu/libretroBuildSystem/build/Makefile.common
meepingsnesroms 125e85d73b Got Mac RetroArch build working with ARM emulator
Hopefully dident break ARM emulator on Windows.
2019-05-13 12:38:42 -07:00

82 lines
2.2 KiB
Makefile

EMU_PATH := $(CORE_DIR)/../src
LIBRETRO_COMM_DIR := $(CORE_DIR)/libretro-common
COREDEFINES :=
INCFLAGS := -I$(LIBRETRO_COMM_DIR)/include
ifeq ($(DEBUG), 1)
COREDEFINES += -DEMU_DEBUG -DEMU_SANDBOX
else
COREDEFINES += -DEMU_NO_SAFETY
endif
ifneq (,$(findstring msvc200,$(platform)))
INCFLAGS += -I$(LIBRETRO_COMM_DIR)/include/compat/msvc
endif
ifneq (,$(findstring msvc20,$(platform)))
# Mu is dependent on stdbool.h and the standard inline directive existing
INCFLAGS += -I$(CORE_DIR)/fixIncludes/stdbool
COREDEFINES += -Dinline=_inline -DINLINE=_inline
endif
ifneq (,$(findstring windows,$(platform)))
# Windows
EMU_SUPPORT_PALM_OS5 = 1
EMU_OS := windows
ifneq (,$(findstring x64,$(platform)))
EMU_ARCH := x86_64
else
EMU_ARCH := x86_32
endif
else ifneq (,$(findstring armv,$(platform)))
# ARM Linux
EMU_SUPPORT_PALM_OS5 = 1
EMU_ARCH := armv7
EMU_OS := linux
else ifneq (,$(filter unix osx osx_x86 osx_x86_64 linux_x86 linux_x86_64 linux-portable_x86 linux-portable_x86_64,$(platform)))
# x86_* Linux
EMU_SUPPORT_PALM_OS5 = 1
ifneq (,$(filter osx osx_x86_64 linux_x86_64 linux-portable_x86_64,$(platform)))
EMU_ARCH := x86_64
else
EMU_ARCH := x86_32
endif
EMU_OS := linux
endif
ifneq (,$(filter ps3 sncps3 psl1ght ngc wii wiiu,$(platform)))
COREDEFINES += -DEMU_BIG_ENDIAN
else ifeq ($(platform), osx)
ifeq ($(arch), ppc)
COREDEFINES += -DEMU_BIG_ENDIAN
endif
endif
ifeq ($(EMU_SUPPORT_PALM_OS5), 1)
ifneq ($(platform), android_jni)
CXXFLAGS += -std=c++11
endif
endif
include $(EMU_PATH)/makefile.all
COREDEFINES += $(EMU_DEFINES)
SOURCES_C := $(CORE_DIR)/libretro.c \
$(CORE_DIR)/cursors.c \
$(EMU_SOURCES_C)
SOURCES_CXX := $(EMU_SOURCES_CXX)
SOURCES_ASM := $(EMU_SOURCES_ASM)
ifneq ($(STATIC_LINKING), 1)
SOURCES_C += $(LIBRETRO_COMM_DIR)/compat/compat_strl.c \
$(LIBRETRO_COMM_DIR)/compat/compat_posix_string.c \
$(LIBRETRO_COMM_DIR)/compat/fopen_utf8.c \
$(LIBRETRO_COMM_DIR)/encodings/encoding_utf.c \
$(LIBRETRO_COMM_DIR)/memmap/memmap.c \
$(LIBRETRO_COMM_DIR)/streams/file_stream.c \
$(LIBRETRO_COMM_DIR)/string/stdstring.c \
$(LIBRETRO_COMM_DIR)/vfs/vfs_implementation.c
endif