1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
|
--- configure.in.orig Tue Jan 16 07:26:29 2001
+++ configure.in Thu Jul 4 00:47:06 2002
@@ -43,16 +43,10 @@
dnl General options
dnl --------------------------------------------------------------------------
TR_CPPFLAGS=""
-TR_CFLAGS="-O2 -Wall -fomit-frame-pointer -ffast-math -fexpensive-optimizations"
-TR_CXXFLAGS="-O2 -Wall -fomit-frame-pointer -ffast-math -fexpensive-optimizations"
+TR_CFLAGS=""
+TR_CXXFLAGS=""
TR_LIBS=""
-case "$host" in
-i*86-*-*) TR_CFLAGS="$TR_CFLAGS -malign-loops=2 -malign-jumps=2 -malign-functions=2";
- TR_CXXFLAGS="$TR_CXXFLAGS -malign-loops=2 -malign-jumps=2 -malign-functions=2";;
-alpha*-*-linux-*) TR_CFLAGS="$TR_CFLAGS -mieee";;
-esac
-
AC_ARG_ENABLE(debug, [ --enable-debug Produce an executable with debugging symbols],
[TR_CFLAGS="-g -Wall"; TR_CXXFLAGS="-g -Wall"],
[TR_CPPFLAGS="$TR_CPPFLAGS -DTUXRACER_NO_ASSERT=1"])
@@ -303,6 +297,10 @@
saved_LIBS="$LIBS"
+if test "x$THREAD_LIB" = "x" ; then
+ THREAD_LIB="-lpthread"
+fi
+
AC_DEFUN( CHECK_FOR_GL_LIB, [
AC_MSG_CHECKING([for $GL_LIB_NAME library])
LIBS="$saved_LIBS $TR_LIBS $GL_LDOPTS -l$GL_LIB_NAME"
@@ -313,15 +311,15 @@
TR_LIBS="$TR_LIBS $GL_LDOPTS -l$GL_LIB_NAME"
else
- dnl Try with -lpthread
+ dnl Try with pthreads
AC_MSG_CHECKING([for $GL_LIB_NAME library (with pthreads)])
- LIBS="$saved_LIBS $TR_LIBS $GL_LDOPTS -l$GL_LIB_NAME -lpthread"
+ LIBS="$saved_LIBS $TR_LIBS $GL_LDOPTS -l$GL_LIB_NAME $THREAD_LIB"
AC_TRY_LINK( , , have_GL=yes, have_GL=no)
AC_MSG_RESULT([$have_GL])
if test "x$have_GL" = "xyes" ; then
- TR_LIBS="$TR_LIBS $GL_LDOPTS -l$GL_LIB_NAME -lpthread"
+ TR_LIBS="$TR_LIBS $GL_LDOPTS -l$GL_LIB_NAME $THREAD_LIB"
fi
fi
])
@@ -466,7 +464,7 @@
if test "x$have_glx_h" = "xno" ; then
AC_MSG_ERROR([Cannot find GL/glx.h])
fi
-
+ CFLAGS="$CFLAGS -DGLX_GLXEXT_LEGACY"
dnl Check that glXGetProcAddressARB is defined in glx.h
AC_MSG_CHECKING([whether glx.h defines glXGetProcAddressARB]);
AC_TRY_COMPILE( [#include <GL/glx.h>], [ char *foo = (char*) glXGetProcAddressARB; ],
|