-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile
executable file
·45 lines (32 loc) · 859 Bytes
/
Makefile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
ccflags = -I. -g -Wall -finline-functions -finline-small-functions
ldflags = -lpthread
featureflags =
src = main.c gadgetfs_controller.c controller_defines.c common.c usb/usbstring.c util.c
# dummy input
#src += input_dummy.c
# commands
src += input_commands/commands.c
# click
src += input_commands/click.c
featureflags += -DCLICK
# wii
src += input_commands/wii.c
ldflags += -lxwiimote
featureflags += -DWII
# mariomaker2
src += input_commands/mariomaker2.c
featureflags += -DMARIOMAKER2
# tas
src += input_commands/tas.c
featureflags += -DTAS
all: gadgetfs_controller.bin
run: gadgetfs_controller.bin
sudo ./gadgetfs_controller.bin
run_tmp: gadgetfs_controller.bin
cp $< /tmp/
sudo /tmp/$<
.PHONY: gadgetfs_controller.bin
gadgetfs_controller.bin:
gcc $(ccflags) $(featureflags) -o $@ $(src) $(ldflags)
clear:
rm gadgetfs_controller.bin