[GRASS5] Problem compiling Grass51

Hi to all,
I have a problem trying to compile last version of Grass51
(26/04/2003 cvs updated)...

make[1]: Entering directory `/home/rpms/GRASS/Sept2002/grass51_exp_2003_04_26/lib'
bitmap
make[2]: Entering directory `/home/rpms/GRASS/Sept2002/grass51_exp_2003_04_26/lib/bitmap'
make[2]: *** No rule to make target `OBJ.i686-pc-linux-gnu/bitmap.o', needed
by `/home/rpms/GRASS/Sept2002/grass51_exp_2003_04_26/dist.i686-pc-linux-gnu/lib/libgrass_bitmap.a'.
Stop.
make[2]: Leaving directory `/home/rpms/GRASS/Sept2002/grass51_exp_2003_04_26/lib/bitmap'
make[1]: *** [subdirs] Error 1
make[1]: Leaving directory `/home/rpms/GRASS/Sept2002/grass51_exp_2003_04_26/lib'
make: *** [default] Error 1

Could someone help me?

Thank you

Mauro

________________________________________
Raddoppia la tua casella navigando con il numero unico! http://www.jumpy.it/Canali_J/Aiuto/articles.shtml?BXXCYXCYAH/art903

maurosw@jumpy.it wrote:

I have a problem trying to compile last version of Grass51
(26/04/2003 cvs updated)...

make[1]: Entering directory `/home/rpms/GRASS/Sept2002/grass51_exp_2003_04_26/lib'
bitmap
make[2]: Entering directory `/home/rpms/GRASS/Sept2002/grass51_exp_2003_04_26/lib/bitmap'
make[2]: *** No rule to make target `OBJ.i686-pc-linux-gnu/bitmap.o', needed
by `/home/rpms/GRASS/Sept2002/grass51_exp_2003_04_26/dist.i686-pc-linux-gnu/lib/libgrass_bitmap.a'.
Stop.
make[2]: Leaving directory `/home/rpms/GRASS/Sept2002/grass51_exp_2003_04_26/lib/bitmap'
make[1]: *** [subdirs] Error 1
make[1]: Leaving directory `/home/rpms/GRASS/Sept2002/grass51_exp_2003_04_26/lib'
make: *** [default] Error 1

Could someone help me?

You have to run "make mix" or "make copymix" first.

The "grass51" repository only contains those files which are new or
have changed in 5.1; everything else has to be linked or copied from
the 5.0 source tree.

--
Glynn Clements <glynn.clements@virgin.net>

After "make copymix" (Grass50 cvs updated and Grass51 cvs updated)
I have this problem:

gcc -I/home/rpms/GRASS/gdal-1.1.8/ogr/ -g -O2 -Wall -I/home/rpms/GRASS/gdal-1.1.8/ogr/
-I/home/rpms/GRASS/Sept2002/grass51_exp_2003_04_26/include -I/home/rpms/GRASS/Sept2002/grass51_exp_2003_04_26/dist.i686-pc-linux-gnu/include
  -I/home/rpms/GRASS/gdal-1.1.8/port -I/home/rpms/GRASS/gdal-1.1.8/core
-I/home/rpms/GRASS/gdal-1.1.8/ogr -I/home/rpms/GRASS/gdal-1.1.8/ogr/ogrsf_frmts
-DUSE_GDAL_H -I/usr/local/pgsql/include/ -I/home/rpms/GRASS/Sept2002/grass51_exp_2003_04_26/include
-I/home/rpms/GRASS/Sept2002/grass51_exp_2003_04_26/dist.i686-pc-linux-gnu/include
\
        -o OBJ.i686-pc-linux-gnu/input2d.o -c input2d.c
input2d.c:194: conflicting types for `IL_create_bitmask'
interpf.h:70: previous declaration of `IL_create_bitmask'
/home/rpms/GRASS/Sept2002/grass51_exp_2003_04_26/include/gis.h:36: warning:
`GRASS_copyright' defined but not used
make[3]: *** [OBJ.i686-pc-linux-gnu/input2d.o] Error 1
make[3]: Leaving directory `/home/rpms/GRASS/Sept2002/grass51_exp_2003_04_26/lib/rst/interp_float'
make[2]: *** [subdirs] Error 1
make[2]: Leaving directory `/home/rpms/GRASS/Sept2002/grass51_exp_2003_04_26/lib/rst'
make[1]: *** [subdirs] Error 1
make[1]: Leaving directory `/home/rpms/GRASS/Sept2002/grass51_exp_2003_04_26/lib'
make: *** [default] Error 1

-- Original Message --
From: Glynn Clements <glynn.clements@virgin.net>
Date: Mon, 28 Apr 2003 18:03:25 +0100
To: maurosw@jumpy.it
Cc: grass5@grass.itc.it
Subject: Re: [GRASS5] Problem compiling Grass51

maurosw@jumpy.it wrote:

I have a problem trying to compile last version of Grass51
(26/04/2003 cvs updated)...

make[1]: Entering directory `/home/rpms/GRASS/Sept2002/grass51_exp_2003_04_26/lib'
bitmap
make[2]: Entering directory `/home/rpms/GRASS/Sept2002/grass51_exp_2003_04_26/lib/bitmap'
make[2]: *** No rule to make target `OBJ.i686-pc-linux-gnu/bitmap.o',

needed

by `/home/rpms/GRASS/Sept2002/grass51_exp_2003_04_26/dist.i686-pc-linux-gnu/lib/libgrass_bitmap.a'.
Stop.
make[2]: Leaving directory `/home/rpms/GRASS/Sept2002/grass51_exp_2003_04_26/lib/bitmap'
make[1]: *** [subdirs] Error 1
make[1]: Leaving directory `/home/rpms/GRASS/Sept2002/grass51_exp_2003_04_26/lib'
make: *** [default] Error 1

