summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMatthias Maier <tamiko@gentoo.org>2023-06-19 19:19:20 -0500
committerMatthias Maier <tamiko@gentoo.org>2023-06-19 19:45:54 -0500
commit9f4a07d859cb62b737d5ab70161693cbb768b3d0 (patch)
treef088b76ca730ea65d081d2d2b3409e8d0adb6730 /sci-libs/p4est
parentsci-libs/libsc: QA: fix install locations, EAPI bump (diff)
downloadgentoo-9f4a07d859cb62b737d5ab70161693cbb768b3d0.tar.gz
gentoo-9f4a07d859cb62b737d5ab70161693cbb768b3d0.tar.bz2
gentoo-9f4a07d859cb62b737d5ab70161693cbb768b3d0.zip
sci-libs/p4est: QA: fix install locations, EAPI bump
Signed-off-by: Matthias Maier <tamiko@gentoo.org>
Diffstat (limited to 'sci-libs/p4est')
-rw-r--r--sci-libs/p4est/files/p4est-2.8.5-fix_cmake_path.patch44
-rw-r--r--sci-libs/p4est/p4est-2.8.5-r2.ebuild (renamed from sci-libs/p4est/p4est-2.8.5-r1.ebuild)9
2 files changed, 49 insertions, 4 deletions
diff --git a/sci-libs/p4est/files/p4est-2.8.5-fix_cmake_path.patch b/sci-libs/p4est/files/p4est-2.8.5-fix_cmake_path.patch
new file mode 100644
index 000000000000..8202a4007ede
--- /dev/null
+++ b/sci-libs/p4est/files/p4est-2.8.5-fix_cmake_path.patch
@@ -0,0 +1,44 @@
+diff --git a/CMakeLists.txt b/CMakeLists.txt
+index d1b2094..e5fe188 100644
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -104,9 +104,8 @@ endif(BUILD_TESTING)
+ # --- packaging
+
+ install(FILES
+-${CMAKE_CURRENT_SOURCE_DIR}/cmake/FindSC.cmake
+ ${CMAKE_CURRENT_SOURCE_DIR}/cmake/FindP4EST.cmake
+-DESTINATION cmake)
++DESTINATION ${library_reldir}/cmake/P4est)
+
+ include(cmake/pkgconf.cmake)
+ include(cmake/install.cmake)
+diff --git a/cmake/install.cmake b/cmake/install.cmake
+index f4f92c4..0f31976 100644
+--- a/cmake/install.cmake
++++ b/cmake/install.cmake
+@@ -4,7 +4,7 @@ include(CMakePackageConfigHelpers)
+
+ configure_package_config_file(${CMAKE_CURRENT_LIST_DIR}/config.cmake.in
+ ${CMAKE_CURRENT_BINARY_DIR}/CMakeFiles/${PROJECT_NAME}Config.cmake
+-INSTALL_DESTINATION cmake
++INSTALL_DESTINATION ${library_reldir}/cmake/P4est
+ )
+
+ write_basic_package_version_file(
+@@ -14,13 +14,13 @@ COMPATIBILITY SameMajorVersion
+
+ install(EXPORT ${PROJECT_NAME}-targets
+ NAMESPACE ${PROJECT_NAME}::
+-DESTINATION cmake
++DESTINATION ${library_reldir}/cmake/P4est
+ )
+
+ install(FILES
+ ${CMAKE_CURRENT_BINARY_DIR}/CMakeFiles/${PROJECT_NAME}Config.cmake
+ ${CMAKE_CURRENT_BINARY_DIR}/CMakeFiles/${PROJECT_NAME}ConfigVersion.cmake
+-DESTINATION cmake
++DESTINATION ${library_reldir}/cmake/P4est
+ )
+
+ # --- CPack
diff --git a/sci-libs/p4est/p4est-2.8.5-r1.ebuild b/sci-libs/p4est/p4est-2.8.5-r2.ebuild
index e53b6f7eaa2e..3a6126c24456 100644
--- a/sci-libs/p4est/p4est-2.8.5-r1.ebuild
+++ b/sci-libs/p4est/p4est-2.8.5-r2.ebuild
@@ -1,7 +1,7 @@
# Copyright 1999-2023 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
-EAPI=7
+EAPI=8
inherit cmake toolchain-funcs
@@ -38,6 +38,7 @@ BDEPEND="virtual/pkgconfig"
PATCHES=(
"${FILESDIR}"/${P}-fix_build_system.patch
"${FILESDIR}"/${P}-set_version.patch
+ "${FILESDIR}"/${P}-fix_cmake_path.patch
)
pkg_pretend() {
@@ -61,9 +62,9 @@ src_configure() {
src_install() {
cmake_src_install
- mv "${ED}"/usr/cmake "${ED}"/usr/$(get_libdir)/ || die "mv failed"
+ [ ! "$(get_libdir)" = "lib" ] && mv ${ED}/usr/{lib,$(get_libdir)}/pkgconfig || die "mv failed"
- mkdir -p "${ED}"/usr/share/doc/${P}
- mv "${ED}"/usr/share/docs/P4EST/* "${ED}"/usr/share/doc/${P}/ || die "mv failed"
+ mkdir -p "${ED}"/usr/share/doc/${PF}
+ mv "${ED}"/usr/share/docs/P4EST/* "${ED}"/usr/share/doc/${PF}/ || die "mv failed"
rm -r "${ED}"/usr/share/docs || die "rm failed"
}