[HOpenGL] problems compiling hopengl on freebsd

Chris Moline uglydaemon@shaw.ca
Wed, 28 Aug 2002 20:37:29 -0600 (MDT)


On Wed, 28 Aug 2002 09:39:21 +0200, Sven Panne <Sven_Panne@BetaResearch.de> wrote:
> Hmmm, that looks OK to me. Perhaps autoconf couldn't find the include path
> and/or library path for the X11 stuff. Could you send me your config.log,
> config.status and a transcript of your shell session for configure, please?

when you asked me for config.log and config.status i didnt know they existed and so i resolved to have a look at them to see if that helped. i think it might have. i am not sure but ill run it by you to see if it does.

ok. i was looking and i found some lines that made me think that maybe the problem was that some -l flags werent getting specified. they are lines 183 to 202

configure:3710: checking for library containing glEnd
configure:3730: gcc -o conftest -g -O2   -I/usr/X11R6/include  conftest.c  -lSM
/tmp/ccL3PAy0.o: In function `main':
/usr/home/chris/HOpenGL-1.03/configure(.text+0x7): undefined reference to `glEnd
configure:3733: $? = 1
configure: failed program was:
#line 3718 "configure"
#include "confdefs.h"
#include <GL/glut.h>
int
main ()
{
glEnd()
  ;
  return 0;
}
configure:3762: gcc -o conftest -g -O2   -I/usr/X11R6/include  conftest.c -lGL
/usr/X11R6/lib/libGL.so: undefined reference to `pthread_getspecific'
/usr/X11R6/lib/libGL.so: undefined reference to `pthread_key_create'
/usr/X11R6/lib/libGL.so: undefined reference to `pthread_setspecific'

some of those lines have been truncated.

so i tried creating a test.c which looks like this

#include <GL/glut.h>

int main() {
	glEnd();
	printf("hello world!\n");
	return 0;
}

then i tried compiling it with

gcc test.c -I/usr/X11R6/include -lSM -lICE  -L/usr/X11R6/lib -lX11 -lXext -lXmu -lXt -lXi  -lm -pthread -lGL

this compiles with no errors. running ./a.out gives hello world!. so i am thinking it is working now. this leads me to think that perhaps the problem is that -lpthread is not getting specified on the commandline. does this sound plausible?

sincerly,
chris moline