File: rules

package info (click to toggle)
talloc 1.2.0~git20080616-1
  • links: PTS
  • area: main
  • in suites: lenny
  • size: 1,428 kB
  • ctags: 1,019
  • sloc: ansic: 8,394; sh: 2,772; xml: 738; makefile: 143
file content (82 lines) | stat: -rwxr-xr-x 1,664 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
73
74
75
76
77
78
79
80
81
82
#!/usr/bin/make -f

CFLAGS = -g -Wall

ifneq (,$(findstring noopt,$(DEB_BUILD_OPTIONS)))
CFLAGS += -O0
else
CFLAGS += -O2
endif

include /usr/share/quilt/quilt.make

DESTDIR=$(CURDIR)/debian/tmp

conf_args = --prefix=/usr

ifeq ($(DEB_BUILD_GNU_TYPE), $(DEB_HOST_GNU_TYPE))
conf_args += --build $(DEB_BUILD_GNU_TYPE)
else
conf_args += --build $(DEB_BUILD_GNU_TYPE) --host $(DEB_HOST_GNU_TYPE)
endif

configure: patch configure-stamp
configure-stamp:
	dh_testdir
	CFLAGS="$(CFLAGS)" ./configure $(conf_args)
	touch configure-stamp

build: configure build-stamp
build-stamp:
	dh_testdir
	$(MAKE) all
ifeq (,$(findstring notest,$(DEB_BUILD_OPTIONS)))
	./testsuite
endif
	touch build-stamp

get-orig-source:
	./debian/build-orig.sh

clean:	clean-patched unpatch

clean-patched: 
	dh_testdir
	dh_testroot
	rm -f build-stamp configure-stamp
	[ ! -f Makefile ] || $(MAKE) distclean
	dh_clean

install: build
	dh_testdir
	dh_testroot
	dh_clean -k
	dh_installdirs
	mkdir -p $(DESTDIR)`swig -swiglib`
	$(MAKE) install DESTDIR=$(DESTDIR)
	ln -s libtalloc.so.1.2.0 $(DESTDIR)/usr/lib/libtalloc.so.1
	ln -s libtalloc.so.1.2.0 $(DESTDIR)/usr/lib/libtalloc.so
	dh_install --list-missing --fail-missing --sourcedir=$(DESTDIR)

# Build architecture-dependent files here.
# Pass -a to all debhelper commands in this target to reduce clutter.

binary-arch: DH_OPTIONS=-a
binary-arch: build install
	dh_testdir
	dh_testroot
	dh_installdocs
	dh_installchangelogs 
	dh_strip
	dh_link
	dh_compress
	dh_fixperms
	dh_makeshlibs
	dh_installdeb
	dh_shlibdeps
	dh_gencontrol
	dh_md5sums
	dh_builddeb

binary: binary-arch
.PHONY: build clean binary-arch binary install configure patch unpatch