[Git][debian-gis-team/saga][master] 2 commits: Simplify gdal-3.13.patch, use CSLConstList unconditionally.

Bas Couwenberg (@sebastic) gitlab at salsa.debian.org
Mon Apr 20 12:08:15 BST 2026



Bas Couwenberg pushed to branch master at Debian GIS Project / saga


Commits:
2a7fa45c by Bas Couwenberg at 2026-04-19T13:52:00+02:00
Simplify gdal-3.13.patch, use CSLConstList unconditionally.

- - - - -
3bd4a64c by Bas Couwenberg at 2026-04-20T13:08:06+02:00
Mark gdal-3.13.patch as Applied-Upstream.

- - - - -


1 changed file:

- debian/patches/gdal-3.13.patch


Changes:

=====================================
debian/patches/gdal-3.13.patch
=====================================
@@ -7,69 +7,54 @@ Description: Fix FTBFS with GDAL 3.13.0.
  "
 Author: Bas Couwenberg <sebastic at debian.org>
 Forwarded: https://sourceforge.net/p/saga-gis/bugs/336/
+Applied-Upstream: https://sourceforge.net/p/saga-gis/code/ci/a7c18659885dc7baa02604f0fafd4df34bcdde93/
 
 --- a/saga-gis/src/tools/io/io_gdal/gdal_driver.cpp
 +++ b/saga-gis/src/tools/io/io_gdal/gdal_driver.cpp
-@@ -749,7 +749,11 @@ bool CSG_GDAL_DataSet::Get_MetaData(CSG_
+@@ -749,7 +749,7 @@ bool CSG_GDAL_DataSet::Get_MetaData(CSG_
  {
  	if( m_pDataSet && is_Reading() )
  	{
 -		char	**pMetaData	= GDALGetMetadata(m_pDataSet, 0);
-+#if GDAL_VERSION_NUM >= GDAL_COMPUTE_VERSION(3, 13, 0)
 +		CSLConstList	pMetaData	= GDALGetMetadata(m_pDataSet, 0);
-+#else
-+		char	**pMetaData	= GDALGetMetadata(m_pDataSet, 0);
-+#endif
  
  		if( pMetaData )
  		{
-@@ -777,7 +781,11 @@ bool CSG_GDAL_DataSet::Get_MetaData(CSG_
+@@ -777,7 +777,7 @@ bool CSG_GDAL_DataSet::Get_MetaData(CSG_
  {
  	if( m_pDataSet && is_Reading() )
  	{
-+#if GDAL_VERSION_NUM >= GDAL_COMPUTE_VERSION(3, 13, 0)
+-		char	**pMetaData	= GDALGetMetadata(m_pDataSet, pszDomain);
 +		CSLConstList	pMetaData	= GDALGetMetadata(m_pDataSet, pszDomain);
-+#else
- 		char	**pMetaData	= GDALGetMetadata(m_pDataSet, pszDomain);
-+#endif
  
  		if( pMetaData )
  		{
-@@ -895,7 +903,11 @@ CSG_String CSG_GDAL_DataSet::Get_MetaDat
+@@ -895,7 +895,7 @@ CSG_String CSG_GDAL_DataSet::Get_MetaDat
  
  	GDALRasterBandH	pBand = is_Reading() ? GDALGetRasterBand(m_pDataSet, i + 1) : NULL;
  
-+#if GDAL_VERSION_NUM >= GDAL_COMPUTE_VERSION(3, 13, 0)
+-	char **pMetaData = pBand ? GDALGetMetadata(pBand, NULL) : NULL;
 +	CSLConstList pMetaData = pBand ? GDALGetMetadata(pBand, NULL) : NULL;
-+#else
- 	char **pMetaData = pBand ? GDALGetMetadata(pBand, NULL) : NULL;
-+#endif
  
  	if( pMetaData )
  	{
-@@ -920,7 +932,11 @@ bool CSG_GDAL_DataSet::Get_MetaData(int
+@@ -920,7 +920,7 @@ bool CSG_GDAL_DataSet::Get_MetaData(int
  {
  	GDALRasterBandH	pBand = is_Reading() ? GDALGetRasterBand(m_pDataSet, i + 1) : NULL;
  
-+#if GDAL_VERSION_NUM >= GDAL_COMPUTE_VERSION(3, 13, 0)
+-	char **pMetaData = pBand ? GDALGetMetadata(pBand, NULL) : NULL;
 +	CSLConstList pMetaData = pBand ? GDALGetMetadata(pBand, NULL) : NULL;
-+#else
- 	char **pMetaData = pBand ? GDALGetMetadata(pBand, NULL) : NULL;
-+#endif
  
  	if( pMetaData )
  	{
 --- a/saga-gis/src/tools/io/io_gdal/ogr_driver.cpp
 +++ b/saga-gis/src/tools/io/io_gdal/ogr_driver.cpp
-@@ -546,7 +546,11 @@ CSG_String CSG_OGR_DataSet::Get_Descript
+@@ -546,7 +546,7 @@ CSG_String CSG_OGR_DataSet::Get_Descript
  
  	if( pLayer != NULL )
  	{
-+#if GDAL_VERSION_NUM >= GDAL_COMPUTE_VERSION(3, 13, 0)
+-		char	**pMetaData	= GDALGetMetadata(pLayer, 0);
 +		CSLConstList	pMetaData	= GDALGetMetadata(pLayer, 0);
-+#else
- 		char	**pMetaData	= GDALGetMetadata(pLayer, 0);
-+#endif
  
  		if( pMetaData )
  		{



View it on GitLab: https://salsa.debian.org/debian-gis-team/saga/-/compare/1cdcb16e40b0f55d73c85c60d180cd0f1d603079...3bd4a64cebcb912e5ff1ff3ced1478484b4e7915

-- 
View it on GitLab: https://salsa.debian.org/debian-gis-team/saga/-/compare/1cdcb16e40b0f55d73c85c60d180cd0f1d603079...3bd4a64cebcb912e5ff1ff3ced1478484b4e7915
You're receiving this email because of your account on salsa.debian.org.


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://alioth-lists.debian.net/pipermail/pkg-grass-devel/attachments/20260420/f3d7caec/attachment-0001.htm>


More information about the Pkg-grass-devel mailing list