File: rules

package info (click to toggle)
eclipse-cdt 8.6.0-2
  • links: PTS, VCS
  • area: main
  • in suites: stretch
  • size: 149,960 kB
  • ctags: 159,618
  • sloc: java: 1,088,470; xml: 54,671; ansic: 5,236; cpp: 5,052; makefile: 1,358; sh: 388; asm: 42; f90: 22
file content (73 lines) | stat: -rwxr-xr-x 2,224 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

export JAVA_HOME:=/usr/lib/jvm/default-java
BUILD_ID:=dist

DEB_HOST_ARCH_CPU ?= $(shell dpkg-architecture -qDEB_HOST_ARCH_CPU)
ifneq (,$(filter $(DEB_HOST_ARCH_CPU),i386 i486 i586 i686))
	ECLIPSE_BUILD_ARCH=x86
endif
ifneq (,$(findstring $(DEB_HOST_ARCH_CPU),arm))
	ECLIPSE_BUILD_ARCH=arm
endif
ifeq ($(DEB_HOST_ARCH_CPU),amd64)
	ECLIPSE_BUILD_ARCH=x86_64
endif
ifneq (,$(findstring $(DEB_HOST_ARCH_CPU),mips))
	ECLIPSE_BUILD_ARCH=$(DEB_HOST_ARCH)
endif
ifneq (,$(filter $(DEB_HOST_ARCH_CPU),parisc parisc64))
	ECLIPSE_BUILD_ARCH=PA_RISC
endif
ifeq ($(DEB_HOST_ARCH_CPU),powerpc)
	ECLIPSE_BUILD_ARCH=ppc
endif
ifeq ($(ECLIPSE_BUILD_ARCH),)
	ECLIPSE_BUILD_ARCH=$(DEB_HOST_ARCH_CPU)
endif

BUILD_DIR:=debian/.eclipse-build

%:
	dh $@ --with eclipse-helper

# There is 'build' directory in the source tree colliding with 'build' target
.PHONY: build
build:
	dh $@ --with eclipse-helper

override_dh_auto_clean:
	# Do not use the auto-clean with ant.
override_dh_auto_build:
	# Do not use the auto-build with ant.

MACROS_DIR=debian/.eclipse-build/org.eclipse.cdt.autotools.ui/macros
override_jh_setupenvironment:
	jh_setupenvironment
	mkdir -p $(MACROS_DIR)
	cd debian/docs && ./regenerateFromTexinfo.sh
	cp debian/docs/acmacros-*.xml debian/docs/ammacros-*.xml $(MACROS_DIR)

override_jh_compilefeatures-arch:
	cd $(BUILD_DIR)/org.eclipse.cdt.core.linux/library && \
		make JAVA_HOME="$(JAVA_HOME)" ARCH=$(ECLIPSE_BUILD_ARCH) CC='gcc -D_GNU_SOURCE' CFLAGS="$(CFLAGS) -fPIC" LDFLAGS="$(LDFLAGS) -fPIC"

override_jh_compilefeatures-indep:
	jh_compilefeatures --build-opts="-DjavacTarget=1.7 -DjavacSource=1.7 -DbuildId=$(BUILD_ID) -DforceContextQualifier=$(BUILD_ID)";

jnidir := /usr/lib/$(DEB_HOST_MULTIARCH)/jni

override_dh_install-arch:
	dh_install -peclipse-cdt-jni $(BUILD_DIR)/org.eclipse.cdt.core.linux.$(ECLIPSE_BUILD_ARCH)/os/linux/$(ECLIPSE_BUILD_ARCH)/*.so $(jnidir)
	dh_install -a --remaining-packages

override_jh_installeclipse-indep:
	jh_installeclipse
	rm -f debian/eclipse-cdt-launch-remote/usr/share/eclipse/dropins/cdt-launch-remote/eclipse/plugins/org.eclipse.cdt.launch.remote.source*.jar

override_dh_clean:
	dh_clean
	rm -rf debian/docs/*.xml

get-orig-source:
	debian/fetch-cdt.sh