aboutsummaryrefslogtreecommitdiff
path: root/Makefile
blob: 92d05e55095a72240a5f9515ffb6a6838a96f9c3 (plain)
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
CC=arm-linux-gnueabi-gcc

all: bin bin/kblightd

clean:
	rm -rf bin

bin:
	mkdir bin

bin/kblightd: src/main.c
	${CC} -static $^ -o $@

run_prep:
	adb root

run: all run_prep
	make kill

	adb push bin/kblightd /sbin/
	adb shell "nohup /sbin/kblightd > /dev/null &" &

debug: all run_prep
	make kill

	adb push bin/kblightd /sbin/
	adb shell "/sbin/kblightd"

kill: all
	adb shell -x pkill kblightd