Could someone help me?

You have to run "make mix" or "make copymix" first.

The "grass51" repository only contains those files which are new or
have changed in 5.1; everything else has to be linked or copied from
the 5.0 source tree.

--
Glynn Clements <glynn.clements@virgin.net>

________________________________________
Raddoppia la tua casella navigando con il numero unico! http://www.jumpy.it/Canali_J/Aiuto/articles.shtml?BXXCYXCYAH/art903

On Tue, 29 Apr 2003 maurosw@jumpy.it wrote:

After "make copymix" (Grass50 cvs updated and Grass51 cvs updated)
I have this problem:

gcc -I/home/rpms/GRASS/gdal-1.1.8/ogr/ -g -O2 -Wall -I/home/rpms/GRASS/gdal-1.1.8/ogr/
-I/home/rpms/GRASS/Sept2002/grass51_exp_2003_04_26/include -I/home/rpms/GRASS/Sept2002/grass51_exp_2003_04_26/dist.i686-pc-linux-gnu/include
  -I/home/rpms/GRASS/gdal-1.1.8/port -I/home/rpms/GRASS/gdal-1.1.8/core
-I/home/rpms/GRASS/gdal-1.1.8/ogr -I/home/rpms/GRASS/gdal-1.1.8/ogr/ogrsf_frmts
-DUSE_GDAL_H -I/usr/local/pgsql/include/ -I/home/rpms/GRASS/Sept2002/grass51_exp_2003_04_26/include
-I/home/rpms/GRASS/Sept2002/grass51_exp_2003_04_26/dist.i686-pc-linux-gnu/include
\
        -o OBJ.i686-pc-linux-gnu/input2d.o -c input2d.c
input2d.c:194: conflicting types for `IL_create_bitmask'
interpf.h:70: previous declaration of `IL_create_bitmask'
/home/rpms/GRASS/Sept2002/grass51_exp_2003_04_26/include/gis.h:36: warning:
`GRASS_copyright' defined but not used
make[3]: *** [OBJ.i686-pc-linux-gnu/input2d.o] Error 1
make[3]: Leaving directory `/home/rpms/GRASS/Sept2002/grass51_exp_2003_04_26/lib/rst/interp_float'
make[2]: *** [subdirs] Error 1
make[2]: Leaving directory `/home/rpms/GRASS/Sept2002/grass51_exp_2003_04_26/lib/rst'
make[1]: *** [subdirs] Error 1
make[1]: Leaving directory `/home/rpms/GRASS/Sept2002/grass51_exp_2003_04_26/lib'
make: *** [default] Error 1

You must be using a GRASS 5 CVS version later than Sunday night but
GRASS5.1 earlier than Monday lunchtime---that was when these changes were
made---if you use the latest versions of both it should be fine.

You can always check the grass-commit mailing list at
http://grass.itc.it/pipermail/grass-commit/ to see if recent changes were
made to the 5.0 tree which cause problems for 5.1 when it is copied over
in the 'make mix' stage.

Paul

On Tue, Apr 29, 2003 at 09:49:24AM +0200, maurosw@jumpy.it wrote:

After "make copymix" (Grass50 cvs updated and Grass51 cvs updated)
I have this problem:

gcc -I/home/rpms/GRASS/gdal-1.1.8/ogr/ -g -O2 -Wall -I/home/rpms/GRASS/gdal-1.1.8/ogr/
-I/home/rpms/GRASS/Sept2002/grass51_exp_2003_04_26/include -I/home/rpms/GRASS/Sept2002/grass51_exp_2003_04_26/dist.i686-pc-linux-gnu/include
  -I/home/rpms/GRASS/gdal-1.1.8/port -I/home/rpms/GRASS/gdal-1.1.8/core
-I/home/rpms/GRASS/gdal-1.1.8/ogr -I/home/rpms/GRASS/gdal-1.1.8/ogr/ogrsf_frmts
-DUSE_GDAL_H -I/usr/local/pgsql/include/ -I/home/rpms/GRASS/Sept2002/grass51_exp_2003_04_26/include
-I/home/rpms/GRASS/Sept2002/grass51_exp_2003_04_26/dist.i686-pc-linux-gnu/include
\
        -o OBJ.i686-pc-linux-gnu/input2d.o -c input2d.c
input2d.c:194: conflicting types for `IL_create_bitmask'
interpf.h:70: previous declaration of `IL_create_bitmask'
/home/rpms/GRASS/Sept2002/grass51_exp_2003_04_26/include/gis.h:36: warning:
`GRASS_copyright' defined but not used
make[3]: *** [OBJ.i686-pc-linux-gnu/input2d.o] Error 1
make[3]: Leaving directory `/home/rpms/GRASS/Sept2002/grass51_exp_2003_04_26/lib/rst/interp_float'
make[2]: *** [subdirs] Error 1
make[2]: Leaving directory `/home/rpms/GRASS/Sept2002/grass51_exp_2003_04_26/lib/rst'
make[1]: *** [subdirs] Error 1
make[1]: Leaving directory `/home/rpms/GRASS/Sept2002/grass51_exp_2003_04_26/lib'
make: *** [default] Error 1

To compile GRASS 5.1 you have to update GRASS 5.0 CVS HEAD as well. We try
to keep 5.1 in sync with the latest 5.0 changes.

Simply run
cvs up -dP
in both source code trees.

Markus

I solved previous problem (using snapshot and updating only the necessary)
but now I have this error:

gcc -L/home/rpms/GRASS/Sept2002/grass51_exp_2003_04_26/dist.i686-pc-linux-gnu/lib
   -o /home/rpms/GRASS/Sept2002/grass51_exp_2003_04_26/dist.i686-pc-linux-gnu/etc/bin/cmd/d.where
