summaryrefslogtreecommitdiff
path: root/debian/rules
blob: 5ebdce1524949e1da4a5cc2f714c497e89115cfd (plain)
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
#!/usr/bin/make -f

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

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

gstab_architectures := amd64 i386 powerpc s390x
fulldebug_architectures := none
disabled_jit_architectures := armel mips mipsel
disabled_pch_architectures := amd64 powerpc s390x

# JIT is only supported on x86 / armhf / aarch64 / mips32
ifeq (,$(filter $(DEB_HOST_ARCH_CPU),amd64 arm64 armhf i386 mips mipsel sh4))
	EXTRA_CMAKE_ARGUMENTS += -DENABLE_JIT=OFF
endif

# Copied from Fedora; see also https://github.com/annulen/webkit/issues/480
ifneq (,$(filter $(DEB_HOST_ARCH_CPU),ppc64el s390x))
	EXTRA_CMAKE_ARGUMENTS += -DUSE_SYSTEM_MALLOC=ON
endif

%:
	dh $@ --buildsystem=cmake --parallel --with pkgkde_symbolshelper

override_dh_auto_configure:
	dh_auto_configure -- -DPORT=Qt $(EXTRA_CMAKE_ARGUMENTS)

override_dh_auto_build-indep:
	dh_auto_build -- sub-Source-QtWebKit-pro-clean
	dh_auto_build -- -CSource -fMakefile.api docs

override_dh_auto_install-arch:
	dh_auto_install

	# Remove private headers
	rm -rf debian/tmp/usr/include/$(DEB_HOST_MULTIARCH)/qt5/QtWebKit/*/QtWebKit
	rm -rf debian/tmp/usr/include/$(DEB_HOST_MULTIARCH)/qt5/QtWebKitWidgets/*/QtWebKitWidgets

override_dh_auto_install-indep:
	dh_auto_build -- -CSource -fMakefile.api INSTALL_ROOT=$(CURDIR)/debian/tmp install_docs

override_dh_install:
	dh_install --fail-missing

override_dh_auto_test:
	# Do not attempt to run anything to make build-indep work

override_dh_strip:
	dh_strip --dbgsym-migration='libqt5webkit5-dbg (<< 5.212.0~alpha2-1~)'