File: rules

package info (click to toggle)
xaw3d 1.5+E-18.3
  • links: PTS
  • area: main
  • in suites: bullseye, buster, sid
  • size: 1,928 kB
  • sloc: ansic: 28,655; yacc: 247; sh: 191; lex: 126; makefile: 52; sed: 43
file content (73 lines) | stat: -rwxr-xr-x 1,699 bytes parent folder | download | duplicates (2)
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
#!/usr/bin/make -f

SHELL = /bin/bash
PACKAGE = xaw3d

#export DH_VERBOSE = 1

DEB_HOST_MULTIARCH ?= $(shell dpkg-architecture -qDEB_HOST_MULTIARCH)

include /usr/share/dpatch/dpatch.make

ifneq (,$(findstring $(ARCH), $(COMPATARCHS)))
#
# Remove comment to enable libc5 compatibility.
# You need also to use control.oldlib instead of the standard one.
#COMPATSTUFF = yep
#
export DH_OPTIONS = -a
else
export DH_OPTIONS = -Nxaw3d -a
endif

SOURCE=lib/Xaw3d

build: stamp-build
stamp-build: patch-stamp
	rm -rf $(SOURCE)/X11 && install -m755 -d $(SOURCE)/X11
	cd $(SOURCE) && ln -sf ../ X11/Xaw3d && xmkmf
	$(MAKE) -C $(SOURCE) \
          EXTRA_DEFINES="-D_REENTRANT -DARROW_SCROLLBAR" SHLIBDEF="-D_REENTRANT -DARROW_SCROLLBAR"
	touch $@

clean: myclean unpatch
myclean:
	rm -rf $(SOURCE)/X11 $(COMPAT) lib/Xaw3d/laygram.h
	cd $(SOURCE) && [ -f $(SOURCE)/Makefile ] || xmkmf
	$(MAKE) -C $(SOURCE) clean
	dh_clean stamp-build `find . -name Makefile`

install: DH_OPTIONS=
install: stamp-build
	dh_testdir
	dh_testroot
	dh_prep
	$(MAKE) -C $(SOURCE) install \
                DESTDIR=$(CURDIR)/debian/tmp INCDIR=/usr/include \
		SHLIBDIR=/usr/lib/$(DEB_HOST_MULTIARCH) \
		USRLIBDIR=/usr/lib/$(DEB_HOST_MULTIARCH)

binary: binary-indep binary-arch

binary-indep:
# There are no architecture-independent packages here.

binary-arch: install
	dh_testdir
	dh_testroot
	dh_install
	dh_lintian
	dh_installexamples $(SOURCE)/app-defaults
	dh_installdocs $(SOURCE)/README.XAW3D 
	dh_installchangelogs
	dh_installdebconf
	dh_strip
	dh_compress
	dh_fixperms
	dh_installdeb
	dh_shlibdeps
	dh_gencontrol
	dh_md5sums
	dh_builddeb

.PHONY:	build clean install binary binary-arch binary-indep unpatch myclean patch