Makefile tuning, e.g compile vmware-detect and dpkg_not_running with diet
[grml-scripts.git] / compile / Makefile
1 PROGS = ip-screen pong vmware-detect align cpu-screen dpkg_not_running reread_partition_table gtf
2
3 #ifndef CFLAGS
4 CFLAGS = -O2 -Wall
5 #endif
6
7 #ifndef LDFALGS
8 LDFLAGS = -s
9 #endif
10
11 #ifndef CC
12 CC = gcc
13 #endif
14
15 all: $(PROGS)
16
17 ip-screen: ip-screen.c
18         diet $(CC) $(CFLAGS) -o $@ $^
19         strip --strip-all $@
20
21 cpu-screen: cpu-screen.c
22         diet $(CC) $(CFLAGS) -o $@ $^
23         strip --strip-all $@
24
25 pong: pong.c
26
27 vmware-detect: vmware-detect.c
28         diet $(CC) $(CFLAGS) -o $@ $^
29         strip --strip-all $@
30
31 dpkg_not_running: dpkg_not_running.c
32         diet $(CC) $(CFLAGS) -o $@ $^
33         strip --strip-all $@
34
35 align: align.c
36
37 reread_partition_table: reread_partition_table.c
38         diet $(CC) $(CFLAGS) -o $@ $^
39         strip --strip-all $@
40
41 gtf: gtf.c
42         $(CC) gtf.c -lm -Wall -o gtf
43
44 clean:
45         rm -f $(PROGS)