public inbox for gentoo-commits@lists.gentoo.org
 help / color / mirror / Atom feed
From: "Sam James" <sam@gentoo.org>
To: gentoo-commits@lists.gentoo.org
Subject: [gentoo-commits] repo/gentoo:master commit in: sci-libs/gdal/, sci-libs/gdal/files/
Date: Wed, 10 May 2023 19:27:59 +0000 (UTC)	[thread overview]
Message-ID: <1683746868.9010ab474517d315954b99b5fc604a37ee55ec21.sam@gentoo> (raw)

commit:     9010ab474517d315954b99b5fc604a37ee55ec21
Author:     Sam James <sam <AT> gentoo <DOT> org>
AuthorDate: Wed May 10 19:27:37 2023 +0000
Commit:     Sam James <sam <AT> gentoo <DOT> org>
CommitDate: Wed May 10 19:27:48 2023 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=9010ab47

sci-libs/gdal: add 3.7.0

Signed-off-by: Sam James <sam <AT> gentoo.org>

 sci-libs/gdal/Manifest                       |   2 +
 sci-libs/gdal/files/gdal-3.7.0-zlib-OF.patch |  51 +++++
 sci-libs/gdal/gdal-3.7.0.ebuild              | 266 +++++++++++++++++++++++++++
 3 files changed, 319 insertions(+)

diff --git a/sci-libs/gdal/Manifest b/sci-libs/gdal/Manifest
index 085551233d50..cff14a75a5d7 100644
--- a/sci-libs/gdal/Manifest
+++ b/sci-libs/gdal/Manifest
@@ -1,6 +1,8 @@
 DIST gdal-3.5.3.tar.xz 9504740 BLAKE2B 7054df4c7ea6d8d3e6e9cf2544fc5c7a9149dea94ed882723ec82c61268100c2f5330f28a8d9d44e1296511eb2a204c64dfe41f135fadb44db380aa331d9c731 SHA512 b7bac9dd568e9db49d1fa5be8cd48df37f37196b0cacce44f738a981f0c43a77b5750312cd0c3385fdd881a6b525a5ceac56bcd08284d76071bd508d01781f49
 DIST gdal-3.6.2.tar.xz 8635724 BLAKE2B c90606b642c632dd5ec224d63aa80c158c9ee04c6ca0341815f7449b319bf9442d65c2f9b981aedd242713ef6909a30f620b448ba26baf6cd8a31e2a9ae0dd8a SHA512 d404335d37ef4916b6098fa8dc7a5e1579ecdd958b37ce73bb08855fa226d3a7b488eee52db17364ef1c0697d59805d495a734f21dad2ad2f0b27e7b1f253e50
 DIST gdal-3.6.4.tar.xz 8648032 BLAKE2B d6abdbcc87029bf230dae5586f06cbd329e5e43be37d8f5e9a72c67c93a6769458cc9c693b498e3f697b1ee1b68c9f9dbf7545ff9819fceb8fdde81b8d4ac882 SHA512 a8f69158d44ea456c44cfcb8937892697a28d2e4a43333c28db8fb9e81c51436a6edcb7a392b8c7ef63cd7453be6350a938bc4ba910720d9d5d9a1f32c57c558
