[QGIS-Developer] Trying to build with GDAL3/PROJ6, anybody successful?

Richard Duivenvoorde rdmailings at duif.net
Thu May 16 01:48:53 PDT 2019


Hi,

To be able to test some (gdal) wfs3 stuff I've succesfully build my own
gdal3 and proj lib.
But I fail to build QGIS with it.
Anybody already succesfull?
My try (using options I used to build QGIS earlier with my own builds of
gdal/proj):

export
LD_LIBRARY_PATH=/home/richard/bin/qgis/qgisgdal/debug/lib/:/home/richard/bin/gdal/lib:/home/richard/bin/proj/lib

mkdir build;
cd build;
ccmake -DBUILD_TESTING=FALSE -DENABLE_TESTS=OFF -DWITH_SERVER=TRUE
-DWITH_3D=TRUE
-DCMAKE_INSTALL_PREFIX=/home/richard/bin/qgis/qgisgdal/debug
-DWITH_QWTPOLAR=OFF -DCMAKE_BUILD_TYPE=Debug
-DPROJ_INCLUDE_DIR=/home/richard/bin/proj/include/
-DPROJ_LIBRARY=/home/richard/bin/proj/lib/libinternalproj.so.15
-DGDAL_CONFIG=/home/richard/bin/gdal/bin/gdal-config
-DGDAL_INCLUDE_DIR=/home/richard/bin/gdal/include/
-DGDAL_LIBRARY=/home/richard/bin/gdal/lib/libgdal.so
-DQT5_3DEXTRA_LIBRARY=/usr/lib/x86_64-linux-gnu/libQt53DExtras.so
-DCMAKE_PREFIX_PATH=/home/richard/git/qgisgdal/external/qt3dextra-headers/cmake
-DQT5_3DEXTRA_INCLUDE_DIR=/home/richard/git/qgisgdal/external/qt3dextra-headers
-DACCEPT_USE_OF_DEPRECATED_PROJ_API_H=1 ..

The build stops when Make is trying to link libqgis_core.so

It's not clear to me what is the problem: is it trying to use my distro
proj lib?
Or is it trying to find removed symbols?
Or should I just not try this yet :-)

Anybody can see what I'm missing?

Regards,

Richard Duivenvoorde


