From eea8979a05b2cbabfc19b9d49ea3dbf603c9f53d Mon Sep 17 00:00:00 2001 From: Mattias Andrée Date: Sat, 1 Jun 2024 12:49:51 +0200 Subject: First commit MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Mattias Andrée --- Makefile | 41 +++++++++++++++++++++++++++++++++++++++++ 1 file changed, 41 insertions(+) create mode 100644 Makefile (limited to 'Makefile') diff --git a/Makefile b/Makefile new file mode 100644 index 0000000..31cea4c --- /dev/null +++ b/Makefile @@ -0,0 +1,41 @@ +.POSIX: + +CONFIGFILE = config.mk +include $(CONFIGFILE) + +OBJ =\ + alsause.o + +HDR = + +all: alsause +$(OBJ): $(HDR) + +.c.o: + $(CC) -c -o $@ $< $(CFLAGS) $(CPPFLAGS) + +alsause: $(OBJ) + $(CC) -o $@ $(OBJ) $(LDFLAGS) + +install: alsause + mkdir -p -- "$(DESTDIR)$(PREFIX)/bin" + mkdir -p -- "$(DESTDIR)$(MANPREFIX)/man1/" + cp -- alsause "$(DESTDIR)$(PREFIX)/bin/" + cp -- alsause.1 "$(DESTDIR)$(MANPREFIX)/man1/" + +post-install: + chown -- '0:0' "$(DESTDIR)$(PREFIX)/bin/alsause" + chmod -- 4755 "$(DESTDIR)$(PREFIX)/bin/alsause" + +uninstall: + -rm -f -- "$(DESTDIR)$(PREFIX)/bin/alsause" + -rm -f -- "$(DESTDIR)$(MANPREFIX)/man1/alsause.1" + +clean: + -rm -f -- *.o *.a *.lo *.su *.so *.so.* *.gch *.gcov *.gcno *.gcda + -rm -f -- alsause + +.SUFFIXES: +.SUFFIXES: .o .c + +.PHONY: all install post-install uninstall clean -- cgit v1.2.3-70-g09d2