From 3af4933852ab0021e667db087ca55911f1f75382 Mon Sep 17 00:00:00 2001 From: Sam James Date: Tue, 22 Mar 2022 02:13:30 +0000 Subject: sci-libs/libgeotiff: update CMake patch Signed-off-by: Sam James --- .../files/libgeotiff-1.7.1-gnuinstalldirs.patch | 24 +++++++++- sci-libs/libgeotiff/libgeotiff-1.7.1-r1.ebuild | 53 ++++++++++++++++++++++ sci-libs/libgeotiff/libgeotiff-1.7.1.ebuild | 53 ---------------------- 3 files changed, 76 insertions(+), 54 deletions(-) create mode 100644 sci-libs/libgeotiff/libgeotiff-1.7.1-r1.ebuild delete mode 100644 sci-libs/libgeotiff/libgeotiff-1.7.1.ebuild (limited to 'sci-libs') diff --git a/sci-libs/libgeotiff/files/libgeotiff-1.7.1-gnuinstalldirs.patch b/sci-libs/libgeotiff/files/libgeotiff-1.7.1-gnuinstalldirs.patch index 47ee7050aa8a..6fdcd9753f95 100644 --- a/sci-libs/libgeotiff/files/libgeotiff-1.7.1-gnuinstalldirs.patch +++ b/sci-libs/libgeotiff/files/libgeotiff-1.7.1-gnuinstalldirs.patch @@ -1,6 +1,6 @@ https://github.com/OSGeo/libgeotiff/pull/74 -From 8541a109f3aad4756488f730ed8d71060f9b282f Mon Sep 17 00:00:00 2001 +From d18deccb461990c826ceee8fbcc57a44502ace2e Mon Sep 17 00:00:00 2001 From: Sam James Date: Sun, 20 Mar 2022 02:55:50 +0000 Subject: [PATCH] CMake: adopt GNUInstallDirs @@ -13,7 +13,15 @@ This works cross-platform still but it means libgeotiff uses the standard options which CMake projects tend to use for such locations and therefore no special treatment is needed when packaging it. +Fixes: https://github.com/OSGeo/issues/33 Signed-off-by: Sam James +--- + CMakeLists.txt | 41 ++++++++++------------------------- + bin/CMakeLists.txt | 6 ++--- + 2 files changed, 14 insertions(+), 33 deletions(-) + +diff --git a/CMakeLists.txt b/CMakeLists.txt +index 001df67..1840258 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -7,6 +7,8 @@ @@ -96,3 +104,17 @@ Signed-off-by: Sam James # Define grouping of source files in PROJECT file (e.g. Visual Studio) SOURCE_GROUP("CMake Files" FILES CMakeLists.txt) +diff --git a/bin/CMakeLists.txt b/bin/CMakeLists.txt +index dad465f..c61585c 100644 +--- a/bin/CMakeLists.txt ++++ b/bin/CMakeLists.txt +@@ -41,6 +41,6 @@ MESSAGE(STATUS "Adding GeoTIFF utilities to build - done: ${GEOTIFF_UTILITIES}") + # Targets installation + + INSTALL(TARGETS ${GEOTIFF_UTILITIES} +- RUNTIME DESTINATION ${GEOTIFF_BIN_DIR} +- LIBRARY DESTINATION ${GEOTIFF_LIB_DIR} +- ARCHIVE DESTINATION ${GEOTIFF_LIB_DIR}) ++ RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR} ++ LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR} ++ ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR}) diff --git a/sci-libs/libgeotiff/libgeotiff-1.7.1-r1.ebuild b/sci-libs/libgeotiff/libgeotiff-1.7.1-r1.ebuild new file mode 100644 index 000000000000..fe5e5d7051fc --- /dev/null +++ b/sci-libs/libgeotiff/libgeotiff-1.7.1-r1.ebuild @@ -0,0 +1,53 @@ +# Copyright 1999-2022 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +inherit cmake + +DESCRIPTION="Library for reading TIFF files with embedded tags for geographic information" +HOMEPAGE="https://trac.osgeo.org/geotiff/ https://github.com/OSGeo/libgeotiff" +SRC_URI="https://download.osgeo.org/geotiff/${PN}/${P}.tar.gz" + +LICENSE="GPL-2" +SLOT="0/5" +KEYWORDS="~amd64 ~arm ~arm64 ~ia64 ~ppc ~ppc64 ~riscv ~x86 ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos" +IUSE="doc jpeg +tiff zlib" + +DEPEND=">=sci-libs/proj-6.0.0:= + jpeg? ( virtual/jpeg:= ) + tiff? ( >=media-libs/tiff-3.9.1 ) + zlib? ( sys-libs/zlib )" +RDEPEND="${DEPEND}" +BDEPEND="doc? ( app-doc/doxygen )" + +PATCHES=( + "${FILESDIR}"/${PN}-1.7.1-gnuinstalldirs.patch +) + +src_configure() { + local mycmakeargs=( + -DWITH_JPEG=$(usex jpeg) + -DWITH_TIFF=$(usex tiff) + -DWITH_ZLIB=$(usex zlib) + ) + + cmake_src_configure +} + +src_compile() { + cmake_src_compile + + if use doc; then + mkdir -p docs/api || die + cp "${FILESDIR}"/Doxyfile Doxyfile || die + doxygen -u Doxyfile || die "updating doxygen config failed" + doxygen Doxyfile || die "docs generation failed" + fi +} + +src_install() { + use doc && local HTML_DOCS=( docs/api/. ) + + cmake_src_install +} diff --git a/sci-libs/libgeotiff/libgeotiff-1.7.1.ebuild b/sci-libs/libgeotiff/libgeotiff-1.7.1.ebuild deleted file mode 100644 index fe5e5d7051fc..000000000000 --- a/sci-libs/libgeotiff/libgeotiff-1.7.1.ebuild +++ /dev/null @@ -1,53 +0,0 @@ -# Copyright 1999-2022 Gentoo Authors -# Distributed under the terms of the GNU General Public License v2 - -EAPI=8 - -inherit cmake - -DESCRIPTION="Library for reading TIFF files with embedded tags for geographic information" -HOMEPAGE="https://trac.osgeo.org/geotiff/ https://github.com/OSGeo/libgeotiff" -SRC_URI="https://download.osgeo.org/geotiff/${PN}/${P}.tar.gz" - -LICENSE="GPL-2" -SLOT="0/5" -KEYWORDS="~amd64 ~arm ~arm64 ~ia64 ~ppc ~ppc64 ~riscv ~x86 ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos" -IUSE="doc jpeg +tiff zlib" - -DEPEND=">=sci-libs/proj-6.0.0:= - jpeg? ( virtual/jpeg:= ) - tiff? ( >=media-libs/tiff-3.9.1 ) - zlib? ( sys-libs/zlib )" -RDEPEND="${DEPEND}" -BDEPEND="doc? ( app-doc/doxygen )" - -PATCHES=( - "${FILESDIR}"/${PN}-1.7.1-gnuinstalldirs.patch -) - -src_configure() { - local mycmakeargs=( - -DWITH_JPEG=$(usex jpeg) - -DWITH_TIFF=$(usex tiff) - -DWITH_ZLIB=$(usex zlib) - ) - - cmake_src_configure -} - -src_compile() { - cmake_src_compile - - if use doc; then - mkdir -p docs/api || die - cp "${FILESDIR}"/Doxyfile Doxyfile || die - doxygen -u Doxyfile || die "updating doxygen config failed" - doxygen Doxyfile || die "docs generation failed" - fi -} - -src_install() { - use doc && local HTML_DOCS=( docs/api/. ) - - cmake_src_install -} -- cgit v1.2.3-18-g5258