PushA_NX/Makefile

23 lines
571 B
Makefile
Raw Permalink Normal View History

2017-12-31 18:49:45 +01:00
ifeq ($(strip $(LIBTRANSISTOR_HOME)),)
$(error "Please set LIBTRANSISTOR_HOME in your environment. export LIBTRANSISTOR_HOME=<path to libtransistor>")
endif
PROGRAM := hello
OBJ := hello.o draw.o input.o
include $(LIBTRANSISTOR_HOME)/libtransistor.mk
all: $(PROGRAM).nro
%.o: %.c
$(CC) $(CC_FLAGS) -Wno-pointer-arith -c -o $@ $<
%.o: %.S
$(AS) $(AS_FLAGS) $< -filetype=obj -o $@
$(PROGRAM).nro.so: ${OBJ} $(LIBTRANSITOR_NRO_LIB) $(LIBTRANSISTOR_COMMON_LIBS)
2018-07-22 07:28:37 +02:00
$(LD) $(LD_FLAGS) -lSDL2 -o $@ ${OBJ} $(LIBTRANSISTOR_NRO_LDFLAGS)
2017-12-31 18:49:45 +01:00
clean:
2018-07-22 07:28:37 +02:00
rm -rf *.o *.nso *.nro *.so