gentoo-full-overlay/dev-libs/libcdio-paranoia/files/libcdio-paranoia-0.90-oos-tests.patch

49 lines
1.4 KiB
Diff
Raw Normal View History

From 4803c621d4f907402f29eba8cc3a6515bdda2ee2 Mon Sep 17 00:00:00 2001
From: Sergei Trofimovich <slyfox@gentoo.org>
Date: Mon, 12 Jun 2017 21:20:35 +0100
Subject: [PATCH] configure.ac: fix out-of-tree tests
To reproduce the test failure one needs to run
configure using absolute path in a directory
outside source tree. For example:
$ $(pwd)/../libcdio-paranoia/configure
$ make
$ make check
This will cause 'native_abs_top_srcdir' to contain wrong path.
It happens because '[]' is an escape in autoconf.
As a the following configure.ac snippet:
[\\/]* | ?:[\\/]* ) # Absolute name.
gets translated into the following shell code:
\\/* | ?:\\/* ) # Absolute name.
The fix is to change quotes from '[]' for a short while.
Reported-by: eroen
Reported-by: Paolo Pedroni
Bug: https://bugs.gentoo.org/546388
Signed-off-by: Sergei Trofimovich <slyfox@gentoo.org>
---
configure.ac | 2 ++
1 file changed, 2 insertions(+)
diff --git a/configure.ac b/configure.ac
index a502273..608277b 100644
--- a/configure.ac
+++ b/configure.ac
@@ -243,7 +243,9 @@ dnl native_abs_top_srcdir is used here.
case $srcdir in
.) # We are building in place.
native_abs_top_srcdir=$ac_pwd ;;
+ changequote(`,')
[\\/]* | ?:[\\/]* ) # Absolute name.
+ changequote([,])
native_abs_top_srcdir=$srcdir ;;
*) # Relative name.
native_abs_top_srcdir=$ac_pwd/$srcdir ;;
--
2.13.1