]> www.ginac.de Git - ginac.git/blob - debian/rules
Added const_iterator, const_preorder_iterator, const_postorder_iterator. The
[ginac.git] / debian / rules
1 #!/usr/bin/make -f
2
3 # Uncomment this to turn on verbose mode.
4 #export DH_VERBOSE=1
5
6 # This is the debhelper compatability version to use.
7 export DH_COMPAT=4
8 # This has to be exported to make some magic below work.
9 export DH_OPTIONS
10
11 # These are used for cross-compiling and for saving the configure script
12 # from having to guess our platform (since we know it already)
13 DEB_HOST_GNU_TYPE   ?= $(shell dpkg-architecture -qDEB_HOST_GNU_TYPE)
14 DEB_BUILD_GNU_TYPE  ?= $(shell dpkg-architecture -qDEB_BUILD_GNU_TYPE)
15
16
17 ifneq (,$(findstring noopt,$(DEB_BUILD_OPTIONS)))
18         export CXXFLAGS = -O0
19 else
20         export CXXFLAGS = -O2 -finline-limit=1200
21 endif
22 ifeq (,$(findstring nostrip,$(DEB_BUILD_OPTIONS)))
23         INSTALL_PROGRAM += -s
24 endif
25
26 config.status: configure
27         dh_testdir
28         # Add here commands to configure the package.
29         # The Makefile is removed on error in order to prevent the build at this early stage.
30         ./configure --host=$(DEB_HOST_GNU_TYPE) --build=$(DEB_BUILD_GNU_TYPE) --prefix=/usr --mandir=\$${prefix}/share/man --infodir=\$${prefix}/share/info || rm -f Makefile
31
32 build: build-arch
33
34 build-arch: build-arch-stamp
35 build-arch-stamp:  config.status
36         # Add here commands to compile the arch part of the package.
37         $(MAKE)
38
39 clean:
40         dh_testdir
41         dh_testroot
42         rm -f build-arch-stamp config-stamp
43         -$(MAKE) distclean
44         dh_clean
45
46 install: install-arch
47 install-arch:
48         dh_testdir
49         dh_testroot
50         dh_clean -k -a
51         dh_installdirs -a
52         # Add here commands to install the arch part of the package into 
53         # debian/tmp.
54         $(MAKE) install prefix=$(CURDIR)/debian/tmp/usr
55         mkdir -p $(CURDIR)/debian/tmp/usr/share/pixmaps
56         cp $(CURDIR)/debian/ginac.xpm $(CURDIR)/debian/tmp/usr/share/pixmaps/
57
58 # Must not depend on anything. This is to be called by
59 # binary-arch/binary-multi
60 # in another 'make' thread.
61 binary-common:
62         dh_testdir
63         dh_testroot
64         dh_installdocs
65         dh_installmenu
66         dh_installman
67         dh_installinfo
68         dh_installchangelogs ChangeLog
69         dh_movefiles
70         dh_link
71         dh_strip
72         dh_compress
73         dh_fixperms
74         dh_makeshlibs
75         dh_shlibdeps --libpackage=libginac1.1 -l debian/libginac1.1/usr/lib
76         dh_gencontrol
77         dh_installdeb
78         dh_md5sums
79         dh_builddeb
80
81 # Build architecture dependant packages using the common target.
82 binary-arch: build-arch install-arch
83         $(MAKE) -f debian/rules DH_OPTIONS=-a binary-common
84
85 binary: binary-arch
86 .PHONY: build clean binary-arch binary install install-arch