2 # Sample debian/rules that uses debhelper.
3 # GNU copyright 1997 to 1999 by Joey Hess.
5 # Uncomment this to turn on verbose mode.
8 # These are used for cross-compiling and for saving the configure script
9 # from having to guess our platform (since we know it already)
10 DEB_HOST_GNU_TYPE ?= $(shell dpkg-architecture -qDEB_HOST_GNU_TYPE)
11 DEB_BUILD_GNU_TYPE ?= $(shell dpkg-architecture -qDEB_BUILD_GNU_TYPE)
14 ifneq (,$(findstring debug,$(DEB_BUILD_OPTIONS)))
18 # shared library versions, option 1
21 # option 2, assuming the library is created as src/.libs/libfoo.so.2.0.5 or so
22 version=`ls src/.libs/lib*.so.* | \
23 awk '{if (match($$0,/[0-9]+\.[0-9]+\.[0-9]+$$/)) print substr($$0,RSTART)}'`
24 major=`ls src/.libs/lib*.so.* | \
25 awk '{if (match($$0,/\.so\.[0-9]+$$/)) print substr($$0,RSTART+4)}'`
27 config.status: configure
29 # Add here commands to configure the package.
30 -test -r /usr/share/misc/config.sub && \
31 cp -f /usr/share/misc/config.sub config.sub
32 -test -r /usr/share/misc/config.guess && \
33 cp -f /usr/share/misc/config.guess config.guess
35 --host=$(DEB_HOST_GNU_TYPE) \
36 --build=$(DEB_BUILD_GNU_TYPE) \
38 --mandir=\$${prefix}/share/man \
39 --infodir=\$${prefix}/share/info \
40 --with-html-dir=\$${prefix}/share/doc/xmlsec1/html \
43 --disable-apps-crypto-dl \
48 build-stamp: config.status
51 # Add here commands to compile the package.
61 # Add here commands to clean up after the build process.
62 [ ! -f Makefile ] || $(MAKE) distclean
64 dh_clean COPYING config.log config.cache config.status config.sub \
73 # Add here commands to install the package into debian/tmp
74 $(MAKE) install prefix=$(CURDIR)/debian/tmp/usr
75 # strip unwanted RPATH caused by bug in old libtool
76 # chrpath -d $(CURDIR)/debian/tmp/usr/lib/*.so \
77 # $(CURDIR)/debian/tmp/usr/bin/xmlsec1
79 # Build architecture-independent files here.
80 binary-indep: build install
81 # We have nothing to do by default.
83 # Build architecture-dependent files here.
84 binary-arch: build install
88 dh_install -X.cvsignore --sourcedir=debian/tmp
89 dh_installexamples -X.cvsignore examples/*
90 dh_installdocs -X.sgml --all README debian/README.Debian debian/TODO.Debian
92 dh_installchangelogs ChangeLog
94 dh_compress -Xexamples/
98 dh_shlibdeps -l $(CURDIR)/debian/libxmlsec1/usr/lib
103 binary: binary-indep binary-arch
104 .PHONY: build clean binary-indep binary-arch binary install