+DIST gdal-3.7.0.tar.xz 8604724 BLAKE2B 400cc17fc636c637f7c40e93aed8e2db7bfbbe73741da4135cfeec8dbcda24ce0c8035214edf038afc29a916012da86a78d789729540f870231dfa6aa27e424a SHA512 4a3262d75ffbb58ec0821cd266843e28ca64c34383fb2bfaf30c984bf01c6d012381892a31a2ebc7c27a58b058fb44389cd45b05b619579b6178feb192f37bc6
 DIST gdalautotest-3.5.3.tar.gz 12374523 BLAKE2B 3f8e2ba8b49d7bb870a49bde4ec95f807ff79cf23d36504cf7beeccff104364d8fc8e287184a0239cd2c4bf5e26c900cfb29bda3beb615504e588519385a322c SHA512 3b18c94d0b0e1d6d2d38ca82cddc8e69f2acf800fa1b4e7fbabaf112e9ad69fa807b92e652b43ebd122e3b5e8d6cc0d5644e92127a673676bc7df396720dab5e
 DIST gdalautotest-3.6.2.tar.gz 12586870 BLAKE2B 28b6ae04d68964705dfe370bf189343c76fa63e358ce1c7362604743c92130c8e93ec826170a7adfd95aad8a05a5ae7a006b35cf487a81eb0c6695353ab7ef20 SHA512 63dd6f185b766cea9a200190428f2791c99f2d4032e7503404199833fa63cd31bc3b56e198a7d145cd954aace767d16d1d75c602880e9bee962dea98e9cf1859
 DIST gdalautotest-3.6.4.tar.gz 12614090 BLAKE2B d2c33b56790c1cb030a102ff48bec33c3d187c5be6e13d56da8d6cb8e9393734c2144274cbe08cf82b2a023ffb75df9fd01bcfd9f3d73076c95c4b213823f64e SHA512 2a7704e57f8bc0687c759d047b5a8fb290b2959eb058e02b08edf12e9cca17d6a9121213ef48e8b616c94c8cbe321531612700c6db52cb47fbcc5893c1c1c1c1
+DIST gdalautotest-3.7.0.tar.gz 13785892 BLAKE2B cac18436ad2acb558e27e8ba3f1f2c22aa6c7ba258abe25118acf65fb2cb8a3d5f132ccb8315912a54d07f035b5ff331cf6a66bdf51a54c8275c5203e844eb82 SHA512 81e80c799a8a910a861182480e8306c8583cdffe7cb62f47fbaddf031e1c4d1d3fb341edf0daddbb8c934e5f2d547b380feb2f5a9f22cd50db14e43c2b02737b

diff --git a/sci-libs/gdal/files/gdal-3.7.0-zlib-OF.patch b/sci-libs/gdal/files/gdal-3.7.0-zlib-OF.patch
new file mode 100644
index 000000000000..5f6dafeab525
--- /dev/null
+++ b/sci-libs/gdal/files/gdal-3.7.0-zlib-OF.patch
@@ -0,0 +1,51 @@
+--- a/frmts/zlib/contrib/infback9/minified_zutil.c
++++ b/frmts/zlib/contrib/infback9/minified_zutil.c
+@@ -8,9 +8,9 @@
+ #include "minified_zutil.h"
+ 
+ #ifndef STDC
+-extern voidp  malloc OF((uInt size));
+-extern voidp  calloc OF((uInt items, uInt size));
+-extern void   free   OF((voidpf ptr));
++extern voidp  malloc (uInt size);
++extern voidp  calloc (uInt items, uInt size);
++extern void   free   (voidpf ptr);
+ #endif
+ 
+ voidpf ZLIB_INTERNAL zcalloc(voidpf opaque, unsigned items, unsigned size)
+--- a/frmts/zlib/contrib/infback9/minified_zutil.h
++++ b/frmts/zlib/contrib/infback9/minified_zutil.h
+@@ -191,9 +191,9 @@ extern z_const char * const z_errmsg[10]; /* indexed by 2-zlib_error */
+ /* provide prototypes for these when building zlib without LFS */
+ #if !defined(_WIN32) && \
+     (!defined(_LARGEFILE64_SOURCE) || _LFS64_LARGEFILE-0 == 0)
+-    ZEXTERN uLong ZEXPORT adler32_combine64 OF((uLong, uLong, z_off_t));
+-    ZEXTERN uLong ZEXPORT crc32_combine64 OF((uLong, uLong, z_off_t));
+-    ZEXTERN uLong ZEXPORT crc32_combine_gen64 OF((z_off_t));
++    ZEXTERN uLong ZEXPORT adler32_combine64 (uLong, uLong, z_off_t);
++    ZEXTERN uLong ZEXPORT crc32_combine64 (uLong, uLong, z_off_t);
++    ZEXTERN uLong ZEXPORT crc32_combine_gen64 (z_off_t);
+ #endif
+ 
+         /* common defaults */
+@@ -232,16 +232,16 @@ extern z_const char * const z_errmsg[10]; /* indexed by 2-zlib_error */
+ #    define zmemzero(dest, len) memset(dest, 0, len)
+ #  endif
+ #else
+-   void ZLIB_INTERNAL zmemcpy OF((Bytef* dest, const Bytef* source, uInt len));
+-   int ZLIB_INTERNAL zmemcmp OF((const Bytef* s1, const Bytef* s2, uInt len));
+-   void ZLIB_INTERNAL zmemzero OF((Bytef* dest, uInt len));
++   void ZLIB_INTERNAL zmemcpy (Bytef* dest, const Bytef* source, uInt len);
++   int ZLIB_INTERNAL zmemcmp (const Bytef* s1, const Bytef* s2, uInt len);
++   void ZLIB_INTERNAL zmemzero (Bytef* dest, uInt len);
+ #endif
+ 
+ /* Diagnostic functions */
+ #ifdef ZLIB_DEBUG
+ #  include <stdio.h>
+    extern int ZLIB_INTERNAL z_verbose;
+-   extern void ZLIB_INTERNAL z_error OF((char *m));
++   extern void ZLIB_INTERNAL z_error (char *m);
+ #  define Assert(cond,msg) {if(!(cond)) z_error(msg);}
+ #  define Trace(x) {if (z_verbose>=0) fprintf x ;}
+ #  define Tracev(x) {if (z_verbose>0) fprintf x ;}

