/tags/debian_5-0-1_0-potato-4/debian/rules
# · Makefile · 128 lines · 92 code · 16 blank · 20 comment · 1 complexity · 2b64a38bc60a714538f3f0f74a641c54 MD5 · raw file
- #!/usr/bin/make -f
- # -*- Makefile -*-
- # Made with the aid of dh_make, by Craig Small
- # Sample debian/rules that uses debhelper. GNU copyright 1997 by Joey Hess.
- # This version is for a hypothetical package that builds an
- # architecture-dependant package, as well as an architecture-independant
- # package.
- # Modified by Rafael Laboissiere <rafael@icp.inpg.fr> on 1998/06/12
- # for the plplot package
- # Uncomment this to turn on verbose mode.
- #export DH_VERBOSE=1
- debbase := $(shell pwd)/debian
- debtmp := $(debbase)/tmp
- debusr := $(debtmp)/usr
- deblib := $(debusr)/lib
- debdoc := $(debusr)/share/doc
- cfflags := --with-double --disable-linuxvga --without-rpath
- build: build-stamp
- build-stamp:
- dh_testdir
- ( cd cf ; \
- autoconf ; \
- mv configure .. )
- # Build first bare libraries (no Tcl/Tk)
- ./configure --prefix=/usr --disable-tcl --disable-tk \
- --disable-python $(cfflags)
- # This PLLIB_PATH setting is necessary to avoid the lintian error
- # ldconfig-symlink-referencing-wrong-file
- make PLLIB_PATH=
- mv tmp/lib*.{a,so}* tmp/plrender $(debbase)
- # Build the Tcl/Tk libraries
- ./configure --prefix=/usr --enable-tcl --enable-tk \
- --enable-python $(cfflags)
- make PLLIB_PATH=
- touch build-stamp
- clean:
- dh_testdir
- dh_testroot
- rm -f build-stamp
- -$(MAKE) clean
- rm -f configure confdefs.h config.log $(debbase)/lib* \
- $(debbase)/plrender
- dh_clean
- install: install-stamp
- install-stamp: build-stamp
- dh_testdir
- dh_testroot
- dh_clean -k
- (cd tmp; make PREFIX=$(debusr) install)
- # This hack ought to go away when it is fixed upstream
- chmod -x $(deblib)/plplot5.0.1/tcl/plcolor.tcl
- # Temporary hack
- rm -f $(debusr)/bin/plplot_linkage
- ( cd $(debdoc)/plplot ; \
- mv CHANGES changelog ; \
- rm -f Copyright COPYING.LIB mklinks README.local )
- dh_installmanpages --package=plplot
- dh_movefiles --package=python-plplot
- # Make x16.py non-executable. Temporary hack.
- chmod -x \
- $(debbase)/python-plplot/usr/share/doc/plplot/examples/python/x16.py
- touch install-stamp
- # Build architecture-independent files here.
- binary-indep: build install
- dh_testversion ge 2.0.86
- dh_testdir -i
- dh_testroot -i
- dh_installdocs -i
- dh_installchangelogs -i
- dh_movefiles -i
- dh_compress -i
- dh_fixperms -i
- dh_suidregister -i
- dh_installdeb -i
- dh_gencontrol -i
- dh_md5sums -i
- dh_builddeb -i
- binary-arch: build install
- dh_testversion ge 2.0.86
- dh_testdir -a
- dh_testroot -a
- dh_installdocs -a
- dh_installchangelogs -a
- dh_installdirs -a
- rm -f $(deblib)/libplcxxd.{so.5.*,so.5}
- mv $(debbase)/libplcxxd.{so.5.*,so.5} $(deblib)
- dh_movefiles -a
- # Why do not dh_movefiles remove empty dirs? Grumpf...
- ( cd $(debusr) ; \
- rm -rf include lib share/info share/man share/doc/plplot/examples )
- mv $(debbase)/libplplotd.{so.5.*,so.5} \
- $(debbase)/plplot-xwin/usr/lib
- mv $(debbase)/plrender $(debbase)/plplot-xwin/usr/bin
- cp $(debbase)/plrender.1 $(debbase)/plplot-xwin/usr/share/man/man1
- dh_strip -a
- dh_compress -a -Xexamples/
- dh_fixperms -a
- dh_suidregister -a
- dh_makeshlibs -a
- dh_installdeb -a
- dh_shlibdeps -a
- for i in xwin tcl ; do \
- dh_shlibdeps --package=plplot-$$i \
- -l$(debbase)/plplot-$$i/usr/lib ; \
- done
- dh_gencontrol -a
- dh_md5sums -a
- dh_builddeb -a
- source diff:
- @echo >&2 'source and diff are obsolete - use dpkg-source -b'; false
- binary: binary-indep binary-arch
- .PHONY: build clean binary-indep binary-arch binary