Tupfiles for super-repositories

Add minimal metadata for a Tup build system. Tup will discover any file
named "Tupfile" in a the sub-directories where it is run. In this case a
tupfile defines the core name and invokes the "include_rules" directive,
which will include the Tup rules defined in parent directories. This
allows a parent repository with platform-specific build rules to host
this repository as a submodule. The sample cores may thus be ported to
new platforms without polluting the local makefiles. Naturally the
external build rules must be synchronized with the source code herein,
the tupfiles here only define TARGET_NAME so that they will never
contradict information contained in the makefiles.

A sample Tuprules.tup for a super-repository:

ifeq ($(TARGET_NAME),advanced_tests)
	CFLAGS += -I../../libretro-common/include
	SOURCES_C += libretro-test.c
endif
CFLAGS += -O3 -Wall -pedantic -std=gnu99
: foreach $(SOURCES_C) |> !libretro_cc |> {objs}
: {objs} |> !libretro_ld |> $(TARGET_NAME)_libretro.so
This commit is contained in:
Emery Hemingway 2019-03-03 10:58:36 +01:00
parent f81b271e0b
commit fd6547e86f
17 changed files with 34 additions and 0 deletions

View file

@ -0,0 +1,2 @@
TARGET_NAME=testaudio_callback
include_rules

View file

@ -0,0 +1,2 @@
TARGET_NAME=testaudio_no_callback
include_rules

View file

@ -0,0 +1,2 @@
TARGET_NAME=testaudio_playback_wav
include_rules

View file

@ -0,0 +1,2 @@
TARGET_NAME=button_test
include_rules

2
lang/freebasic/Tupfile Normal file
View file

@ -0,0 +1,2 @@
TARGET_NAME=freebasic
include_rules

2
lang/pascal/Tupfile Normal file
View file

@ -0,0 +1,2 @@
TARGET_NAME=pascal_pong
include_rules

2
midi/midi_test/Tupfile Normal file
View file

@ -0,0 +1,2 @@
TARGET_NAME=midi_test
include_rules

2
tests/cruzes/Tupfile Normal file
View file

@ -0,0 +1,2 @@
TARGET_NAME=cruzes
include_rules

2
tests/test/Tupfile Normal file
View file

@ -0,0 +1,2 @@
TARGET_NAME=test
include_rules

View file

@ -0,0 +1,2 @@
TARGET_NAME=advanced_tests
include_rules

View file

@ -0,0 +1,2 @@
TARGET_NAME = testgl_compute_shaders
include_rules

View file

@ -0,0 +1,2 @@
TARGET_NAME = testgl_ff
include_rules

View file

@ -0,0 +1,2 @@
TARGET_NAME = testgl
include_rules

View file

@ -0,0 +1,2 @@
TARGET_NAME=testsw
include_rules

View file

@ -0,0 +1,2 @@
TARGET_NAME=testsw_vram
include_rules

View file

@ -0,0 +1,2 @@
TARGET_NAME=testvulkan_async_compute
include_rules

View file

@ -0,0 +1,2 @@
TARGET_NAME=testvulkan
include_rules