[GRASS5] Re: [GRASSLIST:8620] Re: GRASS, gdal and mapserver

Vector library is obviously missing.

Radim

On 10/13/05, Francisco Alonso <alonsarp@um.es> wrote:

El Viernes, 14 de Octubre de 2005 10:25, Radim Blazek escribió:
> On 10/12/05, Francisco Alonso <alonsarp@um.es> wrote:
> > # ogrinfo
> > /var/www/grass5_mapserver/spearfish60/PERMANENT/vector/streams/head
> > Warning 1: GRASS warning: GISBASE enviroment variable was not set, using:
> > /usr/local/grass-6.0.1
> > ogrinfo: relocation error: /usr/local/lib/gdalplugins/ogr_GRASS.so:
> > undefined symbol: Vect_set_fatal_error
>
> ldd /usr/local/lib/gdalplugins/ogr_GRASS.so ?
>
> Radim

# ldd /usr/local/lib/gdalplugins/ogr_GRASS.so
                libgrass_I.so => /usr/lib/libgrass_I.so (0x40014000)
        libgrass_vask.so => /usr/lib/libgrass_vask.so (0x40026000)
        libgrass_gmath.so => /usr/lib/libgrass_gmath.so (0x4002c000)
        libgrass_gis.so => /usr/lib/libgrass_gis.so (0x40032000)
        libgrass_datetime.so => /usr/lib/libgrass_datetime.so (0x400b9000)
        libgrass_gproj.so => /usr/lib/libgrass_gproj.so (0x400c1000)
        libgdal.so.1 => /usr/lib/libgdal.so.1 (0x400c9000)
        libstdc++.so.5 => /usr/lib/libstdc++.so.5 (0x40493000)
        libm.so.6 => /lib/tls/libm.so.6 (0x4054d000)
        libgcc_s.so.1 => /lib/libgcc_s.so.1 (0x4056f000)
        libc.so.6 => /lib/tls/libc.so.6 (0x40578000)
        libfftw.so.2 => /usr/lib/libfftw.so.2 (0x406ad000)
        libz.so.1 => /usr/lib/libz.so.1 (0x406e1000)
        libncurses.so.5 => /lib/libncurses.so.5 (0x406f4000)
        libproj.so.0 => /usr/lib/libproj.so.0 (0x40733000)
        libgeos.so.2 => /usr/lib/libgeos.so.2 (0x40768000)
        libpq.so.3 => /usr/lib/libpq.so.3 (0x4085b000)
        librt.so.1 => /lib/tls/librt.so.1 (0x40876000)
        libdl.so.2 => /lib/tls/libdl.so.2 (0x4087c000)
        libodbc.so.1 => /usr/lib/libodbc.so.1 (0x40880000)
        libxerces-c.so.26 => /usr/lib/libxerces-c.so.26 (0x408f8000)
        libjasper-1.701.so.1 => /usr/lib/libjasper-1.701.so.1 (0x40c42000)
        libmfhdf.so.4 => /usr/lib/libmfhdf.so.4 (0x40c8f000)
        libdf.so.4 => /usr/lib/libdf.so.4 (0x40cb1000)
        libungif.so.4 => /usr/lib/libungif.so.4 (0x40d50000)
        libjpeg.so.62 => /usr/lib/libjpeg.so.62 (0x40d59000)
        libtiff.so.4 => /usr/lib/libtiff.so.4 (0x40d77000)
        libpng12.so.0 => /usr/lib/libpng12.so.0 (0x40dc7000)
        libnetcdf.so.3 => /usr/lib/libnetcdf.so.3 (0x40dec000)
        libcfitsio.so.2 => /usr/lib/libcfitsio.so.2 (0x40e0f000)
        libpthread.so.0 => /lib/tls/libpthread.so.0 (0x40f7d000)
        /lib/ld-linux.so.2 => /lib/ld-linux.so.2 (0x80000000)
        libssl.so.0.9.7 => /usr/lib/i686/cmov/libssl.so.0.9.7 (0x40f8d000)
        libcrypto.so.0.9.7 => /usr/lib/i686/cmov/libcrypto.so.0.9.7
