[GRASS-windows] Compiling grass7 on msys/mingw?

Colin Nielsen colin.nielsen at gmail.com
Wed Dec 17 20:21:08 EST 2008


> Copy in the config.guess file from the GRASS distribution.
> CFLAGS="-O2 -s" CXXFLAGS="-O2 -s" LDFLAGS=-s ./configure
> --prefix=/c/grass/extra
> make
> make install
> (Must compile this as a static library because of obscure problems with
> shared)

No luck on that. I got the file (same as I had already) copied the
config.guess from the grass_trunk folder into the xdr folder and ran
the config line (modified to --prefix=/usr/local/ since that's where
the other ones have been install to). make and make install seem to be
fine:
$ make ; make install
make: Nothing to be done for `all'.
Creating RPC header directory
mkdir -p /usr/local//include/rpc && \
        chmod 755 /usr/local//include/rpc
Installing XDR header files
set -x;for i in rpc/types.h rpc/xdr.h ; do \
        (install -c -m 644 $i /usr/local//include/rpc) done
+ install -c -m 644 rpc/types.h /usr/local//include/rpc
+ install -c -m 644 rpc/xdr.h /usr/local//include/rpc
Installing XDR library
install -c -m 644 libxdr.a /usr/local//lib
ranlib /usr/local//lib/libxdr.a

But then the same error came up when I tried to configure grass. Is
there any other log info I can provide to help? Thanks.

-Colin

On Wed, Dec 17, 2008 at 1:48 PM, Moritz Lennert
<mlennert at club.worldonline.be> wrote:
> On 17/12/08 19:17, Colin Nielsen wrote:
>>
>> I compiled my own grass 6.3 long ago using the steps provided by Marco
>> Pasetti using the following:
>> ./configure  --prefix=/usr/local --with-includes=/usr/local/include
>> --with-libs=/usr/local/lib --disable-x11 --without-jpeg --without-x
>> --with-cxx --enable-shared --enable-largefile --with-opengl=windows
>> --with-fftw --with-freetype --with-proj-share=/usr/local/share/proj
>> --with-gdal=/usr/local/bin/gdal-config --with-tcltk
>> --with-tcltk-includes=/usr/local/tcl-tk/include
>> --with-tcltk-libs=/usr/local/tcl-tk/bin --with-sqlite
>> --with-sqlite-includes=/usr/local/sqlite/include
>> --with-sqlite-libs=/usr/local/sqlite/lib --with-postgres
>> --with-postgres-includes=/usr/local/pgsql/include
>> --with-postgres-libs=/usr/local/pgsql/lib
>>
>> This worked well although as I remember I made a modification or two
>> from the original instructions. So now with the same instructions I'm
>> trying to compile grass7. It stops when it hits an error on XDR:
>> checking for xdrmem_create... no
>> checking for xdrmem_create in -lsun... no
>> checking for xdrmem_create in -lnsl... no
>> checking for xdrmem_create in -lrpclib... no
>> checking for xdrmem_create in -lxdr... no
>> configure: error: *** Unable to locate XDR functions.
>>
>> I originally installed the "xdr-4.0-mingw2" package and also just
>> tried "sunrpc-4.0-bin" as I saw on a list somewhere but neither seem
>> to fix it. In /usr/local/include/rpc there is xdr.h but for some
>> reason configure isn't finding it. Any advice? Are there other reasons
>> I should give up on a grass7 build that I'm not aware of? Thanks.
>
> XDR has repeatedly been a problem under windows. Try this (from
> http://www.stjohnspoint.co.uk/grass/README.extralibs)
>
> xdrlib
> ------
>
> xdr-4.0-mingw2
> http://wiki.qgis.org/qgiswiki/BuildingWindowsBinaryOnLinux?action=AttachFile&do=get&target=xdr-4.0-mingw2.tar.gz
> (special stripped-down version with networking code removed)
>
> Copy in the config.guess file from the GRASS distribution.
> CFLAGS="-O2 -s" CXXFLAGS="-O2 -s" LDFLAGS=-s ./configure
> --prefix=/c/grass/extra
> make
> make install
> (Must compile this as a static library because of obscure problems with
> shared)
>
>
> Marco, maybe you could update
> http://www.webalice.it/marco.pasetti/grass/BuildFromSource.html#Xdr to
> reflect this better ? Or have you been able to do this differently ?
>
> Moritz
>


More information about the grass-windows mailing list