[GRASS5] GRASS <-> GDAL circular references

Jens Oberender grass at troja.net
Sat May 22 17:34:45 EDT 2004


Hi again

> >> What is the correct solution?
> >
> > Probably to remove the GDAL stuff from libgrass_gproj. 5.0/5.3 worked
> > OK without it.
> 
> But then GPJ_grass_to_wkt() won't work as it relies on the co-ordinate 
> system conversion functions in OGR/GDAL. It uses a lot of them and they 
> are far too complicated to make a copy of them all and include in GRASS.
> 
> It is conceivably a good idea that the modules that use libgrass_gproj 
> only for re-projecting don't have to rely on being linked to GDAL when 
> they don't use any of it, but that is not relevant here as Radim 
> specifically wants to use one of the libgrass_gproj functions that
> relies on GDAL/OGR.
> 
> > Given the nature of GDAL (C++, many dependencies, possible dependency
> > upon GRASS), the less that depends upon it, the better.
> 
> Yes ideally just import/export modules but then that is kind of what
> we're talking about here?

As I understand you, the stuff in convert.c isn't used by GRASS modules,
so why not move it into Radim's GDAL code?
Then it's not a problem anymore.
If it is used by some GRASS modules it should be possible to move the
functions in convert.c to a libgrass_gproj_conv, so libgrass_gproj is
"clean" of GDAL stuff, but GRASS modules can still use both.

Just my 3.141592 cents.

Ciao,
	Jens




More information about the grass-dev mailing list