(0x40fbe000)
        libkrb5.so.3 => /usr/lib/libkrb5.so.3 (0x410bd000)
        libcrypt.so.1 => /lib/tls/libcrypt.so.1 (0x41125000)
        libresolv.so.2 => /lib/tls/libresolv.so.2 (0x41152000)
        libnsl.so.1 => /lib/tls/libnsl.so.1 (0x41164000)
        libltdl.so.3 => /usr/lib/libltdl.so.3 (0x41179000)
        libk5crypto.so.3 => /usr/lib/libk5crypto.so.3 (0x41180000)
        libcom_err.so.2 => /lib/libcom_err.so.2 (0x411a3000)

Seems to be ok

Paco

--
Francisco Alonso Sarría
Departamento de Geografía (Area de Geografía Física)
Universidad de Murcia. Campus La Merced
E-30001 Murcia
Telfn: +34 968364357
www.um.es/geograf/sigmur

On 10/13/05, Francisco Alonso <alonsarp@um.es> wrote:
> El Viernes, 14 de Octubre de 2005 10:25, Radim Blazek escribió:
> > On 10/12/05, Francisco Alonso <alonsarp@um.es> wrote:
> > > # ogrinfo
> > > /var/www/grass5_mapserver/spearfish60/PERMANENT/vector/streams/head
> > > Warning 1: GRASS warning: GISBASE enviroment variable was not set,
> > > using: /usr/local/grass-6.0.1
> > > ogrinfo: relocation error: /usr/local/lib/gdalplugins/ogr_GRASS.so:
> > > undefined symbol: Vect_set_fatal_error
> >

Ok I have it.

After realizing that

# ldd ogr_GRASS.so

didn't mention the grass vector library I remembered that I had linked just
the grass libraries needed by gdal. On the other hand the makefile I obtained
with:

./configure --with-gdal=/usr/local/bin/gdal-config
--with-grass=/usr/local/grass-6.0.1

doesn't include any -lgrass_vect, so I put it myself just to try.

After that ldd ogr_GRASS .so did complain about libgrass_vect. I linked it,
and after some more links and incluiding -lgrass_dbmidriver in the LIBS line
of the Makefile I have ogrinfo working properly:

# ogrinfo /var/www/grass5_mapserver/spearfish60/PERMANENT/vector/streams/head
Warning 1: GRASS warning: GISBASE enviroment variable was not set, using:
/usr/local/grass-6.0.1
INFO: Open of
`/var/www/grass5_mapserver/spearfish60/PERMANENT/vector/streams/head'
using driver `GRASS' successful.
1: 0
2: 1

Thanks a lot for your suggestions.

I am still working on my other problem (mapserver not showing GRASS raster
files that gdal can read)

I tried to gdal_translate the spearfish soils layer to pcraster and reading it
with mapserver (ugly colours but it worked) so it seem that grass-gdal
connection works and mapserver-gdal also works.

