SHA256
1
0
forked from pool/gdal

Accepting request 394770 from Application:Geo:Staging

OBS-URL: https://build.opensuse.org/request/show/394770
OBS-URL: https://build.opensuse.org/package/show/Application:Geo/gdal?expand=0&rev=28
This commit is contained in:
Martin Pluskal 2016-05-11 08:41:17 +00:00 committed by Git OBS Bridge
parent 6ee2f62d5a
commit 505fab81ad
8 changed files with 45 additions and 115 deletions

View File

@ -1,7 +1,7 @@
diff -rup a/GDALmake.opt.in b/GDALmake.opt.in diff -rup gdal-2.1.0-orig/GDALmake.opt.in gdal-2.1.0/GDALmake.opt.in
--- a/GDALmake.opt.in 2016-01-26 16:21:51.000000000 +0100 --- gdal-2.1.0-orig/GDALmake.opt.in 2016-04-25 20:35:57.000000000 +0300
+++ b/GDALmake.opt.in 2016-02-23 12:25:16.102779881 +0100 +++ gdal-2.1.0/GDALmake.opt.in 2016-05-10 05:25:25.988438174 +0300
@@ -66,7 +66,7 @@ INST_DOCS = @exec_prefix@/doc @@ -68,7 +68,7 @@ INST_DOCS = @exec_prefix@/doc
INST_MAN = @mandir@ INST_MAN = @mandir@
INST_HTML = $(HOME)/www/gdal INST_HTML = $(HOME)/www/gdal
@ -9,4 +9,4 @@ diff -rup a/GDALmake.opt.in b/GDALmake.opt.in
+CPPFLAGS = @CPPFLAGS@ -I$(GDAL_ROOT)/port -I$(GDAL_ROOT)/gcore @EXTRA_INCLUDES@ -DGDAL_COMPILATION +CPPFLAGS = @CPPFLAGS@ -I$(GDAL_ROOT)/port -I$(GDAL_ROOT)/gcore @EXTRA_INCLUDES@ -DGDAL_COMPILATION
CFLAGS = @CFLAGS@ @C_WFLAGS@ $(USER_DEFS) CFLAGS = @CFLAGS@ @C_WFLAGS@ $(USER_DEFS)
CXXFLAGS = @CXXFLAGS@ @CXX_WFLAGS@ $(USER_DEFS) CXXFLAGS = @CXXFLAGS@ @CXX_WFLAGS@ $(USER_DEFS)
LDFLAGS = @LDFLAGS@ CFLAGS_NOFTRAPV = @CFLAGS_NOFTRAPV@ @C_WFLAGS@ $(USER_DEFS)

View File

