filename | configure |
changeset | 635:76c63aac3590 |
prev | 614:a2d239d4438a |
next | 1066:ddffe9d2b332 |
author | nkeynes |
date | Thu Feb 14 13:54:11 2008 +0000 (14 years ago) |
branch | lxdream-render |
permissions | -rw-r--r-- |
last change | Commit render work in progress. Main changes: * Preliminary OSMesa support * Move the generic gl code out to pvr2/ * Implement scene data structure + reader * Remove the 1/z adjustments |
file | annotate | diff | log | raw |
1.1 --- a/configure Mon Jan 28 02:38:09 2008 +00001.2 +++ b/configure Thu Feb 14 13:54:11 2008 +00001.3 @@ -700,6 +700,8 @@1.4 host_cpu1.5 host_vendor1.6 host_os1.7 +OSMESA_DRIVER_TRUE1.8 +OSMESA_DRIVER_FALSE1.9 PKG_CONFIG1.10 LIBPNG_CFLAGS1.11 LIBPNG_LIBS1.12 @@ -1353,6 +1355,12 @@1.13 --enable-watch Enable watchpoints in the debugger (warning: hurts1.14 performance)1.16 +Optional Packages:1.17 + --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]1.18 + --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)1.19 + --with-osmesa Build with the osmesa GL library (software1.20 + rendering)1.21 +1.22 Some influential environment variables:1.23 CC C compiler command1.24 CFLAGS C compiler flags1.25 @@ -4983,6 +4991,15 @@1.26 fi1.27 fi1.29 +1.30 +# Check whether --with-osmesa was given.1.31 +if test "${with_osmesa+set}" = set; then1.32 + withval=$with_osmesa;1.33 +else1.34 + with_osmesa=no1.35 +fi1.36 +1.37 +1.38 # On IRIX 5.3, sys/types and inttypes.h are conflicting.1.41 @@ -5052,6 +5069,235 @@1.42 done1.45 +if test "x$with_osmesa" != xno; then1.46 +1.47 +1.48 +{ echo "$as_me:$LINENO: checking for OSMesaCreateContext in -lOSMesa" >&51.49 +echo $ECHO_N "checking for OSMesaCreateContext in -lOSMesa... $ECHO_C" >&6; }1.50 +if test "${ac_cv_lib_OSMesa_OSMesaCreateContext+set}" = set; then1.51 + echo $ECHO_N "(cached) $ECHO_C" >&61.52 +else1.53 + ac_check_lib_save_LIBS=$LIBS1.54 +LIBS="-lOSMesa $LIBS"1.55 +cat >conftest.$ac_ext <<_ACEOF1.56 +/* confdefs.h. */1.57 +_ACEOF1.58 +cat confdefs.h >>conftest.$ac_ext1.59 +cat >>conftest.$ac_ext <<_ACEOF1.60 +/* end confdefs.h. */1.61 +1.62 +/* Override any GCC internal prototype to avoid an error.1.63 + Use char because int might match the return type of a GCC1.64 + builtin and then its argument prototype would still apply. */1.65 +#ifdef __cplusplus1.66 +extern "C"1.67 +#endif1.68 +char OSMesaCreateContext ();1.69 +int1.70 +main ()1.71 +{1.72 +return OSMesaCreateContext ();1.73 + ;1.74 + return 0;1.75 +}1.76 +_ACEOF1.77 +rm -f conftest.$ac_objext conftest$ac_exeext1.78 +if { (ac_try="$ac_link"1.79 +case "(($ac_try" in1.80 + *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;1.81 + *) ac_try_echo=$ac_try;;1.82 +esac1.83 +eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&51.84 + (eval "$ac_link") 2>conftest.er11.85 + ac_status=$?1.86 + grep -v '^ *+' conftest.er1 >conftest.err1.87 + rm -f conftest.er11.88 + cat conftest.err >&51.89 + echo "$as_me:$LINENO: \$? = $ac_status" >&51.90 + (exit $ac_status); } && {1.91 + test -z "$ac_c_werror_flag" ||1.92 + test ! -s conftest.err1.93 + } && test -s conftest$ac_exeext &&1.94 + $as_test_x conftest$ac_exeext; then1.95 + ac_cv_lib_OSMesa_OSMesaCreateContext=yes1.96 +else1.97 + echo "$as_me: failed program was:" >&51.98 +sed 's/^/| /' conftest.$ac_ext >&51.99 +1.100 + ac_cv_lib_OSMesa_OSMesaCreateContext=no1.101 +fi1.102 +1.103 +rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \1.104 + conftest$ac_exeext conftest.$ac_ext1.105 +LIBS=$ac_check_lib_save_LIBS1.106 +fi1.107 +{ echo "$as_me:$LINENO: result: $ac_cv_lib_OSMesa_OSMesaCreateContext" >&51.108 +echo "${ECHO_T}$ac_cv_lib_OSMesa_OSMesaCreateContext" >&6; }1.109 +if test $ac_cv_lib_OSMesa_OSMesaCreateContext = yes; then1.110 + cat >>confdefs.h <<_ACEOF1.111 +#define HAVE_LIBOSMESA 11.112 +_ACEOF1.113 +1.114 + LIBS="-lOSMesa $LIBS"1.115 +1.116 +else1.117 + { { echo "$as_me:$LINENO: error: --with-osmesa was given, but OSMesa library could not be found1.118 +See \`config.log' for more details." >&51.119 +echo "$as_me: error: --with-osmesa was given, but OSMesa library could not be found1.120 +See \`config.log' for more details." >&2;}1.121 + { (exit 1); exit 1; }; }1.122 +fi1.123 +1.124 + if test "${ac_cv_header_GL_osmesa_h+set}" = set; then1.125 + { echo "$as_me:$LINENO: checking for GL/osmesa.h" >&51.126 +echo $ECHO_N "checking for GL/osmesa.h... $ECHO_C" >&6; }1.127 +if test "${ac_cv_header_GL_osmesa_h+set}" = set; then1.128 + echo $ECHO_N "(cached) $ECHO_C" >&61.129 +fi1.130 +{ echo "$as_me:$LINENO: result: $ac_cv_header_GL_osmesa_h" >&51.131 +echo "${ECHO_T}$ac_cv_header_GL_osmesa_h" >&6; }1.132 +else1.133 + # Is the header compilable?1.134 +{ echo "$as_me:$LINENO: checking GL/osmesa.h usability" >&51.135 +echo $ECHO_N "checking GL/osmesa.h usability... $ECHO_C" >&6; }1.136 +cat >conftest.$ac_ext <<_ACEOF1.137 +/* confdefs.h. */1.138 +_ACEOF1.139 +cat confdefs.h >>conftest.$ac_ext1.140 +cat >>conftest.$ac_ext <<_ACEOF1.141 +/* end confdefs.h. */1.142 +$ac_includes_default1.143 +#include <GL/osmesa.h>1.144 +_ACEOF1.145 +rm -f conftest.$ac_objext1.146 +if { (ac_try="$ac_compile"1.147 +case "(($ac_try" in1.148 + *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;1.149 + *) ac_try_echo=$ac_try;;1.150 +esac1.151 +eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&51.152 + (eval "$ac_compile") 2>conftest.er11.153 + ac_status=$?1.154 + grep -v '^ *+' conftest.er1 >conftest.err1.155 + rm -f conftest.er11.156 + cat conftest.err >&51.157 + echo "$as_me:$LINENO: \$? = $ac_status" >&51.158 + (exit $ac_status); } && {1.159 + test -z "$ac_c_werror_flag" ||1.160 + test ! -s conftest.err1.161 + } && test -s conftest.$ac_objext; then1.162 + ac_header_compiler=yes1.163 +else1.164 + echo "$as_me: failed program was:" >&51.165 +sed 's/^/| /' conftest.$ac_ext >&51.166 +1.167 + ac_header_compiler=no1.168 +fi1.169 +1.170 +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext1.171 +{ echo "$as_me:$LINENO: result: $ac_header_compiler" >&51.172 +echo "${ECHO_T}$ac_header_compiler" >&6; }1.173 +1.174 +# Is the header present?1.175 +{ echo "$as_me:$LINENO: checking GL/osmesa.h presence" >&51.176 +echo $ECHO_N "checking GL/osmesa.h presence... $ECHO_C" >&6; }1.177 +cat >conftest.$ac_ext <<_ACEOF1.178 +/* confdefs.h. */1.179 +_ACEOF1.180 +cat confdefs.h >>conftest.$ac_ext1.181 +cat >>conftest.$ac_ext <<_ACEOF1.182 +/* end confdefs.h. */1.183 +#include <GL/osmesa.h>1.184 +_ACEOF1.185 +if { (ac_try="$ac_cpp conftest.$ac_ext"1.186 +case "(($ac_try" in1.187 + *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;1.188 + *) ac_try_echo=$ac_try;;1.189 +esac1.190 +eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&51.191 + (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er11.192 + ac_status=$?1.193 + grep -v '^ *+' conftest.er1 >conftest.err1.194 + rm -f conftest.er11.195 + cat conftest.err >&51.196 + echo "$as_me:$LINENO: \$? = $ac_status" >&51.197 + (exit $ac_status); } >/dev/null && {1.198 + test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||1.199 + test ! -s conftest.err1.200 + }; then1.201 + ac_header_preproc=yes1.202 +else1.203 + echo "$as_me: failed program was:" >&51.204 +sed 's/^/| /' conftest.$ac_ext >&51.205 +1.206 + ac_header_preproc=no1.207 +fi1.208 +1.209 +rm -f conftest.err conftest.$ac_ext1.210 +{ echo "$as_me:$LINENO: result: $ac_header_preproc" >&51.211 +echo "${ECHO_T}$ac_header_preproc" >&6; }1.212 +1.213 +# So? What about this header?1.214 +case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in1.215 + yes:no: )1.216 + { echo "$as_me:$LINENO: WARNING: GL/osmesa.h: accepted by the compiler, rejected by the preprocessor!" >&51.217 +echo "$as_me: WARNING: GL/osmesa.h: accepted by the compiler, rejected by the preprocessor!" >&2;}1.218 + { echo "$as_me:$LINENO: WARNING: GL/osmesa.h: proceeding with the compiler's result" >&51.219 +echo "$as_me: WARNING: GL/osmesa.h: proceeding with the compiler's result" >&2;}1.220 + ac_header_preproc=yes1.221 + ;;1.222 + no:yes:* )1.223 + { echo "$as_me:$LINENO: WARNING: GL/osmesa.h: present but cannot be compiled" >&51.224 +echo "$as_me: WARNING: GL/osmesa.h: present but cannot be compiled" >&2;}1.225 + { echo "$as_me:$LINENO: WARNING: GL/osmesa.h: check for missing prerequisite headers?" >&51.226 +echo "$as_me: WARNING: GL/osmesa.h: check for missing prerequisite headers?" >&2;}1.227 + { echo "$as_me:$LINENO: WARNING: GL/osmesa.h: see the Autoconf documentation" >&51.228 +echo "$as_me: WARNING: GL/osmesa.h: see the Autoconf documentation" >&2;}1.229 + { echo "$as_me:$LINENO: WARNING: GL/osmesa.h: section \"Present But Cannot Be Compiled\"" >&51.230 +echo "$as_me: WARNING: GL/osmesa.h: section \"Present But Cannot Be Compiled\"" >&2;}1.231 + { echo "$as_me:$LINENO: WARNING: GL/osmesa.h: proceeding with the preprocessor's result" >&51.232 +echo "$as_me: WARNING: GL/osmesa.h: proceeding with the preprocessor's result" >&2;}1.233 + { echo "$as_me:$LINENO: WARNING: GL/osmesa.h: in the future, the compiler will take precedence" >&51.234 +echo "$as_me: WARNING: GL/osmesa.h: in the future, the compiler will take precedence" >&2;}1.235 +1.236 + ;;1.237 +esac1.238 +{ echo "$as_me:$LINENO: checking for GL/osmesa.h" >&51.239 +echo $ECHO_N "checking for GL/osmesa.h... $ECHO_C" >&6; }1.240 +if test "${ac_cv_header_GL_osmesa_h+set}" = set; then1.241 + echo $ECHO_N "(cached) $ECHO_C" >&61.242 +else1.243 + ac_cv_header_GL_osmesa_h=$ac_header_preproc1.244 +fi1.245 +{ echo "$as_me:$LINENO: result: $ac_cv_header_GL_osmesa_h" >&51.246 +echo "${ECHO_T}$ac_cv_header_GL_osmesa_h" >&6; }1.247 +1.248 +fi1.249 +if test $ac_cv_header_GL_osmesa_h = yes; then1.250 + :1.251 +else1.252 + { { echo "$as_me:$LINENO: error: --with-osmesa was given, but osmesa.h could not be found1.253 +See \`config.log' for more details." >&51.254 +echo "$as_me: error: --with-osmesa was given, but osmesa.h could not be found1.255 +See \`config.log' for more details." >&2;}1.256 + { (exit 1); exit 1; }; }1.257 +fi1.258 +1.259 +1.260 +1.261 +fi1.262 +1.263 +1.264 +1.265 +if test "x$with_osmesa" != xno; then1.266 + OSMESA_DRIVER_TRUE=1.267 + OSMESA_DRIVER_FALSE='#'1.268 +else1.269 + OSMESA_DRIVER_TRUE='#'1.270 + OSMESA_DRIVER_FALSE=1.271 +fi1.272 +1.273 +1.274 if test "${ac_cv_header_Carbon_Carbon_h+set}" = set; then1.275 { echo "$as_me:$LINENO: checking for Carbon/Carbon.h" >&51.276 echo $ECHO_N "checking for Carbon/Carbon.h... $ECHO_C" >&6; }1.277 @@ -5506,6 +5752,7 @@1.280 if test "$APPLE_BUILD" != 'yes'; then1.281 +if test "x$with_osmesa" == "xno"; then1.283 { echo "$as_me:$LINENO: checking for glXQueryVersion in -lGL" >&51.284 echo $ECHO_N "checking for glXQueryVersion in -lGL... $ECHO_C" >&6; }1.285 @@ -5716,6 +5963,7 @@1.288 fi1.289 +fi1.292 pkg_failed=no1.293 @@ -8204,6 +8452,13 @@1.294 Usually this means the macro was only invoked conditionally." >&2;}1.295 { (exit 1); exit 1; }; }1.296 fi1.297 +if test -z "${OSMESA_DRIVER_TRUE}" && test -z "${OSMESA_DRIVER_FALSE}"; then1.298 + { { echo "$as_me:$LINENO: error: conditional \"OSMESA_DRIVER\" was never defined.1.299 +Usually this means the macro was only invoked conditionally." >&51.300 +echo "$as_me: error: conditional \"OSMESA_DRIVER\" was never defined.1.301 +Usually this means the macro was only invoked conditionally." >&2;}1.302 + { (exit 1); exit 1; }; }1.303 +fi1.304 if test -z "${GUI_CARBON_TRUE}" && test -z "${GUI_CARBON_FALSE}"; then1.305 { { echo "$as_me:$LINENO: error: conditional \"GUI_CARBON\" was never defined.1.306 Usually this means the macro was only invoked conditionally." >&51.307 @@ -8890,6 +9145,8 @@1.308 host_cpu!$host_cpu$ac_delim1.309 host_vendor!$host_vendor$ac_delim1.310 host_os!$host_os$ac_delim1.311 +OSMESA_DRIVER_TRUE!$OSMESA_DRIVER_TRUE$ac_delim1.312 +OSMESA_DRIVER_FALSE!$OSMESA_DRIVER_FALSE$ac_delim1.313 PKG_CONFIG!$PKG_CONFIG$ac_delim1.314 LIBPNG_CFLAGS!$LIBPNG_CFLAGS$ac_delim1.315 LIBPNG_LIBS!$LIBPNG_LIBS$ac_delim1.316 @@ -8898,8 +9155,6 @@1.317 GUI_CARBON_TRUE!$GUI_CARBON_TRUE$ac_delim1.318 GUI_CARBON_FALSE!$GUI_CARBON_FALSE$ac_delim1.319 GUI_GTK_TRUE!$GUI_GTK_TRUE$ac_delim1.320 -GUI_GTK_FALSE!$GUI_GTK_FALSE$ac_delim1.321 -BUILD_SH4X86_TRUE!$BUILD_SH4X86_TRUE$ac_delim1.322 _ACEOF1.324 if test `sed -n "s/.*$ac_delim\$/X/p" conf$$subs.sed | grep -c X` = 97; then1.325 @@ -8941,6 +9196,8 @@1.326 ac_delim='%!_!# '1.327 for ac_last_try in false false false false false :; do1.328 cat >conf$$subs.sed <<_ACEOF1.329 +GUI_GTK_FALSE!$GUI_GTK_FALSE$ac_delim1.330 +BUILD_SH4X86_TRUE!$BUILD_SH4X86_TRUE$ac_delim1.331 BUILD_SH4X86_FALSE!$BUILD_SH4X86_FALSE$ac_delim1.332 BUILD_X86_64_TRUE!$BUILD_X86_64_TRUE$ac_delim1.333 BUILD_X86_64_FALSE!$BUILD_X86_64_FALSE$ac_delim1.334 @@ -8983,7 +9240,7 @@1.335 LTLIBOBJS!$LTLIBOBJS$ac_delim1.336 _ACEOF1.338 - if test `sed -n "s/.*$ac_delim\$/X/p" conf$$subs.sed | grep -c X` = 40; then1.339 + if test `sed -n "s/.*$ac_delim\$/X/p" conf$$subs.sed | grep -c X` = 42; then1.340 break1.341 elif $ac_last_try; then1.342 { { echo "$as_me:$LINENO: error: could not make $CONFIG_STATUS" >&5
.