Newer
Older
# Sample debian/rules that uses debhelper.
# This file is public domain software, originally written by Joey Hess.
#
# This version is for packages that are architecture independent.
# Uncomment this to turn on verbose mode.

Yaroslav Halchenko
committed
export DH_VERBOSE=1
DEBPREFIX=$(CURDIR)/debian/tmp/usr
PYVER := $(shell pyversions -vd)

Yaroslav Halchenko
committed
ifneq (,$(filter parallel=%,$(DEB_BUILD_OPTIONS)))
NUMJOBS = $(patsubst parallel=%,%,$(filter parallel=%,$(DEB_BUILD_OPTIONS)))
MAKEFLAGS += -j$(NUMJOBS)
endif
build: build-arch build-indep
build-arch: build-stamp
build-indep: build-stamp
clean:
dh_testdir
dh_testroot
rm -f build-stamp
# Add here commands to clean up after the build process.
rm -rf ./.libs ./_libs ./.deps ./.stimfit
find -name '*.o' | xargs -r rm -f
find -name '*.lo' | xargs -r rm -f
find -name '*.a' | xargs -r rm -f
find -name '*.la' | xargs -r rm -f
find -name '*.so' | xargs -r rm -f
rm -f $(CURDIR)/test.h5
dh_autoreconf_clean
dh_autoreconf
./configure --enable-python --enable-debian --with-biosig --prefix=$(DEBPREFIX)

Yaroslav Halchenko
committed
$(MAKE)
ifeq (,$(filter nocheck,$(DEB_BUILD_OPTIONS)))
$(MAKE) check

Yaroslav Halchenko
committed
endif
./configure --enable-module --enable-debian --with-biosig --prefix=$(DEBPREFIX)

Yaroslav Halchenko
committed
$(MAKE)
mkdir $(CURDIR)/man && \
# Build architecture-independent files here.
binary-indep: build install
# We have nothing to do by default.
binary-arch: build install
dh_installchangelogs ./debian/changelog
dh_installdocs
dh_installexamples
# dh_installdebconf
# dh_installlogrotate
# dh_installemacsen
# dh_installcatalogs
# dh_installpam
# dh_installinit
# dh_installcron
# dh_installinfo
# dh_installwm
# dh_installudev
# dh_lintian
# dh_bugfiles
# dh_undocumented
dh_installman $(CURDIR)/man/stimfit.1
dh_install --sourcedir=$(CURDIR)/debian/tmp
[ -x /usr/bin/dh_python2 ] && dh_python2 -V$(PYVER) || :

Yaroslav Halchenko
committed
[ -x /usr/bin/dh_numpy ] && dh_numpy || :
dh_makeshlibs
dh_shlibdeps
dh_installdeb
dh_gencontrol
dh_md5sums
dh_builddeb
binary: binary-indep binary-arch
.PHONY: build clean binary-indep binary-arch binary install