@ -1,79 +0,0 @@
Index: /branches/2.0/gdal/ogr/ogrsf_frmts/sqlite/ogrsqlitevfs.cpp
===================================================================
--- a/ogr/ogrsf_frmts/sqlite/ogrsqlitevfs.cpp (revision 33410)
+++ b/ogr/ogrsf_frmts/sqlite/ogrsqlitevfs.cpp (revision 33411)
@@ -381,9 +381,49 @@
}
-static int OGRSQLiteVFSCurrentTime (sqlite3_vfs* pVFS, double* p1)
-{
- sqlite3_vfs* pUnderlyingVFS = GET_UNDERLYING_VFS(pVFS);
- //CPLDebug("SQLITE", "OGRSQLiteVFSCurrentTime()");
- return pUnderlyingVFS->xCurrentTime(pUnderlyingVFS, p1);
+// Derived for sqlite3.c implementation of unixCurrentTime64 and winCurrentTime64
+#ifdef WIN32
+#include <windows.h>
+static int OGRSQLiteVFSCurrentTimeInt64 (sqlite3_vfs* /*pVFS*/, sqlite3_int64 *piNow)
+{
+ FILETIME ft;
+ static const sqlite3_int64 winFiletimeEpoch = 23058135*(sqlite3_int64)8640000;
+ static const sqlite3_int64 max32BitValue =
+ (sqlite3_int64)2000000000 + (sqlite3_int64)2000000000 +
+ (sqlite3_int64)294967296;
+
+#if defined(_WIN32_WCE)
+ SYSTEMTIME time;
+ GetSystemTime(&time);
+ /* if SystemTimeToFileTime() fails, it returns zero. */
+ if (!SystemTimeToFileTime(&time,&ft)){
+ return SQLITE_ERROR;
+ }
+#else
+ GetSystemTimeAsFileTime( &ft );
+#endif
+ *piNow = winFiletimeEpoch +
+ ((((sqlite3_int64)ft.dwHighDateTime)*max32BitValue) +
+ (sqlite3_int64)ft.dwLowDateTime)/(sqlite3_int64)10000;
+ return SQLITE_OK;
+}
+#else
+#include <sys/time.h>
+static int OGRSQLiteVFSCurrentTimeInt64 (sqlite3_vfs* /*pVFS*/, sqlite3_int64 *piNow)
+{
+ struct timeval sNow;
+ static const sqlite3_int64 unixEpoch = 24405875*(sqlite3_int64)8640000;
+ (void)gettimeofday(&sNow, NULL); /* Cannot fail given valid arguments */
+ *piNow = unixEpoch + 1000*(sqlite3_int64)sNow.tv_sec + sNow.tv_usec/1000;
+
+ return SQLITE_OK;
+}
+#endif
+
+static int OGRSQLiteVFSCurrentTime (sqlite3_vfs* /*pVFS*/, double* p1)
+{
+ sqlite3_int64 i = 0;
+ int rc = OGRSQLiteVFSCurrentTimeInt64(NULL, &i);
+ *p1 = i/86400000.0;
+ return rc;
}
@@ -408,5 +448,9 @@
pVFSAppData->nCounter = 0;
+#if SQLITE_VERSION_NUMBER >= 3008000L /* perhaps not the minimal version that defines xCurrentTimeInt64, but who cares */
+ pMyVFS->iVersion = 2;
+#else
pMyVFS->iVersion = 1;
+#endif
pMyVFS->szOsFile = sizeof(OGRSQLiteFileStruct);
pMyVFS->mxPathname = pDefaultVFS->mxPathname;
@@ -425,4 +469,9 @@
pMyVFS->xCurrentTime = OGRSQLiteVFSCurrentTime;
pMyVFS->xGetLastError = OGRSQLiteVFSGetLastError;
+#if SQLITE_VERSION_NUMBER >= 3008000L /* perhaps not the minimal version that defines xCurrentTimeInt64, but who cares */
+ if( pMyVFS->iVersion >= 2 )
+ pMyVFS->xCurrentTimeInt64 = OGRSQLiteVFSCurrentTimeInt64;
+#endif
+
return pMyVFS;
}

View File

@ -1,3 +0,0 @@
version https://git-lfs.github.com/spec/v1
oid sha256:90f838853cc1c07e55893483faa7e923e4b4b1659c6bc9df3538366030a7e622
size 7018768

3
gdal-2.1.0.tar.xz Normal file
View File

@ -0,0 +1,3 @@
version https://git-lfs.github.com/spec/v1
oid sha256:568b43441955b306364fcf97fb47d4c1512ac6f2f5f76b2ec39a890d2418ee03
size 7656496

View File

@ -1,16 +0,0 @@
diff -rup a/swig/python/GNUmakefile b/swig/python/GNUmakefile
--- a/swig/python/GNUmakefile 2015-06-14 21:06:33.000000000 +0200
+++ b/swig/python/GNUmakefile 2015-07-27 18:24:17.135954561 +0200
@@ -67,11 +67,7 @@ egg:
install:
-ifeq ($(PY_HAVE_SETUPTOOLS),1)
- $(PYTHON) setup.py install
-else
- $(PYTHON) setup.py install --prefix=$(DESTDIR)$(prefix)
-endif
+ $(PYTHON) setup.py install --prefix=$(prefix) --root=$(DESTDIR)
for f in $(SCRIPTS) ; do $(INSTALL) ./scripts/$$f $(DESTDIR)$(INST_BIN) ; done

