#!/usr/bin/make -f DPKG_EXPORT_BUILDFLAGS = 1 include /usr/share/dpkg/buildflags.mk include /usr/share/dpkg/architecture.mk PDIR=$(CURDIR)/debian/tclthread %: dh $@ override_dh_auto_clean: dh_auto_clean # # Remove installed files rm -rf $(PDIR) configure-stamp: dh_testdir ./configure --host=$(DEB_HOST_GNU_TYPE) \ --build=$(DEB_BUILD_GNU_TYPE) \ --prefix=/usr \ --mandir=\$${prefix}/share/man \ --infodir=\$${prefix}/share/info \ --with-tcl=/usr/lib \ --enable-threads touch configure-stamp clean-aol-stamp: install-stamp $(MAKE) distclean touch clean-aol-stamp configure-aol-stamp: clean-aol-stamp dh_testdir ./configure --host=$(DEB_HOST_GNU_TYPE) \ --build=$(DEB_BUILD_GNU_TYPE) \ --prefix=/usr \ --mandir=\$${prefix}/share/man \ --infodir=\$${prefix}/share/info \ --with-tcl=/usr/lib \ --with-naviserver=/usr/share/aolserver4 \ --enable-threads touch configure-aol-stamp build: build-indep build-arch build-indep: build-arch: install-stamp build-stamp: configure-stamp dh_testdir $(MAKE) touch build-stamp build-aol-stamp: configure-aol-stamp dh_testdir $(MAKE) touch build-aol-stamp install-stamp: build-stamp dh_testdir dh_prep dh_installdirs $(MAKE) install DESTDIR=$(PDIR) install -m 755 -d $(PDIR)/usr/lib/tcltk/$(DEB_HOST_MULTIARCH) mv $(PDIR)/usr/lib/thread* $(PDIR)/usr/lib/tcltk/$(DEB_HOST_MULTIARCH) # fix up files permissions chmod -R u+w $(PDIR) # cleanup manpages mv $(PDIR)/usr/share/man/mann $(PDIR)/usr/share/man/man3 cd $(PDIR)/usr/share/man/man3 && \ for f in *.n ; do \ sed -e's/^\.TH \([^ ]\+\) n/.TH \1 3tcl/' \ $$f > `basename $$f .n`.3tcl; \ rm $$f; \ done # remove empty directories find $(PDIR) -empty -prune -exec rmdir \{\} \; touch install-stamp install-aol-stamp: build-aol-stamp dh_testdir for f in libthread*.so ; do \ for d in $(PDIR)/usr/lib/tcltk/$(DEB_HOST_MULTIARCH)/thread* ; do \ cp $$f $$d/`basename $$f .so`-aolserver.so ; \ done ; \ done touch install-aol-stamp override_dh_auto_install: override_dh_compress: dh_compress -X.tcl override_dh_gencontrol: tcltk-depends dh_gencontrol get-orig-source: wget -O tclthread_2.8.10.orig.tar.gz \ http://prdownloads.sourceforge.net/tcl/thread2.8.10.tar.gz .PHONY: build build-indep build-arch override_dh_auto_install \ override_dh_compress override_dh_gencontrol get-orig-source \ override_dh_auto_clean