OBJ.i686-pc-linux-gnu/b_w_line.o OBJ.i686-pc-linux-gnu/main.o OBJ.i686-pc-linux-gnu/where.o
/home/rpms/GRASS/Sept2002/grass51_exp_2003_04_26/dist.i686-pc-linux-gnu/lib/libgrass_display.a
/home/rpms/GRASS/Sept2002/grass51_exp_2003_04_26/dist.i686-pc-linux-gnu/lib/libgrass_raster.a
/home/rpms/GRASS/Sept2002/grass51_exp_2003_04_26/dist.i686-pc-linux-gnu/lib/libgrass_gproj.a
-lproj /home/rpms/GRASS/Sept2002/grass51_exp_2003_04_26/dist.i686-pc-linux-gnu/lib/libgrass_gis.a
   -lm -lz
/home/rpms/GRASS/Sept2002/grass51_exp_2003_04_26/dist.i686-pc-linux-gnu/lib/libgrass_gproj.a(get_proj.o):
In function `pj_print_proj_params':
/home/rpms/GRASS/Sept2002/grass51_exp_2003_04_26/lib/proj/get_proj.c:377:
undefined reference to `pj_get_def'
/home/rpms/GRASS/Sept2002/grass51_exp_2003_04_26/lib/proj/get_proj.c:386:
undefined reference to `pj_get_def'
collect2: ld returned 1 exit status
make[2]: *** [/home/rpms/GRASS/Sept2002/grass51_exp_2003_04_26/dist.i686-pc-linux-gnu/etc/bin/cmd/d.where]
Error 1
make[2]: Leaving directory `/home/rpms/GRASS/Sept2002/grass51_exp_2003_04_26/display/d.where'
make[1]: *** [subdirs] Error 1
make[1]: Leaving directory `/home/rpms/GRASS/Sept2002/grass51_exp_2003_04_26/display'
make: *** [default] Error 1

Any idea?

Mauro

-- Original Message --
Date: Tue, 29 Apr 2003 09:20:42 +0100 (BST)
From: Paul Kelly <paul-grass@stjohnspoint.co.uk>
To: maurosw@jumpy.it
cc: grass5@grass.itc.it
Subject: Re: [GRASS5] Problem compiling Grass51

On Tue, 29 Apr 2003 maurosw@jumpy.it wrote:

After "make copymix" (Grass50 cvs updated and Grass51 cvs updated)
I have this problem:

gcc -I/home/rpms/GRASS/gdal-1.1.8/ogr/ -g -O2 -Wall -I/home/rpms/GRASS/gdal-1.1.8/ogr/
-I/home/rpms/GRASS/Sept2002/grass51_exp_2003_04_26/include -I/home/rpms/GRASS/Sept2002/grass51_exp_2003_04_26/dist.i686-pc-linux-gnu/include
  -I/home/rpms/GRASS/gdal-1.1.8/port -I/home/rpms/GRASS/gdal-1.1.8/core
-I/home/rpms/GRASS/gdal-1.1.8/ogr -I/home/rpms/GRASS/gdal-1.1.8/ogr/ogrsf_frmts
-DUSE_GDAL_H -I/usr/local/pgsql/include/ -I/home/rpms/GRASS/Sept2002/grass51_exp_2003_04_26/include
-I/home/rpms/GRASS/Sept2002/grass51_exp_2003_04_26/dist.i686-pc-linux-gnu/include
\
        -o OBJ.i686-pc-linux-gnu/input2d.o -c input2d.c
input2d.c:194: conflicting types for `IL_create_bitmask'
interpf.h:70: previous declaration of `IL_create_bitmask'
/home/rpms/GRASS/Sept2002/grass51_exp_2003_04_26/include/gis.h:36: warning:
`GRASS_copyright' defined but not used
make[3]: *** [OBJ.i686-pc-linux-gnu/input2d.o] Error 1
make[3]: Leaving directory `/home/rpms/GRASS/Sept2002/grass51_exp_2003_04_26/lib/rst/interp_float'
make[2]: *** [subdirs] Error 1
make[2]: Leaving directory `/home/rpms/GRASS/Sept2002/grass51_exp_2003_04_26/lib/rst'
make[1]: *** [subdirs] Error 1
make[1]: Leaving directory `/home/rpms/GRASS/Sept2002/grass51_exp_2003_04_26/lib'
make: *** [default] Error 1

You must be using a GRASS 5 CVS version later than Sunday night but
GRASS5.1 earlier than Monday lunchtime---that was when these changes were
made---if you use the latest versions of both it should be fine.

You can always check the grass-commit mailing list at
http://grass.itc.it/pipermail/grass-commit/ to see if recent changes were
made to the 5.0 tree which cause problems for 5.1 when it is copied over
in the 'make mix' stage.

Paul

________________________________________
Raddoppia la tua casella navigando con il numero unico! http://www.jumpy.it/Canali_J/Aiuto/articles.shtml?BXXCYXCYAH/art903

On Tue, Apr 29, 2003 at 12:54:40PM +0200, maurosw@jumpy.it wrote:

I solved previous problem (using snapshot and updating only the necessary)
but now I have this error:

[...]

/home/rpms/GRASS/Sept2002/grass51_exp_2003_04_26/dist.i686-pc-linux-gnu/lib/libgrass_gproj.a(get_proj.o):
In function `pj_print_proj_params':
/home/rpms/GRASS/Sept2002/grass51_exp_2003_04_26/lib/proj/get_proj.c:377:
undefined reference to `pj_get_def'
/home/rpms/GRASS/Sept2002/grass51_exp_2003_04_26/lib/proj/get_proj.c:386:
undefined reference to `pj_get_def'
collect2: ld returned 1 exit status
make[2]: *** [/home/rpms/GRASS/Sept2002/grass51_exp_2003_04_26/dist.i686-pc-linux-gnu/etc/bin/cmd/d.where]
Error 1
make[2]: Leaving directory `/home/rpms/GRASS/Sept2002/grass51_exp_2003_04_26/display/d.where'
make[1]: *** [subdirs] Error 1
make[1]: Leaving directory `/home/rpms/GRASS/Sept2002/grass51_exp_2003_04_26/display'
make: *** [default] Error 1