View File

@ -1,7 +1,19 @@
-------------------------------------------------------------------
Tue May 10 03:11:00 UTC 2016 - Angelos Tzotsos <tzotsos@opensuse.org>
- New upstream release 2.1.0
- https://trac.osgeo.org/gdal/wiki/Release/2.1.0-News
- packaging changes
- Removed gdal-python_install.patch
- Removed gdal-2.0.2-sqlite-crash.patch
- Added ogr_wrap.patch to solve no-return-in-non-void-function error
- Submitted ogr_wrap.patch upstream: https://trac.osgeo.org/gdal/ticket/6506
- Redone patch GDALmake.opt.in.patch
------------------------------------------------------------------- -------------------------------------------------------------------
Tue Feb 23 14:42:10 UTC 2016 - bruno@ioda-net.ch Tue Feb 23 14:42:10 UTC 2016 - bruno@ioda-net.ch
- Ugrade to 2x series version : 2.0.2 bugfix release - Upgrade to 2x series version : 2.0.2 bugfix release
- https://trac.osgeo.org/gdal/wiki/Release/2.0.2-News - https://trac.osgeo.org/gdal/wiki/Release/2.0.2-News
- https://trac.osgeo.org/gdal/wiki/Release/2.0.1-News - https://trac.osgeo.org/gdal/wiki/Release/2.0.1-News
- https://trac.osgeo.org/gdal/wiki/Release/2.0.0-News - https://trac.osgeo.org/gdal/wiki/Release/2.0.0-News

View File

