#!/usr/bin/make -f # Copyright (C) 2012-2015 Hunter Kaller # Copyright (C) 2014-2017 Sergio Benjamim # This program is free software: you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation, either version 3 of the License, or # (at your option) any later version. # # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License # along with this program. If not, see . # Fix hardening-no-bindnow and hardening-no-pie export DEB_BUILD_MAINT_OPTIONS = hardening=+bindnow,+pie export DEB_LDFLAGS_MAINT_APPEND = -Wl,--as-needed export DEB_CXXFLAGS_MAINT_STRIP=-O2 export DEB_CFLAGS_MAINT_STRIP=-O2 export QT_SELECT := qt5 ARCH=$(shell dpkg-architecture -qDEB_HOST_ARCH) ifeq ($(ARCH), $(filter $(ARCH), amd64 i386)) CONFIG_EXTRA_FLAGS=--enable-sse else ifeq ($(ARCH),armhf) CONFIG_EXTRA_FLAGS=--disable-cg --enable-opengles --enable-neon --enable-floathard else ifeq ($(ARCH),arm64) CONFIG_EXTRA_FLAGS=--disable-cg --enable-opengles endif GIT_HASH := "b2ceb50" %: dh $@ override_dh_auto_configure: sed 's/@DEB_HOST_MULTIARCH@/$(DEB_HOST_MULTIARCH)/g' \ retroarch.cfg > debian/retroarch.cfg sed 's/@DEB_HOST_MULTIARCH@/$(DEB_HOST_MULTIARCH)/g' \ debian/retroarch.dirs.in > debian/retroarch.dirs sed 's/@DEB_HOST_MULTIARCH@/$(DEB_HOST_MULTIARCH)/g' \ debian/retroarch.install.in > debian/retroarch.install sed 's/@DEB_HOST_MULTIARCH@/$(DEB_HOST_MULTIARCH)/g' \ debian/retroarch.links.in > debian/retroarch.links # See ./configure --help for valid flags # disable flags (i.e. --disable-ffmpeg for example) if there is no package relative to the feature in Build-Depends ./configure --prefix=/usr --disable-oss --disable-vg --disable-vulkan --disable-builtinminiupnpc $(CONFIG_EXTRA_FLAGS) override_dh_auto_build: dh_auto_build -- GIT_VERSION="'$(GIT_HASH)'" # SoftFilters dh_auto_build -- -C gfx/video_filters/ # Audio DSP plugins dh_auto_build -- -C libretro-common/audio/dsp_filters/ override_dh_auto_install: override_dh_auto_clean: touch config.mk dh_auto_clean dh_auto_clean -- -C gfx/video_filters/ clean dh_auto_clean -- -C libretro-common/audio/dsp_filters/ clean