[GRASS5] Swig interface for Grass

Jachym Cepicky jachym.cepicky at centrum.cz
Tue Feb 14 17:15:21 EST 2006


hallo,
what I have read on wikipedia (http://en.wikipedia.org/wiki/SWIG), SWIG
is released under a BSD type license. Could that not be a problem for
GRASS at least for distribution of both software in one package?


I tryed to compile and use the grass.pm module, without success:

./configure  --with-cxx --with-nls --with-freetype --enable-largefile --with-tcltk-includes=/usr/include/tcl8.3 --with-postgres-includes=/usr/include/postgresql/ --with-freetype-includes=/usr/include/freetype2/ --with-fftw --with-nls --with-readline --with-sqlite

cd swig/perl
perl Makefile.PL

MakeMaker (v6.17)
Writing Makefile for R_slope_aspect::r_slope_aspect
Writing Makefile for R_slope_aspect
Writing Makefile for Grass

make
make[1]: Entering directory `/usr/src/gis/grass/grass6/swig/perl/R_slope_aspect'
cd r_slope_aspect && make LIB="" LIBPERL_A="libperl.a" LINKTYPE="dynamic" PREFIX="/usr" OPTIMIZE="-O2" PASTHRU_DEFINE="" PASTHRU_INC=""
make[2]: Entering directory `/usr/src/gis/grass/grass6/swig/perl/R_slope_aspect/r_slope_aspect'
cc -c  -I/usr/include -I/usr/src/gis/grass/grass6/include -D_REENTRANT -D_GNU_SOURCE -DTHREADS_HAVE_PIDS -DDEBIAN -fno-strict-aliasing -pipe -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -O2   -DVERSION=\"\" -DXS_VERSION=\"\" -fPIC "-I/usr/lib/perl/5.8/CORE"  -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -O2 -Wall -fpic -ggdb -DPACKAGE=\""grassmods"\" r_slope_aspect.c
r_slope_aspect.c:4:23: error: grass/gis.h: No such file or directory
In file included from r_slope_aspect.c:5:
local_proto.h:2: error: syntax error before 'RASTER_MAP_TYPE'
r_slope_aspect.c:6:27: error: grass/glocale.h: No such file or directory
r_slope_aspect.c: In function 'r_slope_aspect':
r_slope_aspect.c:36: error: storage size of 'cats' isn't known
r_slope_aspect.c:49: error: 'DCELL' undeclared (first use in this function)
r_slope_aspect.c:49: error: (Each undeclared identifier is reported only once
r_slope_aspect.c:49: error: for each function it appears in.)
r_slope_aspect.c:49: error: 'elev_cell' undeclared (first use in this function)
r_slope_aspect.c:49: error: 'temp' undeclared (first use in this function)
.....
.....

I suppose, this has something to do with last changes in grass header
files(?)

jachym


On Mon, Jan 02, 2006 at 09:15:44AM +0100, Markus Neteler wrote:
> Hello Sajith,
> 
> sorry for the delay.
> Unfortunately I don't know much about SWIG. My suggestion
> is to study how things are done in GDAL. I can see that there
> are all typemaps in
>  gdal/swig/include/
> 
> Maybe we should try the same?
> 
> Probably I should launch a "call for help" in the
> FreeGIS mailing list to find someone to help?
> 
> Markus
> 
> 
> On Sun, Dec 25, 2005 at 12:43:32PM +0530, Sajith VK wrote:
> > Hello all,
> > 
> > I was going through the perl-grass interface(swing)
> > and to do the same for python.
> > 
> > Since I am not good in "make and perl" I find difficulty in
> > modifying the Makefile needed.
> > 
> > So here I am attaching my "typemaps" for python-grass.
> > Can someone suggest how to develop the Makefile for this?
> > 
> > 
> > --
> > Change the rules, or the rules will change you
> >      ---------Kumaranasan
> 
> 
> 
> 
> -- 
> Markus Neteler     <neteler itc it>       http://mpa.itc.it
> ITC-irst -  Centro per la Ricerca Scientifica e Tecnologica
> MPBA - Predictive Models for Biol. & Environ. Data Analysis
> Via Sommarive, 18        -       38050 Povo (Trento), Italy
> 
> _______________________________________________
> grass5 mailing list
> grass5 at grass.itc.it
> http://grass.itc.it/mailman/listinfo/grass5

-- 
Jachym Cepicky                                  
e-mail: jachym.cepicky at centrum.cz           
URL: http://les-ejk.cz                      
GPG: http://les-ejk.cz/gnupg_public_key/    
-----------------------------------------   
OFFICE:                                     
Department of Geoinformation Technologies   
LDF MZLU v Brně                             
Zemědělská 3                                
613 00 Brno                                 
e-mail: xcepicky at node.mendelu.cz            
URL:    http://mapserver.mendelu.cz
Tel.:   +420 545 134 514




More information about the grass-dev mailing list