Morning,
I'm attempting to compile the QGIS 2.8.1 grass plugin against GRASS
7.0.0 on Arch Linux 64bit.
I read somewhere (maybe GIS.se?) that the GRASS plugin in QGIS doesn't
have full functionality and a kickstarter/crowdfunding process could be
underway to get it up to par, but in the meantime it was also mentioned
it's still possible to use the toolbar to load grass 7 layers into the
qgis canvas.
GDAL 1.11.2 is installed and so is gdal-grass plugin using some patches
to get GDAL working with grass 7.
I'm using the following cmake options in the QGIS build:
-DWITH_GRASS=ON
-DGRASS_PREFIX=/opt/grass
-DGRASS_INCLUDE_DIR=/opt/grass/include
But QGIS fails to build with the following error:
Scanning dependencies of target qgisgrass
[ 50%] Building CXX object
src/providers/grass/CMakeFiles/qgisgrass.dir/qgsgrass.cpp.o
/tmp/makepkg/qgis/src/qgis/src/providers/grass/qgsgrass.cpp: In static
member function ‘static void QgsGrass::setMapset(QString, QString,
QString)’:
/tmp/makepkg/qgis/src/qgis/src/providers/grass/qgsgrass.cpp:383:51:
error: ‘G__setenv’ was not declared in this scope
G__setenv( "GISDBASE", gisdbase.toUtf8().data() );
^
/tmp/makepkg/qgis/src/qgis/src/providers/grass/qgsgrass.cpp:392:30:
error: ‘G_available_mapsets’ was not declared in this scope
ms = G_available_mapsets();
^
/tmp/makepkg/qgis/src/qgis/src/providers/grass/qgsgrass.cpp: In static
member function ‘static QString QgsGrass::openMapset(QString, QString,
QString)’:
/tmp/makepkg/qgis/src/qgis/src/providers/grass/qgsgrass.cpp:611:46:
error: ‘G__setenv’ was not declared in this scope
G__setenv( "GISRC", mGisrc.toUtf8().data() );
^
/tmp/makepkg/qgis/src/qgis/src/providers/grass/qgsgrass.cpp: In static
member function ‘static QString QgsGrass::closeMapset()’:
/tmp/makepkg/qgis/src/qgis/src/providers/grass/qgsgrass.cpp:657:39:
error: ‘G__setenv’ was not declared in this scope
G__setenv( "GISRC", ( char * ) "" );
^
/tmp/makepkg/qgis/src/qgis/src/providers/grass/qgsgrass.cpp: In static
member function ‘static bool QgsGrass::region(QString, QString, QString,
Cell_head*)’:
/tmp/makepkg/qgis/src/qgis/src/providers/grass/qgsgrass.cpp:1082:83:
error: ‘G__get_window’ was not declared in this scope
G__get_window( window, ( char * ) "", ( char * ) "WIND",
mapset.toUtf8().data() );
^
/tmp/makepkg/qgis/src/qgis/src/providers/grass/qgsgrass.cpp: In static
member function ‘static bool QgsGrass::mapRegion(int, QString, QString,
QString, QString, Cell_head*)’:
/tmp/makepkg/qgis/src/qgis/src/providers/grass/qgsgrass.cpp:1268:94:
error: ‘G__get_window’ was not declared in this scope
G__get_window( window, ( char * ) "windows", map.toUtf8().data(),
mapset.toUtf8().data() );
^
src/providers/grass/CMakeFiles/qgisgrass.dir/build.make:60: recipe for
target 'src/providers/grass/CMakeFiles/qgisgrass.dir/qgsgrass.cpp.o' failed
make[2]: ***
[src/providers/grass/CMakeFiles/qgisgrass.dir/qgsgrass.cpp.o] Error 1
CMakeFiles/Makefile2:1251: recipe for target
'src/providers/grass/CMakeFiles/qgisgrass.dir/all' failed
make[1]: *** [src/providers/grass/CMakeFiles/qgisgrass.dir/all] Error 2
Makefile:137: recipe for target 'all' failed
make: *** [all] Error 2
So I'm not sure what the hiccup is exactly. GRASS 7 is installed and
runs fine outside of QGIS, but maybe it's missing some environment
variables (like GISRC or GISDBASE) that QGIS needs to compile against it?
Donovan
_______________________________________________
Qgis-user mailing list
[email protected]
http://lists.osgeo.org/mailman/listinfo/qgis-user