2019-03-03 12:25:05 +01:00
|
|
|
CORE_PKGS += libc libm
|
|
|
|
LDFLAGS += --no-undefined
|
|
|
|
CFLAGS += -O3 -Wall -pedantic -std=gnu99
|
|
|
|
|
2019-05-23 12:08:51 +02:00
|
|
|
SIMPLE_DEPENDS = @(PUBLIC_SRC_STDCXX)
|
2019-03-24 20:04:00 +01:00
|
|
|
|
|
|
|
GL_DEPENDS = \
|
2019-03-31 14:05:06 +02:00
|
|
|
$(SIMPLE_DEPENDS) \
|
2019-03-24 20:04:00 +01:00
|
|
|
@(UPSTREAM_USER)/src/init/@(UPSTREAM_VERSION) \
|
|
|
|
@(PUBLIC_SRC_EXPAT) \
|
|
|
|
@(PUBLIC_SRC_MESA) \
|
|
|
|
|
2019-03-03 12:25:05 +01:00
|
|
|
ifeq ($(TARGET_NAME),testaudio_callback)
|
|
|
|
CFLAGS += -I../../libretro-common/include
|
|
|
|
SOURCES_C += libretro-test.c
|
2019-03-24 20:04:00 +01:00
|
|
|
PKG_DEPENDS += $(SIMPLE_DEPENDS)
|
2019-03-30 15:33:04 +01:00
|
|
|
: $(TUP_CWD)/audio.runtime |> !collect_pkg_runtime |>
|
2019-03-03 12:25:05 +01:00
|
|
|
endif
|
|
|
|
|
|
|
|
ifeq ($(TARGET_NAME),testaudio_no_callback)
|
|
|
|
CFLAGS += -I../../libretro-common/include
|
|
|
|
SOURCES_C += libretro-test.c
|
2019-03-24 20:04:00 +01:00
|
|
|
PKG_DEPENDS += $(SIMPLE_DEPENDS)
|
2019-03-30 15:33:04 +01:00
|
|
|
: $(TUP_CWD)/audio.runtime |> !collect_pkg_runtime |>
|
2019-03-03 12:25:05 +01:00
|
|
|
endif
|
|
|
|
|
|
|
|
ifeq ($(TARGET_NAME),testaudio_playback_wav)
|
|
|
|
CFLAGS += -I../../libretro-common/include
|
|
|
|
SOURCES_C += libretro-test.c
|
2019-03-24 20:04:00 +01:00
|
|
|
PKG_DEPENDS += $(SIMPLE_DEPENDS)
|
2019-03-30 15:33:04 +01:00
|
|
|
: $(TUP_CWD)/audio.runtime |> !collect_pkg_runtime |>
|
2019-03-03 12:25:05 +01:00
|
|
|
endif
|
|
|
|
|
|
|
|
ifeq ($(TARGET_NAME),button_test)
|
|
|
|
CFLAGS += -Ilibretro-common/include
|
|
|
|
SOURCES_C += libretro.c
|
2019-03-24 20:04:00 +01:00
|
|
|
PKG_DEPENDS += $(SIMPLE_DEPENDS)
|
2019-03-30 15:33:04 +01:00
|
|
|
: $(TUP_CWD)/simple.runtime |> !collect_pkg_runtime |>
|
2019-03-03 12:25:05 +01:00
|
|
|
endif
|
|
|
|
|
2019-03-24 20:04:00 +01:00
|
|
|
ifeq ($(TARGET_NAME),freebasic)
|
|
|
|
TARGET_NAME=
|
2019-03-03 12:25:05 +01:00
|
|
|
# : fbastest.bas |> fbc -dll %f -x %o |> libretro.so {core}
|
2019-03-24 20:04:00 +01:00
|
|
|
# PKG_DEPENDS += $(SIMPLE_DEPENDS)
|
2019-03-30 15:33:04 +01:00
|
|
|
# : $(TUP_CWD)/simple.runtime |> !collect_pkg_runtime |>
|
2019-03-24 20:04:00 +01:00
|
|
|
endif
|
2019-03-03 12:25:05 +01:00
|
|
|
|
2019-03-24 20:04:00 +01:00
|
|
|
ifeq ($(TARGET_NAME),pascal_pong)
|
|
|
|
TARGET_NAME=
|
2019-03-03 12:25:05 +01:00
|
|
|
# : pong.pas |> fpc -o%o %f |> libretro.so {core}
|
2019-03-24 20:04:00 +01:00
|
|
|
# PKG_DEPENDS += $(SIMPLE_DEPENDS)
|
2019-03-30 15:33:04 +01:00
|
|
|
# : $(TUP_CWD)/simple.runtime |> !collect_pkg_runtime |>
|
2019-03-24 20:04:00 +01:00
|
|
|
endif
|
2019-03-03 12:25:05 +01:00
|
|
|
|
|
|
|
ifeq ($(TARGET_NAME),midi_test)
|
|
|
|
SOURCES_C += libretro.c
|
2019-03-24 20:04:00 +01:00
|
|
|
PKG_DEPENDS += $(SIMPLE_DEPENDS)
|
2019-03-30 15:33:04 +01:00
|
|
|
: $(TUP_CWD)/midi.runtime |> !collect_pkg_runtime |>
|
2019-03-03 12:25:05 +01:00
|
|
|
endif
|
|
|
|
|
|
|
|
ifeq ($(TARGET_NAME),test)
|
2019-04-05 23:54:15 +02:00
|
|
|
TARGET_NAME = simple_tests
|
2019-03-03 12:25:05 +01:00
|
|
|
CFLAGS += -I../../libretro-common/include
|
|
|
|
SOURCES_C += libretro-test.c
|
2019-03-24 20:04:00 +01:00
|
|
|
PKG_DEPENDS += $(SIMPLE_DEPENDS)
|
2019-03-30 15:33:04 +01:00
|
|
|
: $(TUP_CWD)/simple.runtime |> !collect_pkg_runtime |>
|
2019-03-03 12:25:05 +01:00
|
|
|
endif
|
|
|
|
|
|
|
|
ifeq ($(TARGET_NAME),cruzes)
|
|
|
|
SOURCES_C += cruzes.c ttf2c.c
|
|
|
|
# : obj/Carlito-Regular.ttf |> ttf2c 24 font24 %f %o |> font24.h
|
|
|
|
# : obj/Carlito-Regular.ttf |> ttf2c 16 font16 %f %o |> font16.h
|
|
|
|
# : obj/Carlito-Regular.ttf |> ttf2c 10 font10 %f %o |> font10.h
|
2019-03-24 20:04:00 +01:00
|
|
|
PKG_DEPENDS += $(SIMPLE_DEPENDS)
|
2019-03-30 15:33:04 +01:00
|
|
|
: $(TUP_CWD)/simple.runtime |> !collect_pkg_runtime |>
|
2019-03-03 12:25:05 +01:00
|
|
|
endif
|
|
|
|
|
|
|
|
ifeq ($(TARGET_NAME),advanced_tests)
|
|
|
|
CFLAGS += -I../../libretro-common/include
|
|
|
|
SOURCES_C += libretro-test.c
|
2019-03-24 20:04:00 +01:00
|
|
|
PKG_DEPENDS += $(SIMPLE_DEPENDS)
|
2019-03-30 15:33:04 +01:00
|
|
|
: $(TUP_CWD)/audio.runtime |> !collect_pkg_runtime |>
|
2019-03-03 12:25:05 +01:00
|
|
|
endif
|
|
|
|
|
|
|
|
ifeq ($(TARGET_NAME),testgl_compute_shaders)
|
|
|
|
CORE_PKGS += mesa
|
2019-06-29 11:46:02 +02:00
|
|
|
CFLAGS += -Igl -DNDEBUG -DHAVE_ZIP_DEFLATE
|
2019-03-03 12:25:05 +01:00
|
|
|
SOURCES_CXX += libretro/libretro.cpp
|
|
|
|
SOURCES_CXX += gl/*.cpp
|
|
|
|
SOURCES_CXX += app/boxes.cpp
|
|
|
|
SOURCES_C += glsym/rglgen.c
|
|
|
|
SOURCES_C += glsym/glsym_gl.c
|
|
|
|
|
2019-03-31 14:05:06 +02:00
|
|
|
PKG_DEPENDS += $(GL_DEPENDS)
|
2019-03-30 15:33:04 +01:00
|
|
|
: $(TUP_CWD)/testgl.runtime |> !collect_pkg_runtime |>
|
2019-03-03 12:25:05 +01:00
|
|
|
endif
|
|
|
|
|
|
|
|
ifeq ($(TARGET_NAME),testgl_ff)
|
|
|
|
CORE_PKGS += mesa
|
|
|
|
CFLAGS +=
|
|
|
|
SOURCES_C += libretro_gl_ff_test.c glsym/rglgen.c glsym/glsym_gl.c
|
2019-03-24 20:04:00 +01:00
|
|
|
PKG_DEPENDS += $(GL_DEPENDS)
|
2019-03-30 15:33:04 +01:00
|
|
|
: $(TUP_CWD)/testgl.runtime |> !collect_pkg_runtime |>
|
2019-03-03 12:25:05 +01:00
|
|
|
endif
|
|
|
|
|
|
|
|
ifeq ($(TARGET_NAME),testgl)
|
|
|
|
CORE_PKGS += mesa
|
|
|
|
CFLAGS +=
|
|
|
|
SOURCES_C += libretro_gl_test.c
|
|
|
|
SOURCES_C += glsym/rglgen.c
|
|
|
|
SOURCES_C += glsym/glsym_gl.c
|
|
|
|
|
2019-03-24 20:04:00 +01:00
|
|
|
PKG_DEPENDS += $(GL_DEPENDS)
|
2019-03-30 15:33:04 +01:00
|
|
|
: $(TUP_CWD)/testgl.runtime |> !collect_pkg_runtime |>
|
2019-03-03 12:25:05 +01:00
|
|
|
endif
|
|
|
|
|
|
|
|
ifeq ($(TARGET_NAME),testsw)
|
|
|
|
CFLAGS += -I../../libretro-common/include
|
|
|
|
SOURCES_C += libretro-test.c
|
2019-03-24 20:04:00 +01:00
|
|
|
PKG_DEPENDS += $(SIMPLE_DEPENDS)
|
2019-03-30 15:33:04 +01:00
|
|
|
: $(TUP_CWD)/simple.runtime |> !collect_pkg_runtime |>
|
2019-03-03 12:25:05 +01:00
|
|
|
endif
|
|
|
|
|
|
|
|
ifeq ($(TARGET_NAME),testsw_vram)
|
|
|
|
CFLAGS += -I../../libretro-common/include
|
|
|
|
SOURCES_C += libretro-test.c
|
2019-03-24 20:04:00 +01:00
|
|
|
PKG_DEPENDS += $(SIMPLE_DEPENDS)
|
2019-03-30 15:33:04 +01:00
|
|
|
: $(TUP_CWD)/simple.runtime |> !collect_pkg_runtime |>
|
2019-03-03 12:25:05 +01:00
|
|
|
endif
|
|
|
|
|
|
|
|
ifeq ($(TARGET_NAME),testvulkan_async_compute)
|
|
|
|
CFLAGS += -I../../libretro-common/include -Iinclude
|
|
|
|
SOURCES_C += libretro-test.c vulkan_symbol_wrapper.c
|
2019-03-24 20:04:00 +01:00
|
|
|
PKG_DEPENDS += $(GL_DEPENDS)
|
2019-03-30 15:33:04 +01:00
|
|
|
: $(TUP_CWD)/testgl.runtime |> !collect_pkg_runtime |>
|
2019-03-03 12:25:05 +01:00
|
|
|
endif
|
|
|
|
|
|
|
|
ifeq ($(TARGET_NAME),testvulkan)
|
|
|
|
CFLAGS += -I../../libretro-common/include -Iinclude
|
|
|
|
SOURCES_C += libretro-test.c vulkan_symbol_wrapper.c
|
2019-03-24 20:04:00 +01:00
|
|
|
PKG_DEPENDS += $(GL_DEPENDS)
|
2019-03-30 15:33:04 +01:00
|
|
|
: $(TUP_CWD)/testgl.runtime |> !collect_pkg_runtime |>
|
2019-03-03 12:25:05 +01:00
|
|
|
endif
|
|
|
|
|
2019-03-24 20:04:00 +01:00
|
|
|
ifneq ($(TARGET_NAME),)
|
2019-03-03 12:25:05 +01:00
|
|
|
: foreach $(SOURCES_C) |> !libretro_cc |> {libretro_objs}
|
|
|
|
|
|
|
|
: {libretro_objs} |> !libretro_core_link |> {core}
|
2019-03-24 20:04:00 +01:00
|
|
|
: {core} |> !collect_bin |>
|
|
|
|
: |> !bin |>
|
2019-03-03 12:25:05 +01:00
|
|
|
|
2019-03-31 14:05:06 +02:00
|
|
|
: README.md |> !collect_pkg |>
|
2019-03-03 12:25:05 +01:00
|
|
|
|
2019-03-24 20:04:00 +01:00
|
|
|
endif
|