File: rules

package info (click to toggle)
gcc-3.3 1%3A3.3.6ds1-32
  • links: PTS
  • area: main
  • in suites: bullseye
  • size: 25,816 kB
  • sloc: sh: 10,372; makefile: 1,050; perl: 155; awk: 23; cpp: 14
file content (87 lines) | stat: -rwxr-xr-x 2,353 bytes parent folder | download | duplicates (4)
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
83
84
85
86
87
#! /usr/bin/make -f
# -*- makefile -*-
# Build rules for gcc (>= 2.95) and gcc-snapshot
# Targets found in this makefile:
#	- unpack tarballs
#	- patch sources
#	- (re)create the control file
#	- create a debian/rules.parameters file, which is included
#	  by debian/rules2
# All other targets are passed to the debian/rules2 file

# Uncomment this to turn on verbose mode.
#export DH_VERBOSE=1

default: build

include debian/rules.defs
include debian/rules.unpack
include debian/rules.patch

build_only_archs = amd64 i386 powerpc

pre-build:
ifeq (,$(filter $(DEB_TARGET_ARCH), $(build_only_archs)))
	@echo "The package is not built anymore for $(DEB_TARGET_ARCH)"
	@exit 42
endif

control: $(control_dependencies)
	-mkdir -p $(stampdir)
	$(MAKE) -f debian/rules.conf $@

configure: $(configure_dependencies)
$(configure_stamp): control $(unpack_stamp) $(patch_stamp)
	$(MAKE) -f debian/rules2 $@
$(configure_dummy_stamp): control
	$(MAKE) -f debian/rules2 $@
$(configure_hppa64_stamp): $(build_stamp)
	$(MAKE) -f debian/rules2 $@

build: pre-build $(build_dependencies)
$(build_stamp): $(unpack_stamp) $(patch_stamp) $(configure_stamp)
	$(MAKE) -f debian/rules2 $@
$(build_dummy_stamp): $(configure_dummy_stamp)
	$(MAKE) -f debian/rules2 $@
$(build_hppa64_stamp): $(configure_hppa64_stamp)
	$(MAKE) -f debian/rules2 $@

check: $(build_stamp)
	$(MAKE) -f debian/rules2 $@

clean:
	rm -rf $(stampdir)
# remove temporary dirs used for unpacking
	rm -rf $(gcc_srcdir) $(gpc_srcdir) p
	-$(MAKE) -f debian/rules2 $@
	rm -rf $(srcdir) $(builddir)* debian/tmp* html
	rm -f bootstrap-* first-move-stamp
	rm -f debian/*.tmp
	-find debian -name '.#*' | xargs rm -f
	dh_clean

install: $(install_dependencies)
$(install_stamp): $(build_stamp)
	$(MAKE) -f debian/rules2 $@
$(install_dummy_stamp): $(build_dummy_stamp)
	$(MAKE) -f debian/rules2 $@
$(install_hppa64_stamp): $(build_hppa64_stamp)
	$(MAKE) -f debian/rules2 $@

html-docs doxygen-docs xxx:
	$(MAKE) -f debian/rules2 $@

binary-indep binary-arch binary: install
	$(MAKE) -f debian/rules2 $@

source diff:
	@echo >&2 'source and diff are obsolete - use dpkg-source -b'; false

release:
	foo=$(shell basename $(CURDIR)); \
		if [ "$$foo" != "gcc-3.3" ]; then \
			find -name CVS -o -name .cvsignore -o -name '.#*' | \
				xargs rm -rf; \
		fi

.PHONY: build clean binary-indep binary-arch binary release