-
Notifications
You must be signed in to change notification settings - Fork 15
/
Makefile
31 lines (25 loc) · 1.11 KB
/
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
#!/usr/bin/make
VERSION=$(shell cat ChangeLog |grep Version | sed "s/.*: *//" | head -1)
DISTRIBUTION=/tmp/rad_eap_test-${VERSION}.tar.bz2
FILES=rad_eap_test README ChangeLog COPYING doc/rad_eap_test.1 $(wildcard patches/*)
[email protected]:/var/www/rad_eap_test/
PUB_FILES=${DISTRIBUTION} README ChangeLog rad_eap_test.html
rad_eap_test.html: doc/rad_eap_test.1
man2html <doc/rad_eap_test.1 | grep -v '^Content-type: text/html' | \
sed "s/<A HREF=\"\/cgi-bin\/man\/man2html\">Return to Main Contents<\/A>//" | \
sed "s/\/cgi-bin\/man\/man2html/http:\/\/packages.debian.org\/unstable\/doc\/man2html.html/" >rad_eap_test.html
${DISTRIBUTION}: ${FILES} rad_eap_test.html
(mkdir /tmp/rad_eap_test-${VERSION}; \
tar jcf ${DISTRIBUTION} ${FILES}; \
cd /tmp/rad_eap_test-${VERSION}; \
tar jxf ${DISTRIBUTION}; \
find -type f -exec chmod 644 {} \; ; \
chmod 755 rad_eap_test ; \
find -type d -exec chmod 755 {} \; ; \
cd ..; \
pwd ;\
tar -j -c --owner=root --group=staff -f ${DISTRIBUTION} rad_eap_test-${VERSION})
tar: ${DISTRIBUTION}
publish: tar
scp ${PUB_FILES} ${PUB_TARGET}
all: tar publish