forked from poliva/lightum
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathMakefile
35 lines (29 loc) · 886 Bytes
/
Makefile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
DESTDIR?=/
SHELL = /bin/sh
CC?=gcc -O
CFLAGS = `pkg-config --cflags dbus-1` -Wall
LDFLAGS= `pkg-config --libs dbus-1` -lX11 -lXext -lXss
INSTALL = /usr/bin/install -c
INSTALLDATA = /usr/bin/install -c -m 644
srcdir = .
prefix = $(DESTDIR)
bindir = $(prefix)/usr/bin
docdir = $(prefix)/usr/share/doc
OBJ=functions.o dbus.o configfile.o lightum.o
BIN=lightum
all: ${OBJ}
$(CC) $(CFLAGS) ${OBJ} $(LDFLAGS) -o ${BIN}
install: all
mkdir -p $(bindir)
$(INSTALL) lightum $(bindir)/lightum
mkdir -p $(prefix)/etc/xdg/autostart/
$(INSTALLDATA) lightum.desktop $(prefix)/etc/xdg/autostart/
mkdir -p $(docdir)/lightum/
$(INSTALLDATA) $(srcdir)/README $(docdir)/lightum/
$(INSTALLDATA) $(srcdir)/LICENSE $(docdir)/lightum/
uninstall:
rm -rf $(bindir)/lightum
rm -rf $(prefix)/etc/xdg/autostart/lightum.desktop
rm -rf $(docdir)/lightum/
clean:
rm lightum *.o 2>/dev/null || exit 0