summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--net-dns/resolv_wrapper/files/resolv_wrapper-1.1.8-cmocka-cmake.patch26
-rw-r--r--net-dns/resolv_wrapper/resolv_wrapper-1.1.8.ebuild10
2 files changed, 34 insertions, 2 deletions
diff --git a/net-dns/resolv_wrapper/files/resolv_wrapper-1.1.8-cmocka-cmake.patch b/net-dns/resolv_wrapper/files/resolv_wrapper-1.1.8-cmocka-cmake.patch
new file mode 100644
index 000000000000..23f1577ed99b
--- /dev/null
+++ b/net-dns/resolv_wrapper/files/resolv_wrapper-1.1.8-cmocka-cmake.patch
@@ -0,0 +1,26 @@
+https://git.samba.org/?p=resolv_wrapper.git;a=commit;h=f2e7f58025ecb4cf399494166abea01813b1d0f0
+
+From f2e7f58025ecb4cf399494166abea01813b1d0f0 Mon Sep 17 00:00:00 2001
+From: Andreas Schneider <asn@samba.org>
+Date: Fri, 17 Feb 2023 17:51:27 +0100
+Subject: [PATCH] cmake: Fix cmocka >= 1.1.6 find_package() in CONFIG mode
+MIME-Version: 1.0
+Content-Type: text/plain; charset=utf8
+Content-Transfer-Encoding: 8bit
+
+Signed-off-by: Andreas Schneider <asn@samba.org>
+Reviewed-by: Pavel Filipenský <pfilipensky@samba.org>
+--- a/tests/CMakeLists.txt
++++ b/tests/CMakeLists.txt
+@@ -1,5 +1,9 @@
+ project(tests C)
+
++if (TARGET cmocka::cmocka)
++ set(CMOCKA_LIBRARY cmocka::cmocka)
++endif()
++
+ set(TORTURE_LIBRARY torture)
+
+ # A simple DNS server for testing
+--
+2.34.1
diff --git a/net-dns/resolv_wrapper/resolv_wrapper-1.1.8.ebuild b/net-dns/resolv_wrapper/resolv_wrapper-1.1.8.ebuild
index 7f5091771e60..119dd3c0a227 100644
--- a/net-dns/resolv_wrapper/resolv_wrapper-1.1.8.ebuild
+++ b/net-dns/resolv_wrapper/resolv_wrapper-1.1.8.ebuild
@@ -15,10 +15,16 @@ KEYWORDS="~alpha amd64 arm ~arm64 ~hppa ~ia64 ppc ppc64 sparc x86"
IUSE="test"
RESTRICT="!test? ( test )"
-BDEPEND="test? (
+BDEPEND="
+ test? (
dev-util/cmocka
net-libs/socket_wrapper
- )"
+ )
+"
+
+PATCHES=(
+ "${FILESDIR}"/${P}-cmocka-cmake.patch
+)
# Work around a problem with >=dev-build/cmake-3.3.0 (bug #558340)
# Because of this we cannot use cmake-multilib_src_configure() here.