2016-08-07 02:56:09 +00:00
|
|
|
SOURCES_CXX :=
|
|
|
|
SOURCES_C :=
|
|
|
|
|
|
|
|
DEPS_DIR := $(CORE_DIR)/deps
|
|
|
|
LIBRETRO_DIR := $(CORE_DIR)/libretro-common
|
|
|
|
MEDNAFEN_DIR := $(CORE_DIR)/mednafen
|
2016-08-07 03:02:12 +00:00
|
|
|
CORE_EMU_DIR := $(MEDNAFEN_DIR)/ss
|
2016-08-14 10:12:16 +00:00
|
|
|
CDROM_DIR := $(MEDNAFEN_DIR)/cdrom
|
2016-08-07 02:56:09 +00:00
|
|
|
|
|
|
|
INCFLAGS := -I$(CORE_DIR) -I$(MEDNAFEN_DIR) -I$(MEDNAFEN_DIR)/include -I$(MEDNAFEN_DIR)/intl -I$(MEDNAFEN_DIR)/hw_sound -I$(MEDNAFEN_DIR)/hw_cpu -I$(MEDNAFEN_DIR)/hw_misc -I$(LIBRETRO_DIR)/include -I$(DEPS_DIR)/zlib
|
|
|
|
|
|
|
|
|
|
|
|
SOURCES_C += $(DEPS_DIR)/zlib/adler32.c \
|
|
|
|
$(DEPS_DIR)/zlib/compress.c \
|
|
|
|
$(DEPS_DIR)/zlib/crc32.c \
|
|
|
|
$(DEPS_DIR)/zlib/deflate.c \
|
|
|
|
$(DEPS_DIR)/zlib/gzclose.c \
|
|
|
|
$(DEPS_DIR)/zlib/gzlib.c \
|
|
|
|
$(DEPS_DIR)/zlib/gzread.c \
|
|
|
|
$(DEPS_DIR)/zlib/gzwrite.c \
|
|
|
|
$(DEPS_DIR)/zlib/inffast.c \
|
|
|
|
$(DEPS_DIR)/zlib/inflate.c \
|
|
|
|
$(DEPS_DIR)/zlib/inftrees.c \
|
|
|
|
$(DEPS_DIR)/zlib/trees.c \
|
|
|
|
$(DEPS_DIR)/zlib/uncompr.c \
|
|
|
|
$(DEPS_DIR)/zlib/zutil.c
|
|
|
|
|
|
|
|
ifeq ($(HAVE_GRIFFIN),1)
|
2016-08-11 06:22:52 +00:00
|
|
|
SOURCES_CXX += beetle_ss_griffin.cpp
|
2016-08-07 02:56:09 +00:00
|
|
|
|
2016-08-11 06:22:52 +00:00
|
|
|
SOURCES_C += beetle_ss_griffin_c.c
|
2016-08-07 02:56:09 +00:00
|
|
|
endif
|
|
|
|
|
|
|
|
ifeq ($(NEED_THREADING), 1)
|
|
|
|
FLAGS += -DWANT_THREADING -DHAVE_THREADS
|
|
|
|
endif
|
|
|
|
|
|
|
|
ifeq ($(NEED_CRC32), 1)
|
|
|
|
FLAGS += -DWANT_CRC32
|
|
|
|
SOURCES_C += $(CORE_DIR)/scrc32.c
|
|
|
|
endif
|
|
|
|
|
|
|
|
ifeq ($(NEED_DEINTERLACER), 1)
|
|
|
|
FLAGS += -DNEED_DEINTERLACER
|
|
|
|
endif
|
|
|
|
|
|
|
|
ifeq ($(IS_X86), 1)
|
|
|
|
FLAGS += -DARCH_X86
|
|
|
|
endif
|
|
|
|
|
|
|
|
ifeq ($(NEED_BPP), 8)
|
|
|
|
FLAGS += -DWANT_8BPP
|
|
|
|
endif
|
|
|
|
|
|
|
|
ifeq ($(NEED_BPP), 16)
|
|
|
|
FLAGS += -DWANT_16BPP
|
|
|
|
endif
|
|
|
|
|
|
|
|
ifeq ($(NEED_BPP), 32)
|
|
|
|
FLAGS += -DWANT_32BPP
|
|
|
|
endif
|
|
|
|
|
|
|
|
ifeq ($(WANT_NEW_API), 1)
|
|
|
|
FLAGS += -DWANT_NEW_API
|
|
|
|
endif
|
|
|
|
|
|
|
|
ifeq ($(NO_COMPUTED_GOTO), 1)
|
|
|
|
FLAGS += -DNO_COMPUTED_GOTO
|
|
|
|
endif
|
|
|
|
|
|
|
|
ifeq ($(FRONTEND_SUPPORTS_RGB565), 1)
|
|
|
|
FLAGS += -DFRONTEND_SUPPORTS_RGB565
|
|
|
|
endif
|
|
|
|
|
|
|
|
ifeq ($(NEED_CD), 1)
|
|
|
|
FLAGS += -DNEED_CD
|
|
|
|
endif
|
|
|
|
|
2017-07-27 21:24:50 +00:00
|
|
|
ifeq ($(HAVE_CHD), 1)
|
|
|
|
FLAGS += -DHAVE_CHD -D_7ZIP_ST -DPACKAGE_VERSION=\"1.3.2\" -DFLAC_API_EXPORTS -DFLAC__HAS_OGG=0 -DHAVE_LROUND -DHAVE_STDINT_H -DHAVE_STDLIB_H -DHAVE_SYS_PARAM_H
|
2017-07-28 13:49:22 +00:00
|
|
|
INCFLAGS += -I$(DEPS_DIR)/crypto -I$(DEPS_DIR)/flac-1.3.2/include -I$(DEPS_DIR)/flac-1.3.2/src/libFLAC/include -I$(DEPS_DIR)/lzma-16.04/C -I$(DEPS_DIR)/libchdr
|
2017-07-30 19:44:43 +00:00
|
|
|
|
|
|
|
ifeq ($(platform), win)
|
|
|
|
FLAGS += -DHAVE_FSEEKO
|
|
|
|
endif
|
2017-07-27 21:24:50 +00:00
|
|
|
endif
|
|
|
|
|
2016-08-07 02:56:09 +00:00
|
|
|
ifeq ($(NEED_TREMOR), 1)
|
2016-08-26 16:48:09 +00:00
|
|
|
FLAGS += -DNEED_TREMOR
|
2016-08-07 02:56:09 +00:00
|
|
|
endif
|
|
|
|
|
|
|
|
ifneq ($(HAVE_GRIFFIN), 1)
|
|
|
|
SOURCES_CXX += \
|
2016-08-07 03:02:12 +00:00
|
|
|
$(CORE_EMU_DIR)/db.cpp \
|
|
|
|
$(CORE_EMU_DIR)/cdb.cpp \
|
|
|
|
$(CORE_EMU_DIR)/sound.cpp \
|
|
|
|
$(CORE_EMU_DIR)/cart.cpp \
|
|
|
|
$(CORE_EMU_DIR)/scu_dsp_gen.cpp \
|
|
|
|
$(CORE_EMU_DIR)/scu_dsp_mvi.cpp \
|
|
|
|
$(CORE_EMU_DIR)/scu_dsp_jmp.cpp \
|
|
|
|
$(CORE_EMU_DIR)/scu_dsp_misc.cpp \
|
|
|
|
$(CORE_EMU_DIR)/vdp1.cpp \
|
|
|
|
$(CORE_EMU_DIR)/vdp1_line.cpp \
|
|
|
|
$(CORE_EMU_DIR)/vdp1_sprite.cpp \
|
|
|
|
$(CORE_EMU_DIR)/vdp1_poly.cpp \
|
|
|
|
$(CORE_EMU_DIR)/vdp2.cpp \
|
|
|
|
$(CORE_EMU_DIR)/vdp2_render.cpp \
|
|
|
|
$(CORE_EMU_DIR)/smpc.cpp \
|
2016-08-07 02:56:09 +00:00
|
|
|
$(CORE_EMU_DIR)/input/gamepad.cpp \
|
2017-06-05 17:01:14 +00:00
|
|
|
$(CORE_EMU_DIR)/input/gun.cpp \
|
2016-08-07 03:02:12 +00:00
|
|
|
$(CORE_EMU_DIR)/input/3dpad.cpp \
|
2017-03-26 22:35:24 +00:00
|
|
|
$(CORE_EMU_DIR)/input/mouse.cpp \
|
|
|
|
$(CORE_EMU_DIR)/input/multitap.cpp \
|
|
|
|
$(CORE_EMU_DIR)/input/mission.cpp \
|
|
|
|
$(CORE_EMU_DIR)/input/keyboard.cpp \
|
|
|
|
$(CORE_EMU_DIR)/input/wheel.cpp
|
2016-08-07 02:56:09 +00:00
|
|
|
|
2017-04-22 20:29:05 +00:00
|
|
|
SOURCES_CXX += \
|
|
|
|
$(CORE_EMU_DIR)/cart/backup.cpp \
|
|
|
|
$(CORE_EMU_DIR)/cart/cs1ram.cpp \
|
|
|
|
$(CORE_EMU_DIR)/cart/debug.cpp \
|
|
|
|
$(CORE_EMU_DIR)/cart/extram.cpp \
|
2017-11-07 00:59:33 +00:00
|
|
|
$(CORE_EMU_DIR)/cart/rom.cpp \
|
|
|
|
$(CORE_EMU_DIR)/cart/ar4mp.cpp
|
2017-04-22 20:29:05 +00:00
|
|
|
|
2016-08-11 06:22:52 +00:00
|
|
|
SOURCES_CXX += $(MEDNAFEN_DIR)/hw_cpu/m68k/m68k.cpp
|
|
|
|
|
2016-08-07 02:56:09 +00:00
|
|
|
SOURCES_C += $(CORE_DIR)/libretro_cbs.c
|
|
|
|
|
|
|
|
ifeq ($(NEED_TREMOR), 1)
|
|
|
|
SOURCES_C += $(wildcard $(MEDNAFEN_DIR)/tremor/*.c)
|
|
|
|
endif
|
|
|
|
|
2016-08-14 10:12:16 +00:00
|
|
|
ifneq ($(HAVE_GRIFFIN),1)
|
|
|
|
SOURCES_CXX += $(CDROM_DIR)/CDAccess.cpp \
|
|
|
|
$(CDROM_DIR)/CDAccess_Image.cpp \
|
|
|
|
$(CDROM_DIR)/CDAccess_CCD.cpp \
|
|
|
|
$(CDROM_DIR)/CDAFReader.cpp \
|
|
|
|
$(CDROM_DIR)/CDAFReader_Vorbis.cpp \
|
|
|
|
$(CDROM_DIR)/cdromif.cpp \
|
|
|
|
$(CDROM_DIR)/CDUtility.cpp \
|
|
|
|
$(CDROM_DIR)/lec.cpp \
|
|
|
|
$(CDROM_DIR)/galois.cpp \
|
|
|
|
$(CDROM_DIR)/recover-raw.cpp \
|
|
|
|
$(CDROM_DIR)/l-ec.cpp \
|
|
|
|
$(CDROM_DIR)/edc_crc32.cpp
|
2016-08-07 02:56:09 +00:00
|
|
|
endif
|
2016-08-14 10:12:16 +00:00
|
|
|
FLAGS += -DNEED_CD
|
2016-08-07 02:56:09 +00:00
|
|
|
|
2017-07-27 21:24:50 +00:00
|
|
|
ifeq ($(HAVE_CHD), 1)
|
|
|
|
SOURCES_C += \
|
|
|
|
$(DEPS_DIR)/crypto/md5.c \
|
|
|
|
$(DEPS_DIR)/crypto/sha1.c \
|
|
|
|
$(DEPS_DIR)/flac-1.3.2/src/libFLAC/bitmath.c \
|
|
|
|
$(DEPS_DIR)/flac-1.3.2/src/libFLAC/bitreader.c \
|
|
|
|
$(DEPS_DIR)/flac-1.3.2/src/libFLAC/cpu.c \
|
|
|
|
$(DEPS_DIR)/flac-1.3.2/src/libFLAC/crc.c \
|
|
|
|
$(DEPS_DIR)/flac-1.3.2/src/libFLAC/fixed.c \
|
|
|
|
$(DEPS_DIR)/flac-1.3.2/src/libFLAC/fixed_intrin_sse2.c \
|
|
|
|
$(DEPS_DIR)/flac-1.3.2/src/libFLAC/fixed_intrin_ssse3.c \
|
|
|
|
$(DEPS_DIR)/flac-1.3.2/src/libFLAC/float.c \
|
|
|
|
$(DEPS_DIR)/flac-1.3.2/src/libFLAC/format.c \
|
|
|
|
$(DEPS_DIR)/flac-1.3.2/src/libFLAC/lpc.c \
|
|
|
|
$(DEPS_DIR)/flac-1.3.2/src/libFLAC/lpc_intrin_avx2.c \
|
|
|
|
$(DEPS_DIR)/flac-1.3.2/src/libFLAC/lpc_intrin_sse2.c \
|
|
|
|
$(DEPS_DIR)/flac-1.3.2/src/libFLAC/lpc_intrin_sse41.c \
|
|
|
|
$(DEPS_DIR)/flac-1.3.2/src/libFLAC/lpc_intrin_sse.c \
|
|
|
|
$(DEPS_DIR)/flac-1.3.2/src/libFLAC/md5.c \
|
|
|
|
$(DEPS_DIR)/flac-1.3.2/src/libFLAC/memory.c \
|
|
|
|
$(DEPS_DIR)/flac-1.3.2/src/libFLAC/metadata_iterators.c \
|
|
|
|
$(DEPS_DIR)/flac-1.3.2/src/libFLAC/metadata_object.c \
|
|
|
|
$(DEPS_DIR)/flac-1.3.2/src/libFLAC/stream_decoder.c \
|
|
|
|
$(DEPS_DIR)/flac-1.3.2/src/libFLAC/window.c \
|
|
|
|
$(DEPS_DIR)/lzma-16.04/C/Alloc.c \
|
|
|
|
$(DEPS_DIR)/lzma-16.04/C/Bra86.c \
|
|
|
|
$(DEPS_DIR)/lzma-16.04/C/Bra.c \
|
|
|
|
$(DEPS_DIR)/lzma-16.04/C/BraIA64.c \
|
|
|
|
$(DEPS_DIR)/lzma-16.04/C/CpuArch.c \
|
|
|
|
$(DEPS_DIR)/lzma-16.04/C/Delta.c \
|
|
|
|
$(DEPS_DIR)/lzma-16.04/C/LzFind.c \
|
|
|
|
$(DEPS_DIR)/lzma-16.04/C/Lzma86Dec.c \
|
|
|
|
$(DEPS_DIR)/lzma-16.04/C/Lzma86Enc.c \
|
|
|
|
$(DEPS_DIR)/lzma-16.04/C/LzmaDec.c \
|
|
|
|
$(DEPS_DIR)/lzma-16.04/C/LzmaEnc.c \
|
|
|
|
$(DEPS_DIR)/lzma-16.04/C/LzmaLib.c \
|
|
|
|
$(DEPS_DIR)/lzma-16.04/C/Sort.c \
|
|
|
|
$(DEPS_DIR)/libchdr/bitstream.c \
|
|
|
|
$(DEPS_DIR)/libchdr/cdrom.c \
|
|
|
|
$(DEPS_DIR)/libchdr/chd.c \
|
|
|
|
$(DEPS_DIR)/libchdr/flac.c \
|
|
|
|
$(DEPS_DIR)/libchdr/huffman.c
|
|
|
|
|
2017-07-30 19:44:43 +00:00
|
|
|
ifeq ($(platform), win)
|
|
|
|
SOURCES_C += $(DEPS_DIR)/flac-1.3.2/src/libFLAC/windows_unicode_filenames.c
|
|
|
|
endif
|
2017-07-28 13:49:22 +00:00
|
|
|
|
2017-07-27 21:24:50 +00:00
|
|
|
SOURCES_CXX += \
|
|
|
|
$(CDROM_DIR)/CDAccess_CHD.cpp
|
|
|
|
endif
|
|
|
|
|
2016-08-07 02:56:09 +00:00
|
|
|
SOURCES_CXX += \
|
|
|
|
$(MEDNAFEN_DIR)/error.cpp \
|
|
|
|
$(MEDNAFEN_DIR)/settings.cpp \
|
|
|
|
$(MEDNAFEN_DIR)/general.cpp \
|
|
|
|
$(MEDNAFEN_DIR)/FileStream.cpp \
|
|
|
|
$(MEDNAFEN_DIR)/MemoryStream.cpp \
|
|
|
|
$(MEDNAFEN_DIR)/Stream.cpp \
|
|
|
|
$(MEDNAFEN_DIR)/state.cpp \
|
|
|
|
$(MEDNAFEN_DIR)/mempatcher.cpp \
|
|
|
|
$(MEDNAFEN_DIR)/video/Deinterlacer.cpp \
|
|
|
|
$(MEDNAFEN_DIR)/video/surface.cpp \
|
2016-08-12 00:44:16 +00:00
|
|
|
$(MEDNAFEN_DIR)/git.cpp \
|
2017-11-11 10:14:32 +00:00
|
|
|
$(CORE_DIR)/input.cpp \
|
2016-08-07 02:56:09 +00:00
|
|
|
$(CORE_DIR)/libretro.cpp
|
|
|
|
|
|
|
|
SOURCES_C += \
|
|
|
|
$(MEDNAFEN_DIR)/file.c \
|
|
|
|
$(MEDNAFEN_DIR)/mednafen-endian.c
|
|
|
|
|
2016-08-07 14:11:21 +00:00
|
|
|
SOURCES_CXX += $(MEDNAFEN_DIR)/hash/sha256.cpp \
|
|
|
|
$(MEDNAFEN_DIR)/hash/md5.cpp
|
2016-08-07 02:56:09 +00:00
|
|
|
|
|
|
|
ifneq ($(STATIC_LINKING), 1)
|
|
|
|
SOURCES_C += $(LIBRETRO_DIR)/streams/file_stream.c \
|
|
|
|
$(LIBRETRO_DIR)/string/stdstring.c
|
|
|
|
|
|
|
|
ifeq ($(NEED_THREADING), 1)
|
|
|
|
SOURCES_C += $(LIBRETRO_DIR)/rthreads/rthreads.c
|
|
|
|
endif
|
|
|
|
|
|
|
|
endif
|
|
|
|
endif
|
|
|
|
|
|
|
|
SOURCES_C += $(LIBRETRO_DIR)/file/retro_stat.c
|