@ -23,24 +23,20 @@
%define sourcename gdal %define sourcename gdal
Name: gdal Name: gdal
Version: 2.0.2 Version: 2.1.0
Release: 0 Release: 0
Summary: GDAL/OGR - a translator library for raster and vector geospatial data formats Summary: GDAL/OGR - a translator library for raster and vector geospatial data formats
License: MIT and BSD-3-Clause and SUSE-Public-Domain License: MIT and BSD-3-Clause and SUSE-Public-Domain
Group: Development/Libraries/C and C++ Group: Development/Libraries/C and C++
Url: http://www.gdal.org/ Url: http://www.gdal.org/
Source0: http://download.osgeo.org/%{name}/%{version}/%{sourcename}-%{version}.tar.xz Source0: http://download.osgeo.org/%{name}/%{version}/%{sourcename}-%{version}.tar.xz
Patch0: gdal-python_install.patch Patch0: gdal-perl.patch
# Was Java but everything changed keep the reminder for 2 updates
#Patch1: gdal-configure.patch
Patch2: gdal-perl.patch
# Fix occasional parallel build failure # Fix occasional parallel build failure
Patch3: GDALmake.opt.in.patch Patch1: GDALmake.opt.in.patch
# Fix hard coded name of libproj library # Fix hard coded name of libproj library
# But libproj.so is valid if libproj-devel is installed ? # But libproj.so is valid if libproj-devel is installed ?
Patch4: gdal-libproj.patch Patch2: gdal-libproj.patch
# https://trac.osgeo.org/gdal/ticket/6360 Patch3: ogr_wrap.patch
Patch5: gdal-2.0.2-sqlite-crash.patch
BuildRequires: blas-devel BuildRequires: blas-devel
BuildRequires: chrpath BuildRequires: chrpath
BuildRequires: curl-devel BuildRequires: curl-devel
@ -159,10 +155,9 @@ The GDAL python modules provide support to handle multiple GIS file formats.
%prep %prep
%setup -q -n %{sourcename}-%{version} %setup -q -n %{sourcename}-%{version}
%patch0 -p1 %patch0 -p1
%patch1 -p1
%patch2 -p1 %patch2 -p1
%patch3 -p1 %patch3 -p1
%patch4 -p1
%patch5 -p1
# Fix mandir # Fix mandir
sed -i "s|^mandir=.*|mandir='\${prefix}/share/man'|" configure sed -i "s|^mandir=.*|mandir='\${prefix}/share/man'|" configure
@ -324,6 +319,7 @@ sed -i 's,\(#define PACKAGE_.*\),/* \1 */,' %{buildroot}%{_includedir}/gdal/cpl_
%{_bindir}/gdal_merge.py %{_bindir}/gdal_merge.py
%{_bindir}/gdal_polygonize.py %{_bindir}/gdal_polygonize.py
%{_bindir}/gdal_proximity.py %{_bindir}/gdal_proximity.py
%{_bindir}/gdal_pansharpen.py
%{_bindir}/gdal_rasterize %{_bindir}/gdal_rasterize
%{_bindir}/gdal_retile.py %{_bindir}/gdal_retile.py
%{_bindir}/gdal_sieve.py %{_bindir}/gdal_sieve.py
@ -363,6 +359,7 @@ sed -i 's,\(#define PACKAGE_.*\),/* \1 */,' %{buildroot}%{_includedir}/gdal/cpl_
%{_mandir}/man1/gdal_fillnodata.1* %{_mandir}/man1/gdal_fillnodata.1*
%{_mandir}/man1/gdal_grid.1* %{_mandir}/man1/gdal_grid.1*
%{_mandir}/man1/gdal_merge.1* %{_mandir}/man1/gdal_merge.1*
%{_mandir}/man1/gdal_pansharpen.1*
%{_mandir}/man1/gdal_polygonize.1* %{_mandir}/man1/gdal_polygonize.1*
%{_mandir}/man1/gdal_proximity.1* %{_mandir}/man1/gdal_proximity.1*
%{_mandir}/man1/gdal_rasterize.1* %{_mandir}/man1/gdal_rasterize.1*
@ -382,6 +379,9 @@ sed -i 's,\(#define PACKAGE_.*\),/* \1 */,' %{buildroot}%{_includedir}/gdal/cpl_
%{_mandir}/man1/gdaltindex.1* %{_mandir}/man1/gdaltindex.1*
%{_mandir}/man1/gdaltransform.1* %{_mandir}/man1/gdaltransform.1*
%{_mandir}/man1/gdalwarp.1* %{_mandir}/man1/gdalwarp.1*
%{_mandir}/man1/gnm_utilities.1*
%{_mandir}/man1/gnmanalyse.1*
%{_mandir}/man1/gnmmanage.1*
%{_mandir}/man1/nearblack.1* %{_mandir}/man1/nearblack.1*
%{_mandir}/man1/ogr2ogr.1* %{_mandir}/man1/ogr2ogr.1*
%{_mandir}/man1/ogr_utilities.1* %{_mandir}/man1/ogr_utilities.1*

13
ogr_wrap.patch Normal file
View File

@ -0,0 +1,13 @@
diff -rup gdal-2.1.0-orig/swig/include/ogr.i gdal-2.1.0/swig/include/ogr.i
--- gdal-2.1.0-orig/swig/include/ogr.i 2016-04-25 20:35:57.000000000 +0300
+++ gdal-2.1.0/swig/include/ogr.i 2016-05-10 17:37:30.288087450 +0300
@@ -2020,8 +2020,7 @@ public:
int GetGeomFieldIndex(int i) {
if (i < 0 || i >= OGR_FD_GetGeomFieldCount(self))
CPLError(CE_Failure, 1, FIELD_INDEX_ERROR_TMPL, i);
- else
- return i;
+ return i;
}
#endif