Debian Codegraph @

debian/rules

raw symbols SCIP
1 #!/usr/bin/make -f
2 # -*- makefile -*-
3
4 # Uncomment this to turn on verbose mode.
5 # export DH_VERBOSE=1
6
7 export DEB_BUILD_MAINT_OPTIONS = hardening=+all
8 export SDL_AUDIODRIVER = dummy
9 export SDL_VIDEODRIVER = dummy
10
11 include /usr/share/dpkg/default.mk
12
13 built_binaries := $(shell dh_listpackages)
14 configure_options := \
15 -DSDL2COMPAT_STATIC=OFF \
16 -DSDL2COMPAT_VENDOR_INFO="$(DEB_VENDOR) $(DEB_VERSION)" \
17 -DSDL2COMPAT_WERROR=OFF \
18 $(NULL)
19
20 ifneq ($(filter nocheck,$(DEB_BUILD_OPTIONS))$(filter %-tests,$(built_binaries)),nocheck)
21 configure_options += -DSDL2COMPAT_TESTS=ON
22 else
23 configure_options += -DSDL2COMPAT_TESTS=OFF
24 endif
25
26 ifneq ($(filter %-tests,$(built_binaries)),)
27 configure_options += -DSDL2COMPAT_INSTALL_TESTS=ON
28 else
29 configure_options += -DSDL2COMPAT_INSTALL_TESTS=OFF
30 endif
31
32 %:
33 dh $@ -Scmake+ninja -Bcmake-build
34
35 override_dh_auto_configure:
36 ifeq ($(DEB_VERSION_UPSTREAM),2.32.56+git20251029~ee7cf25+ds)
37 echo release-2.32.56-63-gee7cf25 > REVISION.txt
38 endif
39 dh_auto_configure -- $(configure_options)
40
41 # Only run testtimer as an autopkgtest on machines that we're reasonably
42 # sure are both fast and set up to be usable for interactive use
43 # (currently only x86 and 64-bit ARM).
44 # There is an assertion that requesting a 1ms delay does not result in
45 # a delay of more than 100ms, and that's not going to be reliably true
46 # on slow machines like riscv64 or batch-processing-oriented machines
47 # like s390x.
48 ifeq (,$(filter amd64 arm64 i386,$(DEB_HOST_ARCH)))
49 execute_after_dh_auto_install:
50 rm -fv debian/tmp/usr/share/installed-tests/SDL2_compat/testtimer.test
51 endif
52
53 override_dh_makeshlibs:
54 dh_makeshlibs -plibsdl2-compat -n
55 dh_makeshlibs --remaining-packages
56
57 # debhelper >= 13.4 makes all of /usr/libexec executable, which is not
58 # quite right for installed-tests
59 override_dh_fixperms:
60 dh_fixperms -Xusr/libexec/installed-tests
61 chmod --recursive a+rX,u+w,og-w debian/*-tests/usr/libexec/installed-tests