Any idea?

Yes: There was not yet GPROJDEP defined (fixed now).
To fix the problem, remove
/home/rpms/GRASS/Sept2002/grass51_exp_2003_04_26/dist.i686-pc-linux-gnu/lib/libgrass_gproj.a

and recompile proj:
cd src/proj
make clean
make

then d.where should compile.

Markus

Hello,

I grabbed the latest CVS versios of grass and grass51 this morning and am having problems building grass51.

I have updated and rebuilt grass50, but grass51 does not want to build. I get the following error about the PROJ library.

make[2]: *** No rule to make target `-lproj', needed by `OBJ.i686-pc-linux-gnu/b_w_line.o'. Stop.
make[2]: Leaving directory `/home/covill/GRASS_DIST/grass51/display/d.where'
make[1]: *** [subdirs] Error 1
make[1]: Leaving directory `/home/covill/GRASS_DIST/grass51/display'
make: *** [default] Error 1

If I jump ahead and try and build another PROJ dependant program such as g.region I get the same error.

The PROJ test passes in configure.

Any idea what the problem is?

--
Bob Covill

Tekmap Consulting
P.O. Box 2016
Fall River, N.S.
B2T 1K6
Canada

E-Mail: bcovill@tekmap.ns.ca
Phone: 902-860-1496
Fax: 902-860-1498

On Tue, Apr 29, 2003 at 10:36:06AM -0300, Bob Covill wrote:

Hello,

I grabbed the latest CVS versios of grass and grass51 this morning and
am having problems building grass51.

I have updated and rebuilt grass50, but grass51 does not want to build.
I get the following error about the PROJ library.

make[2]: *** No rule to make target `-lproj', needed by
`OBJ.i686-pc-linux-gnu/b_w_line.o'. Stop.
make[2]: Leaving directory `/home/covill/GRASS_DIST/grass51/display/d.where'
make[1]: *** [subdirs] Error 1
make[1]: Leaving directory `/home/covill/GRASS_DIST/grass51/display'
make: *** [default] Error 1

If I jump ahead and try and build another PROJ dependant program such as
g.region I get the same error.

The PROJ test passes in configure.

Any idea what the problem is?

Bob,

could you run

#fetch an updated file:
cvs up include/Make

#again:
configure ....
make

? I have tried to fix this problem some hours ago.

Markus

Markus Neteler wrote:

On Tue, Apr 29, 2003 at 10:36:06AM -0300, Bob Covill wrote:

Hello,

I grabbed the latest CVS versios of grass and grass51 this morning and am having problems building grass51.

I have updated and rebuilt grass50, but grass51 does not want to build. I get the following error about the PROJ library.

make[2]: *** No rule to make target `-lproj', needed by `OBJ.i686-pc-linux-gnu/b_w_line.o'. Stop.
make[2]: Leaving directory `/home/covill/GRASS_DIST/grass51/display/d.where'
make[1]: *** [subdirs] Error 1
make[1]: Leaving directory `/home/covill/GRASS_DIST/grass51/display'
make: *** [default] Error 1

If I jump ahead and try and build another PROJ dependant program such as g.region I get the same error.

The PROJ test passes in configure.

Any idea what the problem is?

Bob,

could you run

#fetch an updated file:
cvs up include/Make

#again:
configure ....
make

? I have tried to fix this problem some hours ago.

Markus

Markus,

That did not work. I tried updating (grass51), and it still failed. To be completely sure, I deleted grass51 and then checked it out from scratch.

Still the same error.

Any more ideas?

--
Bob Covill

Tekmap Consulting
P.O. Box 2016
Fall River, N.S.
B2T 1K6
Canada

E-Mail: bcovill@tekmap.ns.ca
Phone: 902-860-1496
Fax: 902-860-1498

Hello Bob
I found a mistake in the Makefile where $(PROJ_INC) should have been
$(PROJINC) but that isn't your problem. If $(GPROJDEP) is removed from the
dependency list it is all right. Seems the problem is related to an
earlier e-mail this morning
http://grass.itc.it/pipermail/grass5/2003-April/005350.html
I don't think $(GPROJDEP) should be defined as GPROJDEP = $(GPROJLIB)
in grass51/include/Make/Grass.make.in since
GPROJLIB = $(ARCH_LIBDIR)/$(LIB_PREFIX)$(GPROJ_LIBNAME).$(LIB_SUFFIX) $(PROJLIB)
So when there is anything in $(PROJLIB) this won't work as a dependency rule
in the Makefile.
But this is also done for $(GISDEP) where
GISLIB = $(ARCH_LIBDIR)/$(LIB_PREFIX)$(GIS_LIBNAME).$(LIB_SUFFIX) \
$(SOCKLIB) $(INTLLIB)
so if $(SOCKLIB) or $(INTLLIB) where defined as anything, presumably this
wouldn't work either.

I fixed it by sort of swapping round the definitions of $(GPROJLIB) and
$(GPROJDEP); probably this file needs to be re-arranged:
GPROJDEP = $(ARCH_LIBDIR)/$(LIB_PREFIX)$(GPROJ_LIBNAME).$(LIB_SUFFIX)
first and then
GPROJLIB = $(GPROJDEP) $(PROJLIB)
further down in the file. grass/src/CMD/generic/make.mid gives a clue as
to how this should be done properly.

