[GRASS-dev] compiling i.pr: error: ogr_api.h: No such file or
directory
Moritz Lennert
mlennert at club.worldonline.be
Tue Nov 27 08:45:11 EST 2007
Hello,
Trying to compile i.pr from the GRASS Add-Ons, I get the following error:
*************
make[1]: Entering directory
`/home/mlennert/SRC/GRASS/i.pr/i.pr_sites_aggregate'
gcc -I/home/mlennert/SRC/GRASS/grass6/dist.i486-pc-linux-gnu/include
-Wall -g -O2 -I../include/ -DPACKAGE=\""grassmods"\"
-I/home/mlennert/SRC/GRASS/grass6/dist.i486-pc-linux-gnu/include -o
OBJ.i486-pc-linux-gnu/main.o -c main.c
In file included from
/home/mlennert/SRC/GRASS/grass6/dist.i486-pc-linux-gnu/include/grass/vect/digit.h:3,
from
/home/mlennert/SRC/GRASS/grass6/dist.i486-pc-linux-gnu/include/grass/Vect.h:4,
from main.c:6:
/home/mlennert/SRC/GRASS/grass6/dist.i486-pc-linux-gnu/include/grass/vect/dig_structs.h:22:21:
error: ogr_api.h: No such file or directory
In file included from
/home/mlennert/SRC/GRASS/grass6/dist.i486-pc-linux-gnu/include/grass/vect/digit.h:3,
from
/home/mlennert/SRC/GRASS/grass6/dist.i486-pc-linux-gnu/include/grass/Vect.h:4,
from main.c:6:
/home/mlennert/SRC/GRASS/grass6/dist.i486-pc-linux-gnu/include/grass/vect/dig_structs.h:170:
error: expected specifier-qualifier-list before 'OGRDataSourceH'
main.c: In function 'main':
main.c:90: warning: value computed is not used
main.c:93: warning: value computed is not used
make[1]: *** [OBJ.i486-pc-linux-gnu/main.o] Error 1
make[1]: Leaving directory
`/home/mlennert/SRC/GRASS/i.pr/i.pr_sites_aggregate'
**************
'locate ogr_api.h' gives:
/usr/include/gdal/ogr_api.h
The relevant lines in include/grass/vect/dig_structs.h are
#ifdef HAVE_OGR
#include "ogr_api.h"
#endif
When I change this to
#include "gdal/ogr_api.h"
it compiles correctly.
Is this a bug in grass, i.e. should this be gdal/ogr_api.h in the
headers file ?
Moritz
More information about the grass-dev
mailing list