[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: [Pkg-grass-general] Re: [GRASS5] r.out.gdal



[Debian]

> > G:user1 > r.out.gdal in=elevation.10m out=elev format=GTiff type=Float32
> > Writing format: GTiff
> > Writing type:   Float32
> > ERROR 4: `/home/hamish/grassdata/spearfish57/PERMANENT/cellhd/elevation.10m' not recognised as a supported file format.
> > 
> > GDALOpen failed - 4
> > `/home/hamish/grassdata/spearfish57/PERMANENT/cellhd/elevation.10m' not recognised as a supported file format.
>  
> what does
> 
> gdalinfo /home/hamish/grassdata/spearfish57/PERMANENT/cellhd/elevation.10m
> say?

The same. Because 'gdalinfo --formats' is missing GRASS.....


> > The GDAL-GRASS plugin is installed from the DebianGIS libgdal1-grass 
> > package.
..
> AFAIK the plugin directory must be ../gdalplugins:
> 
> grep gdalplugins ./gcore/gdaldrivermanager.cpp
>  * Search in lib/gdalplugins instead of directly in lib directory.
>  * the /usr/local/lib/gdalplugins directory, and (if known) the lib/gdalplugins
>                                         GDAL_PREFIX "/lib/gdalplugins" );
>                                         "/usr/local/lib/gdalplugins" );
>                                                    "lib/gdalplugins", NULL ) );
> 
> So it won't work if installed as /usr/lib/gdal_GRASS.so
> (should be /usr/lib/gdalplugins/gdal_GRASS.so ?)


Ok, that is the problem and gets GRASS to show up in 'gdalinfo --formats':

mkdir /usr/lib/gdalplugins
ln -s /usr/lib/gdal_GRASS.so /usr/lib/gdalplugins/gdal_GRASS.so


If doing this is against Debian policy then the above code in Debian's 
GDAL package needs to be patched to use perhaps '/usr/lib/libgdal1' or 
just  '/usr/lib'. (I'm not sure if it must be /usr/lib/package-name, but 
everything else is /usr/lib/dir/ seems to be like that)


** So the libgdal1-grass package is broken with GDAL 1.2.6.



> Hope this helps

It does.

I still get a segfault, both with r.out.gdal and loading a GRASS raster into
QGIS, but progress has been made today.



thanks,
Hamish



Reply to: