aboutsummaryrefslogtreecommitdiff
path: root/configure
diff options
context:
space:
mode:
authorpbrook <pbrook@c046a42c-6fe2-441c-8c8c-71466251a162>2008-05-29 14:34:11 +0000
committerpbrook <pbrook@c046a42c-6fe2-441c-8c8c-71466251a162>2008-05-29 14:34:11 +0000
commitbd0c5661bfd5d665f3e733b6724406b5a0ca1403 (patch)
tree612dbce3ddce4a2995bcf730ed95a77940a1d458 /configure
parentb5fc909e020fa97891ed92b0f3118efe9d35ecd7 (diff)
NPTL host detection and futex syscall passthrough.
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@4616 c046a42c-6fe2-441c-8c8c-71466251a162
Diffstat (limited to 'configure')
-rwxr-xr-xconfigure29
1 files changed, 29 insertions, 0 deletions
diff --git a/configure b/configure
index b3d7fd8642..8eec675eec 100755
--- a/configure
+++ b/configure
@@ -112,6 +112,7 @@ darwin_user="no"
build_docs="no"
uname_release=""
curses="yes"
+nptl="yes"
# OS specific
targetos=`uname -s`
@@ -331,6 +332,8 @@ for opt do
;;
--disable-curses) curses="no"
;;
+ --disable-nptl) nptl="no"
+ ;;
*) echo "ERROR: unknown option $opt"; show_help="yes"
;;
esac
@@ -424,6 +427,7 @@ echo " --enable-dsound enable DirectSound audio driver"
echo " --disable-brlapi disable BrlAPI"
echo " --disable-vnc-tls disable TLS encryption for VNC server"
echo " --disable-curses disable curses output"
+echo " --disable-nptl disable usermode NPTL support"
echo " --enable-system enable all system emulation targets"
echo " --disable-system disable all system emulation targets"
echo " --enable-linux-user enable all linux usermode emulation targets"
@@ -641,6 +645,24 @@ int main(void) {
}
EOF
+# Check host NPTL support
+cat > $TMPC <<EOF
+#include <sched.h>
+#include <sys/futex.h>
+void foo()
+{
+#if !defined(CLONE_SETTLS) || !defined(FUTEX_WAIT)
+#error bork
+#endif
+}
+EOF
+
+if $cc $ARCH_CFLAGS -c -o $TMPO $TMPC 2> /dev/null ; then
+ :
+else
+ nptl="no"
+fi
+
##########################################
# SDL probe
@@ -839,6 +861,7 @@ echo "brlapi support $brlapi"
echo "Documentation $build_docs"
[ ! -z "$uname_release" ] && \
echo "uname -r $uname_release"
+echo "NPTL support $nptl"
if test $sdl_too_old = "yes"; then
echo "-> Your SDL version is too old - please upgrade to have SDL support"
@@ -1190,6 +1213,7 @@ echo "#include \"../config-host.h\"" >> $config_h
bflt="no"
elfload32="no"
+target_nptl="no"
interp_prefix1=`echo "$interp_prefix" | sed "s/%M/$target_cpu/g"`
echo "#define CONFIG_QEMU_PREFIX \"$interp_prefix1\"" >> $config_h
@@ -1232,6 +1256,7 @@ case "$target_cpu" in
echo "#define TARGET_ARCH \"arm\"" >> $config_h
echo "#define TARGET_ARM 1" >> $config_h
bflt="yes"
+ target_nptl="yes"
;;
cris)
echo "TARGET_ARCH=cris" >> $config_mak
@@ -1379,6 +1404,10 @@ if test "$target_user_only" = "yes" -a "$bflt" = "yes"; then
echo "TARGET_HAS_BFLT=yes" >> $config_mak
echo "#define TARGET_HAS_BFLT 1" >> $config_h
fi
+if test "$target_user_only" = "yes" \
+ -a "$nptl" = "yes" -a "$target_nptl" = "yes"; then
+ echo "#define USE_NPTL 1" >> $config_h
+fi
# 32 bit ELF loader in addition to native 64 bit loader?
if test "$target_user_only" = "yes" -a "$elfload32" = "yes"; then
echo "TARGET_HAS_ELFLOAD32=yes" >> $config_mak