[gdal-dev] gdal-grass on mac osx, build errors

William Kyngesburye woklist at kyngchaos.com
Mon May 11 10:35:37 EDT 2009


You should be able to build the GRASS plugin off my GDAL framework, to  
avoid unnecessary duplication, and retain all the other formats built  
into my framework.  Though there might be a version issue between GDAL  
1.7/GRASS plugin and my GDAL 1.6 framework.

I'll look into and get back to you.  I have a makefile that I use  
myself that I can adapt.

On May 11, 2009, at 9:04 AM, massimo di stefano wrote:

> hi i'm tring to have gdal-grass installed on osx using grass7+gdal  
> svn,
> i compiled gdal, then grass,
>
> then cd in the gdal source/frmts/grass
>
> run make dist to create the tar.gz package.
>
> i configured it using : ./configure --with-gdal=/usr/local/gdal/bin/ 
> gdal-config --with-grass=/usr/local/grass-7.0.svn/
>
> but iget these error :
>
> cd /Users/Shared/source/gdal-grass-1.7.0
> macbook-pro-15-di-sasha:gdal-grass-1.7.0 sasha$ ./configure --with- 
> gdal=/usr/local/gdal/bin/gdal-config --with-grass=/usr/local/ 
> grass-7.0.svn/
> checking for gcc... gcc
> checking for C compiler default output file name... a.out
> checking whether the C compiler works... yes
> checking whether we are cross compiling... no
> checking for suffix of executables...
> checking for suffix of object files... o
> checking whether we are using the GNU C compiler... yes
> checking whether gcc accepts -g... yes
> checking for gcc option to accept ANSI C... none needed
> checking for g++... g++
> checking whether we are using the GNU C++ compiler... yes
> checking whether g++ accepts -g... yes
> checking for ranlib... ranlib
> Undefined symbols:
>  "_main", referenced from:
>      start in crt1.10.5.o
> ld: symbol(s) not found
> collect2: ld returned 1 exit status
> checking for g++ -dynamiclib ... yes
> user supplied gdal-config (/usr/local/gdal/bin/gdal-config)
> using /usr/local/gdal//lib/gdalplugins as GDAL shared library  
> autoload directory
> checking for G_asprintf in -lgrass_gis... no
> checking for G_putenv in -lgrass_gis... yes
> configure: creating ./config.status
> config.status: creating Makefile
> macbook-pro-15-di-sasha:gdal-grass-1.7.0 sasha$ make
> g++ -Wall -fPIC  -DUSE_CPL -DGRASS_GISBASE=\"/usr/local/ 
> grass-7.0.svn/\" -I/usr/local/gdal//include -I/usr/local/ 
> grass-7.0.svn//include   -c -o grass57dataset.o grass57dataset.cpp
> In file included from grass57dataset.cpp:45:
> /usr/local/grass-7.0.svn//include/grass/gprojects.h:21:22: error:  
> proj_api.h: No such file or directory
> /usr/local/grass-7.0.svn//include/grass/gprojects.h:35: error:  
> ‘projPJ’ does not name a type
> make: *** [grass57dataset.o] Error 1
>
>
>
> need i to configure and build gdal giving the proj path ?
>
> i've proj installed as framework in : /Library/Frameworks/ 
> PROJ.framework/
>
> i tried to work around the problem adding
> in the gdal-grass makefile,
> -L and -I path to where i've proj installed
>
> but don't fix the problem instead give me an other error
>
> macbook-pro-15-di-sasha:gdal-grass-1.7.0 sasha$ make
> g++ -Wall -fPIC  -DUSE_CPL -DGRASS_GISBASE=\"/usr/local/ 
> grass-7.0.svn/\" -I/usr/local/gdal//include -I/usr/local/ 
> grass-7.0.svn//include   -c -o grass57dataset.o grass57dataset.cpp
> g++ -dynamiclib grass57dataset.o -L/usr/local/grass-7.0.svn//lib - 
> lgrass_gmath -lgrass_gis -lgrass_datetime -lgrass_gproj -lgrass_vect  
> -lgrass_dbmibase -lgrass_dbmiclient -lgrass_dgl -lgrass_dig2 - 
> lgrass_rtree -lgrass_linkm -L/usr/local/gdal//lib -lgdal  -o  
> gdal_GRASS.so
> Undefined symbols:
>  "_I_get_group_ref", referenced from:
>      GRASSDataset::Open(GDALOpenInfo*)       in grass57dataset.o
>  "_I_init_group_ref", referenced from:
>      GRASSDataset::Open(GDALOpenInfo*)       in grass57dataset.o
>  "_I_free_group_ref", referenced from:
>      GRASSDataset::Open(GDALOpenInfo*)       in grass57dataset.o
> ld: symbol(s) not found
> collect2: ld returned 1 exit status
> make: *** [gdal_GRASS.so] Error 1
>
>
>
> ... restoring the original Makefile and installig proj from source  
> in /usr/local
> give me the exacltly same error ad i hadd adding -L and -I in the  
> makefile
>
>
>
>
>
> have you any suggestion ?
>
> thaks!
>
>
>
>
>
>
>
>
>
>
>
> Massimo Di Stefano
> massimodisasha at yahoo.it
>
> epifanio on   irc.freenode.net  /join gfoss
>
>
>
>
>
>
>
> Chiacchiera con i tuoi amici in tempo reale!
> http://it.yahoo.com/mail_it/foot/*http://it.messenger.yahoo.com
> _______________________________________________
> gdal-dev mailing list
> gdal-dev at lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/gdal-dev

-----
William Kyngesburye <kyngchaos*at*kyngchaos*dot*com>
http://www.kyngchaos.com/

"The beast is actively interested only in now, and, as it is always  
now and always shall be, there is an eternity of time for the  
accomplishment of objects."

- the wisdom of Tarzan







More information about the gdal-dev mailing list