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 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130
|
include /usr/share/dpkg/architecture.mk
include /usr/share/dpkg/pkg-info.mk
confflags = --disable-rpath --enable-sdl-dlopen \
--disable-nas --disable-esd --disable-arts \
--disable-alsa-shared --disable-pulseaudio-shared \
--enable-ibus \
--disable-x11-shared --disable-video-directfb \
--enable-video-opengles \
--disable-video-opengles1 \
--enable-video-wayland --disable-wayland-shared \
--enable-video-kmsdrm --disable-kmsdrm-shared \
--enable-hidapi
export AUTOHEADER := /bin/true
ifeq ($(DEB_HOST_ARCH_CPU),powerpc)
confflags += --disable-altivec
endif
ifeq ($(DEB_HOST_ARCH_CPU),ppc64el)
confflags += --disable-altivec
endif
ifeq (hurd,$(findstring hurd,$(DEB_HOST_ARCH_CPU)))
confflags += --disable-video-vulkan
confflags += --disable-video-wayland
endif
ifeq (kfreefsd,$(findstring kfreebsd,$(DEB_HOST_ARCH_CPU)))
confflags += --disable-video-vulkan
confflags += --disable-video-wayland
endif
ifeq (hurd,$(findstring hurd,$(DEB_HOST_ARCH_CPU)))
confflags += --disable--video-opengles
endif
confflags += ac_cv_header_libunwind_h=no
%:
dh $@
override_dh_auto_configure:
dh_auto_configure -- $(confflags)
dh_auto_configure \
--buildsystem=autoconf \
--sourcedirectory=$(CURDIR)/test \
--builddirectory=$(CURDIR)/debian/build-tests \
-- \
--x-includes=/usr/include \
--x-libraries=/usr/lib/$(DEB_HOST_MULTIARCH) \
SDL_CFLAGS=-I$(CURDIR)/include \
SDL_LIBS="-L$(CURDIR)/build/.libs -lSDL2" \
ac_cv_lib_SDL2_ttf_TTF_Init=no \
$(NULL)
override_dh_auto_build-indep:
GZIP="-9n" tar \
--exclude=autom4te.cache \
--owner=0 --group=0 --mode=go=rX,u+rw,a-s \
--clamp-mtime --mtime="@$(SOURCE_DATE_EPOCH)" \
--sort=name \
-czf debian/examples.tar.gz test
sed -e 's/FULL_PATH_NAMES *=.*/FULL_PATH_NAMES = NO/' < docs/doxyfile > debian/Doxyfile
cd docs && doxygen ../debian/Doxyfile
find docs/output -name "*.md5" -delete
find docs/output -type d -empty -delete
override_dh_installexamples-indep:
dh_installexamples -i --doc-main-package=libsdl2-doc
override_dh_auto_build-arch:
dh_auto_build -- V=1
dh_auto_build \
--buildsystem=autoconf \
--sourcedirectory=$(CURDIR)/test \
--builddirectory=$(CURDIR)/debian/build-tests \
-- \
V=1
override_dh_auto_clean-indep:
dh_auto_clean
rm -f debian/Doxyfile
rm -f debian/examples.tar.gz
rm -rf docs/output
override_dh_auto_install-arch:
dh_auto_install -- V=1
dh_auto_install \
--buildsystem=autoconf \
--sourcedirectory=$(CURDIR)/test \
--builddirectory=$(CURDIR)/debian/build-tests \
-- \
installedtestsdir='/usr/lib/$(DEB_HOST_MULTIARCH)/installed-tests/SDL2' \
V=1
override_dh_install:
mkdir -p debian/tmp/usr/include/$(DEB_HOST_MULTIARCH)/SDL2
mv debian/tmp/usr/include/SDL2/SDL_config.h debian/tmp/usr/include/$(DEB_HOST_MULTIARCH)/SDL2/_real_SDL_config.h
ln -s ../../SDL2/SDL_platform.h debian/tmp/usr/include/$(DEB_HOST_MULTIARCH)/SDL2/
ln -s ../../SDL2/begin_code.h debian/tmp/usr/include/$(DEB_HOST_MULTIARCH)/SDL2/
ln -s ../../SDL2/close_code.h debian/tmp/usr/include/$(DEB_HOST_MULTIARCH)/SDL2/
dh_install
override_dh_missing:
dh_missing --fail-missing
override_dh_link:
dh_link -plibsdl2-dev usr/lib/$(DEB_HOST_MULTIARCH)/libSDL2-2.0.so.0 usr/lib/$(DEB_HOST_MULTIARCH)/libSDL2-2.0.so
dh_link --remaining-packages
override_dh_installchangelogs:
dh_installchangelogs -- WhatsNew.txt
|