genode-ehmry/libretro/cores/Tuprules.tup

43 lines
1.3 KiB
Plaintext

!libretro_cc = |> ^ CC %f^ \
$(CC) \
`pkg-config --cflags $(CORE_PKGS)` \
$(CFLAGS) $(INCFLAGS) \
`pkg-config --cflags genode-lib` \
-c %f -o %o \
|> %f.o
!libretro_cxx = |> ^ CXX %f^ \
$(CXX) \
`pkg-config --cflags $(CORE_PKGS)` \
$(CFLAGS) $(CXXFLAGS) $(INCFLAGS) \
`pkg-config --cflags genode-lib` \
-c %f -o %o \
|> %f.o
!libretro_core_link = |> ^o LD %d^ \
$(LD) %f -o %o \
-shared --version-script=$(LINK_T) $(NO_UNDEFINED) \
$(LDFLAGS) \
`pkg-config --libs $(CORE_PKGS)` \
`pkg-config --libs genode-lib` \
|> libretro.so
!publish_core = | libretro.so |> ^ STRIP %o^ \
strip -o %o %f \
|> $(DEPOT_BIN_DIR)/libretro-$(TARGET_NAME)/@(DEPOT_VERSION)/%b
!publish_core_archives = |> ^ varse %d archives^ \
tup varsed %f %o ; \
echo @(DEPOT_USER)/src/libretro-$(TARGET_NAME)/@(DEPOT_VERSION) >> %o \
|> $(DEPOT_PKG_DIR)/$(TARGET_NAME)/@(DEPOT_VERSION)/archives
!publish_core_runtime = |> ^ validate %d runtime^ \
xmllint -schema $(ERRATA_DIR)/runtime.xsd %f > %o \
|> $(DEPOT_PKG_DIR)/$(TARGET_NAME)/@(DEPOT_VERSION)/runtime $(DEPOT_DIR)/<libretro-runtimes>
!publish_core_metadata = |> ^ CP %o^ cp %f %o |> $(DEPOT_PKG_DIR)/$(TARGET_NAME)/@(DEPOT_VERSION)/%b
LINK_T = $(TUP_CWD)/link.T
CFLAGS += -D__LIBRETRO__ -DFRONTEND_SUPPORTS_RGB565
NO_UNDEFINED = --no-undefined