-
Notifications
You must be signed in to change notification settings - Fork 1
/
Makefile
34 lines (33 loc) · 980 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
VERSION = 0.7
INSTALL = /usr/bin/install -c
prefix = /usr
bindir = /usr/bin
exec_prefix = /usr
mandir = /usr/share/man
top_srcdir = .
SHELL = /bin/sh
PWD := $(shell pwd)
mkinstalldirs = $(SHELL) $(top_srcdir)/mkinstalldirs
fake:
echo
install:
$(mkinstalldirs) $(DESTDIR)$(bindir)
$(mkinstalldirs) $(DESTDIR)$(mandir)/man1
${INSTALL} ldaplist $(DESTDIR)${bindir}
${INSTALL} ldaplist.1 $(DESTDIR)${mandir}/man1
bytecode:
echo "import py_compile; py_compile.compile('ldaplist')" | python
deb:
dpkg-buildpackage -rfakeroot
rpm:
ln -s . ldaplist-$(VERSION)
tar --exclude-vcs -zcf ~/rpmbuild/SOURCES/ldaplist-$(VERSION).tar.gz .
cd ~/rpmbuild/SOURCES/; rpmbuild -tb --sign --rmsource --clean ldaplist-$(VERSION).tar.gz
rm ldaplist-$(VERSION)
version:
sed -i 's/Version: .*/Version: $(VERSION)/' ldaplist.spec
sed -i 's/^VERSION=.*/VERSION=$(VERSION)/' ldaplist
sed -i 's/^VERSION =.*/VERSION = $(VERSION)/' Makefile
dch -v $(VERSION)
vi ldaplist.spec
packages: deb rpm