And now I have changed the roads layer definition in the map file to read the
roads grass layer instead of shape (I'm workig with spearfish demo):

LAYER
  NAME roads
  TYPE LINE
  STATUS DEFAULT
  DATA /var/www/grass5_mapserver/spearfish60/PERMANENT/vector/roads/head
  TOLERANCE 5
  LABELITEM CAT_ID
  TEMPLATE /var/www/grass5_mapserver/spearfish/roads.html
# OFFSITE 0
  CLASS
    NAME "Road"
    COLOR 80 80 80
    LABEL
      POSITION CC
      SIZE SMALL
      COLOR 0 0 225
    END
  END
END

but I have a prettty similar error message

# /usr/local/mapserver-4.6.1/shp2img -m
/var/www/grass5_mapserver/map-script/mapserver.map -o mapa.png

msDrawMap(): Image handling error. Failed to draw layer named 'roads'. <br>
msSHPOpenFile(): Unable to access file.
(/var/www/grass5_mapserver/spearfish60/PERMANENT/vector/roads/head) <br>
msSHPOpenFile(): Unable to access file.
(/var/www/grass5_mapserver/spearfish60/PERMANENT/vector/roads/head) <br>

but the file DO exist, do I need to specify in any way that it is a GRASS
file?

Do you know where you can download the files of the demo 2 accesible from
http://grass.itc.it/start.html ?

I will continue trying, but if anyone has suggestions ....

Paco

--
Francisco Alonso Sarría
Departamento de Geografía (Area de Geografía Física)
Universidad de Murcia. Campus La Merced
E-30001 Murcia
Telfn: +34 968364357
www.um.es/geograf/sigmur

Hi all:

May be I have mised some step:

1- I compiled gdal without grass
2- I compiled grass with gdal (v.in.ogr, v.out.ogr, etc. work fine)
3- I compile the gdal-grass package (fixing some problems in the Makefile to
access grass vector libraries)
4- I stored ogr_GRASS.so and gdal_GRASS.so a in /usr/local/lib/gdalplugins/

Now ogrinfo and gdalinfo can read GRASS files because they load the plugins

# gdalinfo --formats|grep GRASS
  GRASS (ro): GRASS Database Rasters (5.7+)

# ogrinfo --formats|grep GRASS
  -> "GRASS" (readonly)

but gdal-config is a script created before the plugins and aparently doesn't
know about them

# gdal-config --formats
gxf gtiff hfa aigrid aaigrid ceos ceos2 iso8211 xpm sdts raw dted mem jdem
envisat elas fit vrt usgsdem l1b nitf bmp pcidsk airsar rs2 ilwis rmf rik bsb
gif jpeg png pcraster

probably the same problem with libgdal.so and when I compile mapserver it
doesn't think he can read GRASS files.

I think I missed something, I'm not to sure about what ldconfig does but I
have run it each time I made a change :wink:

Any idea

Thanks in advance

PAco

Vector library is obviously missing.

Radim

On 10/13/05, Francisco Alonso <alonsarp@um.es> wrote:
> El Viernes, 14 de Octubre de 2005 10:25, Radim Blazek escribió:
> > On 10/12/05, Francisco Alonso <alonsarp@um.es> wrote:
> > > # ogrinfo
> > > /var/www/grass5_mapserver/spearfish60/PERMANENT/vector/streams/head
> > > Warning 1: GRASS warning: GISBASE enviroment variable was not set,
> > > using: /usr/local/grass-6.0.1
> > > ogrinfo: relocation error: /usr/local/lib/gdalplugins/ogr_GRASS.so:
> > > undefined symbol: Vect_set_fatal_error
> >
> > ldd /usr/local/lib/gdalplugins/ogr_GRASS.so ?
> >
> > Radim
>
> # ldd /usr/local/lib/gdalplugins/ogr_GRASS.so
> libgrass_I.so => /usr/lib/libgrass_I.so (0x40014000)
> libgrass_vask.so => /usr/lib/libgrass_vask.so (0x40026000)
> libgrass_gmath.so => /usr/lib/libgrass_gmath.so (0x4002c000)
> libgrass_gis.so => /usr/lib/libgrass_gis.so (0x40032000)
> libgrass_datetime.so => /usr/lib/libgrass_datetime.so
> (0x400b9000) libgrass_gproj.so => /usr/lib/libgrass_gproj.so (0x400c1000)
> libgdal.so.1 => /usr/lib/libgdal.so.1 (0x400c9000)
> libstdc++.so.5 => /usr/lib/libstdc++.so.5 (0x40493000)
> libm.so.6 => /lib/tls/libm.so.6 (0x4054d000)
> libgcc_s.so.1 => /lib/libgcc_s.so.1 (0x4056f000)
> libc.so.6 => /lib/tls/libc.so.6 (0x40578000)
> libfftw.so.2 => /usr/lib/libfftw.so.2 (0x406ad000)
> libz.so.1 => /usr/lib/libz.so.1 (0x406e1000)
> libncurses.so.5 => /lib/libncurses.so.5 (0x406f4000)
> libproj.so.0 => /usr/lib/libproj.so.0 (0x40733000)
> libgeos.so.2 => /usr/lib/libgeos.so.2 (0x40768000)
> libpq.so.3 => /usr/lib/libpq.so.3 (0x4085b000)
> librt.so.1 => /lib/tls/librt.so.1 (0x40876000)
> libdl.so.2 => /lib/tls/libdl.so.2 (0x4087c000)
> libodbc.so.1 => /usr/lib/libodbc.so.1 (0x40880000)
> libxerces-c.so.26 => /usr/lib/libxerces-c.so.26 (0x408f8000)
> libjasper-1.701.so.1 => /usr/lib/libjasper-1.701.so.1
> (0x40c42000) libmfhdf.so.4 => /usr/lib/libmfhdf.so.4 (0x40c8f000)
> libdf.so.4 => /usr/lib/libdf.so.4 (0x40cb1000)
> libungif.so.4 => /usr/lib/libungif.so.4 (0x40d50000)
> libjpeg.so.62 => /usr/lib/libjpeg.so.62 (0x40d59000)
> libtiff.so.4 => /usr/lib/libtiff.so.4 (0x40d77000)
> libpng12.so.0 => /usr/lib/libpng12.so.0 (0x40dc7000)
> libnetcdf.so.3 => /usr/lib/libnetcdf.so.3 (0x40dec000)
> libcfitsio.so.2 => /usr/lib/libcfitsio.so.2 (0x40e0f000)
> libpthread.so.0 => /lib/tls/libpthread.so.0 (0x40f7d000)
> /lib/ld-linux.so.2 => /lib/ld-linux.so.2 (0x80000000)
> libssl.so.0.9.7 => /usr/lib/i686/cmov/libssl.so.0.9.7
> (0x40f8d000) libcrypto.so.0.9.7 => /usr/lib/i686/cmov/libcrypto.so.0.9.7
> (0x40fbe000)
> libkrb5.so.3 => /usr/lib/libkrb5.so.3 (0x410bd000)
> libcrypt.so.1 => /lib/tls/libcrypt.so.1 (0x41125000)
> libresolv.so.2 => /lib/tls/libresolv.so.2 (0x41152000)
> libnsl.so.1 => /lib/tls/libnsl.so.1 (0x41164000)
> libltdl.so.3 => /usr/lib/libltdl.so.3 (0x41179000)
> libk5crypto.so.3 => /usr/lib/libk5crypto.so.3 (0x41180000)
> libcom_err.so.2 => /lib/libcom_err.so.2 (0x411a3000)
>

--
Francisco Alonso Sarría
Departamento de Geografía (Area de Geografía Física)
Universidad de Murcia. Campus La Merced
E-30001 Murcia
Telfn: +34 968364357
www.um.es/geograf/sigmur

On Fri, Oct 14, 2005 at 11:38:01AM +0200, Radim Blazek wrote:

Vector library is obviously missing.

Right, for the new GDAL-OGR-GRASS plugin you need to link
as many as these libs:

cd /usr/local/lib
ln -s /usr/local/grass6/lib/libgrass_I.so .
ln -s /usr/local/grass6/lib/libgrass_vask.so .
ln -s /usr/local/grass6/lib/libgrass_gmath.so .
ln -s /usr/local/grass6/lib/libgrass_gis.so .
ln -s /usr/local/grass6/lib/libgrass_datetime.so .
ln -s /usr/local/grass6/lib/libgrass_vect.so .
ln -s /usr/local/grass6/lib/libgrass_dig2.so .
ln -s /usr/local/grass6/lib/libgrass_dbmiclient.so .
ln -s /usr/local/grass6/lib/libgrass_dbmibase.so .
ln -s /usr/local/grass6/lib/libgrass_shape.so .
ln -s /usr/local/grass6/lib/libgrass_dgl.so .
ln -s /usr/local/grass6/lib/libgrass_rtree.so .
ln -s /usr/local/grass6/lib/libgrass_linkm.so .
ln -s /usr/local/grass6/lib/libgrass_form.so .
ln -s /usr/local/grass6/lib/libgrass_gproj.so .
ln -s /usr/local/grass6/lib/libgrass_vect.so .
ln -s /usr/local/grass6/lib/libgrass_dig2.so .
ln -s /usr/local/grass6/lib/libgrass_dbmiclient.so .
ln -s /usr/local/grass6/lib/libgrass_dbmibase.so .
ln -s /usr/local/grass6/lib/libgrass_shape.so .
ln -s /usr/local/grass6/lib/libgrass_dgl.so .
ln -s /usr/local/grass6/lib/libgrass_rtree.so .
ln -s /usr/local/grass6/lib/libgrass_linkm.so .
ln -s /usr/local/grass6/lib/libgrass_form.so .
ln -s /usr/local/grass6/lib/libgrass_gproj.so .

(paths may differ)

Then it will work.

Markus

On 10/13/05, Francisco Alonso <alonsarp@um.es> wrote:
> El Viernes, 14 de Octubre de 2005 10:25, Radim Blazek escribió:
> > On 10/12/05, Francisco Alonso <alonsarp@um.es> wrote:
> > > # ogrinfo
> > > /var/www/grass5_mapserver/spearfish60/PERMANENT/vector/streams/head
> > > Warning 1: GRASS warning: GISBASE enviroment variable was not set, using:
> > > /usr/local/grass-6.0.1
> > > ogrinfo: relocation error: /usr/local/lib/gdalplugins/ogr_GRASS.so:
> > > undefined symbol: Vect_set_fatal_error
> >
> > ldd /usr/local/lib/gdalplugins/ogr_GRASS.so ?
> >
> > Radim
>
> # ldd /usr/local/lib/gdalplugins/ogr_GRASS.so
> libgrass_I.so => /usr/lib/libgrass_I.so (0x40014000)
> libgrass_vask.so => /usr/lib/libgrass_vask.so (0x40026000)
> libgrass_gmath.so => /usr/lib/libgrass_gmath.so (0x4002c000)
> libgrass_gis.so => /usr/lib/libgrass_gis.so (0x40032000)
> libgrass_datetime.so => /usr/lib/libgrass_datetime.so (0x400b9000)
> libgrass_gproj.so => /usr/lib/libgrass_gproj.so (0x400c1000)
> libgdal.so.1 => /usr/lib/libgdal.so.1 (0x400c9000)
> libstdc++.so.5 => /usr/lib/libstdc++.so.5 (0x40493000)
> libm.so.6 => /lib/tls/libm.so.6 (0x4054d000)
> libgcc_s.so.1 => /lib/libgcc_s.so.1 (0x4056f000)
> libc.so.6 => /lib/tls/libc.so.6 (0x40578000)
> libfftw.so.2 => /usr/lib/libfftw.so.2 (0x406ad000)
> libz.so.1 => /usr/lib/libz.so.1 (0x406e1000)
> libncurses.so.5 => /lib/libncurses.so.5 (0x406f4000)
> libproj.so.0 => /usr/lib/libproj.so.0 (0x40733000)
> libgeos.so.2 => /usr/lib/libgeos.so.2 (0x40768000)
> libpq.so.3 => /usr/lib/libpq.so.3 (0x4085b000)
> librt.so.1 => /lib/tls/librt.so.1 (0x40876000)
> libdl.so.2 => /lib/tls/libdl.so.2 (0x4087c000)
> libodbc.so.1 => /usr/lib/libodbc.so.1 (0x40880000)
> libxerces-c.so.26 => /usr/lib/libxerces-c.so.26 (0x408f8000)
> libjasper-1.701.so.1 => /usr/lib/libjasper-1.701.so.1 (0x40c42000)
> libmfhdf.so.4 => /usr/lib/libmfhdf.so.4 (0x40c8f000)
> libdf.so.4 => /usr/lib/libdf.so.4 (0x40cb1000)
> libungif.so.4 => /usr/lib/libungif.so.4 (0x40d50000)
> libjpeg.so.62 => /usr/lib/libjpeg.so.62 (0x40d59000)
> libtiff.so.4 => /usr/lib/libtiff.so.4 (0x40d77000)
> libpng12.so.0 => /usr/lib/libpng12.so.0 (0x40dc7000)
> libnetcdf.so.3 => /usr/lib/libnetcdf.so.3 (0x40dec000)
> libcfitsio.so.2 => /usr/lib/libcfitsio.so.2 (0x40e0f000)
> libpthread.so.0 => /lib/tls/libpthread.so.0 (0x40f7d000)
> /lib/ld-linux.so.2 => /lib/ld-linux.so.2 (0x80000000)
> libssl.so.0.9.7 => /usr/lib/i686/cmov/libssl.so.0.9.7 (0x40f8d000)
> libcrypto.so.0.9.7 => /usr/lib/i686/cmov/libcrypto.so.0.9.7
> (0x40fbe000)
> libkrb5.so.3 => /usr/lib/libkrb5.so.3 (0x410bd000)
> libcrypt.so.1 => /lib/tls/libcrypt.so.1 (0x41125000)
> libresolv.so.2 => /lib/tls/libresolv.so.2 (0x41152000)
> libnsl.so.1 => /lib/tls/libnsl.so.1 (0x41164000)
> libltdl.so.3 => /usr/lib/libltdl.so.3 (0x41179000)
> libk5crypto.so.3 => /usr/lib/libk5crypto.so.3 (0x41180000)
> libcom_err.so.2 => /lib/libcom_err.so.2 (0x411a3000)
>
> Seems to be ok
>
> Paco
>
> --
> Francisco Alonso Sarría
> Departamento de Geografía (Area de Geografía Física)
> Universidad de Murcia. Campus La Merced
> E-30001 Murcia
> Telfn: +34 968364357
> www.um.es/geograf/sigmur
>
>

_______________________________________________
grass5 mailing list
grass5@grass.itc.it
http://grass.itc.it/mailman/listinfo/grass5

Hello Francisco,

On Thu, 13 Oct 2005 20:56:03 +0200 Francisco Alonso <alonsarp@um.es>
wrote:

> On 10/13/05, Francisco Alonso <alonsarp@um.es> wrote:
> > El Viernes, 14 de Octubre de 2005 10:25, Radim Blazek escribió:
> > > On 10/12/05, Francisco Alonso <alonsarp@um.es> wrote:
> > > > # ogrinfo
> > > > /var/www/grass5_mapserver/spearfish60/PERMANENT/vector/streams/head
> > > > Warning 1: GRASS warning: GISBASE enviroment variable was not
> > > > set, using: /usr/local/grass-6.0.1
> > > > ogrinfo: relocation
> > > > error: /usr/local/lib/gdalplugins/ogr_GRASS.so: undefined
> > > > symbol: Vect_set_fatal_error
> > >

Ok I have it.

After realizing that

# ldd ogr_GRASS.so

didn't mention the grass vector library I remembered that I had
linked just the grass libraries needed by gdal. On the other hand the
makefile I obtained with:

./configure --with-gdal=/usr/local/bin/gdal-config
--with-grass=/usr/local/grass-6.0.1

doesn't include any -lgrass_vect, so I put it myself just to try.

After that ldd ogr_GRASS .so did complain about libgrass_vect. I
linked it, and after some more links and incluiding
-lgrass_dbmidriver in the LIBS line of the Makefile I have ogrinfo
working properly:

#
ogrinfo /var/www/grass5_mapserver/spearfish60/PERMANENT/vector/streams/head
Warning 1: GRASS warning: GISBASE enviroment variable was not set,
using: /usr/local/grass-6.0.1 INFO: Open of
`/var/www/grass5_mapserver/spearfish60/PERMANENT/vector/streams/head'
using driver `GRASS' successful.
1: 0
2: 1

Thanks a lot for your suggestions.

I am still working on my other problem (mapserver not showing GRASS
raster files that gdal can read)

I tried to gdal_translate the spearfish soils layer to pcraster and
reading it with mapserver (ugly colours but it worked) so it seem
that grass-gdal connection works and mapserver-gdal also works.

And now I have changed the roads layer definition in the map file to
read the roads grass layer instead of shape (I'm workig with
spearfish demo):

[...]

but I have a prettty similar error message

# /usr/local/mapserver-4.6.1/shp2img -m
/var/www/grass5_mapserver/map-script/mapserver.map -o mapa.png

msDrawMap(): Image handling error. Failed to draw layer named
'roads'. <br> msSHPOpenFile(): Unable to access file.
(/var/www/grass5_mapserver/spearfish60/PERMANENT/vector/roads/head)
<br> msSHPOpenFile(): Unable to access file.
(/var/www/grass5_mapserver/spearfish60/PERMANENT/vector/roads/head)
<br>

but the file DO exist, do I need to specify in any way that it is a
GRASS file?

Do you know where you can download the files of the demo 2 accesible
from http://grass.itc.it/start.html ?

I will continue trying, but if anyone has suggestions ....

Try this:
Layer
  NAME GRASSVektor
  TYPE LINE
  CONNECTIONTYPE OGR
  CONNECTION /path/to/location/mapset/vector/map/head
  DATA "1"
  gml_include_items all
  DUMP true
   METADATA
    wfs_title ?GRASS_vektor?
    ...
   END
   CLASS
   END
...
END

Best
  Stephan

--
GDF Hannover - Solutions for spatial data analysis and remote sensing
Hannover Office - Mengendamm 16d - D-30177 Hannover
Internet: www.gdf-hannover.de - Email: holl@gdf-hannover.de
Phone : ++49-(0)511.39088507 - Fax: ++49-(0)511.39088508

Markus,

We're going to try to get the grass-gdal plugin working today in Fedora.

I'm afraid I don't exactly understand what we need to do here, or in your
advice to run ldconfigure for the plugin.

Can you elaborate a bit?

Thanks much
Michael
______________________________
Michael Barton, Professor of Anthropology
School of Human Evolution and Social Change
Arizona State University
Tempe, AZ 85287-2402
USA

voice: 480-965-6262; fax: 480-965-7671
www: http://www.public.asu.edu/~cmbarton

From: Markus Neteler <neteler@itc.it>
Date: Fri, 14 Oct 2005 11:48:38 +0200
To: Grass Developers List <grass5@grass.itc.it>
Subject: Re: [GRASS5] Re: [GRASSLIST:8620] Re: GRASS, gdal and mapserver

On Fri, Oct 14, 2005 at 11:38:01AM +0200, Radim Blazek wrote:

Vector library is obviously missing.

Right, for the new GDAL-OGR-GRASS plugin you need to link
as many as these libs:

cd /usr/local/lib
ln -s /usr/local/grass6/lib/libgrass_I.so .
ln -s /usr/local/grass6/lib/libgrass_vask.so .
ln -s /usr/local/grass6/lib/libgrass_gmath.so .
ln -s /usr/local/grass6/lib/libgrass_gis.so .
ln -s /usr/local/grass6/lib/libgrass_datetime.so .
ln -s /usr/local/grass6/lib/libgrass_vect.so .
ln -s /usr/local/grass6/lib/libgrass_dig2.so .
ln -s /usr/local/grass6/lib/libgrass_dbmiclient.so .
ln -s /usr/local/grass6/lib/libgrass_dbmibase.so .
ln -s /usr/local/grass6/lib/libgrass_shape.so .
ln -s /usr/local/grass6/lib/libgrass_dgl.so .
ln -s /usr/local/grass6/lib/libgrass_rtree.so .
ln -s /usr/local/grass6/lib/libgrass_linkm.so .
ln -s /usr/local/grass6/lib/libgrass_form.so .
ln -s /usr/local/grass6/lib/libgrass_gproj.so .
ln -s /usr/local/grass6/lib/libgrass_vect.so .
ln -s /usr/local/grass6/lib/libgrass_dig2.so .
ln -s /usr/local/grass6/lib/libgrass_dbmiclient.so .
ln -s /usr/local/grass6/lib/libgrass_dbmibase.so .
ln -s /usr/local/grass6/lib/libgrass_shape.so .
ln -s /usr/local/grass6/lib/libgrass_dgl.so .
ln -s /usr/local/grass6/lib/libgrass_rtree.so .
ln -s /usr/local/grass6/lib/libgrass_linkm.so .
ln -s /usr/local/grass6/lib/libgrass_form.so .
ln -s /usr/local/grass6/lib/libgrass_gproj.so .

(paths may differ)

Then it will work.

Markus

On 10/13/05, Francisco Alonso <alonsarp@um.es> wrote:

El Viernes, 14 de Octubre de 2005 10:25, Radim Blazek escribió:

On 10/12/05, Francisco Alonso <alonsarp@um.es> wrote:

# ogrinfo
/var/www/grass5_mapserver/spearfish60/PERMANENT/vector/streams/head
Warning 1: GRASS warning: GISBASE enviroment variable was not set, using:
/usr/local/grass-6.0.1
ogrinfo: relocation error: /usr/local/lib/gdalplugins/ogr_GRASS.so:
undefined symbol: Vect_set_fatal_error

ldd /usr/local/lib/gdalplugins/ogr_GRASS.so ?

Radim

# ldd /usr/local/lib/gdalplugins/ogr_GRASS.so
                libgrass_I.so => /usr/lib/libgrass_I.so (0x40014000)
        libgrass_vask.so => /usr/lib/libgrass_vask.so (0x40026000)
        libgrass_gmath.so => /usr/lib/libgrass_gmath.so (0x4002c000)
        libgrass_gis.so => /usr/lib/libgrass_gis.so (0x40032000)
        libgrass_datetime.so => /usr/lib/libgrass_datetime.so (0x400b9000)
        libgrass_gproj.so => /usr/lib/libgrass_gproj.so (0x400c1000)
        libgdal.so.1 => /usr/lib/libgdal.so.1 (0x400c9000)
        libstdc++.so.5 => /usr/lib/libstdc++.so.5 (0x40493000)
        libm.so.6 => /lib/tls/libm.so.6 (0x4054d000)
        libgcc_s.so.1 => /lib/libgcc_s.so.1 (0x4056f000)
        libc.so.6 => /lib/tls/libc.so.6 (0x40578000)
        libfftw.so.2 => /usr/lib/libfftw.so.2 (0x406ad000)
        libz.so.1 => /usr/lib/libz.so.1 (0x406e1000)
        libncurses.so.5 => /lib/libncurses.so.5 (0x406f4000)
        libproj.so.0 => /usr/lib/libproj.so.0 (0x40733000)
        libgeos.so.2 => /usr/lib/libgeos.so.2 (0x40768000)
        libpq.so.3 => /usr/lib/libpq.so.3 (0x4085b000)
        librt.so.1 => /lib/tls/librt.so.1 (0x40876000)
        libdl.so.2 => /lib/tls/libdl.so.2 (0x4087c000)
        libodbc.so.1 => /usr/lib/libodbc.so.1 (0x40880000)
        libxerces-c.so.26 => /usr/lib/libxerces-c.so.26 (0x408f8000)
        libjasper-1.701.so.1 => /usr/lib/libjasper-1.701.so.1 (0x40c42000)
        libmfhdf.so.4 => /usr/lib/libmfhdf.so.4 (0x40c8f000)
        libdf.so.4 => /usr/lib/libdf.so.4 (0x40cb1000)
        libungif.so.4 => /usr/lib/libungif.so.4 (0x40d50000)
        libjpeg.so.62 => /usr/lib/libjpeg.so.62 (0x40d59000)
        libtiff.so.4 => /usr/lib/libtiff.so.4 (0x40d77000)
        libpng12.so.0 => /usr/lib/libpng12.so.0 (0x40dc7000)
        libnetcdf.so.3 => /usr/lib/libnetcdf.so.3 (0x40dec000)
        libcfitsio.so.2 => /usr/lib/libcfitsio.so.2 (0x40e0f000)
        libpthread.so.0 => /lib/tls/libpthread.so.0 (0x40f7d000)
        /lib/ld-linux.so.2 => /lib/ld-linux.so.2 (0x80000000)
        libssl.so.0.9.7 => /usr/lib/i686/cmov/libssl.so.0.9.7 (0x40f8d000)
        libcrypto.so.0.9.7 => /usr/lib/i686/cmov/libcrypto.so.0.9.7
(0x40fbe000)
        libkrb5.so.3 => /usr/lib/libkrb5.so.3 (0x410bd000)
        libcrypt.so.1 => /lib/tls/libcrypt.so.1 (0x41125000)
        libresolv.so.2 => /lib/tls/libresolv.so.2 (0x41152000)
        libnsl.so.1 => /lib/tls/libnsl.so.1 (0x41164000)
        libltdl.so.3 => /usr/lib/libltdl.so.3 (0x41179000)
        libk5crypto.so.3 => /usr/lib/libk5crypto.so.3 (0x41180000)
        libcom_err.so.2 => /lib/libcom_err.so.2 (0x411a3000)

Seems to be ok

Paco

--
Francisco Alonso Sarría
Departamento de Geografía (Area de Geografía Física)
Universidad de Murcia. Campus La Merced
E-30001 Murcia
Telfn: +34 968364357
www.um.es/geograf/sigmur

_______________________________________________
grass5 mailing list
grass5@grass.itc.it
http://grass.itc.it/mailman/listinfo/grass5

> On 10/13/05, Francisco Alonso <alonsarp@um.es> wrote:
> > El Viernes, 14 de Octubre de 2005 10:25, Radim Blazek escribió:
> > > On 10/12/05, Francisco Alonso <alonsarp@um.es> wrote:
> > > > # ogrinfo
> > > > /var/www/grass5_mapserver/spearfish60/PERMANENT/vector/streams/head
> > > > Warning 1: GRASS warning: GISBASE enviroment variable was not set, using:
> > > > /usr/local/grass-6.0.1
> > > > ogrinfo: relocation error: /usr/local/lib/gdalplugins/ogr_GRASS.so:
> > > > undefined symbol: Vect_set_fatal_error

Hi,

I have found the same error here. There is simply a bug in the
new plugin as it isn't linked to the vector libs (oversight
in the configure[.in] of the new plugin).

I have submitted patches to Frank and Radim.

Markus