BTW I still can't compile d.where as there is a vsnprintf() somewhere in
libgrass_gis.a according to the error message. I don't use GRASS 5.1 as it
is full of Linux-isms etc. and I can never get it to compile properly on the
Irix system I use most of them (GRASS 5.0 was like this also a year or two
ago but it is much tidier now).

Paul

On Tue, 29 Apr 2003, Bob Covill wrote:

Hello,

I grabbed the latest CVS versios of grass and grass51 this morning and
am having problems building grass51.

I have updated and rebuilt grass50, but grass51 does not want to build.
I get the following error about the PROJ library.

make[2]: *** No rule to make target `-lproj', needed by
`OBJ.i686-pc-linux-gnu/b_w_line.o'. Stop.
make[2]: Leaving directory `/home/covill/GRASS_DIST/grass51/display/d.where'
make[1]: *** [subdirs] Error 1
make[1]: Leaving directory `/home/covill/GRASS_DIST/grass51/display'
make: *** [default] Error 1

If I jump ahead and try and build another PROJ dependant program such as
g.region I get the same error.

The PROJ test passes in configure.

Any idea what the problem is?

--
Bob Covill

Tekmap Consulting
P.O. Box 2016
Fall River, N.S.
B2T 1K6
Canada

E-Mail: bcovill@tekmap.ns.ca
Phone: 902-860-1496
Fax: 902-860-1498

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

On Tue, Apr 29, 2003 at 03:34:57PM +0100, Paul Kelly wrote:

Hello Bob
I found a mistake in the Makefile where $(PROJ_INC) should have been
$(PROJINC) but that isn't your problem. If $(GPROJDEP) is removed from the
dependency list it is all right. Seems the problem is related to an
earlier e-mail this morning
http://grass.itc.it/pipermail/grass5/2003-April/005350.html
I don't think $(GPROJDEP) should be defined as GPROJDEP = $(GPROJLIB)
in grass51/include/Make/Grass.make.in since
GPROJLIB = $(ARCH_LIBDIR)/$(LIB_PREFIX)$(GPROJ_LIBNAME).$(LIB_SUFFIX) $(PROJLIB)
So when there is anything in $(PROJLIB) this won't work as a dependency rule
in the Makefile.
But this is also done for $(GISDEP) where
GISLIB = $(ARCH_LIBDIR)/$(LIB_PREFIX)$(GIS_LIBNAME).$(LIB_SUFFIX) \
$(SOCKLIB) $(INTLLIB)
so if $(SOCKLIB) or $(INTLLIB) where defined as anything, presumably this
wouldn't work either.

right now (before reading this mail) I have submitted the dependencies for
all LIBs. The next changes I would leave to an expert - as I don't know too
much about Makefiles. On my Linux boxes it works well, but I have neither
access to SGI nor Solaris to try there.

I fixed it by sort of swapping round the definitions of $(GPROJLIB) and
$(GPROJDEP); probably this file needs to be re-arranged:
GPROJDEP = $(ARCH_LIBDIR)/$(LIB_PREFIX)$(GPROJ_LIBNAME).$(LIB_SUFFIX)
first and then
GPROJLIB = $(GPROJDEP) $(PROJLIB)
further down in the file. grass/src/CMD/generic/make.mid gives a clue as
to how this should be done properly.

BTW I still can't compile d.where as there is a vsnprintf() somewhere in
libgrass_gis.a according to the error message.

Here it is:
./lib/gis/debug.c

I don't use GRASS 5.1 as it
is full of Linux-isms etc. and I can never get it to compile properly on the
Irix system I use most of them (GRASS 5.0 was like this also a year or two
ago but it is much tidier now).

Would you mind to post the error messages? Only then we could avoid
problems we are not aware of.

Markus

On Tue, 29 Apr 2003, Markus Neteler wrote:

right now (before reading this mail) I have submitted the dependencies for
all LIBs. The next changes I would leave to an expert - as I don't know too
much about Makefiles. On my Linux boxes it works well, but I have neither
access to SGI nor Solaris to try there.

I don't see how d.where could compile anywhere the way it currently is (I
presume Bob is using Linux as well?) As I understand it the dependency has
to be an actual file or list of files that make can check to see when they
were last modified. The dependencies follow a colon on the makefile. And
underneath that are instructions for compiling the output program.

Before fixing it we have to know why it is done like that, with the full
pathname of the static library. Why not do it like GPROJLIB = -lproj,
GISLIB = -lgis etc. in GRASS 5.0. Neater looking and makes it possible to
use shared libraries.

> I fixed it by sort of swapping round the definitions of $(GPROJLIB) and
> $(GPROJDEP); probably this file needs to be re-arranged:
> GPROJDEP = $(ARCH_LIBDIR)/$(LIB_PREFIX)$(GPROJ_LIBNAME).$(LIB_SUFFIX)
> first and then
> GPROJLIB = $(GPROJDEP) $(PROJLIB)
> further down in the file. grass/src/CMD/generic/make.mid gives a clue as
> to how this should be done properly.
>
> BTW I still can't compile d.where as there is a vsnprintf() somewhere in
> libgrass_gis.a according to the error message.

Here it is:
./lib/gis/debug.c

I think we need a G_snprintf() and G_vsnprintf() or something like that.
Would it be all right just to copy the code straight from a 3rd party snprintf
implementation to enable this?

> I don't use GRASS 5.1 as it
> is full of Linux-isms etc. and I can never get it to compile properly on the
> Irix system I use most of them (GRASS 5.0 was like this also a year or two
> ago but it is much tidier now).

