beetle-psx-libretro/Makefile.common

172 lines
3.9 KiB
Makefile
Raw Normal View History

2015-07-26 15:02:51 +00:00
SOURCES_CXX :=
SOURCES_C :=
2015-09-30 00:49:00 +00:00
LIBRETRO_DIR := $(CORE_DIR)/libretro-common
2015-07-26 15:02:51 +00:00
MEDNAFEN_DIR := $(CORE_DIR)/mednafen
CORE_EMU_DIR := $(MEDNAFEN_DIR)/psx
2016-03-24 17:12:12 +00:00
ifeq ($(HAVE_OPENGL), 1)
2016-02-11 21:45:48 +00:00
ifeq ($(GLES), 1)
GLFLAGS := -DHAVE_OPENGLES -DHAVE_OPENGLES2
CFLAGS += $(GLFLAGS)
CXXFLAGS += $(GLFLAGS)
SOURCES_C += $(LIBRETRO_DIR)/glsym/glsym_es2.c
else
GLFLAGS := -DHAVE_OPENGL
CFLAGS += $(GLFLAGS)
CXXFLAGS += $(GLFLAGS)
SOURCES_C += $(LIBRETRO_DIR)/glsym/glsym_gl.c
endif
SOURCES_C += $(LIBRETRO_DIR)/glsm/glsm.c \
$(LIBRETRO_DIR)/glsym/rglgen.c
2016-04-09 19:53:44 +00:00
2016-04-09 20:41:17 +00:00
SOURCES_C += \
2016-04-10 00:40:36 +00:00
$(CORE_DIR)/rsx/rsx_lib_gl.c \
2016-04-09 20:41:17 +00:00
$(CORE_DIR)/rsx/gl/framebuffer.c \
2016-04-09 20:58:12 +00:00
$(CORE_DIR)/rsx/gl/texture.c \
$(CORE_DIR)/rsx/gl/vertex.c
2016-02-11 21:45:48 +00:00
endif
2015-09-30 00:49:00 +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
2015-07-26 15:02:51 +00:00
2014-11-02 06:47:01 +00:00
ifeq ($(HAVE_GRIFFIN),1)
2016-01-31 10:36:13 +00:00
SOURCES_CXX += beetle_psx_griffin.cpp \
2015-07-26 15:02:51 +00:00
$(CORE_EMU_DIR)/dma.cpp \
$(CORE_EMU_DIR)/sio.cpp
2016-01-31 10:36:13 +00:00
SOURCES_C += beetle_psx_griffin_c.c
2014-11-02 06:47:01 +00:00
endif
2015-07-29 16:32:39 +00:00
ifeq ($(DEBUG), 1)
2016-01-31 10:36:13 +00:00
SOURCES_CXX += $(CORE_EMU_DIR)/dis.cpp
2015-07-29 16:32:39 +00:00
endif
2014-11-02 06:47:01 +00:00
ifeq ($(NEED_THREADING), 1)
2016-02-09 17:02:52 +00:00
FLAGS += -DWANT_THREADING -DHAVE_THREADS
2014-11-02 06:47:01 +00:00
endif
ifeq ($(NEED_CRC32), 1)
FLAGS += -DWANT_CRC32
2015-07-26 15:02:51 +00:00
SOURCES_C += $(CORE_DIR)/scrc32.c
2014-11-02 06:47:01 +00:00
endif
ifeq ($(NEED_DEINTERLACER), 1)
FLAGS += -DNEED_DEINTERLACER
endif
2015-07-26 15:02:51 +00:00
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
2016-01-31 10:36:13 +00:00
ifeq ($(NEED_CD), 1)
FLAGS += -DNEED_CD
endif
ifeq ($(NEED_TREMOR), 1)
FLAGS += -DNEED_TREMOR
endif
ifneq ($(HAVE_GRIFFIN), 1)
SOURCES_CXX += \
$(CORE_EMU_DIR)/irq.cpp \
$(CORE_EMU_DIR)/timer.cpp \
$(CORE_EMU_DIR)/dma.cpp \
$(CORE_EMU_DIR)/frontio.cpp \
$(CORE_EMU_DIR)/sio.cpp \
$(CORE_EMU_DIR)/cpu.cpp \
$(CORE_EMU_DIR)/gte.cpp \
$(CORE_EMU_DIR)/cdc.cpp \
$(CORE_EMU_DIR)/spu.cpp \
$(CORE_EMU_DIR)/gpu.cpp \
$(CORE_EMU_DIR)/mdec.cpp \
$(CORE_EMU_DIR)/input/gamepad.cpp \
$(CORE_EMU_DIR)/input/dualanalog.cpp \
$(CORE_EMU_DIR)/input/dualshock.cpp \
$(CORE_EMU_DIR)/input/justifier.cpp \
$(CORE_EMU_DIR)/input/guncon.cpp \
$(CORE_EMU_DIR)/input/negcon.cpp \
$(CORE_EMU_DIR)/input/memcard.cpp \
$(CORE_EMU_DIR)/input/multitap.cpp \
$(CORE_EMU_DIR)/input/mouse.cpp
ifeq ($(NEED_TREMOR), 1)
SOURCES_C += $(wildcard $(MEDNAFEN_DIR)/tremor/*.c)
endif
2015-07-26 15:02:51 +00:00
2014-11-02 06:47:01 +00:00
ifeq ($(NEED_CD), 1)
2015-07-26 15:02:51 +00:00
SOURCES_CXX += $(MEDNAFEN_DIR)/cdrom/CDAccess.cpp \
2014-11-02 06:47:01 +00:00
$(MEDNAFEN_DIR)/cdrom/CDAccess_Image.cpp \
$(MEDNAFEN_DIR)/cdrom/CDAccess_CCD.cpp \
$(MEDNAFEN_DIR)/cdrom/SimpleFIFO.cpp \
$(MEDNAFEN_DIR)/cdrom/audioreader.cpp \
$(MEDNAFEN_DIR)/cdrom/misc.cpp \
2014-11-02 06:47:01 +00:00
$(MEDNAFEN_DIR)/cdrom/cdromif.cpp
2016-01-31 10:36:13 +00:00
endif
2015-07-28 21:03:58 +00:00
SOURCES_C += \
2015-07-28 23:14:10 +00:00
$(MEDNAFEN_DIR)/cdrom/CDUtility.c \
2015-07-28 21:17:20 +00:00
$(MEDNAFEN_DIR)/cdrom/galois.c \
2015-07-28 21:27:46 +00:00
$(MEDNAFEN_DIR)/cdrom/l-ec.c \
2015-07-28 23:02:54 +00:00
$(MEDNAFEN_DIR)/cdrom/lec.c \
2015-07-28 21:36:17 +00:00
$(MEDNAFEN_DIR)/cdrom/recover-raw.c \
2015-07-28 21:03:58 +00:00
$(MEDNAFEN_DIR)/cdrom/edc_crc32.c
2016-01-31 05:00:36 +00:00
2015-07-26 15:02:51 +00:00
SOURCES_CXX += \
2015-07-25 16:06:37 +00:00
$(MEDNAFEN_DIR)/error.cpp \
2014-11-02 06:47:01 +00:00
$(MEDNAFEN_DIR)/settings.cpp \
$(MEDNAFEN_DIR)/general.cpp \
$(MEDNAFEN_DIR)/FileStream.cpp \
$(MEDNAFEN_DIR)/MemoryStream.cpp \
$(MEDNAFEN_DIR)/Stream.cpp \
$(MEDNAFEN_DIR)/state.cpp \
2015-07-25 16:06:37 +00:00
$(MEDNAFEN_DIR)/mempatcher.cpp \
2014-11-02 06:47:01 +00:00
$(MEDNAFEN_DIR)/video/Deinterlacer.cpp \
$(MEDNAFEN_DIR)/video/surface.cpp \
2015-07-26 15:02:51 +00:00
$(CORE_DIR)/libretro.cpp
2014-11-02 06:47:01 +00:00
2015-07-26 15:02:51 +00:00
SOURCES_C += \
2015-07-25 16:26:40 +00:00
$(MEDNAFEN_DIR)/file.c \
2016-04-08 15:03:52 +00:00
$(CORE_DIR)/rsx/rsx_intf.c \
2015-08-06 13:14:15 +00:00
$(MEDNAFEN_DIR)/md5.c \
2015-07-25 16:26:40 +00:00
$(MEDNAFEN_DIR)/mednafen-endian.c
2014-11-02 06:47:01 +00:00
2015-09-30 00:49:00 +00:00
ifneq ($(STATIC_LINKING), 1)
SOURCES_C += $(LIBRETRO_DIR)/streams/file_stream.c \
2016-01-31 05:00:36 +00:00
$(MEDNAFEN_DIR)/trio/trio.c \
$(MEDNAFEN_DIR)/trio/triostr.c
2015-10-03 06:04:28 +00:00
ifeq ($(NEED_THREADING), 1)
2016-03-08 16:29:28 +00:00
SOURCES_C += $(LIBRETRO_DIR)/rthreads/rthreads.c
2015-10-03 06:04:28 +00:00
endif
2016-01-31 10:36:13 +00:00
2015-09-30 00:49:00 +00:00
endif
2016-01-31 05:00:36 +00:00
endif
2016-01-31 10:36:13 +00:00
SOURCES_C += $(LIBRETRO_DIR)/file/retro_stat.c