rules 650 Bytes
Newer Older
ale's avatar
ale committed
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23
#!/usr/bin/make -f
# -*- makefile -*-

# Uncomment this to turn on verbose mode.
#export DH_VERBOSE=1

# This has to be exported to make some magic below work.
export DH_OPTIONS

DEBDIR = $(CURDIR)/debian
PKGDIR = $(DEBDIR)/liber

%:
	dh $@ 

override_dh_install:
	# Build the sources using your locally-installed Go version.
	# This is crazy, clearly, but it's a temporary workaround for wheezy.
	install -m 755 -o root -g root -d $(PKGDIR)/usr/bin
	install -m 755 -o root -g root -d $(PKGDIR)/usr/share/liber
	go build -o $(PKGDIR)/usr/bin/liber cmd/liber/liber.go
	(umask 022; cp -R --preserve=timestamps htdocs $(PKGDIR)/usr/share/liber/htdocs)