filename | configure |
changeset | 656:031d23fa6d0b |
prev | 653:3202ff01d48e |
next | 657:c4143facbfcb |
author | nkeynes |
date | Wed Apr 02 01:46:58 2008 +0000 (15 years ago) |
permissions | -rw-r--r-- |
last change | Add configure-time checks for fbo and shader functions in libGL (so linking doesn't fail on really old libGL implementations) |
file | annotate | diff | log | raw |
1.1 --- a/configure Fri Mar 28 12:32:25 2008 +00001.2 +++ b/configure Wed Apr 02 01:46:58 2008 +00001.3 @@ -5973,6 +5973,274 @@1.4 fi1.5 fi1.7 +{ echo "$as_me:$LINENO: checking for glGenFramebuffersEXT" >&51.8 +echo $ECHO_N "checking for glGenFramebuffersEXT... $ECHO_C" >&6; }1.9 +if test "${ac_cv_func_glGenFramebuffersEXT+set}" = set; then1.10 + echo $ECHO_N "(cached) $ECHO_C" >&61.11 +else1.12 + cat >conftest.$ac_ext <<_ACEOF1.13 +/* confdefs.h. */1.14 +_ACEOF1.15 +cat confdefs.h >>conftest.$ac_ext1.16 +cat >>conftest.$ac_ext <<_ACEOF1.17 +/* end confdefs.h. */1.18 +/* Define glGenFramebuffersEXT to an innocuous variant, in case <limits.h> declares glGenFramebuffersEXT.1.19 + For example, HP-UX 11i <limits.h> declares gettimeofday. */1.20 +#define glGenFramebuffersEXT innocuous_glGenFramebuffersEXT1.21 +1.22 +/* System header to define __stub macros and hopefully few prototypes,1.23 + which can conflict with char glGenFramebuffersEXT (); below.1.24 + Prefer <limits.h> to <assert.h> if __STDC__ is defined, since1.25 + <limits.h> exists even on freestanding compilers. */1.26 +1.27 +#ifdef __STDC__1.28 +# include <limits.h>1.29 +#else1.30 +# include <assert.h>1.31 +#endif1.32 +1.33 +#undef glGenFramebuffersEXT1.34 +1.35 +/* Override any GCC internal prototype to avoid an error.1.36 + Use char because int might match the return type of a GCC1.37 + builtin and then its argument prototype would still apply. */1.38 +#ifdef __cplusplus1.39 +extern "C"1.40 +#endif1.41 +char glGenFramebuffersEXT ();1.42 +/* The GNU C library defines this for functions which it implements1.43 + to always fail with ENOSYS. Some functions are actually named1.44 + something starting with __ and the normal name is an alias. */1.45 +#if defined __stub_glGenFramebuffersEXT || defined __stub___glGenFramebuffersEXT1.46 +choke me1.47 +#endif1.48 +1.49 +int1.50 +main ()1.51 +{1.52 +return glGenFramebuffersEXT ();1.53 + ;1.54 + return 0;1.55 +}1.56 +_ACEOF1.57 +rm -f conftest.$ac_objext conftest$ac_exeext1.58 +if { (ac_try="$ac_link"1.59 +case "(($ac_try" in1.60 + *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;1.61 + *) ac_try_echo=$ac_try;;1.62 +esac1.63 +eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&51.64 + (eval "$ac_link") 2>conftest.er11.65 + ac_status=$?1.66 + grep -v '^ *+' conftest.er1 >conftest.err1.67 + rm -f conftest.er11.68 + cat conftest.err >&51.69 + echo "$as_me:$LINENO: \$? = $ac_status" >&51.70 + (exit $ac_status); } && {1.71 + test -z "$ac_c_werror_flag" ||1.72 + test ! -s conftest.err1.73 + } && test -s conftest$ac_exeext &&1.74 + $as_test_x conftest$ac_exeext; then1.75 + ac_cv_func_glGenFramebuffersEXT=yes1.76 +else1.77 + echo "$as_me: failed program was:" >&51.78 +sed 's/^/| /' conftest.$ac_ext >&51.79 +1.80 + ac_cv_func_glGenFramebuffersEXT=no1.81 +fi1.82 +1.83 +rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \1.84 + conftest$ac_exeext conftest.$ac_ext1.85 +fi1.86 +{ echo "$as_me:$LINENO: result: $ac_cv_func_glGenFramebuffersEXT" >&51.87 +echo "${ECHO_T}$ac_cv_func_glGenFramebuffersEXT" >&6; }1.88 +if test $ac_cv_func_glGenFramebuffersEXT = yes; then1.89 +1.90 +cat >>confdefs.h <<\_ACEOF1.91 +#define HAVE_OPENGL_FBO 11.92 +_ACEOF1.93 +1.94 +fi1.95 +1.96 +{ echo "$as_me:$LINENO: checking for glCreateShader" >&51.97 +echo $ECHO_N "checking for glCreateShader... $ECHO_C" >&6; }1.98 +if test "${ac_cv_func_glCreateShader+set}" = set; then1.99 + echo $ECHO_N "(cached) $ECHO_C" >&61.100 +else1.101 + cat >conftest.$ac_ext <<_ACEOF1.102 +/* confdefs.h. */1.103 +_ACEOF1.104 +cat confdefs.h >>conftest.$ac_ext1.105 +cat >>conftest.$ac_ext <<_ACEOF1.106 +/* end confdefs.h. */1.107 +/* Define glCreateShader to an innocuous variant, in case <limits.h> declares glCreateShader.1.108 + For example, HP-UX 11i <limits.h> declares gettimeofday. */1.109 +#define glCreateShader innocuous_glCreateShader1.110 +1.111 +/* System header to define __stub macros and hopefully few prototypes,1.112 + which can conflict with char glCreateShader (); below.1.113 + Prefer <limits.h> to <assert.h> if __STDC__ is defined, since1.114 + <limits.h> exists even on freestanding compilers. */1.115 +1.116 +#ifdef __STDC__1.117 +# include <limits.h>1.118 +#else1.119 +# include <assert.h>1.120 +#endif1.121 +1.122 +#undef glCreateShader1.123 +1.124 +/* Override any GCC internal prototype to avoid an error.1.125 + Use char because int might match the return type of a GCC1.126 + builtin and then its argument prototype would still apply. */1.127 +#ifdef __cplusplus1.128 +extern "C"1.129 +#endif1.130 +char glCreateShader ();1.131 +/* The GNU C library defines this for functions which it implements1.132 + to always fail with ENOSYS. Some functions are actually named1.133 + something starting with __ and the normal name is an alias. */1.134 +#if defined __stub_glCreateShader || defined __stub___glCreateShader1.135 +choke me1.136 +#endif1.137 +1.138 +int1.139 +main ()1.140 +{1.141 +return glCreateShader ();1.142 + ;1.143 + return 0;1.144 +}1.145 +_ACEOF1.146 +rm -f conftest.$ac_objext conftest$ac_exeext1.147 +if { (ac_try="$ac_link"1.148 +case "(($ac_try" in1.149 + *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;1.150 + *) ac_try_echo=$ac_try;;1.151 +esac1.152 +eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&51.153 + (eval "$ac_link") 2>conftest.er11.154 + ac_status=$?1.155 + grep -v '^ *+' conftest.er1 >conftest.err1.156 + rm -f conftest.er11.157 + cat conftest.err >&51.158 + echo "$as_me:$LINENO: \$? = $ac_status" >&51.159 + (exit $ac_status); } && {1.160 + test -z "$ac_c_werror_flag" ||1.161 + test ! -s conftest.err1.162 + } && test -s conftest$ac_exeext &&1.163 + $as_test_x conftest$ac_exeext; then1.164 + ac_cv_func_glCreateShader=yes1.165 +else1.166 + echo "$as_me: failed program was:" >&51.167 +sed 's/^/| /' conftest.$ac_ext >&51.168 +1.169 + ac_cv_func_glCreateShader=no1.170 +fi1.171 +1.172 +rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \1.173 + conftest$ac_exeext conftest.$ac_ext1.174 +fi1.175 +{ echo "$as_me:$LINENO: result: $ac_cv_func_glCreateShader" >&51.176 +echo "${ECHO_T}$ac_cv_func_glCreateShader" >&6; }1.177 +if test $ac_cv_func_glCreateShader = yes; then1.178 +1.179 +cat >>confdefs.h <<\_ACEOF1.180 +#define HAVE_OPENGL_SHADER 11.181 +_ACEOF1.182 +1.183 +fi1.184 +1.185 +{ echo "$as_me:$LINENO: checking for glCreateShaderObjectARB" >&51.186 +echo $ECHO_N "checking for glCreateShaderObjectARB... $ECHO_C" >&6; }1.187 +if test "${ac_cv_func_glCreateShaderObjectARB+set}" = set; then1.188 + echo $ECHO_N "(cached) $ECHO_C" >&61.189 +else1.190 + cat >conftest.$ac_ext <<_ACEOF1.191 +/* confdefs.h. */1.192 +_ACEOF1.193 +cat confdefs.h >>conftest.$ac_ext1.194 +cat >>conftest.$ac_ext <<_ACEOF1.195 +/* end confdefs.h. */1.196 +/* Define glCreateShaderObjectARB to an innocuous variant, in case <limits.h> declares glCreateShaderObjectARB.1.197 + For example, HP-UX 11i <limits.h> declares gettimeofday. */1.198 +#define glCreateShaderObjectARB innocuous_glCreateShaderObjectARB1.199 +1.200 +/* System header to define __stub macros and hopefully few prototypes,1.201 + which can conflict with char glCreateShaderObjectARB (); below.1.202 + Prefer <limits.h> to <assert.h> if __STDC__ is defined, since1.203 + <limits.h> exists even on freestanding compilers. */1.204 +1.205 +#ifdef __STDC__1.206 +# include <limits.h>1.207 +#else1.208 +# include <assert.h>1.209 +#endif1.210 +1.211 +#undef glCreateShaderObjectARB1.212 +1.213 +/* Override any GCC internal prototype to avoid an error.1.214 + Use char because int might match the return type of a GCC1.215 + builtin and then its argument prototype would still apply. */1.216 +#ifdef __cplusplus1.217 +extern "C"1.218 +#endif1.219 +char glCreateShaderObjectARB ();1.220 +/* The GNU C library defines this for functions which it implements1.221 + to always fail with ENOSYS. Some functions are actually named1.222 + something starting with __ and the normal name is an alias. */1.223 +#if defined __stub_glCreateShaderObjectARB || defined __stub___glCreateShaderObjectARB1.224 +choke me1.225 +#endif1.226 +1.227 +int1.228 +main ()1.229 +{1.230 +return glCreateShaderObjectARB ();1.231 + ;1.232 + return 0;1.233 +}1.234 +_ACEOF1.235 +rm -f conftest.$ac_objext conftest$ac_exeext1.236 +if { (ac_try="$ac_link"1.237 +case "(($ac_try" in1.238 + *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;1.239 + *) ac_try_echo=$ac_try;;1.240 +esac1.241 +eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&51.242 + (eval "$ac_link") 2>conftest.er11.243 + ac_status=$?1.244 + grep -v '^ *+' conftest.er1 >conftest.err1.245 + rm -f conftest.er11.246 + cat conftest.err >&51.247 + echo "$as_me:$LINENO: \$? = $ac_status" >&51.248 + (exit $ac_status); } && {1.249 + test -z "$ac_c_werror_flag" ||1.250 + test ! -s conftest.err1.251 + } && test -s conftest$ac_exeext &&1.252 + $as_test_x conftest$ac_exeext; then1.253 + ac_cv_func_glCreateShaderObjectARB=yes1.254 +else1.255 + echo "$as_me: failed program was:" >&51.256 +sed 's/^/| /' conftest.$ac_ext >&51.257 +1.258 + ac_cv_func_glCreateShaderObjectARB=no1.259 +fi1.260 +1.261 +rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \1.262 + conftest$ac_exeext conftest.$ac_ext1.263 +fi1.264 +{ echo "$as_me:$LINENO: result: $ac_cv_func_glCreateShaderObjectARB" >&51.265 +echo "${ECHO_T}$ac_cv_func_glCreateShaderObjectARB" >&6; }1.266 +if test $ac_cv_func_glCreateShaderObjectARB = yes; then1.267 +1.268 +cat >>confdefs.h <<\_ACEOF1.269 +#define HAVE_OPENGL_SHADER_ARB 11.270 +_ACEOF1.271 +1.272 +fi1.273 +1.274 +1.276 pkg_failed=no1.277 { echo "$as_me:$LINENO: checking for GTK" >&5
.