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
|
#!/usr/bin/make -f
# avoid useless dependencies
export DEB_LDFLAGS_MAINT_APPEND = -Wl,--as-needed
# upstream version
tmpdir:=$(shell mktemp -d)
wrkdir:=$(shell pwd)
# build-hardening flags
export DEB_BUILD_MAINT_OPTIONS = hardening=+all
# file names
sources=$(shell find . -name *.cpp)
headers=$(shell find . -name *.h)
cleanremovals= bin \
CMakeFiles \
src/CMakeFiles \
CMakeCache.txt \
CPackConfig.cmake \
CPackSourceConfig.cmake \
Makefile \
cmake_install.cmake \
src/Makefile \
src/cmake_config.h \
src/cmake_install.cmake \
locale \
install_manifest.txt \
minetest.xpm \
minetest.svg \
minetest.png \
src/cguittfont/CMakeFiles/ \
src/cguittfont/Makefile \
src/cguittfont/cmake_install.cmake \
src/cguittfont/libcguittfont.a
override_dh_clean:
dh_clean --exclude old/Makefile.old
override_dh_auto_clean:
dh_clean --exclude old/Makefile.old
rm -rf ${cleanremovals}
override_dh_auto_configure:
dh_auto_configure -- \
-DRUN_IN_PLACE=0 \
-DCMAKE_VERBOSE_MAKEFILE=ON \
-DENABLE_SYSTEM_JSONCPP=1 \
-DJSON_INCLUDE_DIR=/usr/include/jsoncpp \
-DENABLE_GETTEXT=1 \
-DENABLE_FREETYPE=1 \
-DFREETYPE_INCLUDE_DIR_freetype2=/usr/include/freetype2 \
-DFREETYPE_INCLUDE_DIR_ft2build=/usr/include \
-DENABLE_LEVELDB=1 \
-DLEVELDB_INCLUDE_DIR=/usr/include/leveldb \
-DCUSTOM_LOCALEDIR=/usr/share/locale \
-DCUSTOM_SHAREDIR=/usr/share/games/minetest \
-DCMAKE_INSTALL_PREFIX=/usr \
-DBUILD_SERVER=1
override_dh_installchangelogs:
dh_installchangelogs debian/changelog.upstream
override_dh_install:
find . -name "license.txt" -delete
dh_install --list-missing
# copy the logo
mkdir -p debian/minetest/usr/share/icons/hicolor/24x24/apps/ \
debian/minetest/usr/share/pixmaps/
cp misc/minetest-icon-24x24.png \
debian/minetest/usr/share/icons/hicolor/24x24/apps/minetest-icon.png
convert debian/minetest/usr/share/icons/hicolor/24x24/apps/minetest-icon.png \
debian/minetest/usr/share/pixmaps/minetest.xpm
# Install the mapper script
mkdir -p debian/minetest-data/usr/games
mkdir -p debian/minetest-data/usr/share/games/minetest
cp util/minetestmapper.py debian/minetest-data/usr/games/minetest-mapper
cp util/colors.txt debian/minetest-data/usr/share/games/minetest/minetestmapper-colors.txt
get-orig-source:
uscan --verbose --force-download
clean:
dh ${@} # Without systemd as it may not be there yet
%:
dh ${@} --with systemd
|