[GRASSLIST:347] Re: Fwd: gis.h problem
Glynn Clements
glynn at gclements.plus.com
Thu Mar 23 16:08:49 EST 2006
Ana Soares wrote:
> Yes but now I have another problem !
>
> This works fine :
>
> gcc -c -I /usr/lib/grass/include main.c
>
> But :
>
> $ gcc -o prog main.o
> main.o: In function `main':
> main.c:(.text+0x26): undefined reference to `G_gisinit'
> collect2: ld returned 1 exit status
You need to link against the GRASS libraries, e.g.
gcc ... -L/usr/local/grass6/lib -lgrass_gis
--
Glynn Clements <glynn at gclements.plus.com>
More information about the grass-user
mailing list