initial commit
This commit is contained in:
commit
16399fab9e
7 changed files with 142 additions and 0 deletions
24
Makefile
Normal file
24
Makefile
Normal file
|
@ -0,0 +1,24 @@
|
|||
CC ?= gcc
|
||||
CFLAGS ?= -std=c99 -Wall -Werror
|
||||
OBJ = wakeup.o
|
||||
BIN = wakeup
|
||||
PREFIX ?= /usr
|
||||
|
||||
prog: $(OBJ)
|
||||
$(CC) $(CFLAGS) $(OBJ) -o $(BIN)
|
||||
|
||||
%.o: %.c
|
||||
$(CC) $(CFLAGS) -c $<
|
||||
|
||||
install: prog
|
||||
mkdir -p ${PREFIX}/bin
|
||||
install -m 755 -o root -g root -s ${BIN} ${PREFIX}/bin
|
||||
|
||||
format:
|
||||
clang-format -i *.c
|
||||
|
||||
clean:
|
||||
rm *.o
|
||||
rm $(BIN)
|
||||
|
||||
.PHONY: install format clean
|
Loading…
Add table
Add a link
Reference in a new issue