Fixed some minor spelling errors.
[ginac.git] / debian / rules
index acaffa985c19b247c61d1ce9cb98453791872539..1bc08c6e2d4c410ec09d7f2ee9c23cbd79b980bc 100755 (executable)
@@ -1,51 +1,17 @@
 #!/usr/bin/make -f
 
-package=ginac
+include /usr/share/cdbs/1/class/autotools.mk
+include /usr/share/cdbs/1/rules/debhelper.mk
 
-version=$(shell expr `pwd` : '.*-\([0-9.]*\)')
-version_major=$(shell expr `pwd` : '.*-\([0-9]*\).[0-9.]*')
+ifeq (,$(findstring noopt,$(DEB_BUILD_OPTIONS)))
+CXXFLAGS += -finline-limit=1200
+endif
 
-build:
-       dh_testdir
-       ./configure --prefix=/usr --with-cint
-       $(MAKE) CXXFLAGS="-O2"
-       touch build
+# 1.5.1-1-blah (Debian version) ==> 1.5 (LT_RELEASE)
+GINAC_RELEASE := $(shell echo $(DEB_VERSION) | cut -f 1,2 -d . )
+GINACLIB := libginac$(GINAC_RELEASE)
 
-clean:
-       dh_testdir
-       dh_clean
-       -rm -f build
-       -$(MAKE) distclean
-       -rm -f `find . -name "*~"`
-       -rm -rf debian/tmp `find debian/* -type d ! -name CVS` debian/files* core
-       -rm -f debian/*substvars
-
-binary-indep: build
-       dh_testdir
-       dh_testroot
-
-binary-arch: build
-       dh_testdir
-       dh_testroot
-       dh_installdirs
-       # When is Automake going to honor FHS?
-       $(MAKE) install prefix=`pwd`/debian/tmp/usr infodir=`pwd`/debian/tmp/usr/share/info mandir=`pwd`/debian/tmp/usr/share/man
-       # Work around dumb lintian error: binary-without-manpage ginaccint.bin
-       (cd `pwd`/debian/tmp/usr/share/man/man1; ln -s ginaccint.1.gz ginaccint.bin.1.gz)
-       dh_installdocs ChangeLog NEWS README
-       dh_installchangelogs
-       dh_installmenu
-       dh_movefiles
-       dh_strip
-       dh_compress
-       dh_fixperms
-       dh_shlibdeps
-       dh_gencontrol
-       dh_makeshlibs
-       dh_installdeb
-       dh_md5sums
-       dh_builddeb
-
-binary: binary-indep binary-arch
-
-.PHONY: binary binary-arch binary-indep clean
+DEB_DH_MAKESHLIBS_ARGS := -V"$(GINACLIB) (>= $(GINAC_RELEASE).0)"
+DEB_DH_SHLIBDEPS_ARGS := --libpackage=$(GINACLIB) -l debian/$(GINACLIB)/usr/lib
+DEB_DBG_PACKAGE_ALL =
+DEB_DBG_PACKAGE_$(GINACLIB) = $(GINACLIB)-dbg