diff options
Diffstat (limited to 'mkubootenv/Makefile')
-rw-r--r-- | mkubootenv/Makefile | 35 |
1 files changed, 35 insertions, 0 deletions
diff --git a/mkubootenv/Makefile b/mkubootenv/Makefile new file mode 100644 index 0000000..a0cbf46 --- /dev/null +++ b/mkubootenv/Makefile @@ -0,0 +1,35 @@ +prefix = $(HOME) + +P = mkubootenv +OBJS = mkubootenv.o crc32.o +WHERE = $(prefix)/bin/$(P) + +CFLAGS += -W -Wall -Wextra -Wstrict-prototypes -Wsign-compare -Wshadow \ + -Wchar-subscripts -Wmissing-declarations -Wmissing-prototypes \ + -Wpointer-arith -Wcast-align + +all: $(P) + +$(P): $(OBJS) + @echo " LD $@" + @$(CC) $(LDFLAGS) -o $@ $^ + +%.o: %.c %.h + @echo " CC $@" + @$(CC) $(CFLAGS) -c $< -o $@ + +%.o: %.c + @echo " CC $@" + @$(CC) $(CFLAGS) -c $< -o $@ + +install: + @echo " INSTALL $(WHERE)" + @install -m755 -D $(P) $(WHERE) + +uninstall: + @echo " UNINSTALL $(WHERE)" + @rm -f $(WHERE) + +clean: + @echo " CLEAN" + @rm -f $(OBJS) $(P) |