Details Ticket 752


Comment | Reply | Take | Open


Serial Number 752
Subject configure: doesn't add -lGL -lGLw -lGLUT entries in head file (Solaris)
Area bug
Queue grass
Requestors neteler@geog.uni-hannover.de
Owner none
Status resolved
Last User Contact Fri Jun 22 08:16:13 2001 (7 yr ago)
Current Priority 30
Final Priority 70
Due No date assigned
Last Action Fri Jun 22 13:47:28 2001 (7 yr ago)
Created Tue Jun 12 19:35:04 2001 (7 yr ago)

Transaction History Ticket 752


Tue, Jun 12 2001 19:35:04    Request created by mneteler  
Subject: configure: doesn't add -lGL -lGLw -lGLUT entries in head file (Solaris)
Platform: SUN/Solaris2.6
grass downloaded at: CVS Server, Germany
grass binary for platform: I compiled the sources myself
grass sources source: yes, I am using the latest GRASS from CVS
c compiler name: gcc

Hi,

the "configure" doesn't add -lGL -lGLw -lGLUT in head file on Solaris/SUN
while this is working on Linux. Similar was reported for MaxOSX recently.

After adding above entries into head file, everything compiles fine.
The libraries are detected:

[...]
checking GL/gl.h and GL/GLwMDrawA.h...  -I/usr/include -I/usr/local/include and
-I/usr/include
checking for glBegin in -lGL... (cached) no
checking for gluBeginCurve in -lGLU... (cached) no
checking for GLwDrawingAreaMakeCurrent in -lGLw... (cached) no
checking for GLwCreateMDrawingArea in -lGLwM... (cached) no
[...]

I have no idea how to fix this (as it works for Linux). Probably some wrong variable
quoting?

the final head file is looking like this:
OPENGLINC           =  -I/usr/include -I/usr/local/include
OPENGLwINC          =  -I/usr/include
OPENGLLIB           =  -L/usr/lib
OPENGLULIB          = 
LGLWM               = 
OPENGL32            = 

Regards

 Markus