diff --git a/sci-libs/gdal/gdal-3.7.0.ebuild b/sci-libs/gdal/gdal-3.7.0.ebuild
new file mode 100644
index 000000000000..ef7fc667de4d
--- /dev/null
+++ b/sci-libs/gdal/gdal-3.7.0.ebuild
@@ -0,0 +1,266 @@
+# Copyright 1999-2023 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+PYTHON_COMPAT=( python3_{10..11} )
+inherit cmake java-pkg-opt-2 python-single-r1
+
+DESCRIPTION="Translator library for raster geospatial data formats (includes OGR support)"
+HOMEPAGE="https://gdal.org/"
+SRC_URI="https://download.osgeo.org/${PN}/${PV}/${P}.tar.xz"
+SRC_URI+=" test? ( https://download.osgeo.org/${PN}/${PV}/${PN}autotest-${PV}.tar.gz )"
+
+LICENSE="BSD Info-ZIP MIT"
+SLOT="0/33" # subslot is libgdal.so.<SONAME>
+KEYWORDS="~amd64 ~arm ~arm64 ~ia64 ~ppc ~ppc64 ~riscv ~x86 ~amd64-linux ~x86-linux ~ppc-macos"
+IUSE="armadillo +curl cpu_flags_x86_avx cpu_flags_x86_avx2 cpu_flags_x86_sse cpu_flags_x86_sse2 cpu_flags_x86_sse4_1 cpu_flags_x86_ssse3 doc fits geos gif gml hdf5 heif java jpeg jpeg2k lzma mysql netcdf odbc ogdi opencl oracle pdf png postgres python spatialite sqlite test webp xls zstd"
+RESTRICT="!test? ( test )"
+
+REQUIRED_USE="
+	python? ( ${PYTHON_REQUIRED_USE} )
+	spatialite? ( sqlite )
+	test? ( ${PYTHON_REQUIRED_USE} )
+"
+
+BDEPEND="
+	virtual/pkgconfig
+	doc? ( app-doc/doxygen )
+	java? (
+		dev-java/ant-core
+		dev-lang/swig
+		>=virtual/jdk-1.8:*
+	)
+	python? (
+		dev-lang/swig
+		$(python_gen_cond_dep '
+			dev-python/setuptools[${PYTHON_USEDEP}]
+		')
+	)
+	test? (
+		${PYTHON_DEPS}
+		dev-cpp/gtest
+	)
+"
+DEPEND="
+	dev-libs/expat
+	dev-libs/json-c:=
+	dev-libs/libpcre2
+	dev-libs/libxml2:2
+	dev-libs/openssl:=
+	media-libs/tiff
+	>=sci-libs/libgeotiff-1.5.1-r1:=
+	>=sci-libs/proj-6.0.0:=
+	sys-libs/zlib[minizip(+)]
+	armadillo? ( sci-libs/armadillo:=[lapack] )
+	curl? ( net-misc/curl )
+	fits? ( sci-libs/cfitsio:= )
+	geos? ( >=sci-libs/geos-3.8.0 )
+	gif? ( media-libs/giflib:= )
+	gml? ( >=dev-libs/xerces-c-3.1 )
+	heif? ( media-libs/libheif:= )
+	hdf5? ( >=sci-libs/hdf5-1.6.4:=[cxx,szip] )
+	jpeg? ( media-libs/libjpeg-turbo:= )
+	jpeg2k? ( media-libs/openjpeg:2= )
+	lzma? ( || (
+		app-arch/xz-utils
+		app-arch/lzma
+	) )
+	mysql? ( virtual/mysql )
+	netcdf? ( sci-libs/netcdf:= )
+	odbc? ( dev-db/unixODBC )
+	ogdi? ( >=sci-libs/ogdi-4.1.0-r1 )
+	opencl? ( virtual/opencl )
+	oracle? ( dev-db/oracle-instantclient:= )
+	pdf? ( app-text/poppler:= )
+	png? ( media-libs/libpng:= )
+	postgres? ( >=dev-db/postgresql-8.4:= )
+	python? (
+		${PYTHON_DEPS}
+		$(python_gen_cond_dep '
+			dev-python/numpy[${PYTHON_USEDEP}]
+		')
+	)
+	spatialite? ( dev-db/spatialite )
+	sqlite? ( dev-db/sqlite:3 )
+	webp? ( media-libs/libwebp:= )
+	xls? ( dev-libs/freexl )
+	zstd? ( app-arch/zstd:= )
+"
+RDEPEND="
+	${DEPEND}
+	java? ( >=virtual/jre-1.8:* )
+"
+
+QA_CONFIG_IMPL_DECL_SKIP=(
+	_wstat64 # Windows LFS
+)
+
+PATCHES=(
+	"${FILESDIR}"/${PN}-3.6.4-abseil-cpp-20230125.2-c++17.patch
+	"${FILESDIR}"/${PN}-3.7.0-zlib-OF.patch
+)
+
+pkg_setup() {
+	if use python || use test ; then
+		python-single-r1_pkg_setup
+	fi
+
+	use java && java-pkg-opt-2_pkg_setup
+}
+
+src_prepare() {
+	cmake_src_prepare
+
+	if use test ; then
+		mv "${WORKDIR}"/gdalautotest-${PV} "${S}"/autotest || die
+	fi
+}
+
+src_configure() {
+	local mycmakeargs=(
+		-DENABLE_IPO=OFF
+		-DGDAL_USE_EXTERNAL_LIBS=ON
+		-DGDAL_USE_INTERNAL_LIBS=OFF
+		-DUSE_EXTERNAL_GTEST=ON
+		-DBUILD_TESTING=$(usex test)
+
+		# bug #844874 and bug #845150
+		-DCMAKE_INSTALL_INCLUDEDIR="include/gdal"
+
+		# Options here are generally off because of one of:
+		# - Not yet packaged dependencies
+		#
+		# - Off for autotools build and didn't want more churn by
+		#   enabling during port to CMake. Feel free to request them
+		#   being turned on if useful for you.
+		-DGDAL_USE_ARMADILLO=$(usex armadillo)
+		-DGDAL_USE_ARROW=OFF
+		-DGDAL_USE_BLOSC=OFF
+		-DGDAL_USE_BRUNSLI=OFF
+		-DGDAL_USE_CRNLIB=OFF
+		-DGDAL_USE_CFITSIO=$(usex fits)
+		-DGDAL_USE_CURL=$(usex curl)
+		-DGDAL_USE_CRYPTOPP=OFF
+		-DGDAL_USE_DEFLATE=OFF
+		-DGDAL_USE_ECW=OFF
+		-DGDAL_USE_EXPAT=ON
+		-DGDAL_USE_FILEGDB=OFF
+		-DGDAL_USE_FREEXL=$(usex xls)
+		-DGDAL_USE_FYBA=OFF
+		-DGDAL_USE_GEOTIFF=ON
+		-DGDAL_USE_GEOS=$(usex geos)
+		-DGDAL_USE_GIF=$(usex gif)
+		-DGDAL_USE_GTA=OFF
+		-DGDAL_USE_HEIF=$(usex heif)
+		-DGDAL_USE_HDF4=OFF
+		-DGDAL_USE_HDF5=$(usex hdf5)
+		-DGDAL_USE_HDFS=OFF
+		-DGDAL_USE_ICONV=ON # TODO dep
+		-DGDAL_USE_IDB=OFF
+		-DGDAL_USE_JPEG=$(usex jpeg)
+
+		# https://gdal.org/build_hints.html#jpeg12
+		# Independent of whether using system libjpeg
+		-DGDAL_USE_JPEG12_INTERNAL=ON
+
+		-DGDAL_USE_JSONC=ON
+		-DGDAL_USE_JXL=OFF
+		-DGDAL_USE_KDU=OFF
+		-DGDAL_USE_KEA=OFF
+		-DGDAL_USE_LERC=OFF
+		-DGDAL_USE_LIBKML=OFF
+		-DGDAL_USE_LIBLZMA=$(usex lzma)
+		-DGDAL_USE_LIBXML2=ON
+		-DGDAL_USE_LURATECH=OFF
+		-DGDAL_USE_LZ4=OFF
+		-DGDAL_USE_MONGOCXX=OFF
+		-DGDAL_USE_MRSID=OFF
+		-DGDAL_USE_MSSQL_NCLI=OFF
+		-DGDAL_USE_MSSQL_ODBC=OFF
+		-DGDAL_USE_MYSQL=$(usex mysql)
+		-DGDAL_USE_NETCDF=$(usex netcdf)
+		-DGDAL_USE_ODBC=$(usex odbc)
+		-DGDAL_USE_ODBCCPP=OFF
+		-DGDAL_USE_OGDI=$(usex ogdi)
+		-DGDAL_USE_OPENCAD=OFF
+		-DGDAL_USE_OPENCL=$(usex opencl)
+		-DGDAL_USE_OPENEXR=OFF
+		-DGDAL_USE_OPENJPEG=$(usex jpeg2k)
+		-DGDAL_USE_OPENSSL=ON
+		-DGDAL_USE_ORACLE=$(usex oracle)
+		-DGDAL_USE_PARQUET=OFF
+		-DGDAL_USE_PCRE2=ON
+		-DGDAL_USE_PDFIUM=OFF
+		-DGDAL_USE_PNG=$(usex png)
+		-DGDAL_USE_PODOFO=OFF
+		-DGDAL_USE_POPPLER=$(usex pdf)
+		-DGDAL_USE_POSTGRESQL=$(usex postgres)
+		-DGDAL_USE_QHULL=OFF
+		-DGDAL_USE_RASTERLITE2=OFF
+		-DGDAL_USE_RDB=OFF
+		-DGDAL_USE_SPATIALITE=$(usex spatialite)
+		-DGDAL_USE_SQLITE3=$(usex sqlite)
+		-DGDAL_USE_SFCGAL=OFF
+		-DGDAL_USE_TEIGHA=OFF
+		-DGDAL_USE_TIFF=ON
+		-DGDAL_USE_TILEDB=OFF
+		-DGDAL_USE_WEBP=$(usex webp)
+		-DGDAL_USE_XERCESC=$(usex gml)
+		-DGDAL_USE_ZLIB=ON
+		-DGDAL_USE_ZSTD=$(usex zstd)
+
+		# Bindings
+		-DBUILD_PYTHON_BINDINGS=$(usex python)
+		-DBUILD_JAVA_BINDINGS=$(usex java)
+		# bug #845369
+		-DBUILD_CSHARP_BINDINGS=OFF
+
+		# Check work/gdal-3.5.0_build/CMakeCache.txt after configure
+		# and https://github.com/OSGeo/gdal/blob/master/cmake/helpers/CheckCompilerMachineOption.cmake#L71
+		# Commented out: not (yet?) implemented upstream.
+		# Also, arm64 stuff is a TODO upstream, but not there (yet?)
+		-Dtest_avx=$(usex cpu_flags_x86_avx)
+		-Dtest_avx2=$(usex cpu_flags_x86_avx2)
+		-Dtest_sse=$(usex cpu_flags_x86_sse)
+		-Dtest_sse2=$(usex cpu_flags_x86_sse2)
+		#-Dtest_sse3=$(usex cpu_flags_x86_sse3)
+		-Dtest_sse4.1=$(usex cpu_flags_x86_sse4_1)
+		#-Dtest_sse4.2=$(usex cpu_flags_x86_sse4_2)
+		#-Dtest_sse4a=$(usex cpu_flags_x86_sse4a)
+		-Dtest_ssse3=$(usex cpu_flags_x86_ssse3)
+		#-Dtest_fma4=$(usex cpu_flags_x86_fma4)
+		#-Dtest_xop=$(usex cpu_flags_x86_xop)
+	)
+
+	cmake_src_configure
+}
+
+src_compile() {
+	cmake_src_compile
+
+	use doc && cmake_src_compile doc
+}
+
+src_test() {
+	export GDAL_RUN_SLOW_TESTS=0
+	export GDAL_DOWNLOAD_TEST_DATA=0
+
+	# Two test suites:
+	# 1. autotests (much larger, uses pytest)
+	# 2. Small set of fuzzing tests (no download needed)
+
+	# Missing file for test-unit?
+	cmake_src_test -E "(test-unit)"
+}
+
+src_install() {
+	cmake_src_install
+	use python && python_optimize
+	# TODO: install docs?
+}
+
+pkg_postinst() {
+	elog "Check available image and data formats after building with"
+	elog "gdalinfo and ogrinfo (using the --formats switch)."
+}


             reply	other threads:[~2023-05-10 19:28 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-05-10 19:27 Sam James [this message]
  -- strict thread matches above, loose matches on Subject: below --
2024-05-13 23:14 [gentoo-commits] repo/gentoo:master commit in: sci-libs/gdal/, sci-libs/gdal/files/ Andreas Sturmlechner
2024-04-11 10:02 Andrew Ammerlaan
2023-04-23  6:06 Sam James
2021-03-09 20:43 Sam James
2020-08-05  8:26 Andreas Sturmlechner
2020-01-29 21:32 Andreas Sturmlechner
2020-01-01 15:19 Andreas Sturmlechner
2019-03-02 20:29 Andreas Sturmlechner
2019-01-12 20:07 Andreas Sturmlechner
2018-11-03 22:51 Andreas Sturmlechner
2018-08-12 19:17 Amy Liffey
2018-08-04 12:04 Amy Liffey
2018-06-19  9:09 Amy Liffey
2018-02-04 10:18 Andreas Sturmlechner
2018-01-16 21:06 Andreas Sturmlechner
2016-11-07 13:56 Amy Winston
2015-10-24 17:23 Justin Lecher

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1683746868.9010ab474517d315954b99b5fc604a37ee55ec21.sam@gentoo \
    --to=sam@gentoo.org \
    --cc=gentoo-commits@lists.gentoo.org \
    --cc=gentoo-dev@lists.gentoo.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox