view Makefile @ 69:79a35af2cb56 v1.3

gui.c: Add angled brackets around case mmmmmmffmfmgm
author Paper <37962225+mrpapersonic@users.noreply.github.com>
date Thu, 05 Jan 2023 07:51:33 -0500
parents 207684d44b54
children 8f90d5addda9
line wrap: on
line source

CFLAGS=-Wall -O2 -fstack-protector -fdata-sections -ffunction-sections
LDFLAGS=

ifeq ($(shell uname -s),Darwin)  # macOS is the odd one...
	LDFLAGS+=-Wl,-dead_strip
else
	LDFLAGS+=-Wl,--gc-sections
endif

src/%.o : src/%.c
	$(CC) -c $(CFLAGS) $< -o $@

msvpvf: src/main.o src/common.o
	$(CC) $(CFLAGS) -o $@ $^  $(LDFLAGS)

# GUI is windows-only, please use cross-compiler!
gui: src/gui.o src/common.o
	$(CC) $(CFLAGS) -o $@ $^ $(LDFLAGS) -mwindows -lshlwapi

clean:
	rm -f src/*.o *.exe msvpvf gui