summary refs log tree commit diff
path: root/bin/Makefile
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--bin/Makefile94
1 files changed, 47 insertions, 47 deletions
diff --git a/bin/Makefile b/bin/Makefile
index 6b6452aa..571313e5 100644
--- a/bin/Makefile
+++ b/bin/Makefile
@@ -1,66 +1,66 @@
 PREFIX = ~/.local
 
-BINS += atch
-BINS += dtch
-BINS += glitch
-BINS += hnel
-BINS += modem
-BINS += open
-BINS += pbcopy
-BINS += pbd
-BINS += pbpaste
-BINS += pngo
-BINS += psf2png
-BINS += scheme
-BINS += ttpre
-BINS += wake
-BINS += xx
-
-BINS_BSD += watch
-
-BINS_LINUX += bri
-BINS_LINUX += fbatt
-BINS_LINUX += fbclock
-BINS_LINUX += psfed
-
-BINS_ALL = $(BINS) $(BINS_BSD) $(BINS_LINUX)
-MAN1_ALL = $(BINS_ALL:%=man/%.1)
+BIN += atch
+BIN += dtch
+BIN += glitch
+BIN += hnel
+BIN += modem
+BIN += open
+BIN += pbcopy
+BIN += pbd
+BIN += pbpaste
+BIN += pngo
+BIN += psf2png
+BIN += scheme
+BIN += ttpre
+BIN += wake
+BIN += xx
+
+BIN_BSD += watch
+
+BIN_LINUX += bri
+BIN_LINUX += fbatt
+BIN_LINUX += fbclock
+BIN_LINUX += psfed
+
+BIN_ALL = $(BIN) $(BIN_BSD) $(BIN_LINUX)
+MAN_ALL = $(BIN_ALL:%=man/%.1)
 
 CFLAGS += -Wall -Wextra -Wpedantic
-LDLIBS = -lcurses -lm -lutil -lz
+LDLIBS = -lm -lutil -lz
 
-any: .gitignore tags $(BINS)
+any: .gitignore tags $(BIN)
 
-bsd: any $(BINS_BSD)
+bsd: any $(BIN_BSD)
 
-linux: any $(BINS_LINUX)
+linux: any $(BIN_LINUX)
 
-.gitignore: Makefile
-	echo '*.o' tags scheme.h $(BINS_ALL) scheme.png \
-		| tr ' ' '\n' \
-		> .gitignore
+scheme.h: scheme
+	./scheme -c > scheme.h
 
-tags: *.c
-	ctags -w *.c
+fbatt.o fbclock.o: scheme.h
+
+psf2png.o scheme.o: png.h
 
 atch: dtch
 	ln -f dtch atch
 
-fbatt.o fbclock.o: scheme.h
-
-scheme.h: scheme
-	./scheme -c > scheme.h
-
 open pbcopy pbpaste: pbd
 	ln -f pbd $@
 
-psf2png.o scheme.o: png.h
-
 scheme.png: scheme
 	./scheme -t -g > scheme.png
 
+tags: *.h *.c
+	ctags -w *.h *.c
+
+.gitignore: Makefile
+	echo '*.o' scheme.h scheme.png tags $(BIN_ALL) \
+		| tr ' ' '\n' \
+		> .gitignore
+
 clean:
-	rm -f *.o tags scheme.h $(BINS_ALL) scheme.png
+	rm -f *.o scheme.h scheme.png tags $(BIN_ALL)
 
 README: man/bin.7
 	mandoc man/bin.7 | col -b -x > README
@@ -71,9 +71,9 @@ setuid: bri
 
 link:
 	mkdir -p $(PREFIX)/bin $(PREFIX)/share/man/man1
-	ln -s -f $(BINS_ALL:%=$(PWD)/%) $(PREFIX)/bin
-	ln -s -f $(MAN1_ALL:%=$(PWD)/%) $(PREFIX)/share/man/man1
+	ln -s -f $(BIN_ALL:%=$(PWD)/%) $(PREFIX)/bin
+	ln -s -f $(MAN_ALL:%=$(PWD)/%) $(PREFIX)/share/man/man1
 
 unlink:
-	rm -f $(BINS_ALL:%=$(PREFIX)/bin/%)
-	rm -f $(MAN1_ALL:%=$(PREFIX)/share/man/man1/%)
+	rm -f $(BIN_ALL:%=$(PREFIX)/bin/%)
+	rm -f $(MAN_ALL:man/%=$(PREFIX)/share/man/man1/%)