Marcin Juszkiewicz | 807e4fa | 2011-01-12 17:25:16 -0600 | [diff] [blame] | 1 | BINDIR=/usr/sbin |
Amit Arora | 39f2954 | 2010-09-14 12:03:22 +0530 | [diff] [blame] | 2 | MANDIR=/usr/share/man/man8 |
| 3 | |
Daniel Lezcano | 00af33e | 2011-05-24 15:27:49 +0200 | [diff] [blame] | 4 | CFLAGS?=-O1 -g -Wall -Wshadow |
Amit Arora | e9e16b0 | 2010-08-03 10:15:20 +0530 | [diff] [blame] | 5 | CC?=gcc |
| 6 | |
Thara Gopinath | 9cee8a5 | 2017-07-14 13:25:18 -0400 | [diff] [blame^] | 7 | OBJS = powerdebug.o sensor.o clocks.o regulator.o gpio.o genpd.o\ |
Daniel Lezcano | 8be5260 | 2011-06-21 00:57:08 +0200 | [diff] [blame] | 8 | display.o tree.o utils.o mainloop.o |
Amit Arora | 728e0c9 | 2010-09-14 12:06:09 +0530 | [diff] [blame] | 9 | |
| 10 | default: powerdebug |
Amit Arora | e9e16b0 | 2010-08-03 10:15:20 +0530 | [diff] [blame] | 11 | |
Amit Arora | 39f2954 | 2010-09-14 12:03:22 +0530 | [diff] [blame] | 12 | powerdebug.8.gz: powerdebug.8 |
| 13 | gzip -c $< > $@ |
Amit Arora | e9e16b0 | 2010-08-03 10:15:20 +0530 | [diff] [blame] | 14 | |
| 15 | powerdebug: $(OBJS) powerdebug.h |
Amit Arora | 39f2954 | 2010-09-14 12:03:22 +0530 | [diff] [blame] | 16 | $(CC) ${CFLAGS} $(OBJS) -lncurses -o powerdebug |
Amit Arora | e9e16b0 | 2010-08-03 10:15:20 +0530 | [diff] [blame] | 17 | |
Amit Arora | 39f2954 | 2010-09-14 12:03:22 +0530 | [diff] [blame] | 18 | install: powerdebug powerdebug.8.gz |
Marcin Juszkiewicz | 807e4fa | 2011-01-12 17:25:16 -0600 | [diff] [blame] | 19 | install -d ${DESTDIR}${BINDIR} ${DESTDIR}${MANDIR} |
| 20 | install -m 0755 powerdebug ${DESTDIR}${BINDIR} |
| 21 | install -m 0644 powerdebug.8.gz ${DESTDIR}${MANDIR} |
Amit Arora | e9e16b0 | 2010-08-03 10:15:20 +0530 | [diff] [blame] | 22 | |
Amit Arora | 728e0c9 | 2010-09-14 12:06:09 +0530 | [diff] [blame] | 23 | all: powerdebug powerdebug.8.gz |
| 24 | |
Amit Arora | e9e16b0 | 2010-08-03 10:15:20 +0530 | [diff] [blame] | 25 | clean: |
Daniel Lezcano | 00af33e | 2011-05-24 15:27:49 +0200 | [diff] [blame] | 26 | rm -f powerdebug ${OBJS} powerdebug.8.gz |