File: rules

package info (click to toggle)
bart 0.9.00-3
  • links: PTS, VCS
  • area: main
  • in suites: sid, trixie
  • size: 9,040 kB
  • sloc: ansic: 116,116; python: 1,329; sh: 726; makefile: 639; javascript: 589; cpp: 106
file content (49 lines) | stat: -rwxr-xr-x 1,311 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
#!/usr/bin/make -f

export DEB_BUILD_MAINT_OPTIONS = hardening=+all optimize=-lto

include /usr/share/dpkg/architecture.mk
DPKG_EXPORT_BUILDTOOLS=1
include /usr/share/dpkg/buildtools.mk

# set installation prefix
export PREFIX=/usr/

# turn of parallel builds here to make build deterministic
export PARALLEL=1
export PARALLEL_NJOBS=1

# some archs require turning of some optimizations
NOEXPOPT_ARCHS=arm64 ppc64el s390x ia64 powerpc ppc64 riscv64

# turn off hanging tests on i386
ifeq ($(DEB_BUILD_ARCH), i386)
export ODE_SIMU_OFF=1
endif

ifneq (,$(filter $(NOEXPOPT_ARCHS), $(DEB_BUILD_ARCH)))
export DEB_CFLAGS_MAINT_APPEND = -fno-expensive-optimizations
endif

# Some tests fail on the following architectures probably
# due to minor differences in floating point processing.
# For now, just turn it off...
NOTEST_ARCHS=hurd-i386 kfreebsd-i386

# For this architesture the test will be run but it will pass in any case even when errors occure
PRINT_ERRORS_WHEN_TESTING=sh4 arc m68k alpha loong64

%:
	dh $@

override_dh_auto_test:
ifeq (,$(filter nocheck,$(DEB_BUILD_OPTIONS)))
ifeq (,$(filter $(NOTEST_ARCHS), $(DEB_BUILD_ARCH)))
ifeq (,$(filter $(PRINT_ERRORS_WHEN_TESTING), $(DEB_BUILD_ARCH)))
	make utest
else
	# the test will be run but its passing in any case
	make utest || true
endif
endif
endif