Would you mind to post the error messages? Only then we could avoid
problems we are not aware of.

I will make a start (see below). It can be an occasional series...

make[2]: Entering
directory `/indigo-disk2/grass/grass51/lib/form' cc
-L/indigo-disk2/grass/grass51/dist.mips-sgi-irix6.2/lib
-L/indigo-disk2/grass/doom.ee.qub.ac.uk/lib -o
/indigo-disk2/grass/grass51/dist.mips-sgi-irix6.2/etc/form/form
OBJ.mips-sgi-irix6.2/form.o
/indigo-disk2/grass/grass51/dist.mips-sgi-irix6.2/lib/libgrass_dbmi.a
/indigo-disk2/grass/grass51/dist.mips-sgi-irix6.2/lib/libgrass_gis.a
-L/indigo-disk2/grass/doom.ee.qub.ac.uk/lib -ltk -lm -ltcl -lm \
                         -lm -lz
/indigo-disk2/grass/doom.ee.qub.ac.uk/lib/libsnprintf.a ld: WARNING 84:
/indigo-disk2/grass/doom.ee.qub.ac.uk/lib/libz.a is not used for resolving
any symbol. ld: ERROR 33: Unresolved text symbol "G_setenv2" -- 1st
referenced by
/indigo-disk2/grass/grass51/dist.mips-sgi-irix6.2/lib/libgrass_dbmi.a(connect.o).
ld: ERROR 33: Unresolved text symbol "G__getenv2" -- 1st referenced by
/indigo-disk2/grass/grass51/dist.mips-sgi-irix6.2/lib/libgrass_dbmi.a(connect.o).
ld: INFO 152: Output file removed because of error. make[2]: ***
[/indigo-disk2/grass/grass51/dist.mips-sgi-irix6.2/etc/form/form] Error 1
make[2]: Leaving directory `/indigo-disk2/grass/grass51/lib/form' make[1]:
*** [subdirs] Error 1 make[1]: Leaving directory
`/indigo-disk2/grass/grass51/lib' make: *** [default] Error 1

Paul,

I am still getting the same error. If I swap the GPROJLIB and GPROJDEP definitions around I get the following

/home/covill/GRASS_DIST/grass51/dist.i686-pc-linux-gnu/lib/libgrass_gproj.a(get_proj.o): In function `pj_print_proj_params':
/home/covill/GRASS_DIST/grass51/lib/proj/get_proj.c:374: undefined reference to `pj_get_def'
/home/covill/GRASS_DIST/grass51/lib/proj/get_proj.c:383: undefined reference to `pj_get_def'
collect2: ld returned 1 exit status
make[2]: *** [/home/covill/GRASS_DIST/grass51/dist.i686-pc-linux-gnu/etc/bin/cmd/d.where] Error 1
make[2]: Leaving directory `/home/covill/GRASS_DIST/grass51/display/d.where'
make[1]: *** [subdirs] Error 1

Anything else I could try?

Paul Kelly wrote:

Hello Bob
I found a mistake in the Makefile where $(PROJ_INC) should have been
$(PROJINC) but that isn't your problem. If $(GPROJDEP) is removed from the
dependency list it is all right. Seems the problem is related to an
earlier e-mail this morning
http://grass.itc.it/pipermail/grass5/2003-April/005350.html
I don't think $(GPROJDEP) should be defined as GPROJDEP = $(GPROJLIB)
in grass51/include/Make/Grass.make.in since
GPROJLIB = $(ARCH_LIBDIR)/$(LIB_PREFIX)$(GPROJ_LIBNAME).$(LIB_SUFFIX) $(PROJLIB)
So when there is anything in $(PROJLIB) this won't work as a dependency rule
in the Makefile.
But this is also done for $(GISDEP) where
GISLIB = $(ARCH_LIBDIR)/$(LIB_PREFIX)$(GIS_LIBNAME).$(LIB_SUFFIX) \
$(SOCKLIB) $(INTLLIB)
so if $(SOCKLIB) or $(INTLLIB) where defined as anything, presumably this
wouldn't work either.

I fixed it by sort of swapping round the definitions of $(GPROJLIB) and
$(GPROJDEP); probably this file needs to be re-arranged:
GPROJDEP = $(ARCH_LIBDIR)/$(LIB_PREFIX)$(GPROJ_LIBNAME).$(LIB_SUFFIX)
first and then
GPROJLIB = $(GPROJDEP) $(PROJLIB)
further down in the file. grass/src/CMD/generic/make.mid gives a clue as
to how this should be done properly.

BTW I still can't compile d.where as there is a vsnprintf() somewhere in
libgrass_gis.a according to the error message. I don't use GRASS 5.1 as it
is full of Linux-isms etc. and I can never get it to compile properly on the
Irix system I use most of them (GRASS 5.0 was like this also a year or two
ago but it is much tidier now).

Paul

On Tue, 29 Apr 2003, Bob Covill wrote:

Hello,

I grabbed the latest CVS versios of grass and grass51 this morning and
am having problems building grass51.

I have updated and rebuilt grass50, but grass51 does not want to build.
I get the following error about the PROJ library.

make[2]: *** No rule to make target `-lproj', needed by
`OBJ.i686-pc-linux-gnu/b_w_line.o'. Stop.
make[2]: Leaving directory `/home/covill/GRASS_DIST/grass51/display/d.where'
make[1]: *** [subdirs] Error 1
make[1]: Leaving directory `/home/covill/GRASS_DIST/grass51/display'
make: *** [default] Error 1

If I jump ahead and try and build another PROJ dependant program such as
g.region I get the same error.

The PROJ test passes in configure.

Any idea what the problem is?

--

--
Bob Covill

Tekmap Consulting
P.O. Box 2016
Fall River, N.S.
B2T 1K6
Canada

E-Mail: bcovill@tekmap.ns.ca
Phone: 902-860-1496
Fax: 902-860-1498

Hello Bob

On Tue, 29 Apr 2003, Bob Covill wrote:

Paul,

I am still getting the same error. If I swap the GPROJLIB and GPROJDEP
definitions around I get the following

/home/covill/GRASS_DIST/grass51/dist.i686-pc-linux-gnu/lib/libgrass_gproj.a(get_proj.o):
In function `pj_print_proj_params':
/home/covill/GRASS_DIST/grass51/lib/proj/get_proj.c:374: undefined
reference to `pj_get_def'
/home/covill/GRASS_DIST/grass51/lib/proj/get_proj.c:383: undefined
reference to `pj_get_def'
collect2: ld returned 1 exit status
make[2]: ***
[/home/covill/GRASS_DIST/grass51/dist.i686-pc-linux-gnu/etc/bin/cmd/d.where]
Error 1
make[2]: Leaving directory `/home/covill/GRASS_DIST/grass51/display/d.where'
make[1]: *** [subdirs] Error 1

That looks like a different error to me :slight_smile: Do you think the correct
libproj (the external one) is being linked in? You don't have an old
libproj.a lying around from before it was renamed to libgproj.a or anything
like that? The old GRASS libproj.a didn't contain the pj_get_def()
function; it is only available in the latest versions of PROJ.4. And
libgproj should only be about 50kB in size if you are using the external
PROJ.

Also BTW it wasn't an exact swap of GPROJLIB and GPROJDEP as I'm sure you
noticed. A tidier solution might be something like
GPROJLIBFILE = $(ARCH_LIBDIR)/$(LIB_PREFIX)$(GPROJ_LIBNAME).$(LIB_SUFFIX)
GPROJLIB = $(GPROJLIBFILE) $(PROJLIB)
GPROJDEP = $(GPROJLIBFILE)
which doesn't alter the order of things in the Grass.make file too much
but I don't want to change it before I know why it is set up to use the
full path to the static library like this.

Hope you get it working

Paul

On Tue, Apr 29, 2003 at 04:18:17PM +0100, Paul Kelly wrote:

On Tue, 29 Apr 2003, Markus Neteler wrote:

> right now (before reading this mail) I have submitted the dependencies for
> all LIBs. The next changes I would leave to an expert - as I don't know too
> much about Makefiles. On my Linux boxes it works well, but I have neither
> access to SGI nor Solaris to try there.

I don't see how d.where could compile anywhere the way it currently is (I
presume Bob is using Linux as well?) As I understand it the dependency has

OK, after a clean it also doesn't compile here any more.

to be an actual file or list of files that make can check to see when they
were last modified. The dependencies follow a colon on the makefile. And
underneath that are instructions for compiling the output program.

Before fixing it we have to know why it is done like that, with the full
pathname of the static library. Why not do it like GPROJLIB = -lproj,
GISLIB = -lgis etc. in GRASS 5.0. Neater looking and makes it possible to
use shared libraries.

Probably yes: But -lgrass_gis may be better to avoid conflicts with -ledit
etc. (so -lgrass_edit).

[...]

I will make a start (see below). It can be an occasional series...

make[2]: Entering
directory `/indigo-disk2/grass/grass51/lib/form' cc
-L/indigo-disk2/grass/grass51/dist.mips-sgi-irix6.2/lib
-L/indigo-disk2/grass/doom.ee.qub.ac.uk/lib -o
/indigo-disk2/grass/grass51/dist.mips-sgi-irix6.2/etc/form/form
OBJ.mips-sgi-irix6.2/form.o
/indigo-disk2/grass/grass51/dist.mips-sgi-irix6.2/lib/libgrass_dbmi.a
/indigo-disk2/grass/grass51/dist.mips-sgi-irix6.2/lib/libgrass_gis.a
-L/indigo-disk2/grass/doom.ee.qub.ac.uk/lib -ltk -lm -ltcl -lm \
                         -lm -lz
