comparison Makefile @ 1:7abb5d8b20ea v1.0

Initial commit: part 2 I added a config GUI, and actual stuff to the README. The GUI was 'made' in Visual Studio, but I trimmed down the resource file because it had weird VS2010 skid marks all over it.
author Paper <mrpapersonic@gmail.com>
date Sun, 07 Aug 2022 10:23:10 -0400
parents d91dfd53b8b4
children 712c7fd6702a
comparison
equal deleted inserted replaced
0:d91dfd53b8b4 1:7abb5d8b20ea
1 CFLAGS=-Wall -mdll -Isrc/include -I"discord_game_sdk/c" 1 CFLAGS=-Wall -O2 -mdll -Isrc/include -I"discord_game_sdk/c"
2 ifeq ($(PROCESSOR_ARCHITECTURE),x86) 2 ifeq ($(PROCESSOR_ARCHITECTURE),x86)
3 ifeq ($(PROCESSOR_ARCHITEW6432),x86) 3 ifeq ($(PROCESSOR_ARCHITEW6432),x86)
4 CFLAGS += -I"/c/Program Files/Winamp SDK" 4 CFLAGS += -I"/c/Program Files/Winamp SDK"
5 else 5 else
6 CFLAGS += -I"/c/Program Files (x86)/Winamp SDK" 6 CFLAGS += -I"/c/Program Files (x86)/Winamp SDK"
7 endif 7 endif
8 else 8 else
9 CFLAGS += -I"/c/Program Files (x86)/Winamp SDK" 9 CFLAGS += -I"/c/Program Files (x86)/Winamp SDK"
10 endif 10 endif
11 LDFLAGS=-L"discord_game_sdk/lib/x86" -ldiscord_game_sdk 11 LDFLAGS=-L"discord_game_sdk/lib/x86" -ldiscord_game_sdk
12 DEPS=src/include/config.h src/include/dirtools.h src/include/main.h src/include/timer.h 12 DEPS=src/include/config.h src/include/dirtools.h src/include/main.h \
13 src/include/timer.h src/include/resource.h
14 RC=src/include/dialog.rc
13 OBJ=src/config.o src/dirtools.o src/main.o src/timer.o 15 OBJ=src/config.o src/dirtools.o src/main.o src/timer.o
16
17 gen_DiscordGameSDK.dll: $(OBJ) src/include/dialog.o
18 gcc -o $@ $(CFLAGS) $^ $(LDFLAGS)
19
20 src/include/dialog.o: src/include/dialog.rc
21 windres -i $< -o $@
14 22
15 src/%.o: src/%.c $(DEPS) 23 src/%.o: src/%.c $(DEPS)
16 gcc -c $(CFLAGS) $< -o $@ 24 gcc -c $(CFLAGS) $< -o $@
17 25
18 gen_DiscordGameSDK.dll: $(OBJ)
19 gcc -o $@ $(CFLAGS) $^ $(LDFLAGS)
20
21 clean: 26 clean:
22 rm -f src/*.o *.dll 27 rm -f src/*.o *.dll