aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGravatar Christian Hesse <mail@eworm.de>2013-07-17 21:09:18 +0200
committerGravatar Christian Hesse <mail@eworm.de>2013-07-17 21:09:18 +0200
commitcdeb3a77ab58cc718e4505e2464611774c25aa4d (patch)
treebdf6be210717317fca383c7b1ed3e2b0f75f17b2
parent59d15c9f32056ede5213117b481124b44e750b1d (diff)
downloadudev-block-notify-cdeb3a77ab58cc718e4505e2464611774c25aa4d.tar.gz
udev-block-notify-cdeb3a77ab58cc718e4505e2464611774c25aa4d.tar.zst
build and install documentation
-rw-r--r--Makefile13
1 files changed, 11 insertions, 2 deletions
diff --git a/Makefile b/Makefile
index 25f88b8..c87c98a 100644
--- a/Makefile
+++ b/Makefile
@@ -1,6 +1,7 @@
# udev-block-notify - Notify about udev block events
CC := gcc
+MD := markdown
INSTALL := install
RM := rm
CFLAGS += -O2 -Wall -Werror
@@ -8,13 +9,21 @@ CFLAGS += $(shell pkg-config --cflags --libs libudev) \
$(shell pkg-config --cflags --libs libnotify)
VERSION = $(shell git describe --tags --long)
-all: udev-block-notify.c
+all: udev-block-notify README.html
+
+udev-block-notify: udev-block-notify.c
$(CC) $(CFLAGS) -o udev-block-notify udev-block-notify.c \
-DVERSION="\"$(VERSION)\""
+README.html: README.md
+ $(MD) README.md > README.html
+
install:
$(INSTALL) -D -m0755 udev-block-notify $(DESTDIR)/usr/bin/udev-block-notify
$(INSTALL) -D -m0644 udev-block-notify.desktop $(DESTDIR)/etc/xdg/autostart/udev-block-notify.desktop
+ $(INSTALL) -D -m0644 README.md $(DESTDIR)/usr/share/doc/udev-block-notify/README.md
+ $(INSTALL) -D -m0644 README.html $(DESTDIR)/usr/share/doc/udev-block-notify/README.html
+ $(INSTALL) -D -m0644 screenshot.png $(DESTDIR)/usr/share/doc/udev-block-notify/screenshot.png
clean:
- $(RM) -f *.o *~ udev-block-notify
+ $(RM) -f *.o *~ README.html udev-block-notify