about summary refs log tree commit diff
path: root/c/Makefile
diff options
context:
space:
mode:
authorXiao Pan <gky44px1999@gmail.com>2024-06-15 02:22:17 -0700
committerXiao Pan <gky44px1999@gmail.com>2024-06-15 02:22:17 -0700
commit21e8d30d3e6fea0db5f345ba18936e66a1941a09 (patch)
tree84e4f338d8574ff5437c0bf58d24f8269bc52dfd /c/Makefile
parent561777b7e71d278485e200752350dea6c92b0089 (diff)
archive dynotify
Diffstat (limited to 'c/Makefile')
-rw-r--r--c/Makefile20
1 files changed, 20 insertions, 0 deletions
diff --git a/c/Makefile b/c/Makefile
new file mode 100644
index 0000000..bab4f8f
--- /dev/null
+++ b/c/Makefile
@@ -0,0 +1,20 @@
+PREFIX = /usr/local
+
+all: dynotify
+
+dynotify: dynotify.c
+#	https://stackoverflow.com/q/28533059
+#	https://stackoverflow.com/q/3220277
+	cc -Wall $$(pkg-config --cflags --libs libnotify libcurl json-c) -o $@ $<
+
+clean:
+	rm -f dynotify
+
+install: all
+	mkdir -p ${DESTDIR}${PREFIX}/bin
+	cp -f dynotify ${DESTDIR}${PREFIX}/bin
+
+uninstall:
+	rm -f ${DESTDIR}${PREFIX}/bin/dynotify
+
+.PHONY: all clean install uninstall