#!/usr/bin/make -f # -*- makefile -*- # Uncomment this to turn on verbose mode. #export DH_VERBOSE=1 include /usr/share/dpatch/dpatch.make CFLAGS = -g -Wall -ansi -pedantic CXX=g++ CC=gcc ifneq (,$(findstring noopt,$(DEB_BUILD_OPTIONS))) CFLAGS += -O0 else CFLAGS += -O2 endif ifeq (,$(findstring nostrip,$(DEB_BUILD_OPTIONS))) INSTALL_PROGRAM += -s endif major=$(shell grep VERMAJOR= Makefile | cut -d"=" -f2) version=$(major).$(shell grep VERMINOR= Makefile | cut -d"=" -f2) debversion=`head -n 1 debian/changelog | awk '{ print $$2 }' \ | sed -e s/"("// -e s/")"// -e s/3.0+pre//` configure: configure-stamp configure-stamp: patch-stamp dh_testdir touch configure-stamp build: build-stamp build-stamp: configure-stamp dh_testdir $(MAKE) CXXFLAGS="$(CFLAGS)" CFLAGS="$(CFLAGS)" CXX="$(CXX)" CC="$(CC)" $(MAKE) check touch build-stamp clean: unpatch dh_testdir dh_testroot rm -f build-stamp configure-stamp # Add here commands to clean up after the build process. -$(MAKE) clean SOSUFFIX=so SOPREFIX=lib STATICLIB=libmyspell*.a dh_clean install: build dh_testdir dh_testroot dh_clean -k dh_installdirs mkdir -p $(CURDIR)/debian/tmp/usr $(MAKE) install PREFIX=$(CURDIR)/debian/tmp/usr dh_install --sourcedir=debian/tmp mkdir -p debian/myspell-tools/usr/share/man/man1 pod2man debian/myspell-tools/usr/bin/ispellaff2myspell \ > debian/myspell-tools/usr/share/man/man1/ispellaff2myspell.1 for i in `dh_listpackages`; do \ mkdir -p debian/$$i/usr/share/lintian/overrides && \ echo "$$i: spelling-error-in-copyright usefull useful" \ > debian/$$i/usr/share/lintian/overrides/$$i; \ done binary-indep: build install binary-arch: build install dh_testdir dh_testroot dh_installchangelogs dh_installdocs dh_installexamples dh_installman dh_strip dh_compress dh_fixperms dh_makeshlibs dh_link dh_installdeb dh_shlibdeps dh_perl dh_gencontrol -- -v$(debversion) -Vlibmyspell3-depends=$(debversion) dh_md5sums dh_builddeb binary: binary-indep binary-arch .PHONY: build clean binary-indep binary-arch binary install configure