/indigo-disk2/grass/doom.ee.qub.ac.uk/lib/libsnprintf.a ld: WARNING 84:
/indigo-disk2/grass/doom.ee.qub.ac.uk/lib/libz.a is not used for resolving
any symbol. ld: ERROR 33: Unresolved text symbol "G_setenv2" -- 1st
referenced by
/indigo-disk2/grass/grass51/dist.mips-sgi-irix6.2/lib/libgrass_dbmi.a(connect.o).
ld: ERROR 33: Unresolved text symbol "G__getenv2" -- 1st referenced by
/indigo-disk2/grass/grass51/dist.mips-sgi-irix6.2/lib/libgrass_dbmi.a(connect.o).
ld: INFO 152: Output file removed because of error. make[2]: ***
[/indigo-disk2/grass/grass51/dist.mips-sgi-irix6.2/etc/form/form] Error 1
make[2]: Leaving directory `/indigo-disk2/grass/grass51/lib/form' make[1]:
*** [subdirs] Error 1 make[1]: Leaving directory
`/indigo-disk2/grass/grass51/lib' make: *** [default] Error 1

I have found that
#include "gis.h"

was missing in
./lib/vector/Vlib/field.c
(submitted to CVS). Does this help?

Markus

Paul,

I finally got it to build. I axed all of my external PROJ stuff and grabbed the latest version.

After applying the changes listed below to Grass.make it built cleanly.

Thanks for all of your help.

Paul Kelly wrote:

Hello Bob

On Tue, 29 Apr 2003, Bob Covill wrote:

Paul,

I am still getting the same error. If I swap the GPROJLIB and GPROJDEP
definitions around I get the following

