From a50e13590fe5b3e77017ef3a7e5c3cf0abe29864 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Dan=20Hor=C3=A1k?= Date: Fri, 15 Apr 2016 11:13:59 +0200 Subject: [PATCH] fix cppunit detection --- libdap-cppunit.patch | 30 ++++++++++++++++++++++++++++++ libdap.spec | 4 ++++ 2 files changed, 34 insertions(+) create mode 100644 libdap-cppunit.patch diff --git a/libdap-cppunit.patch b/libdap-cppunit.patch new file mode 100644 index 0000000..bd4e726 --- /dev/null +++ b/libdap-cppunit.patch @@ -0,0 +1,30 @@ +From 08f3403fb6bea17775dacc51c055b3b46f425326 Mon Sep 17 00:00:00 2001 +From: =?UTF-8?q?Dan=20Hor=C3=A1k?= +Date: Fri, 15 Apr 2016 11:06:42 +0200 +Subject: [PATCH] fallback to pkg-config if cppunit-config is not available + +Recent version of cppunit packages do not distribute the cppunit-config script +and expect the usage of pkgconfig file. +--- + configure.ac | 8 +++++++- + 1 file changed, 7 insertions(+), 1 deletion(-) + +diff --git a/configure.ac b/configure.ac +index 2a7f158..9467a87 100644 +--- a/configure.ac ++++ b/configure.ac +@@ -305,7 +305,13 @@ AC_SUBST([UUID_LIBS]) + + AM_PATH_CPPUNIT(1.12.0, + [AM_CONDITIONAL([CPPUNIT], [true])], +- [AM_CONDITIONAL([CPPUNIT], [false])]) ++ [ ++ PKG_CHECK_MODULES(CPPUNIT, [cppunit >= 1.12.0], ++ [AM_CONDITIONAL([CPPUNIT], [true])], ++ [AM_CONDITIONAL([CPPUNIT], [false])] ++ ) ++ ] ++) + + DODS_DEBUG_OPTION + diff --git a/libdap.spec b/libdap.spec index de65234..1900e9c 100644 --- a/libdap.spec +++ b/libdap.spec @@ -14,6 +14,9 @@ Patch0: libdap-offline.patch # https://github.com/OPENDAP/libdap4/pull/13 # https://bugzilla.redhat.com/show_bug.cgi?id=1325114 Patch1: libdap-big-endian-baselines.patch +# Fix cppunit detection +# https://github.com/OPENDAP/libdap4/pull/15 +Patch2: libdap-cppunit.patch # For autoreconf BuildRequires: libtool @@ -69,6 +72,7 @@ Documentation of the libdap library. %setup -q -n %{name}4-version-%{version} %patch0 -p1 -b .offline %patch1 -p1 -b .big-endian-baselines +%patch2 -p1 -b .cppunit iconv -f latin1 -t utf8 < COPYRIGHT_W3C > COPYRIGHT_W3C.utf8 touch -r COPYRIGHT_W3C COPYRIGHT_W3C.utf8 mv COPYRIGHT_W3C.utf8 COPYRIGHT_W3C