File: rules

package info (click to toggle)
cln 1.1.13-2
  • links: PTS
  • area: main
  • in suites: etch, etch-m68k
  • size: 13,040 kB
  • ctags: 17,214
  • sloc: cpp: 79,175; sh: 7,794; ansic: 4,194; makefile: 631; lisp: 115
file content (72 lines) | stat: -rwxr-xr-x 2,955 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
#!/usr/bin/make -f

package=cln

version=$(shell expr `pwd` : '.*-\([0-9.]*\)')
version_major=$(shell expr `pwd` : '.*-\([0-9]*\).[0-9.]*')

build:
	dh_testdir
	./configure --with-gmp --prefix=/usr
	# * ARM: CLN's assembler support is not working properly (it was only
	#   'theoretically' ported by copying from code that had once worked in
	#   CLISP under BSD).
	# * HPPA: Assembler support is not working properly.  Somebody needs to
	#   investigate but currently I don't have the inspiration for fixing
	#   things on exotic architectures.
	case `dpkg-architecture -qDEB_HOST_ARCH` in \
	  arm) \
	    ${MAKE} CPPFLAGS="-DNO_ASM" CXXFLAGS="-O2 -fno-exceptions -finline-limit=1000";; \
	  hppa) \
	    ${MAKE} CPPFLAGS="-DNO_ASM" CXXFLAGS="-O2 -fno-exceptions -finline-limit=1000";; \
	  *) \
	    ${MAKE} CXXFLAGS="-O2 -fno-exceptions -finline-limit=1000";; \
	esac
	touch build

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 -rf debian/.libs debian/*.o
	-rm -f debian/*substvars

binary-indep: build
	dh_testdir
	dh_testroot
# There are no architecture-independent files to be uploaded
# generated by this package.  If there were any they would be
# made here.

binary-arch: build
	dh_testdir
	dh_testroot
	dh_installdirs
	${MAKE} install prefix=$(CURDIR)/debian/tmp/usr includedir=$(CURDIR)/debian/libcln-dev/usr/include bindir=$(CURDIR)/debian/libcln-dev/usr/bin mandir=$(CURDIR)/debian/libcln-dev/usr/share/man infodir=$(CURDIR)/debian/libcln-dev/usr/share/info datadir=$(CURDIR)/debian/libcln-dev/usr/share htmldir=$(CURDIR)/debian/libcln-dev/usr/share/doc/libcln-dev/html dvidir=$(CURDIR)/debian/libcln-dev/usr/share/doc/libcln-dev
	# This installs into libdir, but we must not set libdir because it affects the .la file:
	mv $(CURDIR)/debian/tmp/usr/lib/pkgconfig/* $(CURDIR)/debian/libcln-dev/usr/lib/pkgconfig/
	dh_installdocs ChangeLog NEWS README TODO
	dh_installexamples -plibcln-dev $(CURDIR)/examples/contfrac.cc $(CURDIR)/examples/e.cc $(CURDIR)/examples/fibonacci.cc $(CURDIR)/examples/legendre.cc $(CURDIR)/examples/lucaslehmer.cc $(CURDIR)/examples/nextprime.cc $(CURDIR)/examples/perfnum.cc
	/bin/sh libtool  --mode=install /usr/bin/install -c examples/pi $(CURDIR)/debian/pi/usr/bin/pi
	/usr/bin/install -m 644 examples/pi.1 $(CURDIR)/debian/pi/usr/share/man/man1/pi.1
	/usr/bin/install -m 644 debian/libcln-dev.doc-base $(CURDIR)/debian/libcln-dev/usr/share/doc-base/libcln-dev
	# Note: CLN's doc/Makefile should honor psdir, just as it does honor dvidir:
	/usr/bin/install -m 644 doc/cln.ps $(CURDIR)/debian/libcln-dev/usr/share/doc/libcln-dev
	dh_installchangelogs
	dh_install --sourcedir=debian/tmp
	dh_strip
	dh_compress
	dh_fixperms
	dh_makeshlibs
	dh_installdeb
	dh_shlibdeps
	dh_gencontrol
	dh_md5sums
	dh_builddeb

binary: binary-indep binary-arch

.PHONY: binary binary-arch binary-indep clean