/home/covill/GRASS_DIST/grass51/dist.i686-pc-linux-gnu/lib/libgrass_gproj.a(get_proj.o):
In function `pj_print_proj_params':
/home/covill/GRASS_DIST/grass51/lib/proj/get_proj.c:374: undefined
reference to `pj_get_def'
/home/covill/GRASS_DIST/grass51/lib/proj/get_proj.c:383: undefined
reference to `pj_get_def'
collect2: ld returned 1 exit status
make[2]: ***
[/home/covill/GRASS_DIST/grass51/dist.i686-pc-linux-gnu/etc/bin/cmd/d.where]
Error 1
make[2]: Leaving directory `/home/covill/GRASS_DIST/grass51/display/d.where'
make[1]: *** [subdirs] Error 1

That looks like a different error to me :slight_smile: Do you think the correct
libproj (the external one) is being linked in? You don't have an old
libproj.a lying around from before it was renamed to libgproj.a or anything
like that? The old GRASS libproj.a didn't contain the pj_get_def()
function; it is only available in the latest versions of PROJ.4. And
libgproj should only be about 50kB in size if you are using the external
PROJ.

Also BTW it wasn't an exact swap of GPROJLIB and GPROJDEP as I'm sure you
noticed. A tidier solution might be something like
GPROJLIBFILE = $(ARCH_LIBDIR)/$(LIB_PREFIX)$(GPROJ_LIBNAME).$(LIB_SUFFIX)
GPROJLIB = $(GPROJLIBFILE) $(PROJLIB)
GPROJDEP = $(GPROJLIBFILE)
which doesn't alter the order of things in the Grass.make file too much
but I don't want to change it before I know why it is set up to use the
full path to the static library like this.

Hope you get it working

Paul

--
Bob Covill

Tekmap Consulting
P.O. Box 2016
Fall River, N.S.
B2T 1K6
Canada

E-Mail: bcovill@tekmap.ns.ca
Phone: 902-860-1496
Fax: 902-860-1498

Paul Kelly wrote:

Before fixing it we have to know why it is done like that, with the full
pathname of the static library. Why not do it like GPROJLIB = -lproj,
GISLIB = -lgis etc. in GRASS 5.0. Neater looking and makes it possible to
use shared libraries.

This issue was discussed in more detail in this message:

From: Glynn Clements <glynn.clements@virgin.net>
Subject: Re: [GRASS5] Error building 5.1 CVS head on Solaris 8 sparc <solved>
Date: Mon, 17 Mar 2003 14:46:46 +0000
Message-ID: <15989.57302.700118.276714@cerise.nosuchdomain.co.uk>

Summary: we need separate FOOLIB/DEPFOOLIB variables. Using a single
variable only works for static libraries with no dependencies (or if
you are going to handle all the dependencies in each individual
Makefile, which is the wrong approach).

--
Glynn Clements <glynn.clements@virgin.net>

On Tuesday 29 April 2003 05:18 pm, Paul Kelly wrote:

I will make a start (see below). It can be an occasional series...

make[2]: Entering
directory `/indigo-disk2/grass/grass51/lib/form' cc
-L/indigo-disk2/grass/grass51/dist.mips-sgi-irix6.2/lib
-L/indigo-disk2/grass/doom.ee.qub.ac.uk/lib -o
/indigo-disk2/grass/grass51/dist.mips-sgi-irix6.2/etc/form/form
OBJ.mips-sgi-irix6.2/form.o
/indigo-disk2/grass/grass51/dist.mips-sgi-irix6.2/lib/libgrass_dbmi.a
/indigo-disk2/grass/grass51/dist.mips-sgi-irix6.2/lib/libgrass_gis.a
-L/indigo-disk2/grass/doom.ee.qub.ac.uk/lib -ltk -lm -ltcl -lm \
                         -lm -lz
/indigo-disk2/grass/doom.ee.qub.ac.uk/lib/libsnprintf.a ld: WARNING 84:
/indigo-disk2/grass/doom.ee.qub.ac.uk/lib/libz.a is not used for resolving
any symbol. ld: ERROR 33: Unresolved text symbol "G_setenv2" -- 1st
referenced by
/indigo-disk2/grass/grass51/dist.mips-sgi-irix6.2/lib/libgrass_dbmi.a(conne
ct.o). ld: ERROR 33: Unresolved text symbol "G__getenv2" -- 1st referenced
by
/indigo-disk2/grass/grass51/dist.mips-sgi-irix6.2/lib/libgrass_dbmi.a(conne
ct.o). ld: INFO 152: Output file removed because of error. make[2]: ***
[/indigo-disk2/grass/grass51/dist.mips-sgi-irix6.2/etc/form/form] Error 1
make[2]: Leaving directory `/indigo-disk2/grass/grass51/lib/form' make[1]:
*** [subdirs] Error 1 make[1]: Leaving directory
`/indigo-disk2/grass/grass51/lib' make: *** [default] Error 1

Are there G_setenv2/G__getenv2 realy available in libgrass_gis.a
(nm libgrass_gis.a)?

Radim

On Tuesday 29 April 2003 05:18 pm, Paul Kelly wrote:

I think we need a G_snprintf() and G_vsnprintf() or something like that.
Would it be all right just to copy the code straight from a 3rd party
snprintf implementation to enable this?

I replaced vsnprintf by vfprintf. G_asprintf() seems to be even better
than G_snprintf(). Can I add G_asprintf() suggested by Eric G. Miller
(http://grass.itc.it/pipermail/grass5/2002-May/002936.html) to 5.1?

Nice code is here:
http://www.gnu-darwin.org/sources/4osf1/lib/libc/stdio/asprintf.c
however 'f._file = -1;' is not very portable or yes? I guess
what it means only.
Maybe some other portable equivalent for such buffer exists?

Radim