summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorThomas Deutschmann <whissi@gentoo.org>2020-04-13 00:50:21 +0200
committerThomas Deutschmann <whissi@gentoo.org>2020-04-13 00:51:04 +0200
commit7461a982b3b7cdd5720f72241143e682aa447acc (patch)
treec077853895f9942cc4f27a748f97fd8af0afa21e /net-print/cups-filters
parentdev-lang/go: 1.14.2 bump (diff)
downloadgentoo-7461a982b3b7cdd5720f72241143e682aa447acc.tar.gz
gentoo-7461a982b3b7cdd5720f72241143e682aa447acc.tar.bz2
gentoo-7461a982b3b7cdd5720f72241143e682aa447acc.zip
net-print/cups-filters: make testfont optional
Closes: https://bugs.gentoo.org/717138 Package-Manager: Portage-2.3.98, Repoman-2.3.22 Signed-off-by: Thomas Deutschmann <whissi@gentoo.org>
Diffstat (limited to 'net-print/cups-filters')
-rw-r--r--net-print/cups-filters/cups-filters-1.27.4.ebuild16
-rw-r--r--net-print/cups-filters/cups-filters-9999.ebuild16
-rw-r--r--net-print/cups-filters/files/cups-filters-1.27.4-make-missing-testfont-non-fatal.patch11
3 files changed, 37 insertions, 6 deletions
diff --git a/net-print/cups-filters/cups-filters-1.27.4.ebuild b/net-print/cups-filters/cups-filters-1.27.4.ebuild
index 6cb600e6a3ad..7abb7a7fcbf0 100644
--- a/net-print/cups-filters/cups-filters-1.27.4.ebuild
+++ b/net-print/cups-filters/cups-filters-1.27.4.ebuild
@@ -5,10 +5,10 @@ EAPI=7
GENTOO_DEPEND_ON_PERL=no
-inherit perl-module systemd flag-o-matic
+inherit autotools perl-module systemd flag-o-matic
if [[ "${PV}" == "9999" ]] ; then
- inherit autotools git-r3
+ inherit git-r3
EGIT_REPO_URI="https://github.com/OpenPrinting/cups-filters.git"
else
SRC_URI="http://www.openprinting.org/download/${PN}/${P}.tar.xz"
@@ -54,8 +54,18 @@ BDEPEND="
"
src_prepare() {
+ local need_eautoreconf=
+
default
- [[ "${PV}" == "9999" ]] && eautoreconf
+
+ if ! use test ; then
+ eapply "${FILESDIR}"/${PN}-1.27.4-make-missing-testfont-non-fatal.patch
+ need_eautoreconf=yes
+ elif [[ "${PV}" == "9999" ]] ; then
+ need_eautoreconf=yes
+ fi
+
+ [[ -n ${need_eautoreconf} ]] && eautoreconf
# Bug #626800
append-cxxflags -std=c++11
diff --git a/net-print/cups-filters/cups-filters-9999.ebuild b/net-print/cups-filters/cups-filters-9999.ebuild
index 6cb600e6a3ad..7abb7a7fcbf0 100644
--- a/net-print/cups-filters/cups-filters-9999.ebuild
+++ b/net-print/cups-filters/cups-filters-9999.ebuild
@@ -5,10 +5,10 @@ EAPI=7
GENTOO_DEPEND_ON_PERL=no
-inherit perl-module systemd flag-o-matic
+inherit autotools perl-module systemd flag-o-matic
if [[ "${PV}" == "9999" ]] ; then
- inherit autotools git-r3
+ inherit git-r3
EGIT_REPO_URI="https://github.com/OpenPrinting/cups-filters.git"
else
SRC_URI="http://www.openprinting.org/download/${PN}/${P}.tar.xz"
@@ -54,8 +54,18 @@ BDEPEND="
"
src_prepare() {
+ local need_eautoreconf=
+
default
- [[ "${PV}" == "9999" ]] && eautoreconf
+
+ if ! use test ; then
+ eapply "${FILESDIR}"/${PN}-1.27.4-make-missing-testfont-non-fatal.patch
+ need_eautoreconf=yes
+ elif [[ "${PV}" == "9999" ]] ; then
+ need_eautoreconf=yes
+ fi
+
+ [[ -n ${need_eautoreconf} ]] && eautoreconf
# Bug #626800
append-cxxflags -std=c++11
diff --git a/net-print/cups-filters/files/cups-filters-1.27.4-make-missing-testfont-non-fatal.patch b/net-print/cups-filters/files/cups-filters-1.27.4-make-missing-testfont-non-fatal.patch
new file mode 100644
index 000000000000..50866e4a7291
--- /dev/null
+++ b/net-print/cups-filters/files/cups-filters-1.27.4-make-missing-testfont-non-fatal.patch
@@ -0,0 +1,11 @@
+--- a/configure.ac
++++ b/configure.ac
+@@ -789,7 +789,7 @@ AC_ARG_WITH([test-font-path],
+ [with_test_font_path=`find /usr/share/fonts -name DejaVuSans.ttf || echo /usr/share/fonts/dejavu/DejaVuSans.ttf`]
+ )
+ AC_CHECK_FILE("$with_test_font_path", [], [
+- AC_MSG_ERROR([Requested font file is missing. Please install a package providing it.])
++ AC_MSG_WARN([Specified font for tests not found. Expect test failures!])
+ ])
+ AC_DEFINE_UNQUOTED([TESTFONT], ["$with_test_font_path"], [Path to font used in tests])
+