<div dir="ltr">Hello all,<div><br></div><div>I am trying to build GDAL 3.1.0 on my machine with Ubuntu 18.04. Why go through all the trouble? Because ubuntu-gis doesn't seem to want to bundle the ESRI GDB driver with the gdal binaries, so I have to do it myself. Very annoying.</div><div><br></div><div>Anyway, here is the problematic output from running make:</div><div><br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><font face="monospace">make[3]: Entering directory '/home/ben/software/gdal/gdal-3.1.0/ogr/ogrsf_frmts/sqlite'<br>/bin/bash /home/ben/software/gdal/gdal-3.1.0/libtool --mode=compile --silent --tag=CXX g++ -I/home/ben/software/gdal/gdal-3.1.0/port -I/home/ben/software/gdal/gdal-3.1.0/gcore -I/home/ben/software/gdal/gdal-3.1.0/alg -I/home/ben/software/gdal/gdal-3.1.0/ogr -I/home/ben/software/gdal/gdal-3.1.0/ogr/ogrsf_frmts -I/home/ben/software/gdal/gdal-3.1.0/gnm -I/home/ben/software/gdal/gdal-3.1.0/apps -DHAVE_AVX_AT_COMPILE_TIME -DHAVE_SSSE3_AT_COMPILE_TIME -DHAVE_SSE_AT_COMPILE_TIME -g -O2  -Wall -Wextra -Winit-self -Wunused-parameter -Wformat -Werror=format-security -Wno-format-nonliteral -Wlogical-op -Wshadow -Werror=vla -Wdate-time -Wnull-dereference -Wduplicated-cond -Wfloat-conversion -Wmissing-declarations -Wnon-virtual-dtor -Woverloaded-virtual -fno-operator-names -Wzero-as-null-pointer-constant -Wsuggest-override -Wimplicit-fallthrough  -I..    -I/usr/local/include  -DGNM_ENABLED -D_REENTRANT  -I/home/ben/software/gdal/gdal-3.1.0/port -I/usr/include/openjpeg-2.3 -I/usr/include -I/usr/local/share/libgta -I/usr/local/share/libgta/include -I/usr -I/usr/include  -DGDAL_COMPILATION -DHAVE_XERCES -I/usr/include -I/usr/include/xercesc -D_REENTRANT  -I/home/ben/software/gdal/gdal-3.1.0/port -I/usr/include/openjpeg-2.3 -I/usr/include -I/usr/local/share/libgta -I/usr/local/share/libgta/include -I/usr -I/usr/include  -DGDAL_COMPILATION -DHAVE_SPATIALITE -DSPATIALITE_412_OR_LATER -DHAVE_PCRE -DSQLITE_HAS_COLUMN_METADATA -DHAVE_RASTERLITE2  -c -o ../o/rasterlite2.lo rasterlite2.cpp<br>rasterlite2.cpp: In function ‘GDALDataset* OGRSQLiteDriverCreateCopy(const char*, GDALDataset*, int, char**, GDALProgressFunc, void*)’:<br>rasterlite2.cpp:2283:57: error: invalid conversion from ‘void*’ to ‘rl2CoveragePtr {aka rl2_coverage*}’ [-fpermissive]<br>                                      poDS->GetRL2Context(),<br>                                      ~~~~~~~~~~~~~~~~~~~^~<br>rasterlite2.cpp:2292:49: error: cannot convert ‘rl2CoveragePtr {aka rl2_coverage*}’ to ‘const char*’ for argument ‘3’ to ‘int rl2_load_raw_tiles_into_dbms(sqlite3*, rl2CoveragePtr, const char*, unsigned int, unsigned int, int, double, double, double, double, int (*)(void*, double, double, double, double, unsigned char*, rl2Palette**), void*, int)’<br>                                      bPyramidize) != RL2_OK )<br>                                                 ^<br>rasterlite2.cpp: In member function ‘virtual CPLErr OGRSQLiteDataSource::IBuildOverviews(const char*, int, int*, int, int*, GDALProgressFunc, void*)’:<br>rasterlite2.cpp:2382:68: error: invalid conversion from ‘void*’ to ‘int’ [-fpermissive]<br>                 ret = rl2_build_section_pyramid( hDB, GetRL2Context(),<br>                                                       ~~~~~~~~~~~~~^~<br>In file included from rasterlite2_header.h:46:0,<br>                 from ogr_sqlite.h:44,<br>                 from rasterlite2.cpp:37:<br>/usr/local/include/rasterlite2/rasterlite2.h:4735:2: note:   initializing argument 2 of ‘int rl2_build_section_pyramid(sqlite3*, int, const char*, sqlite3_int64, int, int)’<br>  rl2_build_section_pyramid (sqlite3 * handle, int max_threads,<br>  ^~~~~~~~~~~~~~~~~~~~~~~~~<br>rasterlite2.cpp:2388:71: error: invalid conversion from ‘void*’ to ‘const char*’ [-fpermissive]<br>                 ret = rl2_build_monolithic_pyramid (hDB, GetRL2Context(),<br>                                                          ~~~~~~~~~~~~~^~<br>rasterlite2.cpp:2389:53: error: invalid user-defined conversion from ‘CPLString’ to ‘int’ [-fpermissive]<br>                                                     m_osCoverageName,<br>                                                     ^~~~~~~~~~~~~~~~<br>In file included from /home/ben/software/gdal/gdal-3.1.0/gcore/gdal_priv.h:64:0,<br>                 from /home/ben/software/gdal/gdal-3.1.0/gcore/gdal_pam.h:35,<br>                 from ogr_sqlite.h:41,<br>                 from rasterlite2.cpp:37:<br>/home/ben/software/gdal/gdal-3.1.0/port/cpl_string.h:348:5: note: candidate is: CPLString::operator const char*() const <near match><br>     operator const char* (void) const { return c_str(); }<br>     ^~~~~~~~<br>/home/ben/software/gdal/gdal-3.1.0/port/cpl_string.h:348:5: note:   no known conversion from ‘const char*’ to ‘int’<br>rasterlite2.cpp:2391:61: error: too many arguments to function ‘int rl2_build_monolithic_pyramid(sqlite3*, const char*, int, int)’<br>                                                     bVerbose);<br>                                                             ^<br>In file included from rasterlite2_header.h:46:0,<br>                 from ogr_sqlite.h:44,<br>                 from rasterlite2.cpp:37:<br>/usr/local/include/rasterlite2/rasterlite2.h:4741:2: note: declared here<br>  rl2_build_monolithic_pyramid (sqlite3 * handle, const char *coverage,<br>  ^~~~~~~~~~~~~~~~~~~~~~~~~~~~<br>rasterlite2.cpp:2398:62: error: invalid conversion from ‘void*’ to ‘const char*’ [-fpermissive]<br>                                                 GetRL2Context(),<br>                                                 ~~~~~~~~~~~~~^~<br>rasterlite2.cpp:2399:49: error: invalid user-defined conversion from ‘CPLString’ to ‘int’ [-fpermissive]<br>                                                 m_osCoverageName,<br>                                                 ^~~~~~~~~~~~~~~~<br>In file included from /home/ben/software/gdal/gdal-3.1.0/gcore/gdal_priv.h:64:0,<br>                 from /home/ben/software/gdal/gdal-3.1.0/gcore/gdal_pam.h:35,<br>                 from ogr_sqlite.h:41,<br>                 from rasterlite2.cpp:37:<br>/home/ben/software/gdal/gdal-3.1.0/port/cpl_string.h:348:5: note: candidate is: CPLString::operator const char*() const <near match><br>     operator const char* (void) const { return c_str(); }<br>     ^~~~~~~~<br>/home/ben/software/gdal/gdal-3.1.0/port/cpl_string.h:348:5: note:   no known conversion from ‘const char*’ to ‘int’<br>rasterlite2.cpp:2401:57: error: too many arguments to function ‘int rl2_build_monolithic_pyramid(sqlite3*, const char*, int, int)’<br>                                                 bVerbose);<br>                                                         ^<br>In file included from rasterlite2_header.h:46:0,<br>                 from ogr_sqlite.h:44,<br>                 from rasterlite2.cpp:37:<br>/usr/local/include/rasterlite2/rasterlite2.h:4741:2: note: declared here<br>  rl2_build_monolithic_pyramid (sqlite3 * handle, const char *coverage,<br>  ^~~~~~~~~~~~~~~~~~~~~~~~~~~~<br>../../../GDALmake.opt:649: recipe for target '../o/rasterlite2.lo' failed<br>make[3]: *** [../o/rasterlite2.lo] Error 1<br>make[3]: Leaving directory '/home/ben/software/gdal/gdal-3.1.0/ogr/ogrsf_frmts/sqlite'<br>../../GDALmake.opt:662: recipe for target 'sqlite-target' failed<br>make[2]: *** [sqlite-target] Error 2<br>make[2]: Leaving directory '/home/ben/software/gdal/gdal-3.1.0/ogr/ogrsf_frmts'<br>GNUmakefile:58: recipe for target 'sublibs' failed<br>make[1]: *** [sublibs] Error 2<br>make[1]: Leaving directory '/home/ben/software/gdal/gdal-3.1.0/ogr'<br>GNUmakefile:91: recipe for target 'ogr-target' failed<br>make: *** [ogr-target] Error 2</font></blockquote><div><br></div><div>I have librasterlite3 version 1.1.0-beta0-1 installed on my system, so that's the version that it's linking against or whatever. Honestly doing this is such a nightmare, makes me wish we had OSGEO4W on Linux.</div><div><br></div><div>For reference, here is my configure command:</div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><font face="monospace">./configure \<br>  --with-libz=internal \<br>        --with-liblzma=yes \<br>  --with-zstd=yes \<br>     --with-pg=yes \<br>       --with-cfitsio=/usr \<br> --with-gta=/usr/local/share/libgta \<br>  --with-libtiff=yes \<br>  --with-charls \<br>       --with-sosi=yes \<br>     --with-kea=yes \<br>      --with-netcdf=/usr/bin \<br>      --with-fgdb=/opt/FileGDB_API-64 \<br>     --with-epsilon \<br>      --with-mysql=/usr/bin/mysql_config \<br>  --with-dods-root=/usr \<br>       --with-spatialite=yes \<br>       --with-rasterlite2=yes \<br>      --with-sfcgal=yes \<br>   --with-poppler=yes \<br>  --with-opencl \<br>       --with-armadillo=yes \<br>        --with-mdb \<br>  --with-java \<br> --with-proj=/usr/local \<br>      --with-mrsid=/opt/mrsid/Raster_DSDK/ \<br>        --prefix=/usr \<br>    --with-python=python2.7 --with-python=python3.6 \<br>      --with-grass=/usr/lib/grass74 \<br>       --with-libgrass=/usr/lib/grass74/lib \<br>        --with-ogdi=no</font></blockquote><div>Basically I've been trying to build GDAL with as many drivers as possible. Some of them I just couldn't get to work, which I guess is whatever, but I definitely need rasterlite2, so this not working is a problem.</div><div><br></div><div>Any chance someone can point me in the right direction here? I know I was able to compile version 2.4.0 back in December after hours of headaches, hoping to avoid such a process this time around.</div><div><br></div><div>Thanks,</div><div>Ben Van Riper</div></div>