LogoKolab Groupware OBS > Projects
Log In

View File debian.rules of Package erlang-lager (Project home:mollekopf:branches:Kolab:Winterfell)

#!/usr/bin/make -f
# -*- makefile -*-

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

include /usr/share/dpkg/pkg-info.mk

DESTDIR=$(CURDIR)/debian/erlang-lager

%:
	sed -i 's/3\.2\.2/$(DEB_VERSION_UPSTREAM)/' src/lager.app.src
	dh $@ --buildsystem=rebar --with rebar

override_dh_auto_install:
	dh_auto_install
	for file in include/*.hrl ; do \
		fname=$$(basename $${file}) ; \
		subdir=$$(basename $$(dirname $${file})) ; \
		if [ ! -f $(DESTDIR)/usr/lib/erlang/lib/lager-$(DEB_VERSION_UPSTREAM)/$${subdir}/$${fname} ] ; then \
			install -m 755 -d $(DESTDIR)/usr/lib/erlang/lib/lager-$(DEB_VERSION_UPSTREAM)/$${subdir} ; \
			install -m 644 $${file} \
			$(DESTDIR)/usr/lib/erlang/lib/lager-$(DEB_VERSION_UPSTREAM)/$${subdir} ; \
		fi ; \
	done

	find $(CURDIR)/ | sort
	cat $(CURDIR)/debian/control

get-orig-source:
	dh_testdir
	wget -O ../erlang-lager_$(DEB_VERSION_UPSTREAM).orig.tar.gz \
		https://github.com/basho/lager/archive/$(DEB_VERSION_UPSTREAM).tar.gz