chiark / gitweb /
clean up for distribution
[elogind.git] / Makefile
1 # $Id$
2
3 CFLAGS=-Wall -pipe -W -O2 -Wextra -Wno-unused-parameter
4 VERSION=0.1
5
6 libnss_myhostname.so.2: nss-myhostname.o
7         $(CC) $(CFLAGS) -shared -o $@ -Wl,-soname,$@ $^
8         strip $@
9
10 install:
11         install -D -g root -m 644 -o root -v libnss_myhostname.so.2 /lib/libnss_myhostname.so.2
12
13 clean:
14         rm -f *.o *~ libnss_myhostname.so.2
15
16 nss-myhostname.tar.gz:
17         rm -rf "nss-myhostname-$(VERSION)"
18         mkdir "nss-myhostname-$(VERSION)"
19         cp Makefile README *.c "nss-myhostname-$(VERSION)"/
20         tar czf "nss-myhostname-$(VERSION).tar.gz" "nss-myhostname-$(VERSION)"/
21         rm -rf "nss-myhostname-$(VERSION)"
22
23 tar: nss-myhostname.tar.gz
24
25 .PHONY: clean install tar