[ 29%] Linking CXX shared library ../../output/lib/libqgis_core.so
/usr/bin/ld:
CMakeFiles/qgis_core.dir/processing/qgsprocessingfeedback.cpp.o: in
function `QgsProcessingFeedback::pushVersionInfo(QgsProcessingProvider
const*)':
/home/richard/git/qgisgdal/src/core/processing/qgsprocessingfeedback.cpp:70:
undefined reference to `proj_info'
/usr/bin/ld:
CMakeFiles/qgis_core.dir/qgscoordinatereferencesystem.cpp.o: in function
`getFullProjString(PJconsts*)':
/home/richard/git/qgisgdal/src/core/qgscoordinatereferencesystem.cpp:82:
undefined reference to `proj_crs_create_bound_crs_to_WGS84'
/usr/bin/ld:
/home/richard/git/qgisgdal/src/core/qgscoordinatereferencesystem.cpp:85:
undefined reference to `proj_as_proj_string'
/usr/bin/ld:
/home/richard/git/qgisgdal/src/core/qgscoordinatereferencesystem.cpp:91:
undefined reference to `proj_as_proj_string'
/usr/bin/ld:
CMakeFiles/qgis_core.dir/qgscoordinatereferencesystem.cpp.o: in function
`QgsCoordinateReferenceSystem::loadFromDatabase(QString const&, QString
const&, QString const&)':
/home/richard/git/qgisgdal/src/core/qgscoordinatereferencesystem.cpp:556:
undefined reference to `proj_create_from_database'
/usr/bin/ld:
CMakeFiles/qgis_core.dir/qgscoordinatereferencesystem.cpp.o: in function
`QgsCoordinateReferenceSystem::createFromWkt(QString const&)':
/home/richard/git/qgisgdal/src/core/qgscoordinatereferencesystem.cpp:642:
undefined reference to `proj_create_from_wkt'
/usr/bin/ld:
/home/richard/git/qgisgdal/src/core/qgscoordinatereferencesystem.cpp:658:
undefined reference to `proj_string_list_destroy'
/usr/bin/ld:
/home/richard/git/qgisgdal/src/core/qgscoordinatereferencesystem.cpp:659:
undefined reference to `proj_string_list_destroy'
/usr/bin/ld:
/home/richard/git/qgisgdal/src/core/qgscoordinatereferencesystem.cpp:686:
undefined reference to `proj_get_id_auth_name'
/usr/bin/ld:
/home/richard/git/qgisgdal/src/core/qgscoordinatereferencesystem.cpp:687:
undefined reference to `proj_get_id_code'
/usr/bin/ld:
CMakeFiles/qgis_core.dir/qgscoordinatereferencesystem.cpp.o: in function
`QgsCoordinateReferenceSystem::createFromProj4(QString const&)':
/home/richard/git/qgisgdal/src/core/qgscoordinatereferencesystem.cpp:826:
undefined reference to `proj_create'
/usr/bin/ld:
/home/richard/git/qgisgdal/src/core/qgscoordinatereferencesystem.cpp:831:
undefined reference to `proj_identify'
/usr/bin/ld:
/home/richard/git/qgisgdal/src/core/qgscoordinatereferencesystem.cpp:833:
undefined reference to `proj_list_get_count'
/usr/bin/ld:
/home/richard/git/qgisgdal/src/core/qgscoordinatereferencesystem.cpp:841:
undefined reference to `proj_list_get'
/usr/bin/ld:
/home/richard/git/qgisgdal/src/core/qgscoordinatereferencesystem.cpp:842:
undefined reference to `proj_get_id_auth_name'
/usr/bin/ld:
/home/richard/git/qgisgdal/src/core/qgscoordinatereferencesystem.cpp:850:
undefined reference to `proj_list_destroy'
/usr/bin/ld:
/home/richard/git/qgisgdal/src/core/qgscoordinatereferencesystem.cpp:851:
undefined reference to `proj_int_list_destroy'
/usr/bin/ld:
/home/richard/git/qgisgdal/src/core/qgscoordinatereferencesystem.cpp:854:
undefined reference to `proj_get_id_auth_name'
/usr/bin/ld:
/home/richard/git/qgisgdal/src/core/qgscoordinatereferencesystem.cpp:855:
undefined reference to `proj_get_id_code'
/usr/bin/ld:
CMakeFiles/qgis_core.dir/qgscoordinatereferencesystem.cpp.o: in function
`QgsCoordinateReferenceSystem::setProj4String(QString const&)':
/home/richard/git/qgisgdal/src/core/qgscoordinatereferencesystem.cpp:1317:
undefined reference to `proj_create'
/usr/bin/ld:
/home/richard/git/qgisgdal/src/core/qgscoordinatereferencesystem.cpp:1323:
undefined reference to `proj_context_errno'
/usr/bin/ld:
/home/richard/git/qgisgdal/src/core/qgscoordinatereferencesystem.cpp:1324:
undefined reference to `proj_errno_string'
/usr/bin/ld:
/home/richard/git/qgisgdal/src/core/qgscoordinatereferencesystem.cpp:1329:
undefined reference to `proj_get_ellipsoid'
/usr/bin/ld:
/home/richard/git/qgisgdal/src/core/qgscoordinatereferencesystem.cpp:1332:
undefined reference to `proj_get_id_auth_name'
/usr/bin/ld:
/home/richard/git/qgisgdal/src/core/qgscoordinatereferencesystem.cpp:1333:
undefined reference to `proj_get_id_code'
/usr/bin/ld:
CMakeFiles/qgis_core.dir/qgscoordinatereferencesystem.cpp.o: in function
`QgsCoordinateReferenceSystem::setMapUnits()':
/home/richard/git/qgisgdal/src/core/qgscoordinatereferencesystem.cpp:1412:
undefined reference to `proj_crs_get_coordinate_system'
/usr/bin/ld:
/home/richard/git/qgisgdal/src/core/qgscoordinatereferencesystem.cpp:1419:
undefined reference to `proj_cs_get_axis_count'
/usr/bin/ld:
/home/richard/git/qgisgdal/src/core/qgscoordinatereferencesystem.cpp:1424:
undefined reference to `proj_cs_get_axis_info'
/usr/bin/ld:
CMakeFiles/qgis_core.dir/qgscoordinatereferencesystem.cpp.o: in function
`QgsCoordinateReferenceSystem::toWkt() const':
/home/richard/git/qgisgdal/src/core/qgscoordinatereferencesystem.cpp:1616:
undefined reference to `proj_as_wkt'
/usr/bin/ld:
CMakeFiles/qgis_core.dir/qgscoordinatereferencesystem.cpp.o: in function
`QgsCoordinateReferenceSystem::syncDatabase()':
/home/richard/git/qgisgdal/src/core/qgscoordinatereferencesystem.cpp:2197:
undefined reference to `proj_get_authorities_from_database'
/usr/bin/ld:
/home/richard/git/qgisgdal/src/core/qgscoordinatereferencesystem.cpp:2204:
undefined reference to `proj_get_codes_from_database'
/usr/bin/ld:
/home/richard/git/qgisgdal/src/core/qgscoordinatereferencesystem.cpp:2213:
undefined reference to `proj_create_from_database'
/usr/bin/ld:
/home/richard/git/qgisgdal/src/core/qgscoordinatereferencesystem.cpp:2220:
undefined reference to `proj_get_type'
/usr/bin/ld:
/home/richard/git/qgisgdal/src/core/qgscoordinatereferencesystem.cpp:2241:
undefined reference to `proj_is_deprecated'
/usr/bin/ld:
/home/richard/git/qgisgdal/src/core/qgscoordinatereferencesystem.cpp:2242:
undefined reference to `proj_get_name'
/usr/bin/ld:
/home/richard/git/qgisgdal/src/core/qgscoordinatereferencesystem.cpp:2320:
undefined reference to `proj_crs_get_coordinate_system'
/usr/bin/ld:
/home/richard/git/qgisgdal/src/core/qgscoordinatereferencesystem.cpp:2323:
undefined reference to `proj_cs_get_axis_count'
/usr/bin/ld:
/home/richard/git/qgisgdal/src/core/qgscoordinatereferencesystem.cpp:2329:
undefined reference to `proj_cs_get_axis_info'
/usr/bin/ld:
/home/richard/git/qgisgdal/src/core/qgscoordinatereferencesystem.cpp:2341:
undefined reference to `proj_uom_get_info_from_database'
/usr/bin/ld:
/home/richard/git/qgisgdal/src/core/qgscoordinatereferencesystem.cpp:2412:
undefined reference to `proj_string_list_destroy'
/usr/bin/ld:
/home/richard/git/qgisgdal/src/core/qgscoordinatereferencesystem.cpp:2428:
undefined reference to `proj_string_list_destroy'
/usr/bin/ld:
CMakeFiles/qgis_core.dir/qgscoordinatereferencesystem.cpp.o: in function
`QgsCoordinateReferenceSystem::geographicCrsAuthId() const':
/home/richard/git/qgisgdal/src/core/qgscoordinatereferencesystem.cpp:2916:
undefined reference to `proj_crs_get_geodetic_crs'
/usr/bin/ld:
/home/richard/git/qgisgdal/src/core/qgscoordinatereferencesystem.cpp:2917:
undefined reference to `proj_get_id_code'
/usr/bin/ld:
/home/richard/git/qgisgdal/src/core/qgscoordinatereferencesystem.cpp:2917:
undefined reference to `proj_get_id_auth_name'
/usr/bin/ld:
CMakeFiles/qgis_core.dir/qgscoordinatereferencesystem.cpp.o: in function
`QgsCoordinateReferenceSystemPrivate::QgsCoordinateReferenceSystemPrivate(QgsCoordinateReferenceSystemPrivate
const&)':
/home/richard/git/qgisgdal/src/core/qgscoordinatereferencesystem_p.h:80:
undefined reference to `proj_clone'
/usr/bin/ld: CMakeFiles/qgis_core.dir/qgscoordinatetransform.cpp.o: in
function `QgsCoordinateTransform::transformCoords(int, double*, double*,
double*, QgsCoordinateTransform::TransformDirection) const':
/home/richard/git/qgisgdal/src/core/qgscoordinatetransform.cpp:639:
undefined reference to `proj_trans_generic'
/usr/bin/ld:
/home/richard/git/qgisgdal/src/core/qgscoordinatetransform.cpp:644:
undefined reference to `proj_errno'
/usr/bin/ld:
/home/richard/git/qgisgdal/src/core/qgscoordinatetransform.cpp:692:
undefined reference to `proj_get_source_crs'
/usr/bin/ld:
/home/richard/git/qgisgdal/src/core/qgscoordinatetransform.cpp:693:
undefined reference to `proj_get_source_crs'
/usr/bin/ld:
/home/richard/git/qgisgdal/src/core/qgscoordinatetransform.cpp:701:
undefined reference to `proj_errno_string'
/usr/bin/ld:
/home/richard/git/qgisgdal/src/core/qgscoordinatetransform.cpp:701:
undefined reference to `proj_as_proj_string'
/usr/bin/ld: CMakeFiles/qgis_core.dir/qgscoordinatetransform_p.cpp.o: in
function `QgsCoordinateTransformPrivate::threadLocalProjData()':
/home/richard/git/qgisgdal/src/core/qgscoordinatetransform_p.cpp:286:
undefined reference to `proj_create_crs_to_crs'
/usr/bin/ld: CMakeFiles/qgis_core.dir/qgscoordinatetransform_p.cpp.o: in
function `QgsCoordinateTransformPrivate::freeProj()':
/home/richard/git/qgisgdal/src/core/qgscoordinatetransform_p.cpp:379:
undefined reference to `proj_destroy'
/usr/bin/ld: CMakeFiles/qgis_core.dir/qgsdistancearea.cpp.o: in function
`QgsDistanceArea::latitudeGeodesicCrossesAntimeridian(QgsPointXY const&,
QgsPointXY const&, double&) const':
/home/richard/git/qgisgdal/src/core/qgsdistancearea.cpp:488: undefined
reference to `geod_init'
/usr/bin/ld:
/home/richard/git/qgisgdal/src/core/qgsdistancearea.cpp:491: undefined
reference to `geod_inverseline'
/usr/bin/ld:
/home/richard/git/qgisgdal/src/core/qgsdistancearea.cpp:516: undefined
reference to `geod_inverseline'
/usr/bin/ld:
/home/richard/git/qgisgdal/src/core/qgsdistancearea.cpp:529: undefined
reference to `geod_position'
/usr/bin/ld: CMakeFiles/qgis_core.dir/qgsdistancearea.cpp.o: in function
`QgsDistanceArea::geodesicLine(QgsPointXY const&, QgsPointXY const&,
double, bool) const':
/home/richard/git/qgisgdal/src/core/qgsdistancearea.cpp:681: undefined
reference to `geod_init'
/usr/bin/ld:
/home/richard/git/qgisgdal/src/core/qgsdistancearea.cpp:696: undefined
reference to `geod_inverseline'
/usr/bin/ld:
/home/richard/git/qgisgdal/src/core/qgsdistancearea.cpp:719: undefined
reference to `geod_position'
/usr/bin/ld: CMakeFiles/qgis_core.dir/qgsellipsoidutils.cpp.o: in
function `QgsEllipsoidUtils::definitions()':
/home/richard/git/qgisgdal/src/core/qgsellipsoidutils.cpp:352: undefined
reference to `proj_get_authorities_from_database'
/usr/bin/ld:
/home/richard/git/qgisgdal/src/core/qgsellipsoidutils.cpp:357: undefined
reference to `proj_get_codes_from_database'
/usr/bin/ld:
/home/richard/git/qgisgdal/src/core/qgsellipsoidutils.cpp:362: undefined
reference to `proj_create_from_database'
/usr/bin/ld:
/home/richard/git/qgisgdal/src/core/qgsellipsoidutils.cpp:366: undefined
reference to `proj_get_name'
/usr/bin/ld:
/home/richard/git/qgisgdal/src/core/qgsellipsoidutils.cpp:373: undefined
reference to `proj_ellipsoid_get_parameters'
/usr/bin/ld:
/home/richard/git/qgisgdal/src/core/qgsellipsoidutils.cpp:396: undefined
reference to `proj_string_list_destroy'
/usr/bin/ld:
/home/richard/git/qgisgdal/src/core/qgsellipsoidutils.cpp:401: undefined
reference to `proj_string_list_destroy'
/usr/bin/ld: CMakeFiles/qgis_core.dir/qgsprojutils.cpp.o: in function
`QgsProjContext::QgsProjContext()':
/home/richard/git/qgisgdal/src/core/qgsprojutils.cpp:36: undefined
reference to `proj_context_create'
/usr/bin/ld: CMakeFiles/qgis_core.dir/qgsprojutils.cpp.o: in function
`QgsProjContext::~QgsProjContext()':
/home/richard/git/qgisgdal/src/core/qgsprojutils.cpp:45: undefined
reference to `proj_context_destroy'
/usr/bin/ld: CMakeFiles/qgis_core.dir/qgsprojutils.cpp.o: in function
`QgsProjUtils::ProjPJDeleter::operator()(PJconsts*)':
/home/richard/git/qgisgdal/src/core/qgsprojutils.cpp:73: undefined
reference to `proj_destroy'
/usr/bin/ld: CMakeFiles/qgis_core.dir/qgsprojutils.cpp.o: in function
`QgsProjUtils::usesAngularUnit(QString const&)':
/home/richard/git/qgisgdal/src/core/qgsprojutils.cpp:80: undefined
reference to `proj_create'
/usr/bin/ld: /home/richard/git/qgisgdal/src/core/qgsprojutils.cpp:84:
undefined reference to `proj_crs_get_coordinate_system'
/usr/bin/ld: /home/richard/git/qgisgdal/src/core/qgsprojutils.cpp:88:
undefined reference to `proj_cs_get_axis_count'
/usr/bin/ld: /home/richard/git/qgisgdal/src/core/qgsprojutils.cpp:94:
undefined reference to `proj_cs_get_axis_info'
/usr/bin/ld: /home/richard/git/qgisgdal/src/core/qgsprojutils.cpp:106:
undefined reference to `proj_uom_get_info_from_database'
/usr/bin/ld: CMakeFiles/qgis_core.dir/qgsprojutils.cpp.o: in function
`QgsProjUtils::axisOrderIsSwapped(PJconsts const*)':
/home/richard/git/qgisgdal/src/core/qgsprojutils.cpp:122: undefined
reference to `proj_crs_get_coordinate_system'
/usr/bin/ld: /home/richard/git/qgisgdal/src/core/qgsprojutils.cpp:126:
undefined reference to `proj_cs_get_axis_count'
/usr/bin/ld: /home/richard/git/qgisgdal/src/core/qgsprojutils.cpp:132:
undefined reference to `proj_cs_get_axis_info'
/usr/bin/ld: CMakeFiles/qgis_core.dir/qgsprojutils.cpp.o: in function
`QgsProjUtils::crsToSingleCrs(PJconsts const*)':
/home/richard/git/qgisgdal/src/core/qgsprojutils.cpp:153: undefined
reference to `proj_get_type'
/usr/bin/ld: /home/richard/git/qgisgdal/src/core/qgsprojutils.cpp:156:
undefined reference to `proj_get_source_crs'
/usr/bin/ld: /home/richard/git/qgisgdal/src/core/qgsprojutils.cpp:161:
undefined reference to `proj_crs_get_sub_crs'
/usr/bin/ld: /home/richard/git/qgisgdal/src/core/qgsprojutils.cpp:162:
undefined reference to `proj_get_type'
/usr/bin/ld: /home/richard/git/qgisgdal/src/core/qgsprojutils.cpp:162:
undefined reference to `proj_get_type'
/usr/bin/ld: /home/richard/git/qgisgdal/src/core/qgsprojutils.cpp:165:
undefined reference to `proj_crs_get_sub_crs'
/usr/bin/ld: /home/richard/git/qgisgdal/src/core/qgsprojutils.cpp:173:
undefined reference to `proj_clone'
collect2: error: ld returned 1 exit status
make[2]: *** [src/core/CMakeFiles/qgis_core.dir/build.make:11468:
output/lib/libqgis_core.so.3.7.0] Error 1
make[1]: *** [CMakeFiles/Makefile2:327:
src/core/CMakeFiles/qgis_core.dir/all] Error 2
make: *** [Makefile:152: all] Error 2


More information about the QGIS-Developer mailing list