[GRASS-windows] Re: Compiling WINGrass 7.0SVN

Johannes Radinger JRadinger at gmx.at
Tue Oct 11 05:52:28 EDT 2011


Hi Helmut
Hi others,

so the single steps how I want to compile GRASS 7.0 on Windows and
fail :(

As I don't like my Texteditor (UltraEdit) which created these .bak files and always wanted to save the file in the DOS format, I switched to Notepad++

1) I followed all the necessary steps before as mentioned in the wiki, like getting MinGW, OSGEO4W and the MinGW packages. I did that already last week but I am quite sure that I followed exactly the steps as in the wiki.

2) I used Tortoise to get the the newest SVN source (revision 48726) of GRASS 7.0, and this source-tree is saved in the src folder.

3) I first tried to compile it as it was... with the .[0-9][0-9][0-9] in line 96 of the package.sh, but I got following error in the package.log:

Tue Oct 11 09:06:06 CEDT 2011: STARTING remove old logs
rm: cannot lstat `mswindows/osgeo4w/package.log.[0-9][0-9][0-9]': No such file or directory

so I followed your recommendation:

4) I opened package.sh with notepad++ and removed the '.[0-9][0-9][0-9]' from line 96 and saved the file with the same specifications (unix script file, EOL conversion UNIX format, ANSI)  and closed the editor again. The SVN symbol showed the the file was modified.

5) I tried compiling again. Therefore I typed again in the mysys console:
cd /osgeo4w/usr/scr/grass-7.0*

Johannes Radinger at JOHANNES /osgeo4w/usr/scr/grass-7.0.svn
./mswindows/osgeo4w/package.sh

6) Then I can see that a temporary log file is created in the osgeo4w folder but that is removed afterwards automatically. The whole fail-compilation takes only a few seconds.

7) I can switch back to the old package.sh by adding again .[0-9][0-9][0-9] and I can reproduce the behaviour as mentioned in point 3.


8) I found now the configure log-file which is created (compiling with the package.sh without .[0-9][0-9][0-9] in line 96). Maybe that helps
to find the reason for my problems:


This file contains any messages produced by compilers while
running configure, to aid debugging if configure makes a mistake.

configure:749: checking host system type
configure:772: checking for gcc
configure:876: checking whether the C compiler (gcc  ) works
configure:892: gcc -o conftest    conftest.c  1>&5
configure:918: checking whether the C compiler (gcc  ) is a cross-compiler
configure:923: checking whether we are using GNU C
configure:930: gcc -E conftest.c
configure:948: checking whether gcc accepts -g
configure:977: checking for Cygwin environment
configure:991: gcc -c -g -O2  conftest.c 1>&5
configure: In function 'main':
configure:987:8: error: '__CYGWIN32__' undeclared (first use in this function)
configure:987:8: note: each undeclared identifier is reported only once for each function it appears in
configure: failed program was:
#line 980 "configure"
#include "confdefs.h"

int main() {

#ifndef __CYGWIN__
#define __CYGWIN__ __CYGWIN32__
#endif
return __CYGWIN__;
; return 0; }
configure:1007: checking for mingw32 environment
configure:1017: gcc -c -g -O2  conftest.c 1>&5
configure:1035: checking for executable suffix
configure:1054: checking for full floating-point support
configure:1100: gcc -o conftest.exe -g -O2   conftest.c  1>&5
configure:1171: checking for pwd
configure:1209: checking for source directory
configure:1220: checking for build directory
configure:1288: checking for svnversion
configure:1344: checking for MacOSX App
configure:1356: checking for MacOSX architectures
configure:1385: checking for MacOSX SDK
configure:1439: checking how to build libraries
configure:2257: checking for additional include dirs
configure:2280: checking for additional library dirs
configure:2314: checking for a BSD compatible install
configure:2367: checking for flex
configure:2398: checking for yywrap in -ll
configure:2415: gcc -o conftest.exe -g -O2    -I/c/OSGeo4W/include  -Wl,--export-dynamic,--enable-runtime-pseudo-reloc  -L/c/OSGeo4W/lib -L/osgeo4w/usr/src/grass-7.0.svn/mswindows/osgeo4w/lib conftest.c -ll   1>&5
c:/mingw/bin/../lib/gcc/mingw32/4.5.0/../../../../mingw32/bin/ld.exe: warning: --export-dynamic is not supported for PE targets, did you mean --export-all-symbols?
c:/mingw/bin/../lib/gcc/mingw32/4.5.0/../../../../mingw32/bin/ld.exe: cannot find -ll
collect2: ld returned 1 exit status
configure: failed program was:
#line 2404 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error.  */
/* We use char because int might match the return type of a gcc2
    builtin and then its argument prototype would still apply.  */
char yywrap();

int main() {
yywrap()
; return 0; }
configure:2440: checking for lex




So hopefully we can find the error-causing problem, but I am still looking forward to a successful compilation.

best regards
Johannes


-------- Original-Nachricht --------
> Datum: Mon, 10 Oct 2011 23:33:33 +0200
> Von: Helmut Kudrnovsky <alectoria at gmx.at>
> An: Johannes Radinger <JRadinger at gmx.at>
> CC: grass-windows at lists.osgeo.org
> Betreff: Re: Compiling WINGrass 7.0SVN

> Hi Johannes,
> 
> [please stay on the ML ... so others can also benefit and also others
> can help]
> 
> Am 10.10.2011 11:28, schrieb Johannes Radinger:
> > Hello Helmut,
> > 
> > thank you for the link with WINGrass 6.5 and some preinstalled AddOns. 
> >As I want to include my own AddOns I anyway want to learn how to compile
> it myself.
> 
> the best source for learning is the source itself ;o)
> 
> > 
> > Therefore I followed your workaround notice to edit the package.sh and
> did the 
> >recommended changes in line 96. 
> 
> ok
> 
> >But at the moment I don't manage to get it run. 
> >Now I can see that an error.log is created while it tries to compile, but
> it is removed 
> >after it stopps with the compiling (already after one second). As there
> is no log file I 
> >can't tell what is causing the stop.
> 
> I can't reprodce this ... please provide steps what you are doing
> 
> > 
> > I work with the latest weekly snapshot of GRASS 7.0 and downloaded that
> manually.
> 
> ... should work
> 
> >After editing package.sh a package.sh.bak file is created. 
> 
> that's a backup file of the editor, nothing related with grass gis
> 
> >I think that is a behaviour 
> >because the trunk seems to be associated with SVN and it seems to be a
> backup file (.bak). 
> >This file still contains the orignial lines. 
> 
> 
> >Maybe this is causing the problem?! So I 
> >deleted the package.sh.bak but still the same problem. Is my way of
> editing wrong? 
> >Or is there simply just another thing causing that problem?
> 
> please provide steps
> 
> > 
> > Thank you very much for your help!
> > 
> > cheers
> > Johannes
> > 
> 
> 
> best regards
> Helmut
> 

-- 
Ihr GMX Postfach immer dabei: die kostenlose GMX Mail App für Android.
Komfortabel, sicher und schnell: www.gmx.de/android


More information about the grass-windows mailing list