Wed, Jun 13 2001 15:56:35    Mail sent by neteler@geog.uni-hannover.de  
Return-Path <neteler@geog.uni-hannover.de>
Delivered-To grass-bugs@mailman.intevation.de
Date Wed, 13 Jun 2001 15:27:34 +0100
From Markus Neteler <neteler@geog.uni-hannover.de>
To grass5@geog.uni-hannover.de
Cc Request Tracker <grass-bugs@intevation.de>
Subject Re: [GRASS5] [bug #752] (grass) configure: doesn't add -lGL -lGLw -lGLUT entries in head file (Solaris)
Message-ID <20010613152734.A10125@hgeo02.geog.uni-hannover.de>
Mail-Followup-To grass5@geog.uni-hannover.de, Request Tracker <grass-bugs@intevation.de>
References <20010612173505.465B113A00@mailman.intevation.de> <15142.23525.316240.636978@cerise.nosuchdomain.co.uk>
Mime-Version 1.0
Content-Type text/plain; charset=us-ascii
Content-Disposition inline
User-Agent Mutt/1.2.5i
In-Reply-To <15142.23525.316240.636978@cerise.nosuchdomain.co.uk>; from glynn.clements@virgin.net on Tue, Jun 12, 2001 at 07:13:57PM +0100
On Tue, Jun 12, 2001 at 07:13:57PM +0100, Glynn Clements wrote:
> 
> Request Tracker wrote:
> 
> > the "configure" doesn't add -lGL -lGLw -lGLUT in head file on Solaris/SUN
> > while this is working on Linux. Similar was reported for MaxOSX recently.
> > 
> > After adding above entries into head file, everything compiles fine.
> > The libraries are detected:
> > 
> > [...]
> > checking GL/gl.h and GL/GLwMDrawA.h...  -I/usr/include -I/usr/local/include
and  -I/usr/include
> > checking for glBegin in -lGL... (cached) no
> > checking for gluBeginCurve in -lGLU... (cached) no
> > checking for GLwDrawingAreaMakeCurrent in -lGLw... (cached) no
> > checking for GLwCreateMDrawingArea in -lGLwM... (cached) no
> > [...]
> > 
> > I have no idea how to fix this (as it works for Linux). Probably
> > some wrong variable quoting?
> 
> What does config.log say?
> 
> After the line:
> 
> configure:4226: checking for glBegin in -lGL
> 
> there should be the compilation command, along with any error messages
> and the source of the test program. The error message(s) should
> provide some clues as to why it failed.

It seems there is nothing:

configure:4044: checking libpq paths
configure:4059: checking for PQcmdTuples in -lpq 
configure:4183: checking GL/gl.h and GL/GLwMDrawA.h
configure:4226: checking for glBegin in -lGL
configure:4270: checking for gluBeginCurve in -lGLU
configure:4314: checking for GLwDrawingAreaMakeCurrent in -lGLw
configure:4354: checking for GLwCreateMDrawingArea in -lGLwM
configure:4460: checking for sql.h
configure:4496: checking for location of odbc lib
configure:4594: checking for jpeglib.h

(above of that the curses compile thing is present in config.log).

Strange...

 Markus


Wed, Jun 13 2001 23:42:45    Mail sent by glynn.clements@virgin.net  
Return-Path <glynn.clements@virgin.net>
Delivered-To grass-bugs@mailman.intevation.de
From Glynn Clements <glynn.clements@virgin.net>
MIME-Version 1.0
Content-Type text/plain; charset=us-ascii
Content-Transfer-Encoding 7bit
Message-ID <15143.54194.830470.971544@cerise.nosuchdomain.co.uk>
Date Wed, 13 Jun 2001 21:57:22 +0100
To Markus Neteler <neteler@geog.uni-hannover.de>
Cc grass5@geog.uni-hannover.de, Request Tracker <grass-bugs@intevation.de>
Subject Re: [GRASS5] [bug #752] (grass) configure: doesn't add -lGL -lGLw -lGLUT entries in head file (Solaris)
In-Reply-To <20010613152734.A10125@hgeo02.geog.uni-hannover.de>
References <20010612173505.465B113A00@mailman.intevation.de> <15142.23525.316240.636978@cerise.nosuchdomain.co.uk> <20010613152734.A10125@hgeo02.geog.uni-hannover.de>
X-Mailer VM 6.92 under 21.4 (patch 3) "Academic Rigor" XEmacs Lucid
Markus Neteler wrote:

> > > the "configure" doesn't add -lGL -lGLw -lGLUT in head file on Solaris/SUN
> > > while this is working on Linux. Similar was reported for MaxOSX recently.
> > > 
> > > After adding above entries into head file, everything compiles fine.
> > > The libraries are detected:
> > > 
> > > [...]
> > > checking GL/gl.h and GL/GLwMDrawA.h...  -I/usr/include -I/usr/local/include
and  -I/usr/include
> > > checking for glBegin in -lGL... (cached) no
> > > checking for gluBeginCurve in -lGLU... (cached) no
> > > checking for GLwDrawingAreaMakeCurrent in -lGLw... (cached) no
> > > checking for GLwCreateMDrawingArea in -lGLwM... (cached) no
> > > [...]
> > > 
> > > I have no idea how to fix this (as it works for Linux). Probably
> > > some wrong variable quoting?
> > 
> > What does config.log say?
> > 
> > After the line:
> > 
> > configure:4226: checking for glBegin in -lGL
> > 
> > there should be the compilation command, along with any error messages
> > and the source of the test program. The error message(s) should
> > provide some clues as to why it failed.

Of course, this was based upon the (mistaken) assumption that
configure actually performs the test ...

> It seems there is nothing:
> 
> configure:4044: checking libpq paths
> configure:4059: checking for PQcmdTuples in -lpq 
> configure:4183: checking GL/gl.h and GL/GLwMDrawA.h
> configure:4226: checking for glBegin in -lGL
> configure:4270: checking for gluBeginCurve in -lGLU
> configure:4314: checking for GLwDrawingAreaMakeCurrent in -lGLw
> configure:4354: checking for GLwCreateMDrawingArea in -lGLwM
> configure:4460: checking for sql.h
> configure:4496: checking for location of odbc lib
> configure:4594: checking for jpeglib.h
> 
> (above of that the curses compile thing is present in config.log).
> 
> Strange...

Not really; this is a consequence of configure's caching mechanism.

Do "rm config.cache", then re-run configure, then check again.

Better still, add the lines

     define([AC_CACHE_LOAD], )dnl
     define([AC_CACHE_SAVE], )dnl

to the beginning of configure.in (before the AC_INIT), run autoconf,
then commit both configure.in and configure to CVS.

This will completely disable autoconf's caching mechanism (which
basically causes humans to waste countless hours tracking down
problems in order to allow CPUs to spend more time idle; whoever
thought that this was a good idea deserves shooting; actually,
shooting is too good for them).

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


Wed, Jun 20 2001 19:51:09    Mail sent by neteler@geog.uni-hannover.de  
Return-Path <neteler@geog.uni-hannover.de>
Delivered-To grass-bugs@mailman.intevation.de
Date Wed, 20 Jun 2001 19:21:29 +0100
From Markus Neteler <neteler@geog.uni-hannover.de>
To Glynn Clements <glynn.clements@virgin.net>
Cc grass5@geog.uni-hannover.de, Request Tracker <grass-bugs@intevation.de>
Subject Re: [GRASS5] [bug #752] (grass) configure: doesn't add -lGL -lGLw -lGLUT entries in head file (Solaris)
Message-ID <20010620192129.B6059@hgeo02.geog.uni-hannover.de>
Mail-Followup-To Glynn Clements <glynn.clements@virgin.net>, grass5@geog.uni-hannover.de, Request Tracker <grass-bugs@intevation.de>
References <20010612173505.465B113A00@mailman.intevation.de> <15142.23525.316240.636978@cerise.nosuchdomain.co.uk> <20010613152734.A10125@hgeo02.geog.uni-hannover.de> <15143.54194.830470.971544@cerise.nosuchdomain.co.uk>
Mime-Version 1.0
Content-Type text/plain; charset=us-ascii
Content-Disposition inline
User-Agent Mutt/1.2.5i
In-Reply-To <15143.54194.830470.971544@cerise.nosuchdomain.co.uk>; from glynn.clements@virgin.net on Wed, Jun 13, 2001 at 09:57:22PM +0100
On Wed, Jun 13, 2001 at 09:57:22PM +0100, Glynn Clements wrote:
> 
> Markus Neteler wrote:
> 
> > > > the "configure" doesn't add -lGL -lGLw -lGLUT in head file on Solaris/SUN
> > > > while this is working on Linux. Similar was reported for MaxOSX recently.
> > > > 
> > > > After adding above entries into head file, everything compiles fine.
> > > > The libraries are detected:
> > > > 
> > > > [...]
> > > > checking GL/gl.h and GL/GLwMDrawA.h...  -I/usr/include -I/usr/local/include
and  -I/usr/include
> > > > checking for glBegin in -lGL... (cached) no
> > > > checking for gluBeginCurve in -lGLU... (cached) no
> > > > checking for GLwDrawingAreaMakeCurrent in -lGLw... (cached) no
> > > > checking for GLwCreateMDrawingArea in -lGLwM... (cached) no
> > > > [...]
> > > > 
> > > > I have no idea how to fix this (as it works for Linux). Probably
> > > > some wrong variable quoting?
> > > 
> > > What does config.log say?
> > > 
> > > After the line:
> > > 
> > > configure:4226: checking for glBegin in -lGL
> > > 
> > > there should be the compilation command, along with any error messages
> > > and the source of the test program. The error message(s) should
> > > provide some clues as to why it failed.
> 
> Of course, this was based upon the (mistaken) assumption that
> configure actually performs the test ...
> 
> > It seems there is nothing:
> > 
> > configure:4044: checking libpq paths
> > configure:4059: checking for PQcmdTuples in -lpq 
> > configure:4183: checking GL/gl.h and GL/GLwMDrawA.h
> > configure:4226: checking for glBegin in -lGL
> > configure:4270: checking for gluBeginCurve in -lGLU
> > configure:4314: checking for GLwDrawingAreaMakeCurrent in -lGLw
> > configure:4354: checking for GLwCreateMDrawingArea in -lGLwM
> > configure:4460: checking for sql.h
> > configure:4496: checking for location of odbc lib
> > configure:4594: checking for jpeglib.h
> > 
> > (above of that the curses compile thing is present in config.log).
> > 
> > Strange...
> 
> Not really; this is a consequence of configure's caching mechanism.
> 
> Do "rm config.cache", then re-run configure, then check again.
> 
> Better still, add the lines
> 
>      define([AC_CACHE_LOAD], )dnl
>      define([AC_CACHE_SAVE], )dnl
> 
> to the beginning of configure.in (before the AC_INIT), run autoconf,
> then commit both configure.in and configure to CVS.
> 
> This will completely disable autoconf's caching mechanism (which
> basically causes humans to waste countless hours tracking down
> problems in order to allow CPUs to spend more time idle; whoever
> thought that this was a good idea deserves shooting; actually,
> shooting is too good for them).

Glynn,

even if the cache is disabled, the libraries won't be added.
Seems to be a coding problem in configure.

Markus


Thu, Jun 21 2001 15:20:25    Mail sent by glynn.clements@virgin.net  
Return-Path <glynn.clements@virgin.net>
Delivered-To grass-bugs@mailman.intevation.de
From Glynn Clements <glynn.clements@virgin.net>
MIME-Version 1.0
Content-Type text/plain; charset=us-ascii
Content-Transfer-Encoding 7bit
Message-ID <15153.59598.387666.112034@cerise.nosuchdomain.co.uk>
Date Thu, 21 Jun 2001 13:30:06 +0100
To Markus Neteler <neteler@geog.uni-hannover.de>
Cc grass5@geog.uni-hannover.de, Request Tracker <grass-bugs@intevation.de>
Subject Re: [GRASS5] [bug #752] (grass) configure: doesn't add -lGL -lGLw -lGLUT entries in head file (Solaris)
In-Reply-To <20010620192129.B6059@hgeo02.geog.uni-hannover.de>
References <20010612173505.465B113A00@mailman.intevation.de> <15142.23525.316240.636978@cerise.nosuchdomain.co.uk> <20010613152734.A10125@hgeo02.geog.uni-hannover.de> <15143.54194.830470.971544@cerise.nosuchdomain.co.uk> <20010620192129.B6059@hgeo02.geog.uni-hannover.de>
X-Mailer VM 6.92 under 21.4 (patch 3) "Academic Rigor" XEmacs Lucid
Markus Neteler wrote:

> even if the cache is disabled, the libraries won't be added.
> Seems to be a coding problem in configure.

Yes, but if the caching is disabled, config.log will include the error
message(s) from the attempt to compile the test program.

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


Thu, Jun 21 2001 18:21:16    Mail sent by neteler@geog.uni-hannover.de  
Return-Path <neteler@geog.uni-hannover.de>
Delivered-To grass-bugs@mailman.intevation.de
Date Thu, 21 Jun 2001 17:51:38 +0100
From Markus Neteler <neteler@geog.uni-hannover.de>
To Glynn Clements <glynn.clements@virgin.net>
Cc grass5@geog.uni-hannover.de, Request Tracker <grass-bugs@intevation.de>
Subject Re: [GRASS5] [bug #752] (grass) configure: doesn't add -lGL -lGLw -lGLUT entries in head file (Solaris)
Message-ID <20010621175138.A20975@hgeo02.geog.uni-hannover.de>
Mail-Followup-To Glynn Clements <glynn.clements@virgin.net>, grass5@geog.uni-hannover.de, Request Tracker <grass-bugs@intevation.de>
References <20010612173505.465B113A00@mailman.intevation.de> <15142.23525.316240.636978@cerise.nosuchdomain.co.uk> <20010613152734.A10125@hgeo02.geog.uni-hannover.de> <15143.54194.830470.971544@cerise.nosuchdomain.co.uk> <20010620192129.B6059@hgeo02.geog.uni-hannover.de> <15153.59598.387666.112034@cerise.nosuchdomain.co.uk>
Mime-Version 1.0
Content-Type text/plain; charset=us-ascii
Content-Disposition inline
User-Agent Mutt/1.2.5i
In-Reply-To <15153.59598.387666.112034@cerise.nosuchdomain.co.uk>; from glynn.clements@virgin.net on Thu, Jun 21, 2001 at 01:30:06PM +0100
On Thu, Jun 21, 2001 at 01:30:06PM +0100, Glynn Clements wrote:
> 
> Markus Neteler wrote:
> 
> > even if the cache is disabled, the libraries won't be added.
> > Seems to be a coding problem in configure.
> 
> Yes, but if the caching is disabled, config.log will include the error
> message(s) from the attempt to compile the test program.

Well, here we are:

checking host system type... sparc-sun-solaris2.6
...
checking GL/gl.h and GL/GLwMDrawA.h...  -I/usr/include -I/usr/local/include
and  -I/usr/include
checking for glBegin in -lGL... no
checking for gluBeginCurve in -lGLU... no
checking for GLwDrawingAreaMakeCurrent in -lGLw... no
checking for GLwCreateMDrawingArea in -lGLwM... no
...

configure:4176: checking GL/gl.h and GL/GLwMDrawA.h
configure:4219: checking for glBegin in -lGL
configure:4238: gcc -o conftest -g -O2   -lm  -L/usr/lib conftest.c -lGL
1>&5
Undefined                       first referenced
 symbol                             in file
XSynchronize                        /usr/lib/libGL.so
XShmPutImage                        /usr/lib/libGL.so
XDrawPoint                          /usr/lib/libGL.so
...
ld: fatal: Symbol referencing errors. No output written to conftest

configure:4263: checking for gluBeginCurve in -lGLU
configure:4282: gcc -o conftest -g -O2   -lm  -L/usr/lib conftest.c -lGLU
1>&5
Undefined                       first referenced
 symbol                             in file
glFrontFace                         /usr/lib/libGLU.so
glGetFloatv                         /usr/lib/libGLU.so
...
ld: fatal: Symbol referencing errors. No output written to conftest

configure:4307: checking for GLwDrawingAreaMakeCurrent in -lGLw
configure:4326: gcc -o conftest -g -O2   -lm  -L/usr/lib
-L/usr/openwin/lib -R/usr/openwin
Undefined                       first referenced
 symbol                             in file
glXSwapBuffers                      /usr/lib/libGLw.so
glXMakeCurrent                      /usr/lib/libGLw.so
glXChooseVisual                     /usr/lib/libGLw.so
ld: fatal: Symbol referencing errors. No output written to conftest


However, if I manually add the libs in src/CMD/head/head.sparc... the GRASS
modules like NVIZ compile perfectly. So above test fails although it should
be passed (or GRASS does something else).

Markus


Fri, Jun 22 2001 08:16:13    Mail sent by glynn.clements@virgin.net  
Return-Path <glynn.clements@virgin.net>
Delivered-To grass-bugs@mailman.intevation.de
From Glynn Clements <glynn.clements@virgin.net>
MIME-Version 1.0
Content-Type text/plain; charset=us-ascii
Content-Transfer-Encoding 7bit
Message-ID <15154.57216.953799.663580@cerise.nosuchdomain.co.uk>
Date Fri, 22 Jun 2001 07:02:40 +0100
To Markus Neteler <neteler@geog.uni-hannover.de>
Cc grass5@geog.uni-hannover.de, Request Tracker <grass-bugs@intevation.de>
Subject Re: [GRASS5] [bug #752] (grass) configure: doesn't add -lGL -lGLw -lGLUT entries in head file (Solaris)
In-Reply-To <20010621175138.A20975@hgeo02.geog.uni-hannover.de>
References <20010612173505.465B113A00@mailman.intevation.de> <15142.23525.316240.636978@cerise.nosuchdomain.co.uk> <20010613152734.A10125@hgeo02.geog.uni-hannover.de> <15143.54194.830470.971544@cerise.nosuchdomain.co.uk> <20010620192129.B6059@hgeo02.geog.uni-hannover.de> <15153.59598.387666.112034@cerise.nosuchdomain.co.uk> <20010621175138.A20975@hgeo02.geog.uni-hannover.de>
X-Mailer VM 6.92 under 21.4 (patch 3) "Academic Rigor" XEmacs Lucid
Markus Neteler wrote:

> > Markus Neteler wrote:
> > 
> > > even if the cache is disabled, the libraries won't be added.
> > > Seems to be a coding problem in configure.
> > 
> > Yes, but if the caching is disabled, config.log will include the error
> > message(s) from the attempt to compile the test program.
> 
> Well, here we are:

> configure:4219: checking for glBegin in -lGL
> configure:4238: gcc -o conftest -g -O2   -lm  -L/usr/lib conftest.c -lGL
> 1>&5
> Undefined                       first referenced
>  symbol                             in file
> XSynchronize                        /usr/lib/libGL.so
> XShmPutImage                        /usr/lib/libGL.so
> XDrawPoint                          /usr/lib/libGL.so

Try adding $X_LIBS to the LDFLAGS setting for GL and GLU (as is
already done for GLw). Around line 880 in configure.in.

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


Fri, Jun 22 2001 10:12:29    Mail sent by neteler@geog.uni-hannover.de  
Return-Path <neteler@geog.uni-hannover.de>
Delivered-To grass-bugs@mailman.intevation.de
Date Fri, 22 Jun 2001 09:40:29 +0100
From Markus Neteler <neteler@geog.uni-hannover.de>
To Glynn Clements <glynn.clements@virgin.net>
Cc grass5@geog.uni-hannover.de, Request Tracker <grass-bugs@intevation.de>
Subject Re: [GRASS5] [bug #752] (grass) configure: doesn't add -lGL -lGLw -lGLUT entries in head file (Solaris)
Message-ID <20010622094029.A27733@hgeo02.geog.uni-hannover.de>
Mail-Followup-To Glynn Clements <glynn.clements@virgin.net>, grass5@geog.uni-hannover.de, Request Tracker <grass-bugs@intevation.de>
References <20010612173505.465B113A00@mailman.intevation.de> <15142.23525.316240.636978@cerise.nosuchdomain.co.uk> <20010613152734.A10125@hgeo02.geog.uni-hannover.de> <15143.54194.830470.971544@cerise.nosuchdomain.co.uk> <20010620192129.B6059@hgeo02.geog.uni-hannover.de> <15153.59598.387666.112034@cerise.nosuchdomain.co.uk> <20010621175138.A20975@hgeo02.geog.uni-hannover.de> <15154.57216.953799.663580@cerise.nosuchdomain.co.uk>
Mime-Version 1.0
Content-Type text/plain; charset=us-ascii
Content-Disposition inline
User-Agent Mutt/1.2.5i
In-Reply-To <15154.57216.953799.663580@cerise.nosuchdomain.co.uk>; from glynn.clements@virgin.net on Fri, Jun 22, 2001 at 07:02:40AM +0100
Glynn,

you got it! Now the Mesa stuff is detected properly on Solaris/SUN.

Thanks for your assistance,

 Markus


On Fri, Jun 22, 2001 at 07:02:40AM +0100, Glynn Clements wrote:
> 
> Markus Neteler wrote:
> 
> > > Markus Neteler wrote:
> > > 
> > > > even if the cache is disabled, the libraries won't be added.
> > > > Seems to be a coding problem in configure.
> > > 
> > > Yes, but if the caching is disabled, config.log will include the error
> > > message(s) from the attempt to compile the test program.
> > 
> > Well, here we are:
> 
> > configure:4219: checking for glBegin in -lGL
> > configure:4238: gcc -o conftest -g -O2   -lm  -L/usr/lib conftest.c -lGL
> > 1>&5
> > Undefined                       first referenced
> >  symbol                             in file
> > XSynchronize                        /usr/lib/libGL.so
> > XShmPutImage                        /usr/lib/libGL.so
> > XDrawPoint                          /usr/lib/libGL.so
> 
> Try adding $X_LIBS to the LDFLAGS setting for GL and GLU (as is
> already done for GLw). Around line 880 in configure.in.
> 
> -- 
> Glynn Clements <glynn.clements@virgin.net>
> _______________________________________________
> grass5 mailing list
> grass5@geog.uni-hannover.de
> http://www.geog.uni-hannover.de/mailman/listinfo/grass5

-- 
Markus Neteler *  University of Hannover
Institute of Physical Geography and Landscape Ecology
Schneiderberg 50 * D-30167 Hannover * Germany
Tel: ++49-(0)511-762-4494  Fax: -3984


Fri, Jun 22 2001 13:47:28    Status changed to resolved by mneteler  
Comment | Reply | Take | Open

You are currently authenticated as guest.
[Show Configuration] [Login as another user]

Users Guide - Mail Commands - Homepage of RequestTracker 1.0.7 - list any request