summaryrefslogtreecommitdiff
blob: e3ff2c8fe8182cbddee7a014723da49dbb7265c8 (plain)
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
# NOTE: this Makefile is mainly for developer use, as there isn't really
# anything to build.

distapp = gentoo-bashcomp
distver := $(shell date --iso | sed -e 's~-~~g')
distpkg := $(distapp)-$(distver)

PREFIX = /usr

all:
	@echo Nothing to compile.

install:
	install -d "$(DESTDIR)$(PREFIX)/share/bash-completion"
	install -m0644 gentoo "$(DESTDIR)$(PREFIX)/share/bash-completion"
	install -d "$(DESTDIR)/etc/bash_completion.d"
	ln -snf "../..$(PREFIX)/share/bash-completion/gentoo" \
		"$(DESTDIR)/etc/bash_completion.d/gentoo"

dist:
	mkdir -p "$(distpkg)"
	cp AUTHORS ChangeLog COPYING gentoo Makefile NEWS TODO "$(distpkg)/"
	tar cjf "$(distpkg).tar.bz2" "$(distpkg)"
	rm -fr "$(distpkg)/"
	@echo "success."

dist-sign: dist
	gpg --armour --detach-sign "$(distpkg).tar.bz2"
	mv "$(distpkg).tar.bz2.asc" "$(distpkg).tar.bz2.signature"

dist-upload: dist-sign
	echo -ne "user anonymous gentoo-bashcomp\ncd incoming\nput $(distpkg).tar.bz2\nput $(distpkg).tar.bz2.signature\nbye" | \
		ftp -n ftp.berlios.de
	@echo "uploaded."