diff -Nru erlang-18.2-dfsg/aclocal.m4 erlang-17.3-dfsg/aclocal.m4
--- erlang-18.2-dfsg/aclocal.m4 2015-12-15 20:10:35.000000000 +0000
+++ erlang-17.3-dfsg/aclocal.m4 2014-09-16 19:10:57.000000000 +0000
@@ -1,19 +1,18 @@
dnl
dnl %CopyrightBegin%
dnl
-dnl Copyright Ericsson AB 1998-2015. All Rights Reserved.
+dnl Copyright Ericsson AB 1998-2013. All Rights Reserved.
dnl
-dnl Licensed under the Apache License, Version 2.0 (the "License");
-dnl you may not use this file except in compliance with the License.
-dnl You may obtain a copy of the License at
-dnl
-dnl http://www.apache.org/licenses/LICENSE-2.0
-dnl
-dnl Unless required by applicable law or agreed to in writing, software
-dnl distributed under the License is distributed on an "AS IS" BASIS,
-dnl WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-dnl See the License for the specific language governing permissions and
-dnl limitations under the License.
+dnl The contents of this file are subject to the Erlang Public License,
+dnl Version 1.1, (the "License"); you may not use this file except in
+dnl compliance with the License. You should have received a copy of the
+dnl Erlang Public License along with this software. If not, it can be
+dnl retrieved online at http://www.erlang.org/.
+dnl
+dnl Software distributed under the License is distributed on an "AS IS"
+dnl basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See
+dnl the License for the specific language governing rights and limitations
+dnl under the License.
dnl
dnl %CopyrightEnd%
dnl
@@ -61,6 +60,7 @@
dnl Cross compilation variables
AC_ARG_VAR(erl_xcomp_bigendian, [big endian system: yes|no (only used when cross compiling)])
AC_ARG_VAR(erl_xcomp_double_middle_endian, [double-middle-endian system: yes|no (only used when cross compiling)])
+AC_ARG_VAR(erl_xcomp_linux_clock_gettime_correction, [clock_gettime() can be used for time correction: yes|no (only used when cross compiling)])
AC_ARG_VAR(erl_xcomp_linux_nptl, [have Native POSIX Thread Library: yes|no (only used when cross compiling)])
AC_ARG_VAR(erl_xcomp_linux_usable_sigusrx, [SIGUSR1 and SIGUSR2 can be used: yes|no (only used when cross compiling)])
AC_ARG_VAR(erl_xcomp_linux_usable_sigaltstack, [have working sigaltstack(): yes|no (only used when cross compiling)])
@@ -142,18 +142,18 @@
AC_MSG_CHECKING(for mixed cygwin or msys and native VC++ environment)
if test "X$host" = "Xwin32" -a "x$GCC" != "xyes"; then
- if test -x /usr/bin/msys-?.0.dll; then
- CFLAGS="-O2"
- MIXED_MSYS=yes
- AC_MSG_RESULT([MSYS and VC])
- MIXED_MSYS_VC=yes
- CPPFLAGS="$CPPFLAGS -DERTS_MIXED_MSYS_VC"
- elif test -x /usr/bin/cygpath; then
+ if test -x /usr/bin/cygpath; then
CFLAGS="-O2"
MIXED_CYGWIN=yes
AC_MSG_RESULT([Cygwin and VC])
MIXED_CYGWIN_VC=yes
CPPFLAGS="$CPPFLAGS -DERTS_MIXED_CYGWIN_VC"
+ elif test -x /usr/bin/msysinfo; then
+ CFLAGS="-O2"
+ MIXED_MSYS=yes
+ AC_MSG_RESULT([MSYS and VC])
+ MIXED_MSYS_VC=yes
+ CPPFLAGS="$CPPFLAGS -DERTS_MIXED_MSYS_VC"
else
AC_MSG_RESULT([undeterminable])
AC_MSG_ERROR(Seems to be mixed windows but not with cygwin, cannot handle this!)
@@ -246,31 +246,31 @@
return 1;
lbl2:
return 2;
-],ac_cv_prog_emu_cc="$CC",ac_cv_prog_emu_cc=no)
+],ac_cv_prog_emu_cc=$CC,ac_cv_prog_emu_cc=no)
-if test "$ac_cv_prog_emu_cc" = no; then
+if test $ac_cv_prog_emu_cc = no; then
for ac_progname in emu_cc.sh gcc-4.2 gcc; do
IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
ac_dummy="$PATH"
for ac_dir in $ac_dummy; do
test -z "$ac_dir" && ac_dir=.
- if test -f "$ac_dir/$ac_progname"; then
- ac_cv_prog_emu_cc="$ac_dir/$ac_progname"
+ if test -f $ac_dir/$ac_progname; then
+ ac_cv_prog_emu_cc=$ac_dir/$ac_progname
break
fi
done
IFS="$ac_save_ifs"
- if test "$ac_cv_prog_emu_cc" != no; then
+ if test $ac_cv_prog_emu_cc != no; then
break
fi
done
fi
-if test "$ac_cv_prog_emu_cc" != no; then
- save_CC="$CC"
+if test $ac_cv_prog_emu_cc != no; then
+ save_CC=$CC
save_CFLAGS=$CFLAGS
save_CPPFLAGS=$CPPFLAGS
- CC="$ac_cv_prog_emu_cc"
+ CC=$ac_cv_prog_emu_cc
CFLAGS=""
CPPFLAGS=""
AC_TRY_COMPILE([],[
@@ -291,17 +291,17 @@
return 1;
lbl2:
return 2;
- ],ac_cv_prog_emu_cc="$CC",ac_cv_prog_emu_cc=no)
+ ],ac_cv_prog_emu_cc=$CC,ac_cv_prog_emu_cc=no)
CC=$save_CC
CFLAGS=$save_CFLAGS
CPPFLAGS=$save_CPPFLAGS
fi
])
-if test "$ac_cv_prog_emu_cc" = no; then
+if test $ac_cv_prog_emu_cc = no; then
AC_DEFINE(NO_JUMP_TABLE,[],[Defined if no found C compiler can handle jump tables])
- EMU_CC="$CC"
+ EMU_CC=$CC
else
- EMU_CC="$ac_cv_prog_emu_cc"
+ EMU_CC=$ac_cv_prog_emu_cc
fi
AC_SUBST(EMU_CC)
])
@@ -559,7 +559,7 @@
AC_DEFUN(LM_SYS_MULTICAST,
[AC_CACHE_CHECK([for multicast support], ac_cv_sys_multicast_support,
-[AC_EGREP_CPP(^yes$,
+[AC_EGREP_CPP(yes,
[#include
#include
#include
@@ -724,250 +724,6 @@
])# AC_C_DOUBLE_MIDDLE_ENDIAN
-AC_DEFUN(ERL_MONOTONIC_CLOCK,
-[
- if test "$3" = "yes"; then
- default_resolution_clock_gettime_monotonic="CLOCK_HIGHRES CLOCK_BOOTTIME CLOCK_MONOTONIC"
- low_resolution_clock_gettime_monotonic="CLOCK_MONOTONIC_COARSE CLOCK_MONOTONIC_FAST"
- high_resolution_clock_gettime_monotonic="CLOCK_MONOTONIC_PRECISE"
- else
- default_resolution_clock_gettime_monotonic="CLOCK_HIGHRES CLOCK_UPTIME CLOCK_MONOTONIC"
- low_resolution_clock_gettime_monotonic="CLOCK_MONOTONIC_COARSE CLOCK_UPTIME_FAST"
- high_resolution_clock_gettime_monotonic="CLOCK_UPTIME_PRECISE"
- fi
-
- case "$1" in
- high_resolution)
- check_msg="high resolution "
- prefer_resolution_clock_gettime_monotonic="$high_resolution_clock_gettime_monotonic"
- ;;
- low_resolution)
- check_msg="low resolution "
- prefer_resolution_clock_gettime_monotonic="$low_resolution_clock_gettime_monotonic"
- ;;
- custom_resolution)
- check_msg="custom resolution "
- prefer_resolution_clock_gettime_monotonic="$2"
- ;;
- *)
- check_msg="custom "
- prefer_resolution_clock_gettime_monotonic="$2"
- ;;
- esac
-
- AC_CACHE_CHECK([for clock_gettime(CLOCK_MONOTONIC_RAW, _)], erl_cv_clock_gettime_monotonic_raw,
- [
- AC_TRY_COMPILE([
-#include
- ],
- [
- struct timespec ts;
- long long result;
- clock_gettime(CLOCK_MONOTONIC_RAW, &ts);
- result = ((long long) ts.tv_sec) * 1000000000LL +
- ((long long) ts.tv_nsec);
- ],
- erl_cv_clock_gettime_monotonic_raw=yes,
- erl_cv_clock_gettime_monotonic_raw=no)
- ])
-
- AC_CACHE_CHECK([for clock_gettime() with ${check_msg}monotonic clock type], erl_cv_clock_gettime_monotonic_$1,
- [
- for clock_type in $prefer_resolution_clock_gettime_monotonic $default_resolution_clock_gettime_monotonic $high_resolution_clock_gettime_monotonic $low_resolution_clock_gettime_monotonic; do
- AC_TRY_COMPILE([
-#include
- ],
- [
- struct timespec ts;
- long long result;
- clock_gettime($clock_type,&ts);
- result = ((long long) ts.tv_sec) * 1000000000LL +
- ((long long) ts.tv_nsec);
- ],
- erl_cv_clock_gettime_monotonic_$1=$clock_type,
- erl_cv_clock_gettime_monotonic_$1=no)
- test $erl_cv_clock_gettime_monotonic_$1 = no || break
- done
- ])
-
- AC_CHECK_FUNCS([clock_getres clock_get_attributes gethrtime])
-
- AC_CACHE_CHECK([for mach clock_get_time() with monotonic clock type], erl_cv_mach_clock_get_time_monotonic,
- [
- AC_TRY_COMPILE([
-#include
-#include
- ],
- [
- kern_return_t res;
- clock_serv_t clk_srv;
- mach_timespec_t time_spec;
-
- host_get_clock_service(mach_host_self(), SYSTEM_CLOCK, &clk_srv);
- res = clock_get_time(clk_srv, &time_spec);
- mach_port_deallocate(mach_task_self(), clk_srv);
- ],
- erl_cv_mach_clock_get_time_monotonic=yes,
- erl_cv_mach_clock_get_time_monotonic=no)
- ])
-
- erl_corrected_monotonic_clock=no
- case $erl_cv_clock_gettime_monotonic_$1-$ac_cv_func_gethrtime-$erl_cv_mach_clock_get_time_monotonic-$host_os in
- *-*-*-win32)
- erl_monotonic_clock_func=WindowsAPI
- ;;
- CLOCK_*-*-*-linux*)
- case $erl_cv_clock_gettime_monotonic_$1-$erl_cv_clock_gettime_monotonic_raw in
- CLOCK_BOOTTIME-yes|CLOCK_MONOTONIC-yes)
- erl_corrected_monotonic_clock=yes
- ;;
- *)
- # We don't trust CLOCK_MONOTONIC to be NTP
- # adjusted on linux systems that do not have
- # CLOCK_MONOTONIC_RAW (although it seems to
- # be...)
- ;;
- esac
- erl_monotonic_clock_func=clock_gettime
- ;;
- no-no-no-linux*)
- erl_monotonic_clock_func=times
- ;;
- CLOCK_*-*-*-*)
- erl_monotonic_clock_func=clock_gettime
- ;;
- no-yes-*-*)
- erl_monotonic_clock_func=gethrtime
- ;;
- no-no-yes-*)
- erl_monotonic_clock_func=mach_clock_get_time
- ;;
- no-no-no-*)
- erl_monotonic_clock_func=none
- ;;
- esac
-
- erl_monotonic_clock_low_resolution=no
- erl_monotonic_clock_lib=
- erl_monotonic_clock_id=
- case $erl_monotonic_clock_func in
- clock_gettime)
- erl_monotonic_clock_id=$erl_cv_clock_gettime_monotonic_$1
- for low_res_id in $low_resolution_clock_gettime_monotonic; do
- if test $erl_monotonic_clock_id = $low_res_id; then
- erl_monotonic_clock_low_resolution=yes
- break
- fi
- done
- AC_CHECK_LIB(rt, clock_gettime, [erl_monotonic_clock_lib="-lrt"])
- ;;
- mach_clock_get_time)
- erl_monotonic_clock_id=SYSTEM_CLOCK
- ;;
- times)
- erl_monotonic_clock_low_resolution=yes
- ;;
- *)
- ;;
- esac
-
-])
-
-AC_DEFUN(ERL_WALL_CLOCK,
-[
- default_resolution_clock_gettime_wall="CLOCK_REALTIME"
- low_resolution_clock_gettime_wall="CLOCK_REALTIME_COARSE CLOCK_REALTIME_FAST"
- high_resolution_clock_gettime_wall="CLOCK_REALTIME_PRECISE"
-
- case "$1" in
- high_resolution)
- check_msg="high resolution "
- prefer_resolution_clock_gettime_wall="$high_resolution_clock_gettime_wall"
- ;;
- low_resolution)
- check_msg="low resolution "
- prefer_resolution_clock_gettime_wall="$low_resolution_clock_gettime_wall"
- ;;
- custom_resolution)
- check_msg="custom resolution "
- prefer_resolution_clock_gettime_wall="$2"
- ;;
- *)
- check_msg=""
- prefer_resolution_clock_gettime_wall=
- ;;
- esac
-
- AC_CACHE_CHECK([for clock_gettime() with ${check_msg}wall clock type], erl_cv_clock_gettime_wall_$1,
- [
- for clock_type in $prefer_resolution_clock_gettime_wall $default_resolution_clock_gettime_wall $high_resolution_clock_gettime_wall $low_resolution_clock_gettime_wall; do
- AC_TRY_COMPILE([
-#include
- ],
- [
- struct timespec ts;
- long long result;
- clock_gettime($clock_type,&ts);
- result = ((long long) ts.tv_sec) * 1000000000LL +
- ((long long) ts.tv_nsec);
- ],
- erl_cv_clock_gettime_wall_$1=$clock_type,
- erl_cv_clock_gettime_wall_$1=no)
- test $erl_cv_clock_gettime_wall_$1 = no || break
- done
- ])
-
- AC_CHECK_FUNCS([clock_getres clock_get_attributes gettimeofday])
-
- AC_CACHE_CHECK([for mach clock_get_time() with wall clock type], erl_cv_mach_clock_get_time_wall,
- [
- AC_TRY_COMPILE([
-#include
-#include
- ],
- [
- kern_return_t res;
- clock_serv_t clk_srv;
- mach_timespec_t time_spec;
-
- host_get_clock_service(mach_host_self(), CALENDAR_CLOCK, &clk_srv);
- res = clock_get_time(clk_srv, &time_spec);
- mach_port_deallocate(mach_task_self(), clk_srv);
- ],
- erl_cv_mach_clock_get_time_wall=yes,
- erl_cv_mach_clock_get_time_wall=no)
- ])
-
- erl_wall_clock_low_resolution=no
- erl_wall_clock_id=
- case $1-$erl_cv_clock_gettime_wall_$1-$erl_cv_mach_clock_get_time_wall-$ac_cv_func_gettimeofday-$host_os in
- *-*-*-*-win32)
- erl_wall_clock_func=WindowsAPI
- erl_wall_clock_low_resolution=yes
- ;;
- high_resolution-no-yes-*-*)
- erl_wall_clock_func=mach_clock_get_time
- erl_wall_clock_id=CALENDAR_CLOCK
- ;;
- *-CLOCK_*-*-*-*)
- erl_wall_clock_func=clock_gettime
- erl_wall_clock_id=$erl_cv_clock_gettime_wall_$1
- for low_res_id in $low_resolution_clock_gettime_wall; do
- if test $erl_wall_clock_id = $low_res_id; then
- erl_wall_clock_low_resolution=yes
- break
- fi
- done
- ;;
- *-no-*-yes-*)
- erl_wall_clock_func=gettimeofday
- ;;
- *)
- erl_wall_clock_func=none
- ;;
- esac
-])
-
dnl ----------------------------------------------------------------------
dnl
dnl LM_CHECK_THR_LIB
@@ -1152,226 +908,24 @@
])
-AC_DEFUN(ETHR_CHK_GCC_ATOMIC_OP__,
-[
- # $1 - atomic_op
-
- for atomic_bit_size in 32 64 128; do
- case $atomic_bit_size in
- 32) gcc_atomic_type="$gcc_atomic_type32";;
- 64) gcc_atomic_type="$gcc_atomic_type64";;
- 128) gcc_atomic_type="$gcc_atomic_type128";;
- esac
- gcc_atomic_lockfree="int x[[(2*__atomic_always_lock_free(sizeof($gcc_atomic_type), 0))-1]]"
- case $1 in
- __sync_add_and_fetch | __sync_fetch_and_and | __sync_fetch_and_or)
- atomic_call="volatile $gcc_atomic_type var; $gcc_atomic_type res = $1(&var, ($gcc_atomic_type) 0);"
- ;;
- __sync_val_compare_and_swap)
- atomic_call="volatile $gcc_atomic_type var; $gcc_atomic_type res = $1(&var, ($gcc_atomic_type) 0, ($gcc_atomic_type) 0);"
- ;;
- __atomic_store_n)
- atomic_call="$gcc_atomic_lockfree; volatile $gcc_atomic_type var; $1(&var, ($gcc_atomic_type) 0, __ATOMIC_RELAXED); $1(&var, ($gcc_atomic_type) 0, __ATOMIC_RELEASE);"
- ;;
- __atomic_load_n)
- atomic_call="$gcc_atomic_lockfree; volatile $gcc_atomic_type var; $gcc_atomic_type res = $1(&var, __ATOMIC_RELAXED); res = $1(&var, __ATOMIC_ACQUIRE);"
- ;;
- __atomic_add_fetch| __atomic_fetch_and | __atomic_fetch_or)
- atomic_call="$gcc_atomic_lockfree; volatile $gcc_atomic_type var; $gcc_atomic_type res = $1(&var, ($gcc_atomic_type) 0, __ATOMIC_RELAXED); res = $1(&var, ($gcc_atomic_type) 0, __ATOMIC_ACQUIRE); res = $1(&var, ($gcc_atomic_type) 0, __ATOMIC_RELEASE);"
- ;;
- __atomic_compare_exchange_n)
- atomic_call="$gcc_atomic_lockfree; volatile $gcc_atomic_type var; $gcc_atomic_type val; int res = $1(&var, &val, ($gcc_atomic_type) 0, 0, __ATOMIC_RELAXED, __ATOMIC_RELAXED); res = $1(&var, &val, ($gcc_atomic_type) 0, 0, __ATOMIC_ACQUIRE, __ATOMIC_ACQUIRE);"
- ;;
- *)
- AC_MSG_ERROR([Internal error: missing implementation for $1])
- ;;
- esac
- eval atomic${atomic_bit_size}_call=\"$atomic_call\"
- done
-
- AC_CACHE_CHECK([for 32-bit $1()], ethr_cv_32bit_$1,
- [
- ethr_cv_32bit_$1=no
- AC_TRY_LINK([], [$atomic32_call], [ethr_cv_32bit_$1=yes])
- ])
- AC_CACHE_CHECK([for 64-bit $1()], ethr_cv_64bit_$1,
- [
- ethr_cv_64bit_$1=no
- AC_TRY_LINK([], [$atomic64_call], [ethr_cv_64bit_$1=yes])
- ])
- AC_CACHE_CHECK([for 128-bit $1()], ethr_cv_128bit_$1,
- [
- ethr_cv_128bit_$1=no
- AC_TRY_LINK([], [$atomic128_call], [ethr_cv_128bit_$1=yes])
- ])
-
- case $ethr_cv_128bit_$1-$ethr_cv_64bit_$1-$ethr_cv_32bit_$1 in
- no-no-no)
- have_atomic_ops=0;;
- no-no-yes)
- have_atomic_ops=4;;
- no-yes-no)
- have_atomic_ops=8;;
- no-yes-yes)
- have_atomic_ops=12;;
- yes-no-no)
- have_atomic_ops=16;;
- yes-no-yes)
- have_atomic_ops=20;;
- yes-yes-no)
- have_atomic_ops=24;;
- yes-yes-yes)
- have_atomic_ops=28;;
- esac
- AC_DEFINE_UNQUOTED([ETHR_HAVE_$1], [$have_atomic_ops], [Define as a bitmask corresponding to the word sizes that $1() can handle on your system])
-])
-
-AC_DEFUN(ETHR_CHK_IF_NOOP,
+AC_DEFUN(ETHR_CHK_SYNC_OP,
[
- ethr_test_filename="chk_if_$1$3_noop_config1test.$$"
- cat > "${ethr_test_filename}.c" < "${ethr_test_filename}.c" </dev/null 2>&1; then
- ethr_$1$3_noop=yes
- else
- ethr_$1$3_noop=no
- fi
- rm -f "${ethr_test_filename}.c" "${ethr_test_filename}1.o" "${ethr_test_filename}2.o"
-])
-
-AC_DEFUN(ETHR_CHK_GCC_ATOMIC_OPS,
-[
- AC_CHECK_SIZEOF(short)
- AC_CHECK_SIZEOF(int)
- AC_CHECK_SIZEOF(long)
- AC_CHECK_SIZEOF(long long)
- AC_CHECK_SIZEOF(__int128_t)
-
- if test "$ac_cv_sizeof_short" = "4"; then
- gcc_atomic_type32="short"
- elif test "$ac_cv_sizeof_int" = "4"; then
- gcc_atomic_type32="int"
- elif test "$ac_cv_sizeof_long" = "4"; then
- gcc_atomic_type32="long"
- else
- AC_MSG_ERROR([No 32-bit type found])
- fi
-
- if test "$ac_cv_sizeof_int" = "8"; then
- gcc_atomic_type64="int"
- elif test "$ac_cv_sizeof_long" = "8"; then
- gcc_atomic_type64="long"
- elif test "$ac_cv_sizeof_long_long" = "8"; then
- gcc_atomic_type64="long long"
- else
- AC_MSG_ERROR([No 64-bit type found])
- fi
-
- if test "$ac_cv_sizeof___int128_t" = "16"; then
- gcc_atomic_type128="__int128_t"
- else
- gcc_atomic_type128="#error "
- fi
- AC_CACHE_CHECK([for a working __sync_synchronize()], ethr_cv___sync_synchronize,
- [
- ethr_cv___sync_synchronize=no
- AC_TRY_LINK([],
- [ __sync_synchronize(); ],
- [ethr_cv___sync_synchronize=yes])
- if test $ethr_cv___sync_synchronize = yes; then
- #
- # Old gcc versions on at least x86 have a buggy
- # __sync_synchronize() which does not emit a
- # memory barrier. We try to detect this by
- # compiling to assembly with and without
- # __sync_synchronize() and compare the results.
- #
- ETHR_CHK_IF_NOOP(__sync_synchronize, [()], [])
- if test $ethr___sync_synchronize_noop = yes; then
- # Got a buggy implementation of
- # __sync_synchronize...
- ethr_cv___sync_synchronize="no; buggy implementation"
- fi
- fi
- ])
-
- if test "$ethr_cv___sync_synchronize" = "yes"; then
- have_sync_synchronize_value="~0"
- else
- have_sync_synchronize_value="0"
- fi
- AC_DEFINE_UNQUOTED([ETHR_HAVE___sync_synchronize], [$have_sync_synchronize_value], [Define as a bitmask corresponding to the word sizes that __sync_synchronize() can handle on your system])
-
- ETHR_CHK_GCC_ATOMIC_OP__(__sync_add_and_fetch)
- ETHR_CHK_GCC_ATOMIC_OP__(__sync_fetch_and_and)
- ETHR_CHK_GCC_ATOMIC_OP__(__sync_fetch_and_or)
- ETHR_CHK_GCC_ATOMIC_OP__(__sync_val_compare_and_swap)
-
- ETHR_CHK_GCC_ATOMIC_OP__(__atomic_store_n)
- ETHR_CHK_GCC_ATOMIC_OP__(__atomic_load_n)
- ETHR_CHK_GCC_ATOMIC_OP__(__atomic_add_fetch)
- ETHR_CHK_GCC_ATOMIC_OP__(__atomic_fetch_and)
- ETHR_CHK_GCC_ATOMIC_OP__(__atomic_fetch_or)
- ETHR_CHK_GCC_ATOMIC_OP__(__atomic_compare_exchange_n)
-
- ethr_have_gcc_native_atomics=no
- ethr_arm_dbm_instr_val=0
- case "$GCC-$host_cpu" in
- yes-arm*)
- AC_CACHE_CHECK([for ARM DMB instruction], ethr_cv_arm_dbm_instr,
- [
- ethr_cv_arm_dbm_instr=no
- AC_TRY_LINK([],
- [
- __asm__ __volatile__("dmb sy" : : : "memory");
- __asm__ __volatile__("dmb st" : : : "memory");
- ],
- [ethr_cv_arm_dbm_instr=yes])
- ])
- if test $ethr_cv_arm_dbm_instr = yes; then
- ethr_arm_dbm_instr_val=1
- test $ethr_cv_64bit___atomic_compare_exchange_n = yes &&
- ethr_have_gcc_native_atomics=yes
- fi;;
- *)
- ;;
+ AC_MSG_CHECKING([for $3-bit $1()])
+ case "$2" in
+ "1") sync_call="$1(&var);";;
+ "2") sync_call="$1(&var, ($4) 0);";;
+ "3") sync_call="$1(&var, ($4) 0, ($4) 0);";;
esac
- AC_DEFINE_UNQUOTED([ETHR_HAVE_GCC_ASM_ARM_DMB_INSTRUCTION], [$ethr_arm_dbm_instr_val], [Define as a boolean indicating whether you have a gcc compatible compiler capable of generating the ARM DMB instruction, and are compiling for an ARM processor with ARM DMB instruction support, or not])
- test $ethr_cv_32bit___sync_val_compare_and_swap = yes &&
- ethr_have_gcc_native_atomics=yes
- test $ethr_cv_64bit___sync_val_compare_and_swap = yes &&
- ethr_have_gcc_native_atomics=yes
- if test "$ethr_cv___sync_synchronize" = "yes"; then
- test $ethr_cv_64bit___atomic_compare_exchange_n = yes &&
- ethr_have_gcc_native_atomics=yes
- test $ethr_cv_32bit___atomic_compare_exchange_n = yes &&
- ethr_have_gcc_native_atomics=yes
- fi
- ethr_have_gcc_atomic_builtins=0
- if test $ethr_have_gcc_native_atomics = yes; then
- ethr_native_atomic_implementation=gcc_sync
- test $ethr_cv_32bit___atomic_compare_exchange_n = yes && ethr_have_gcc_atomic_builtins=1
- test $ethr_cv_64bit___atomic_compare_exchange_n = yes && ethr_have_gcc_atomic_builtins=1
- test $ethr_have_gcc_atomic_builtins = 1 && ethr_native_atomic_implementation=gcc_atomic_sync
- fi
- AC_DEFINE_UNQUOTED([ETHR_HAVE_GCC___ATOMIC_BUILTINS], [$ethr_have_gcc_atomic_builtins], [Define as a boolean indicating whether you have a gcc __atomic builtins or not])
- test $ethr_have_gcc_native_atomics = yes && ethr_have_native_atomics=yes
+ have_sync_op=no
+ AC_TRY_LINK([],
+ [
+ $4 res;
+ volatile $4 var;
+ res = $sync_call
+ ],
+ [have_sync_op=yes])
+ test $have_sync_op = yes && $5
+ AC_MSG_RESULT([$have_sync_op])
])
AC_DEFUN(ETHR_CHK_INTERLOCKED,
@@ -1451,16 +1005,6 @@
test $enable_prefer_gcc_native_ethr_impls = yes &&
AC_DEFINE(ETHR_PREFER_GCC_NATIVE_IMPLS, 1, [Define if you prefer gcc native ethread implementations])
-AC_ARG_ENABLE(trust-gcc-atomic-builtins-memory-barriers,
- AS_HELP_STRING([--enable-trust-gcc-atomic-builtins-memory-barriers],
- [trust gcc atomic builtins memory barriers]),
-[ case "$enableval" in
- yes) trust_gcc_atomic_builtins_mbs=1 ;;
- *) trust_gcc_atomic_builtins_mbs=0 ;;
- esac ], trust_gcc_atomic_builtins_mbs=0)
-
-AC_DEFINE_UNQUOTED(ETHR_TRUST_GCC_ATOMIC_BUILTINS_MEMORY_BARRIERS, [$trust_gcc_atomic_builtins_mbs], [Define as a boolean indicating whether you trust gcc's __atomic_* builtins memory barrier implementations, or not])
-
AC_ARG_WITH(libatomic_ops,
AS_HELP_STRING([--with-libatomic_ops=PATH],
[specify and prefer usage of libatomic_ops in the ethread library]))
@@ -1472,33 +1016,12 @@
LM_CHECK_THR_LIB
ERL_INTERNAL_LIBS
-ERL_MONOTONIC_CLOCK(try_find_pthread_compatible, CLOCK_HIGHRES CLOCK_MONOTONIC, no)
-
-case $erl_monotonic_clock_func in
- clock_gettime)
- AC_DEFINE(ETHR_HAVE_CLOCK_GETTIME_MONOTONIC, [1], [Define if you have a clock_gettime() with a monotonic clock])
- ;;
- mach_clock_get_time)
- AC_DEFINE(ETHR_HAVE_MACH_CLOCK_GET_TIME, [1], [Define if you have a mach clock_get_time() with a monotonic clock])
- ;;
- gethrtime)
- AC_DEFINE(ETHR_HAVE_GETHRTIME, [1], [Define if you have a monotonic gethrtime()])
- ;;
- *)
- ;;
-esac
-
-if test "x$erl_monotonic_clock_id" != "x"; then
- AC_DEFINE_UNQUOTED(ETHR_MONOTONIC_CLOCK_ID, [$erl_monotonic_clock_id], [Define to the monotonic clock id to use])
-fi
-
-ethr_native_atomic_implementation=none
ethr_have_native_atomics=no
ethr_have_native_spinlock=no
ETHR_THR_LIB_BASE="$THR_LIB_NAME"
ETHR_THR_LIB_BASE_TYPE="$THR_LIB_TYPE"
ETHR_DEFS="$THR_DEFS"
-ETHR_X_LIBS="$THR_LIBS $ERTS_INTERNAL_X_LIBS $erl_monotonic_clock_lib"
+ETHR_X_LIBS="$THR_LIBS $ERTS_INTERNAL_X_LIBS"
ETHR_LIBS=
ETHR_LIB_NAME=
@@ -1577,10 +1100,7 @@
ETHR_CHK_INTERLOCKED([_InterlockedCompareExchange128], [4], [__int64], AC_DEFINE_UNQUOTED(ETHR_HAVE__INTERLOCKEDCOMPAREEXCHANGE128, 1, [Define if you have _InterlockedCompareExchange128()]))
fi
- if test "$ethr_have_native_atomics" = "yes"; then
- ethr_native_atomic_implementation=windows
- ethr_have_native_spinlock=yes
- fi
+ test "$ethr_have_native_atomics" = "yes" && ethr_have_native_spinlock=yes
;;
pthread|ose_threads)
@@ -1809,50 +1329,6 @@
AC_DEFINE(ETHR_HAVE_PTHREAD_ATTR_SETGUARDSIZE, 1, \
[Define if you have the pthread_attr_setguardsize function.]))
- if test "x$erl_monotonic_clock_id" != "x"; then
- AC_MSG_CHECKING(whether pthread_cond_timedwait() can use the monotonic clock $erl_monotonic_clock_id for timeout)
- pthread_cond_timedwait_monotonic=no
- AC_TRY_LINK([
- #if defined(ETHR_NEED_NPTL_PTHREAD_H)
- # include
- #elif defined(ETHR_HAVE_MIT_PTHREAD_H)
- # include
- #elif defined(ETHR_HAVE_PTHREAD_H)
- # include
- #endif
- #ifdef ETHR_TIME_WITH_SYS_TIME
- # include
- # include
- #else
- # ifdef ETHR_HAVE_SYS_TIME_H
- # include
- # else
- # include
- # endif
- #endif
- #if defined(ETHR_HAVE_MACH_CLOCK_GET_TIME)
- # include
- # include
- #endif
- ],
- [
- int res;
- pthread_condattr_t attr;
- pthread_cond_t cond;
- struct timespec cond_timeout;
- pthread_mutex_t mutex;
- res = pthread_condattr_init(&attr);
- res = pthread_condattr_setclock(&attr, ETHR_MONOTONIC_CLOCK_ID);
- res = pthread_cond_init(&cond, &attr);
- res = pthread_cond_timedwait(&cond, &mutex, &cond_timeout);
- ],
- [pthread_cond_timedwait_monotonic=yes])
- AC_MSG_RESULT([$pthread_cond_timedwait_monotonic])
- if test $pthread_cond_timedwait_monotonic = yes; then
- AC_DEFINE(ETHR_HAVE_PTHREAD_COND_TIMEDWAIT_MONOTONIC, [1], [Define if pthread_cond_timedwait() can be used with a monotonic clock])
- fi
- fi
-
linux_futex=no
AC_MSG_CHECKING([for Linux futexes])
AC_TRY_LINK([
@@ -1873,62 +1349,56 @@
AC_MSG_RESULT([$linux_futex])
test $linux_futex = yes && AC_DEFINE(ETHR_HAVE_LINUX_FUTEX, 1, [Define if you have a linux futex implementation.])
- pthread_setname=no
- AC_MSG_CHECKING([for pthread_setname_np])
- old_CFLAGS=$CFLAGS
- CFLAGS="$CFLAGS -Werror"
- AC_TRY_LINK([#define __USE_GNU
- #include ],
- [pthread_setname_np(pthread_self(), "name");],
- pthread_setname=linux)
- AC_TRY_LINK([#define __USE_GNU
- #include ],
- [pthread_set_name_np(pthread_self(), "name");],
- pthread_setname=bsd)
- AC_TRY_LINK([#define _DARWIN_C_SOURCE
- #include ],
- [pthread_setname_np("name");],
- pthread_setname=darwin)
- AC_MSG_RESULT([$pthread_setname])
- case $pthread_setname in
- linux) AC_DEFINE(ETHR_HAVE_PTHREAD_SETNAME_NP_2, 1,
- [Define if you have linux style pthread_setname_np]);;
- bsd) AC_DEFINE(ETHR_HAVE_PTHREAD_SET_NAME_NP_2, 1,
- [Define if you have bsd style pthread_set_name_np]);;
- darwin) AC_DEFINE(ETHR_HAVE_PTHREAD_SETNAME_NP_1, 1,
- [Define if you have darwin style pthread_setname_np]);;
- *) ;;
- esac
+ fi
- pthread_getname=no
- AC_MSG_CHECKING([for pthread_getname_np])
- AC_TRY_LINK([#define __USE_GNU
- #define _DARWIN_C_SOURCE
- #include ],
- [char buff[256]; pthread_getname_np(pthread_self(), buff, 256);],
- pthread_getname=linux)
- AC_TRY_LINK([#define __USE_GNU
- #define _DARWIN_C_SOURCE
- #include ],
- [char buff[256]; pthread_getname_np(pthread_self(), buff);],
- pthread_getname=ibm)
- AC_MSG_RESULT([$pthread_getname])
- case $pthread_getname in
- linux) AC_DEFINE(ETHR_HAVE_PTHREAD_GETNAME_NP_3, 1,
- [Define if you have linux style pthread_getname_np]);;
- ibm) AC_DEFINE(ETHR_HAVE_PTHREAD_GETNAME_NP_2, 1,
- [Define if you have ibm style pthread_getname_np]);;
- *) ;;
- esac
- CFLAGS=$old_CFLAGS
+ AC_CHECK_SIZEOF(int)
+ AC_CHECK_SIZEOF(long)
+ AC_CHECK_SIZEOF(long long)
+ AC_CHECK_SIZEOF(__int128_t)
+
+ if test "$ac_cv_sizeof_int" = "4"; then
+ int32="int"
+ elif test "$ac_cv_sizeof_long" = "4"; then
+ int32="long"
+ elif test "$ac_cv_sizeof_long_long" = "4"; then
+ int32="long long"
+ else
+ AC_MSG_ERROR([No 32-bit type found])
+ fi
- fi ## test "x$THR_LIB_NAME" = "xpthread"
+ if test "$ac_cv_sizeof_int" = "8"; then
+ int64="int"
+ elif test "$ac_cv_sizeof_long" = "8"; then
+ int64="long"
+ elif test "$ac_cv_sizeof_long_long" = "8"; then
+ int64="long long"
+ else
+ AC_MSG_ERROR([No 64-bit type found])
+ fi
+
+ int128=no
+ if test "$ac_cv_sizeof___int128_t" = "16"; then
+ int128="__int128_t"
+ fi
if test "X$disable_native_ethr_impls" = "Xyes"; then
ethr_have_native_atomics=no
else
+ ETHR_CHK_SYNC_OP([__sync_val_compare_and_swap], [3], [32], [$int32], AC_DEFINE(ETHR_HAVE___SYNC_VAL_COMPARE_AND_SWAP32, 1, [Define if you have __sync_val_compare_and_swap() for 32-bit integers]))
+ test "$have_sync_op" = "yes" && ethr_have_native_atomics=yes
+ ETHR_CHK_SYNC_OP([__sync_add_and_fetch], [2], [32], [$int32], AC_DEFINE(ETHR_HAVE___SYNC_ADD_AND_FETCH32, 1, [Define if you have __sync_add_and_fetch() for 32-bit integers]))
+ ETHR_CHK_SYNC_OP([__sync_fetch_and_and], [2], [32], [$int32], AC_DEFINE(ETHR_HAVE___SYNC_FETCH_AND_AND32, 1, [Define if you have __sync_fetch_and_and() for 32-bit integers]))
+ ETHR_CHK_SYNC_OP([__sync_fetch_and_or], [2], [32], [$int32], AC_DEFINE(ETHR_HAVE___SYNC_FETCH_AND_OR32, 1, [Define if you have __sync_fetch_and_or() for 32-bit integers]))
+
+ ETHR_CHK_SYNC_OP([__sync_val_compare_and_swap], [3], [64], [$int64], AC_DEFINE(ETHR_HAVE___SYNC_VAL_COMPARE_AND_SWAP64, 1, [Define if you have __sync_val_compare_and_swap() for 64-bit integers]))
+ test "$have_sync_op" = "yes" && ethr_have_native_atomics=yes
+ ETHR_CHK_SYNC_OP([__sync_add_and_fetch], [2], [64], [$int64], AC_DEFINE(ETHR_HAVE___SYNC_ADD_AND_FETCH64, 1, [Define if you have __sync_add_and_fetch() for 64-bit integers]))
+ ETHR_CHK_SYNC_OP([__sync_fetch_and_and], [2], [64], [$int64], AC_DEFINE(ETHR_HAVE___SYNC_FETCH_AND_AND64, 1, [Define if you have __sync_fetch_and_and() for 64-bit integers]))
+ ETHR_CHK_SYNC_OP([__sync_fetch_and_or], [2], [64], [$int64], AC_DEFINE(ETHR_HAVE___SYNC_FETCH_AND_OR64, 1, [Define if you have __sync_fetch_and_or() for 64-bit integers]))
- ETHR_CHK_GCC_ATOMIC_OPS([])
+ if test $int128 != no; then
+ ETHR_CHK_SYNC_OP([__sync_val_compare_and_swap], [3], [128], [$int128], AC_DEFINE(ETHR_HAVE___SYNC_VAL_COMPARE_AND_SWAP128, 1, [Define if you have __sync_val_compare_and_swap() for 128-bit integers]))
+ fi
AC_MSG_CHECKING([for a usable libatomic_ops implementation])
case "x$with_libatomic_ops" in
@@ -1951,34 +1421,11 @@
int z;
AO_nop_full();
-#if defined(AO_HAVE_store)
AO_store(&x, (AO_t) 0);
-#elif defined(AO_HAVE_store_release)
- AO_store_release(&x, (AO_t) 0);
-#else
-#error No store
-#endif
-#if defined(AO_HAVE_load)
z = AO_load(&x);
-#elif defined(AO_HAVE_load_acquire)
- z = AO_load_acquire(&x);
-#else
-#error No load
-#endif
-#if defined(AO_HAVE_compare_and_swap_full)
z = AO_compare_and_swap_full(&x, (AO_t) 0, (AO_t) 1);
-#elif defined(AO_HAVE_compare_and_swap_release)
- z = AO_compare_and_swap_release(&x, (AO_t) 0, (AO_t) 1);
-#elif defined(AO_HAVE_compare_and_swap_acquire)
- z = AO_compare_and_swap_acquire(&x, (AO_t) 0, (AO_t) 1);
-#elif defined(AO_HAVE_compare_and_swap)
- z = AO_compare_and_swap(&x, (AO_t) 0, (AO_t) 1);
-#else
-#error No compare_and_swap
-#endif
],
[ethr_have_native_atomics=yes
- ethr_native_atomic_implementation=libatomic_ops
ethr_have_libatomic_ops=yes])
AC_MSG_RESULT([$ethr_have_libatomic_ops])
if test $ethr_have_libatomic_ops = yes; then
@@ -2010,19 +1457,15 @@
*)
AC_MSG_ERROR([Unsupported Sparc memory order: $with_sparc_memory_order]);;
esac
- ethr_native_atomic_implementation=ethread
ethr_have_native_atomics=yes;;
i86pc | i*86 | x86_64 | amd64)
if test "$enable_x86_out_of_order" = "yes"; then
AC_DEFINE(ETHR_X86_OUT_OF_ORDER, 1, [Define if x86/x86_64 out of order instructions should be synchronized])
fi
- ethr_native_atomic_implementation=ethread
ethr_have_native_atomics=yes;;
macppc | ppc | powerpc | "Power Macintosh")
- ethr_native_atomic_implementation=ethread
ethr_have_native_atomics=yes;;
tile)
- ethr_native_atomic_implementation=ethread
ethr_have_native_atomics=yes;;
*)
;;
@@ -2195,233 +1638,109 @@
])
+
dnl ----------------------------------------------------------------------
dnl
dnl ERL_TIME_CORRECTION
dnl
-dnl Check for primitives that can be used for implementing
-dnl erts_os_monotonic_time() and erts_os_system_time()
+dnl In the presence of a high resolution realtime timer Erlang can adapt
+dnl its view of time relative to this timer. On solaris such a timer is
+dnl available with the syscall gethrtime(). On other OS's a fallback
+dnl solution using times() is implemented. (However on e.g. FreeBSD times()
+dnl is implemented using gettimeofday so it doesn't make much sense to
+dnl use it there...) On second thought, it seems to be safer to do it the
+dnl other way around. I.e. only use times() on OS's where we know it will
+dnl work...
dnl
AC_DEFUN(ERL_TIME_CORRECTION,
-[
-
-AC_ARG_WITH(clock-resolution,
-AS_HELP_STRING([--with-clock-resolution=high|low|default],
- [specify wanted clock resolution]))
-
-AC_ARG_WITH(clock-gettime-realtime-id,
-AS_HELP_STRING([--with-clock-gettime-realtime-id=CLOCKID],
- [specify clock id to use with clock_gettime() for realtime time)]))
-
-AC_ARG_WITH(clock-gettime-monotonic-id,
-AS_HELP_STRING([--with-clock-gettime-monotonic-id=CLOCKID],
- [specify clock id to use with clock_gettime() for monotonic time)]))
-
-AC_ARG_ENABLE(prefer-elapsed-monotonic-time-during-suspend,
-AS_HELP_STRING([--enable-prefer-elapsed-monotonic-time-during-suspend],
- [Prefer an OS monotonic time source with elapsed time during suspend])
-AS_HELP_STRING([--disable-prefer-elapsed-monotonic-time-during-suspend],
- [Do not prefer an OS monotonic time source with elapsed time during suspend]),
-[ case "$enableval" in
- yes) prefer_elapsed_monotonic_time_during_suspend=yes ;;
- *) prefer_elapsed_monotonic_time_during_suspend=no ;;
- esac ], prefer_elapsed_monotonic_time_during_suspend=no)
-
-AC_ARG_ENABLE(gettimeofday-as-os-system-time,
- AS_HELP_STRING([--enable-gettimeofday-as-os-system-time],
- [Force usage of gettimeofday() for OS system time]),
-[ case "$enableval" in
- yes) force_gettimeofday_os_system_time=yes ;;
- *) force_gettimeofday_os_system_time=no ;;
- esac ], force_gettimeofday_os_system_time=no)
-
-case "$with_clock_resolution" in
- ""|no|yes)
- with_clock_resolution=default;;
- high|low|default)
- ;;
- *)
- AC_MSG_ERROR([Invalid wanted clock resolution: $with_clock_resolution])
- ;;
-esac
-
-if test "$force_gettimeofday_os_system_time" = "yes"; then
-
- AC_CHECK_FUNCS([gettimeofday])
- if test "$ac_cv_func_gettimeofday" = "yes"; then
- AC_DEFINE(OS_SYSTEM_TIME_GETTIMEOFDAY, [1], [Define if you want to implement erts_os_system_time() using gettimeofday()])
- else
- AC_MSG_ERROR([No gettimeofday() available])
- fi
-
-else # $force_gettimeofday_os_system_time != yes
-
-case "$with_clock_gettime_realtime_id" in
- ""|no)
- with_clock_gettime_realtime_id=no
- ;;
- CLOCK_*CPUTIME*)
- AC_MSG_ERROR([Invalid clock_gettime() realtime clock id: Refusing to use the cputime clock id $with_clock_gettime_realtime_id as realtime clock id])
- ;;
- CLOCK_MONOTONIC*|CLOCK_BOOTTIME*|CLOCK_UPTIME*|CLOCK_HIGHRES*)
- AC_MSG_ERROR([Invalid clock_gettime() realtime clock id: Refusing to use the monotonic clock id $with_clock_gettime_realtime_id as realtime clock id])
- ;;
- CLOCK_*)
- ;;
- *)
- AC_MSG_ERROR([Invalid clock_gettime() clock id: $with_clock_gettime_realtime_id])
- ;;
-esac
-
-case "$with_clock_resolution-$with_clock_gettime_realtime_id" in
- high-no)
- ERL_WALL_CLOCK(high_resolution);;
- low-no)
- ERL_WALL_CLOCK(low_resolution);;
- default-no)
- ERL_WALL_CLOCK(default_resolution);;
- *)
- ERL_WALL_CLOCK(custom_resolution, $with_clock_gettime_realtime_id);;
-esac
-
-case "$erl_wall_clock_func-$erl_wall_clock_id-$with_clock_gettime_realtime_id" in
- *-*-no)
- ;;
- clock_gettime-$with_clock_gettime_realtime_id-$with_clock_gettime_realtime_id)
- ;;
- *)
- AC_MSG_ERROR([$with_clock_gettime_realtime_id as clock id to clock_gettime() doesn't compile])
- ;;
-esac
-
-case $erl_wall_clock_func in
- none)
- AC_MSG_ERROR([No wall clock source found])
- ;;
- mach_clock_get_time)
- AC_DEFINE(OS_SYSTEM_TIME_USING_MACH_CLOCK_GET_TIME, [1], [Define if you want to implement erts_os_system_time() using mach clock_get_time()])
- ;;
- clock_gettime)
- AC_DEFINE(OS_SYSTEM_TIME_USING_CLOCK_GETTIME, [1], [Define if you want to implement erts_os_system_time() using clock_gettime()])
- ;;
- gettimeofday)
- AC_DEFINE(OS_SYSTEM_TIME_GETTIMEOFDAY, [1], [Define if you want to implement erts_os_system_time() using gettimeofday()])
- ;;
- *)
- ;;
-esac
-
-if test "x$erl_wall_clock_id" != "x"; then
- AC_DEFINE_UNQUOTED(WALL_CLOCK_ID_STR, ["$erl_wall_clock_id"], [Define as a string of wall clock id to use])
- AC_DEFINE_UNQUOTED(WALL_CLOCK_ID, [$erl_wall_clock_id], [Define to wall clock id to use])
-fi
-
-fi # $force_gettimeofday_os_system_time != yes
-
-case "$with_clock_gettime_monotonic_id" in
- ""|no)
- with_clock_gettime_monotonic_id=no
- ;;
- CLOCK_*CPUTIME*)
- AC_MSG_ERROR([Invalid clock_gettime() monotonic clock id: Refusing to use the cputime clock id $with_clock_gettime_monotonic_id as monotonic clock id])
- ;;
- CLOCK_REALTIME*|CLOCK_TAI*)
- AC_MSG_ERROR([Invalid clock_gettime() monotonic clock id: Refusing to use the realtime clock id $with_clock_gettime_monotonic_id as monotonic clock id])
- ;;
- CLOCK_*)
- ;;
- *)
- AC_MSG_ERROR([Invalid clock_gettime() clock id: $with_clock_gettime_monotonic_id])
- ;;
-esac
-
-case "$with_clock_resolution-$with_clock_gettime_monotonic_id" in
- high-no)
- ERL_MONOTONIC_CLOCK(high_resolution, undefined, $prefer_elapsed_monotonic_time_during_suspend);;
- low-no)
- ERL_MONOTONIC_CLOCK(low_resolution, undefined, $prefer_elapsed_monotonic_time_during_suspend);;
- default-no)
- ERL_MONOTONIC_CLOCK(default_resolution, undefined, $prefer_elapsed_monotonic_time_during_suspend);;
- *)
- ERL_MONOTONIC_CLOCK(custom_resolution, $with_clock_gettime_monotonic_id, $prefer_elapsed_monotonic_time_during_suspend);;
-esac
-
-case "$erl_monotonic_clock_func-$erl_monotonic_clock_id-$with_clock_gettime_monotonic_id" in
- *-*-no)
- ;;
- clock_gettime-$with_clock_gettime_monotonic_id-$with_clock_gettime_monotonic_id)
- ;;
- *)
- AC_MSG_ERROR([$with_clock_gettime_monotonic_id as clock id to clock_gettime() doesn't compile])
- ;;
-esac
-
-case $erl_monotonic_clock_func in
- times)
- AC_DEFINE(OS_MONOTONIC_TIME_USING_TIMES, [1], [Define if you want to implement erts_os_monotonic_time() using times()])
- ;;
- mach_clock_get_time)
- AC_DEFINE(OS_MONOTONIC_TIME_USING_MACH_CLOCK_GET_TIME, [1], [Define if you want to implement erts_os_monotonic_time() using mach clock_get_time()])
- ;;
- clock_gettime)
- AC_DEFINE(OS_MONOTONIC_TIME_USING_CLOCK_GETTIME, [1], [Define if you want to implement erts_os_monotonic_time() using clock_gettime()])
- ;;
- gethrtime)
- AC_DEFINE(OS_MONOTONIC_TIME_USING_GETHRTIME, [1], [Define if you want to implement erts_os_monotonic_time() using gethrtime()])
- ;;
- *)
- ;;
-esac
-
-if test $erl_corrected_monotonic_clock = yes; then
- AC_DEFINE(ERTS_HAVE_CORRECTED_OS_MONOTONIC_TIME, [1], [Define if OS monotonic clock is corrected])
-fi
-
-if test $erl_monotonic_clock_low_resolution = yes; then
- AC_DEFINE(ERTS_HAVE_LOW_RESOLUTION_OS_MONOTONIC_LOW, [1], [Define if you have a low resolution OS monotonic clock])
-fi
-
-xrtlib="$erl_monotonic_clock_lib"
-if test "x$erl_monotonic_clock_id" != "x"; then
- AC_DEFINE_UNQUOTED(MONOTONIC_CLOCK_ID_STR, ["$erl_monotonic_clock_id"], [Define as a string of monotonic clock id to use])
- AC_DEFINE_UNQUOTED(MONOTONIC_CLOCK_ID, [$erl_monotonic_clock_id], [Define to monotonic clock id to use])
+[if test x$ac_cv_func_gethrtime = x; then
+ AC_CHECK_FUNC(gethrtime)
fi
-
-if test $erl_cv_clock_gettime_monotonic_raw = yes; then
- AC_DEFINE(HAVE_CLOCK_GETTIME_MONOTONIC_RAW, [1], [Define if you have clock_gettime(CLOCK_MONOTONIC_RAW, _)])
+if test x$clock_gettime_correction = xunknown; then
+ AC_TRY_COMPILE([#include ],
+ [struct timespec ts;
+ long long result;
+ clock_gettime(CLOCK_MONOTONIC,&ts);
+ result = ((long long) ts.tv_sec) * 1000000000LL +
+ ((long long) ts.tv_nsec);],
+ clock_gettime_compiles=yes,
+ clock_gettime_compiles=no)
+else
+ clock_gettime_compiles=no
fi
+
-ERL_MONOTONIC_CLOCK(high_resolution, undefined, no)
+AC_CACHE_CHECK([how to correct for time adjustments], erl_cv_time_correction,
+[
+case $clock_gettime_correction in
+ yes)
+ erl_cv_time_correction=clock_gettime;;
+ no|unknown)
+ case $ac_cv_func_gethrtime in
+ yes)
+ erl_cv_time_correction=hrtime ;;
+ no)
+ case $host_os in
+ linux*)
+ case $clock_gettime_correction in
+ unknown)
+ if test x$clock_gettime_compiles = xyes; then
+ if test X$cross_compiling != Xyes; then
+ linux_kernel_vsn_=`uname -r`
+ case $linux_kernel_vsn_ in
+ [[0-1]].*|2.[[0-5]]|2.[[0-5]].*)
+ erl_cv_time_correction=times ;;
+ *)
+ erl_cv_time_correction=clock_gettime;;
+ esac
+ else
+ case X$erl_xcomp_linux_clock_gettime_correction in
+ X)
+ erl_cv_time_correction=cross;;
+ Xyes|Xno)
+ if test $erl_xcomp_linux_clock_gettime_correction = yes; then
+ erl_cv_time_correction=clock_gettime
+ else
+ erl_cv_time_correction=times
+ fi;;
+ *)
+ AC_MSG_ERROR([Bad erl_xcomp_linux_clock_gettime_correction value: $erl_xcomp_linux_clock_gettime_correction]);;
+ esac
+ fi
+ else
+ erl_cv_time_correction=times
+ fi
+ ;;
+ *)
+ erl_cv_time_correction=times ;;
+ esac
+ ;;
+ *)
+ erl_cv_time_correction=none ;;
+ esac
+ ;;
+ esac
+ ;;
+esac
+])
-case $$erl_monotonic_clock_low_resolution-$erl_monotonic_clock_func in
- no-mach_clock_get_time)
- monotonic_hrtime=yes
- AC_DEFINE(SYS_HRTIME_USING_MACH_CLOCK_GET_TIME, [1], [Define if you want to implement erts_os_hrtime() using mach clock_get_time()])
- ;;
- no-clock_gettime)
- monotonic_hrtime=yes
- AC_DEFINE(SYS_HRTIME_USING_CLOCK_GETTIME, [1], [Define if you want to implement erts_os_hrtime() using clock_gettime()])
- ;;
- no-gethrtime)
- monotonic_hrtime=yes
- AC_DEFINE(SYS_HRTIME_USING_GETHRTIME, [1], [Define if you want to implement erts_os_hrtime() using gethrtime()])
+xrtlib=""
+case $erl_cv_time_correction in
+ times)
+ AC_DEFINE(CORRECT_USING_TIMES,[],
+ [Define if you do not have a high-res. timer & want to use times() instead])
;;
- *)
- monotonic_hrtime=no
+ clock_gettime|cross)
+ if test $erl_cv_time_correction = cross; then
+ erl_cv_time_correction=clock_gettime
+ AC_MSG_WARN([result clock_gettime guessed because of cross compilation])
+ fi
+ xrtlib="-lrt"
+ AC_DEFINE(GETHRTIME_WITH_CLOCK_GETTIME,[1],
+ [Define if you want to use clock_gettime to simulate gethrtime])
;;
esac
-
-if test $monotonic_hrtime = yes; then
- AC_DEFINE(HAVE_MONOTONIC_ERTS_SYS_HRTIME, [1], [Define if you have a monotonic erts_os_hrtime() implementation])
-fi
-
-if test "x$erl_monotonic_clock_id" != "x"; then
- AC_DEFINE_UNQUOTED(HRTIME_CLOCK_ID_STR, ["$erl_monotonic_clock_id"], [Define as a string of monotonic clock id to use])
- AC_DEFINE_UNQUOTED(HRTIME_CLOCK_ID, [$erl_monotonic_clock_id], [Define to monotonic clock id to use])
-fi
-
-
dnl
dnl Check if gethrvtime is working, and if to use procfs ioctl
dnl or (yet to be written) write to the procfs ctl file.
@@ -2494,7 +1813,6 @@
esac
])
-LIBRT=$xrtlib
case $erl_gethrvtime in
procfs_ioctl)
AC_DEFINE(HAVE_GETHRVTIME_PROCFS_IOCTL,[1],
@@ -2541,33 +1859,43 @@
exit(0); return 0;
}
],
- erl_clock_gettime_cpu_time=yes,
- erl_clock_gettime_cpu_time=no,
+ erl_clock_gettime=yes,
+ erl_clock_gettime=no,
[
case X$erl_xcomp_clock_gettime_cpu_time in
- X) erl_clock_gettime_cpu_time=cross;;
- Xyes|Xno) erl_clock_gettime_cpu_time=$erl_xcomp_clock_gettime_cpu_time;;
+ X) erl_clock_gettime=cross;;
+ Xyes|Xno) erl_clock_gettime=$erl_xcomp_clock_gettime_cpu_time;;
*) AC_MSG_ERROR([Bad erl_xcomp_clock_gettime_cpu_time value: $erl_xcomp_clock_gettime_cpu_time]);;
esac
])
LIBS=$save_libs
- AC_MSG_RESULT($erl_clock_gettime_cpu_time)
- case $erl_clock_gettime_cpu_time in
- yes)
- AC_DEFINE(HAVE_CLOCK_GETTIME_CPU_TIME,[],
- [define if clock_gettime() works for getting process time])
- LIBRT=-lrt
- ;;
- cross)
- erl_clock_gettime_cpu_time=no
- AC_MSG_WARN([result no guessed because of cross compilation])
+ case $host_os in
+ linux*)
+ AC_MSG_RESULT([no; not stable])
+ LIBRT=$xrtlib
;;
*)
+ AC_MSG_RESULT($erl_clock_gettime)
+ case $erl_clock_gettime in
+ yes)
+ AC_DEFINE(HAVE_CLOCK_GETTIME,[],
+ [define if clock_gettime() works for getting process time])
+ LIBRT=-lrt
+ ;;
+ cross)
+ erl_clock_gettime=no
+ AC_MSG_WARN([result no guessed because of cross compilation])
+ LIBRT=$xrtlib
+ ;;
+ *)
+ LIBRT=$xrtlib
+ ;;
+ esac
;;
esac
+ AC_SUBST(LIBRT)
;;
esac
-AC_SUBST(LIBRT)
])dnl
dnl ----------------------------------------------------------------------
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/bin/start.boot and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/bin/start.boot differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/bin/start_clean.boot and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/bin/start_clean.boot differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/compiler/ebin/beam_a.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/compiler/ebin/beam_a.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/compiler/ebin/beam_asm.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/compiler/ebin/beam_asm.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/compiler/ebin/beam_block.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/compiler/ebin/beam_block.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/compiler/ebin/beam_bool.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/compiler/ebin/beam_bool.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/compiler/ebin/beam_bsm.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/compiler/ebin/beam_bsm.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/compiler/ebin/beam_clean.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/compiler/ebin/beam_clean.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/compiler/ebin/beam_dead.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/compiler/ebin/beam_dead.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/compiler/ebin/beam_dict.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/compiler/ebin/beam_dict.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/compiler/ebin/beam_disasm.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/compiler/ebin/beam_disasm.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/compiler/ebin/beam_except.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/compiler/ebin/beam_except.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/compiler/ebin/beam_flatten.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/compiler/ebin/beam_flatten.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/compiler/ebin/beam_jump.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/compiler/ebin/beam_jump.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/compiler/ebin/beam_listing.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/compiler/ebin/beam_listing.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/compiler/ebin/beam_opcodes.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/compiler/ebin/beam_opcodes.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/compiler/ebin/beam_peep.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/compiler/ebin/beam_peep.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/compiler/ebin/beam_receive.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/compiler/ebin/beam_receive.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/compiler/ebin/beam_split.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/compiler/ebin/beam_split.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/compiler/ebin/beam_trim.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/compiler/ebin/beam_trim.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/compiler/ebin/beam_type.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/compiler/ebin/beam_type.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/compiler/ebin/beam_utils.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/compiler/ebin/beam_utils.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/compiler/ebin/beam_validator.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/compiler/ebin/beam_validator.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/compiler/ebin/beam_z.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/compiler/ebin/beam_z.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/compiler/ebin/cerl.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/compiler/ebin/cerl.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/compiler/ebin/cerl_clauses.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/compiler/ebin/cerl_clauses.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/compiler/ebin/cerl_inline.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/compiler/ebin/cerl_inline.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/compiler/ebin/cerl_sets.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/compiler/ebin/cerl_sets.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/compiler/ebin/cerl_trees.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/compiler/ebin/cerl_trees.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/compiler/ebin/compile.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/compiler/ebin/compile.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/compiler/ebin/core_lib.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/compiler/ebin/core_lib.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/compiler/ebin/core_lint.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/compiler/ebin/core_lint.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/compiler/ebin/core_parse.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/compiler/ebin/core_parse.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/compiler/ebin/core_pp.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/compiler/ebin/core_pp.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/compiler/ebin/core_scan.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/compiler/ebin/core_scan.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/compiler/ebin/erl_bifs.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/compiler/ebin/erl_bifs.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/compiler/ebin/rec_env.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/compiler/ebin/rec_env.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/compiler/ebin/sys_core_dsetel.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/compiler/ebin/sys_core_dsetel.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/compiler/ebin/sys_core_fold.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/compiler/ebin/sys_core_fold.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/compiler/ebin/sys_core_fold_lists.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/compiler/ebin/sys_core_fold_lists.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/compiler/ebin/sys_core_inline.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/compiler/ebin/sys_core_inline.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/compiler/ebin/sys_pre_attributes.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/compiler/ebin/sys_pre_attributes.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/compiler/ebin/sys_pre_expand.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/compiler/ebin/sys_pre_expand.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/compiler/ebin/v3_codegen.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/compiler/ebin/v3_codegen.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/compiler/ebin/v3_core.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/compiler/ebin/v3_core.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/compiler/ebin/v3_kernel.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/compiler/ebin/v3_kernel.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/compiler/ebin/v3_kernel_pp.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/compiler/ebin/v3_kernel_pp.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/compiler/ebin/v3_life.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/compiler/ebin/v3_life.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/kernel/ebin/application.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/kernel/ebin/application.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/kernel/ebin/application_controller.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/kernel/ebin/application_controller.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/kernel/ebin/application_master.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/kernel/ebin/application_master.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/kernel/ebin/application_starter.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/kernel/ebin/application_starter.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/kernel/ebin/auth.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/kernel/ebin/auth.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/kernel/ebin/code.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/kernel/ebin/code.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/kernel/ebin/code_server.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/kernel/ebin/code_server.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/kernel/ebin/disk_log_1.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/kernel/ebin/disk_log_1.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/kernel/ebin/disk_log.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/kernel/ebin/disk_log.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/kernel/ebin/disk_log_server.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/kernel/ebin/disk_log_server.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/kernel/ebin/disk_log_sup.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/kernel/ebin/disk_log_sup.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/kernel/ebin/dist_ac.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/kernel/ebin/dist_ac.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/kernel/ebin/dist_util.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/kernel/ebin/dist_util.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/kernel/ebin/erl_boot_server.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/kernel/ebin/erl_boot_server.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/kernel/ebin/erl_ddll.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/kernel/ebin/erl_ddll.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/kernel/ebin/erl_distribution.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/kernel/ebin/erl_distribution.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/kernel/ebin/erl_epmd.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/kernel/ebin/erl_epmd.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/kernel/ebin/erl_reply.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/kernel/ebin/erl_reply.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/kernel/ebin/error_handler.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/kernel/ebin/error_handler.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/kernel/ebin/error_logger.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/kernel/ebin/error_logger.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/kernel/ebin/erts_debug.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/kernel/ebin/erts_debug.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/kernel/ebin/file.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/kernel/ebin/file.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/kernel/ebin/file_io_server.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/kernel/ebin/file_io_server.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/kernel/ebin/file_server.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/kernel/ebin/file_server.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/kernel/ebin/gen_sctp.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/kernel/ebin/gen_sctp.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/kernel/ebin/gen_tcp.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/kernel/ebin/gen_tcp.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/kernel/ebin/gen_udp.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/kernel/ebin/gen_udp.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/kernel/ebin/global.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/kernel/ebin/global.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/kernel/ebin/global_group.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/kernel/ebin/global_group.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/kernel/ebin/global_search.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/kernel/ebin/global_search.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/kernel/ebin/group.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/kernel/ebin/group.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/kernel/ebin/heart.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/kernel/ebin/heart.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/kernel/ebin/hipe_unified_loader.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/kernel/ebin/hipe_unified_loader.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/kernel/ebin/inet6_sctp.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/kernel/ebin/inet6_sctp.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/kernel/ebin/inet6_tcp.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/kernel/ebin/inet6_tcp.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/kernel/ebin/inet6_tcp_dist.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/kernel/ebin/inet6_tcp_dist.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/kernel/ebin/inet6_udp.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/kernel/ebin/inet6_udp.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/kernel/ebin/inet.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/kernel/ebin/inet.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/kernel/ebin/inet_config.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/kernel/ebin/inet_config.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/kernel/ebin/inet_db.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/kernel/ebin/inet_db.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/kernel/ebin/inet_dns.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/kernel/ebin/inet_dns.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/kernel/ebin/inet_gethost_native.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/kernel/ebin/inet_gethost_native.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/kernel/ebin/inet_hosts.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/kernel/ebin/inet_hosts.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/kernel/ebin/inet_parse.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/kernel/ebin/inet_parse.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/kernel/ebin/inet_res.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/kernel/ebin/inet_res.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/kernel/ebin/inet_sctp.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/kernel/ebin/inet_sctp.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/kernel/ebin/inet_tcp.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/kernel/ebin/inet_tcp.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/kernel/ebin/inet_tcp_dist.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/kernel/ebin/inet_tcp_dist.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/kernel/ebin/inet_udp.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/kernel/ebin/inet_udp.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/kernel/ebin/kernel.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/kernel/ebin/kernel.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/kernel/ebin/kernel_config.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/kernel/ebin/kernel_config.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/kernel/ebin/net_adm.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/kernel/ebin/net_adm.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/kernel/ebin/net.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/kernel/ebin/net.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/kernel/ebin/net_kernel.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/kernel/ebin/net_kernel.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/kernel/ebin/os.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/kernel/ebin/os.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/kernel/ebin/pg2.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/kernel/ebin/pg2.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/kernel/ebin/ram_file.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/kernel/ebin/ram_file.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/kernel/ebin/rpc.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/kernel/ebin/rpc.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/kernel/ebin/seq_trace.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/kernel/ebin/seq_trace.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/kernel/ebin/standard_error.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/kernel/ebin/standard_error.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/kernel/ebin/user.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/kernel/ebin/user.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/kernel/ebin/user_drv.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/kernel/ebin/user_drv.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/kernel/ebin/user_sup.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/kernel/ebin/user_sup.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/kernel/ebin/wrap_log_reader.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/kernel/ebin/wrap_log_reader.beam differ
diff -Nru erlang-18.2-dfsg/bootstrap/lib/kernel/include/dist.hrl erlang-17.3-dfsg/bootstrap/lib/kernel/include/dist.hrl
--- erlang-18.2-dfsg/bootstrap/lib/kernel/include/dist.hrl 2015-12-20 18:13:21.000000000 +0000
+++ erlang-17.3-dfsg/bootstrap/lib/kernel/include/dist.hrl 2014-09-18 07:51:05.000000000 +0000
@@ -3,17 +3,16 @@
%%
%% Copyright Ericsson AB 1999-2014. All Rights Reserved.
%%
-%% Licensed under the Apache License, Version 2.0 (the "License");
-%% you may not use this file except in compliance with the License.
-%% You may obtain a copy of the License at
-%%
-%% http://www.apache.org/licenses/LICENSE-2.0
-%%
-%% Unless required by applicable law or agreed to in writing, software
-%% distributed under the License is distributed on an "AS IS" BASIS,
-%% WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-%% See the License for the specific language governing permissions and
-%% limitations under the License.
+%% The contents of this file are subject to the Erlang Public License,
+%% Version 1.1, (the "License"); you may not use this file except in
+%% compliance with the License. You should have received a copy of the
+%% Erlang Public License along with this software. If not, it can be
+%% retrieved online at http://www.erlang.org/.
+%%
+%% Software distributed under the License is distributed on an "AS IS"
+%% basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See
+%% the License for the specific language governing rights and limitations
+%% under the License.
%%
%% %CopyrightEnd%
%%
diff -Nru erlang-18.2-dfsg/bootstrap/lib/kernel/include/dist_util.hrl erlang-17.3-dfsg/bootstrap/lib/kernel/include/dist_util.hrl
--- erlang-18.2-dfsg/bootstrap/lib/kernel/include/dist_util.hrl 2015-12-20 18:13:21.000000000 +0000
+++ erlang-17.3-dfsg/bootstrap/lib/kernel/include/dist_util.hrl 2014-09-18 07:51:05.000000000 +0000
@@ -3,17 +3,16 @@
%%
%% Copyright Ericsson AB 1999-2011. All Rights Reserved.
%%
-%% Licensed under the Apache License, Version 2.0 (the "License");
-%% you may not use this file except in compliance with the License.
-%% You may obtain a copy of the License at
-%%
-%% http://www.apache.org/licenses/LICENSE-2.0
-%%
-%% Unless required by applicable law or agreed to in writing, software
-%% distributed under the License is distributed on an "AS IS" BASIS,
-%% WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-%% See the License for the specific language governing permissions and
-%% limitations under the License.
+%% The contents of this file are subject to the Erlang Public License,
+%% Version 1.1, (the "License"); you may not use this file except in
+%% compliance with the License. You should have received a copy of the
+%% Erlang Public License along with this software. If not, it can be
+%% retrieved online at http://www.erlang.org/.
+%%
+%% Software distributed under the License is distributed on an "AS IS"
+%% basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See
+%% the License for the specific language governing rights and limitations
+%% under the License.
%%
%% %CopyrightEnd%
%%
diff -Nru erlang-18.2-dfsg/bootstrap/lib/kernel/include/file.hrl erlang-17.3-dfsg/bootstrap/lib/kernel/include/file.hrl
--- erlang-18.2-dfsg/bootstrap/lib/kernel/include/file.hrl 2015-12-20 18:13:21.000000000 +0000
+++ erlang-17.3-dfsg/bootstrap/lib/kernel/include/file.hrl 2014-09-18 07:51:05.000000000 +0000
@@ -3,17 +3,16 @@
%%
%% Copyright Ericsson AB 1997-2013. All Rights Reserved.
%%
-%% Licensed under the Apache License, Version 2.0 (the "License");
-%% you may not use this file except in compliance with the License.
-%% You may obtain a copy of the License at
-%%
-%% http://www.apache.org/licenses/LICENSE-2.0
-%%
-%% Unless required by applicable law or agreed to in writing, software
-%% distributed under the License is distributed on an "AS IS" BASIS,
-%% WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-%% See the License for the specific language governing permissions and
-%% limitations under the License.
+%% The contents of this file are subject to the Erlang Public License,
+%% Version 1.1, (the "License"); you may not use this file except in
+%% compliance with the License. You should have received a copy of the
+%% Erlang Public License along with this software. If not, it can be
+%% retrieved online at http://www.erlang.org/.
+%%
+%% Software distributed under the License is distributed on an "AS IS"
+%% basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See
+%% the License for the specific language governing rights and limitations
+%% under the License.
%%
%% %CopyrightEnd%
%%
diff -Nru erlang-18.2-dfsg/bootstrap/lib/kernel/include/inet.hrl erlang-17.3-dfsg/bootstrap/lib/kernel/include/inet.hrl
--- erlang-18.2-dfsg/bootstrap/lib/kernel/include/inet.hrl 2015-12-20 18:13:21.000000000 +0000
+++ erlang-17.3-dfsg/bootstrap/lib/kernel/include/inet.hrl 2014-09-18 07:51:05.000000000 +0000
@@ -3,17 +3,16 @@
%%
%% Copyright Ericsson AB 1997-2011. All Rights Reserved.
%%
-%% Licensed under the Apache License, Version 2.0 (the "License");
-%% you may not use this file except in compliance with the License.
-%% You may obtain a copy of the License at
-%%
-%% http://www.apache.org/licenses/LICENSE-2.0
-%%
-%% Unless required by applicable law or agreed to in writing, software
-%% distributed under the License is distributed on an "AS IS" BASIS,
-%% WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-%% See the License for the specific language governing permissions and
-%% limitations under the License.
+%% The contents of this file are subject to the Erlang Public License,
+%% Version 1.1, (the "License"); you may not use this file except in
+%% compliance with the License. You should have received a copy of the
+%% Erlang Public License along with this software. If not, it can be
+%% retrieved online at http://www.erlang.org/.
+%%
+%% Software distributed under the License is distributed on an "AS IS"
+%% basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See
+%% the License for the specific language governing rights and limitations
+%% under the License.
%%
%% %CopyrightEnd%
%%
diff -Nru erlang-18.2-dfsg/bootstrap/lib/kernel/include/inet_sctp.hrl erlang-17.3-dfsg/bootstrap/lib/kernel/include/inet_sctp.hrl
--- erlang-18.2-dfsg/bootstrap/lib/kernel/include/inet_sctp.hrl 2015-12-20 18:13:21.000000000 +0000
+++ erlang-17.3-dfsg/bootstrap/lib/kernel/include/inet_sctp.hrl 2014-09-18 07:51:05.000000000 +0000
@@ -3,17 +3,16 @@
%%
%% Copyright Ericsson AB 2007-2009. All Rights Reserved.
%%
-%% Licensed under the Apache License, Version 2.0 (the "License");
-%% you may not use this file except in compliance with the License.
-%% You may obtain a copy of the License at
-%%
-%% http://www.apache.org/licenses/LICENSE-2.0
-%%
-%% Unless required by applicable law or agreed to in writing, software
-%% distributed under the License is distributed on an "AS IS" BASIS,
-%% WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-%% See the License for the specific language governing permissions and
-%% limitations under the License.
+%% The contents of this file are subject to the Erlang Public License,
+%% Version 1.1, (the "License"); you may not use this file except in
+%% compliance with the License. You should have received a copy of the
+%% Erlang Public License along with this software. If not, it can be
+%% retrieved online at http://www.erlang.org/.
+%%
+%% Software distributed under the License is distributed on an "AS IS"
+%% basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See
+%% the License for the specific language governing rights and limitations
+%% under the License.
%%
%% %CopyrightEnd%
%%
diff -Nru erlang-18.2-dfsg/bootstrap/lib/kernel/include/net_address.hrl erlang-17.3-dfsg/bootstrap/lib/kernel/include/net_address.hrl
--- erlang-18.2-dfsg/bootstrap/lib/kernel/include/net_address.hrl 2015-12-20 18:13:21.000000000 +0000
+++ erlang-17.3-dfsg/bootstrap/lib/kernel/include/net_address.hrl 2014-09-18 07:51:05.000000000 +0000
@@ -3,17 +3,16 @@
%%
%% Copyright Ericsson AB 1997-2011. All Rights Reserved.
%%
-%% Licensed under the Apache License, Version 2.0 (the "License");
-%% you may not use this file except in compliance with the License.
-%% You may obtain a copy of the License at
-%%
-%% http://www.apache.org/licenses/LICENSE-2.0
-%%
-%% Unless required by applicable law or agreed to in writing, software
-%% distributed under the License is distributed on an "AS IS" BASIS,
-%% WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-%% See the License for the specific language governing permissions and
-%% limitations under the License.
+%% The contents of this file are subject to the Erlang Public License,
+%% Version 1.1, (the "License"); you may not use this file except in
+%% compliance with the License. You should have received a copy of the
+%% Erlang Public License along with this software. If not, it can be
+%% retrieved online at http://www.erlang.org/.
+%%
+%% Software distributed under the License is distributed on an "AS IS"
+%% basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See
+%% the License for the specific language governing rights and limitations
+%% under the License.
%%
%% %CopyrightEnd%
%%
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/stdlib/ebin/array.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/stdlib/ebin/array.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/stdlib/ebin/base64.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/stdlib/ebin/base64.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/stdlib/ebin/beam_lib.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/stdlib/ebin/beam_lib.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/stdlib/ebin/binary.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/stdlib/ebin/binary.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/stdlib/ebin/calendar.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/stdlib/ebin/calendar.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/stdlib/ebin/c.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/stdlib/ebin/c.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/stdlib/ebin/dets.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/stdlib/ebin/dets.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/stdlib/ebin/dets_server.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/stdlib/ebin/dets_server.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/stdlib/ebin/dets_sup.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/stdlib/ebin/dets_sup.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/stdlib/ebin/dets_utils.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/stdlib/ebin/dets_utils.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/stdlib/ebin/dets_v8.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/stdlib/ebin/dets_v8.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/stdlib/ebin/dets_v9.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/stdlib/ebin/dets_v9.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/stdlib/ebin/dict.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/stdlib/ebin/dict.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/stdlib/ebin/digraph.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/stdlib/ebin/digraph.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/stdlib/ebin/digraph_utils.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/stdlib/ebin/digraph_utils.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/stdlib/ebin/edlin.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/stdlib/ebin/edlin.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/stdlib/ebin/edlin_expand.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/stdlib/ebin/edlin_expand.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/stdlib/ebin/epp.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/stdlib/ebin/epp.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/stdlib/ebin/erl_anno.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/stdlib/ebin/erl_anno.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/stdlib/ebin/erl_bits.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/stdlib/ebin/erl_bits.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/stdlib/ebin/erl_compile.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/stdlib/ebin/erl_compile.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/stdlib/ebin/erl_eval.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/stdlib/ebin/erl_eval.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/stdlib/ebin/erl_expand_records.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/stdlib/ebin/erl_expand_records.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/stdlib/ebin/erl_internal.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/stdlib/ebin/erl_internal.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/stdlib/ebin/erl_lint.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/stdlib/ebin/erl_lint.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/stdlib/ebin/erl_parse.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/stdlib/ebin/erl_parse.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/stdlib/ebin/erl_posix_msg.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/stdlib/ebin/erl_posix_msg.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/stdlib/ebin/erl_pp.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/stdlib/ebin/erl_pp.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/stdlib/ebin/erl_scan.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/stdlib/ebin/erl_scan.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/stdlib/ebin/erl_tar.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/stdlib/ebin/erl_tar.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/stdlib/ebin/error_logger_file_h.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/stdlib/ebin/error_logger_file_h.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/stdlib/ebin/error_logger_tty_h.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/stdlib/ebin/error_logger_tty_h.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/stdlib/ebin/escript.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/stdlib/ebin/escript.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/stdlib/ebin/ets.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/stdlib/ebin/ets.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/stdlib/ebin/eval_bits.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/stdlib/ebin/eval_bits.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/stdlib/ebin/filelib.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/stdlib/ebin/filelib.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/stdlib/ebin/filename.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/stdlib/ebin/filename.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/stdlib/ebin/file_sorter.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/stdlib/ebin/file_sorter.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/stdlib/ebin/gb_sets.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/stdlib/ebin/gb_sets.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/stdlib/ebin/gb_trees.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/stdlib/ebin/gb_trees.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/stdlib/ebin/gen.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/stdlib/ebin/gen.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/stdlib/ebin/gen_event.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/stdlib/ebin/gen_event.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/stdlib/ebin/gen_fsm.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/stdlib/ebin/gen_fsm.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/stdlib/ebin/gen_server.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/stdlib/ebin/gen_server.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/stdlib/ebin/io.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/stdlib/ebin/io.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/stdlib/ebin/io_lib.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/stdlib/ebin/io_lib.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/stdlib/ebin/io_lib_format.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/stdlib/ebin/io_lib_format.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/stdlib/ebin/io_lib_fread.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/stdlib/ebin/io_lib_fread.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/stdlib/ebin/io_lib_pretty.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/stdlib/ebin/io_lib_pretty.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/stdlib/ebin/lib.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/stdlib/ebin/lib.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/stdlib/ebin/lists.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/stdlib/ebin/lists.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/stdlib/ebin/log_mf_h.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/stdlib/ebin/log_mf_h.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/stdlib/ebin/maps.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/stdlib/ebin/maps.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/stdlib/ebin/math.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/stdlib/ebin/math.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/stdlib/ebin/ms_transform.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/stdlib/ebin/ms_transform.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/stdlib/ebin/orddict.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/stdlib/ebin/orddict.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/stdlib/ebin/ordsets.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/stdlib/ebin/ordsets.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/stdlib/ebin/otp_internal.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/stdlib/ebin/otp_internal.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/stdlib/ebin/pg.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/stdlib/ebin/pg.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/stdlib/ebin/pool.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/stdlib/ebin/pool.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/stdlib/ebin/proc_lib.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/stdlib/ebin/proc_lib.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/stdlib/ebin/proplists.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/stdlib/ebin/proplists.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/stdlib/ebin/qlc.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/stdlib/ebin/qlc.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/stdlib/ebin/qlc_pt.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/stdlib/ebin/qlc_pt.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/stdlib/ebin/queue.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/stdlib/ebin/queue.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/stdlib/ebin/rand.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/stdlib/ebin/rand.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/stdlib/ebin/random.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/stdlib/ebin/random.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/stdlib/ebin/re.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/stdlib/ebin/re.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/stdlib/ebin/sets.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/stdlib/ebin/sets.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/stdlib/ebin/shell.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/stdlib/ebin/shell.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/stdlib/ebin/shell_default.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/stdlib/ebin/shell_default.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/stdlib/ebin/slave.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/stdlib/ebin/slave.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/stdlib/ebin/sofs.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/stdlib/ebin/sofs.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/stdlib/ebin/string.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/stdlib/ebin/string.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/stdlib/ebin/supervisor.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/stdlib/ebin/supervisor.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/stdlib/ebin/supervisor_bridge.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/stdlib/ebin/supervisor_bridge.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/stdlib/ebin/sys.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/stdlib/ebin/sys.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/stdlib/ebin/timer.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/stdlib/ebin/timer.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/stdlib/ebin/unicode.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/stdlib/ebin/unicode.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/stdlib/ebin/win32reg.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/stdlib/ebin/win32reg.beam differ
Binary files /tmp/tmp4OT3UZ/1gNB8mPsmk/erlang-18.2-dfsg/bootstrap/lib/stdlib/ebin/zip.beam and /tmp/tmp4OT3UZ/RkyUh2tbhJ/erlang-17.3-dfsg/bootstrap/lib/stdlib/ebin/zip.beam differ
diff -Nru erlang-18.2-dfsg/bootstrap/lib/stdlib/include/assert.hrl erlang-17.3-dfsg/bootstrap/lib/stdlib/include/assert.hrl
--- erlang-18.2-dfsg/bootstrap/lib/stdlib/include/assert.hrl 2015-12-20 18:13:21.000000000 +0000
+++ erlang-17.3-dfsg/bootstrap/lib/stdlib/include/assert.hrl 1970-01-01 00:00:00.000000000 +0000
@@ -1,261 +0,0 @@
-%%
-%% %CopyrightBegin%
-%%
-%% Copyright (C) 2004-2014 Richard Carlsson, Mickaël Rémond
-%%
-%% Licensed under the Apache License, Version 2.0 (the "License");
-%% you may not use this file except in compliance with the License.
-%% You may obtain a copy of the License at
-%%
-%% http://www.apache.org/licenses/LICENSE-2.0
-%%
-%% Unless required by applicable law or agreed to in writing, software
-%% distributed under the License is distributed on an "AS IS" BASIS,
-%% WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-%% See the License for the specific language governing permissions and
-%% limitations under the License.
-%%
-%% %CopyrightEnd%
-%%
-
--ifndef(ASSERT_HRL).
--define(ASSERT_HRL, true).
-
-%% Asserts are enabled unless NOASSERT is defined, and ASSERT can be used to
-%% override it: if both ASSERT and NOASSERT are defined, then ASSERT takes
-%% precedence, and NOASSERT will become undefined.
-%%
-%% Furthermore, if NODEBUG is defined, it implies NOASSERT, unless DEBUG or
-%% ASSERT are defined.
-%%
-%% If asserts are disabled, all assert macros are defined to be the atom
-%% 'ok'. If asserts are enabled, all assert macros are defined to yield 'ok'
-%% as the result if the test succeeds, and raise an error exception if the
-%% test fails. The error term will then have the form {Name, Info} where
-%% Name is the name of the macro and Info is a list of tagged tuples.
-
-%% allow NODEBUG to imply NOASSERT, unless DEBUG
--ifdef(NODEBUG).
--ifndef(DEBUG).
--ifndef(NOASSERT).
--define(NOASSERT, true).
--endif.
--endif.
--endif.
-
-%% allow ASSERT to override NOASSERT
--ifdef(ASSERT).
--undef(NOASSERT).
--endif.
-
-%% Assert macros must not depend on any non-kernel or stdlib libraries.
-%%
-%% We must use fun-call wrappers ((fun () -> ... end)()) to avoid
-%% exporting local variables, and furthermore we only use variable names
-%% prefixed with "__", that hopefully will not be bound outside the fun.
-%% It is not possible to nest assert macros.
-
--ifdef(NOASSERT).
--define(assert(BoolExpr),ok).
--else.
-%% The assert macro is written the way it is so as not to cause warnings
-%% for clauses that cannot match, even if the expression is a constant.
--define(assert(BoolExpr),
- begin
- ((fun () ->
- case (BoolExpr) of
- true -> ok;
- __V -> erlang:error({assert,
- [{module, ?MODULE},
- {line, ?LINE},
- {expression, (??BoolExpr)},
- {expected, true},
- case __V of false -> {value, __V};
- _ -> {not_boolean,__V}
- end]})
- end
- end)())
- end).
--endif.
-
-%% This is the inverse case of assert, for convenience.
--ifdef(NOASSERT).
--define(assertNot(BoolExpr),ok).
--else.
--define(assertNot(BoolExpr),
- begin
- ((fun () ->
- case (BoolExpr) of
- false -> ok;
- __V -> erlang:error({assert,
- [{module, ?MODULE},
- {line, ?LINE},
- {expression, (??BoolExpr)},
- {expected, false},
- case __V of true -> {value, __V};
- _ -> {not_boolean,__V}
- end]})
- end
- end)())
- end).
--endif.
-
-%% This is mostly a convenience which gives more detailed reports.
-%% Note: Guard is a guarded pattern, and can not be used for value.
--ifdef(NOASSERT).
--define(assertMatch(Guard, Expr), ok).
--else.
--define(assertMatch(Guard, Expr),
- begin
- ((fun () ->
- case (Expr) of
- Guard -> ok;
- __V -> erlang:error({assertMatch,
- [{module, ?MODULE},
- {line, ?LINE},
- {expression, (??Expr)},
- {pattern, (??Guard)},
- {value, __V}]})
- end
- end)())
- end).
--endif.
-
-%% This is the inverse case of assertMatch, for convenience.
--ifdef(NOASSERT).
--define(assertNotMatch(Guard, Expr), ok).
--else.
--define(assertNotMatch(Guard, Expr),
- begin
- ((fun () ->
- __V = (Expr),
- case __V of
- Guard -> erlang:error({assertNotMatch,
- [{module, ?MODULE},
- {line, ?LINE},
- {expression, (??Expr)},
- {pattern, (??Guard)},
- {value, __V}]});
- _ -> ok
- end
- end)())
- end).
--endif.
-
-%% This is a convenience macro which gives more detailed reports when
-%% the expected LHS value is not a pattern, but a computed value
--ifdef(NOASSERT).
--define(assertEqual(Expect, Expr), ok).
--else.
--define(assertEqual(Expect, Expr),
- begin
- ((fun (__X) ->
- case (Expr) of
- __X -> ok;
- __V -> erlang:error({assertEqual,
- [{module, ?MODULE},
- {line, ?LINE},
- {expression, (??Expr)},
- {expected, __X},
- {value, __V}]})
- end
- end)(Expect))
- end).
--endif.
-
-%% This is the inverse case of assertEqual, for convenience.
--ifdef(NOASSERT).
--define(assertNotEqual(Unexpected, Expr), ok).
--else.
--define(assertNotEqual(Unexpected, Expr),
- begin
- ((fun (__X) ->
- case (Expr) of
- __X -> erlang:error({assertNotEqual,
- [{module, ?MODULE},
- {line, ?LINE},
- {expression, (??Expr)},
- {value, __X}]});
- _ -> ok
- end
- end)(Unexpected))
- end).
--endif.
-
-%% Note: Class and Term are patterns, and can not be used for value.
-%% Term can be a guarded pattern, but Class cannot.
--ifdef(NOASSERT).
--define(assertException(Class, Term, Expr), ok).
--else.
--define(assertException(Class, Term, Expr),
- begin
- ((fun () ->
- try (Expr) of
- __V -> erlang:error({assertException,
- [{module, ?MODULE},
- {line, ?LINE},
- {expression, (??Expr)},
- {pattern,
- "{ "++(??Class)++" , "++(??Term)
- ++" , [...] }"},
- {unexpected_success, __V}]})
- catch
- Class:Term -> ok;
- __C:__T ->
- erlang:error({assertException,
- [{module, ?MODULE},
- {line, ?LINE},
- {expression, (??Expr)},
- {pattern,
- "{ "++(??Class)++" , "++(??Term)
- ++" , [...] }"},
- {unexpected_exception,
- {__C, __T,
- erlang:get_stacktrace()}}]})
- end
- end)())
- end).
--endif.
-
--define(assertError(Term, Expr), ?assertException(error, Term, Expr)).
--define(assertExit(Term, Expr), ?assertException(exit, Term, Expr)).
--define(assertThrow(Term, Expr), ?assertException(throw, Term, Expr)).
-
-%% This is the inverse case of assertException, for convenience.
-%% Note: Class and Term are patterns, and can not be used for value.
-%% Both Class and Term can be guarded patterns.
--ifdef(NOASSERT).
--define(assertNotException(Class, Term, Expr), ok).
--else.
--define(assertNotException(Class, Term, Expr),
- begin
- ((fun () ->
- try (Expr) of
- _ -> ok
- catch
- __C:__T ->
- case __C of
- Class ->
- case __T of
- Term ->
- erlang:error({assertNotException,
- [{module, ?MODULE},
- {line, ?LINE},
- {expression, (??Expr)},
- {pattern,
- "{ "++(??Class)++" , "
- ++(??Term)++" , [...] }"},
- {unexpected_exception,
- {__C, __T,
- erlang:get_stacktrace()
- }}]});
- _ -> ok
- end;
- _ -> ok
- end
- end
- end)())
- end).
--endif.
-
--endif. % ASSERT_HRL
diff -Nru erlang-18.2-dfsg/bootstrap/lib/stdlib/include/erl_bits.hrl erlang-17.3-dfsg/bootstrap/lib/stdlib/include/erl_bits.hrl
--- erlang-18.2-dfsg/bootstrap/lib/stdlib/include/erl_bits.hrl 2015-12-20 18:13:21.000000000 +0000
+++ erlang-17.3-dfsg/bootstrap/lib/stdlib/include/erl_bits.hrl 2014-09-18 07:51:05.000000000 +0000
@@ -3,17 +3,16 @@
%%
%% Copyright Ericsson AB 1999-2009. All Rights Reserved.
%%
-%% Licensed under the Apache License, Version 2.0 (the "License");
-%% you may not use this file except in compliance with the License.
-%% You may obtain a copy of the License at
-%%
-%% http://www.apache.org/licenses/LICENSE-2.0
-%%
-%% Unless required by applicable law or agreed to in writing, software
-%% distributed under the License is distributed on an "AS IS" BASIS,
-%% WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-%% See the License for the specific language governing permissions and
-%% limitations under the License.
+%% The contents of this file are subject to the Erlang Public License,
+%% Version 1.1, (the "License"); you may not use this file except in
+%% compliance with the License. You should have received a copy of the
+%% Erlang Public License along with this software. If not, it can be
+%% retrieved online at http://www.erlang.org/.
+%%
+%% Software distributed under the License is distributed on an "AS IS"
+%% basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See
+%% the License for the specific language governing rights and limitations
+%% under the License.
%%
%% %CopyrightEnd%
%%
diff -Nru erlang-18.2-dfsg/bootstrap/lib/stdlib/include/erl_compile.hrl erlang-17.3-dfsg/bootstrap/lib/stdlib/include/erl_compile.hrl
--- erlang-18.2-dfsg/bootstrap/lib/stdlib/include/erl_compile.hrl 2015-12-20 18:13:21.000000000 +0000
+++ erlang-17.3-dfsg/bootstrap/lib/stdlib/include/erl_compile.hrl 2014-09-18 07:51:05.000000000 +0000
@@ -3,17 +3,16 @@
%%
%% Copyright Ericsson AB 1997-2009. All Rights Reserved.
%%
-%% Licensed under the Apache License, Version 2.0 (the "License");
-%% you may not use this file except in compliance with the License.
-%% You may obtain a copy of the License at
-%%
-%% http://www.apache.org/licenses/LICENSE-2.0
-%%
-%% Unless required by applicable law or agreed to in writing, software
-%% distributed under the License is distributed on an "AS IS" BASIS,
-%% WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-%% See the License for the specific language governing permissions and
-%% limitations under the License.
+%% The contents of this file are subject to the Erlang Public License,
+%% Version 1.1, (the "License"); you may not use this file except in
+%% compliance with the License. You should have received a copy of the
+%% Erlang Public License along with this software. If not, it can be
+%% retrieved online at http://www.erlang.org/.
+%%
+%% Software distributed under the License is distributed on an "AS IS"
+%% basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See
+%% the License for the specific language governing rights and limitations
+%% under the License.
%%
%% %CopyrightEnd%
%%
diff -Nru erlang-18.2-dfsg/bootstrap/lib/stdlib/include/ms_transform.hrl erlang-17.3-dfsg/bootstrap/lib/stdlib/include/ms_transform.hrl
--- erlang-18.2-dfsg/bootstrap/lib/stdlib/include/ms_transform.hrl 2015-12-20 18:13:21.000000000 +0000
+++ erlang-17.3-dfsg/bootstrap/lib/stdlib/include/ms_transform.hrl 2014-09-18 07:51:05.000000000 +0000
@@ -3,17 +3,16 @@
%%
%% Copyright Ericsson AB 2002-2009. All Rights Reserved.
%%
-%% Licensed under the Apache License, Version 2.0 (the "License");
-%% you may not use this file except in compliance with the License.
-%% You may obtain a copy of the License at
-%%
-%% http://www.apache.org/licenses/LICENSE-2.0
-%%
-%% Unless required by applicable law or agreed to in writing, software
-%% distributed under the License is distributed on an "AS IS" BASIS,
-%% WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-%% See the License for the specific language governing permissions and
-%% limitations under the License.
+%% The contents of this file are subject to the Erlang Public License,
+%% Version 1.1, (the "License"); you may not use this file except in
+%% compliance with the License. You should have received a copy of the
+%% Erlang Public License along with this software. If not, it can be
+%% retrieved online at http://www.erlang.org/.
+%%
+%% Software distributed under the License is distributed on an "AS IS"
+%% basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See
+%% the License for the specific language governing rights and limitations
+%% under the License.
%%
%% %CopyrightEnd%
%%
diff -Nru erlang-18.2-dfsg/bootstrap/lib/stdlib/include/qlc.hrl erlang-17.3-dfsg/bootstrap/lib/stdlib/include/qlc.hrl
--- erlang-18.2-dfsg/bootstrap/lib/stdlib/include/qlc.hrl 2015-12-20 18:13:21.000000000 +0000
+++ erlang-17.3-dfsg/bootstrap/lib/stdlib/include/qlc.hrl 2014-09-18 07:51:05.000000000 +0000
@@ -3,17 +3,16 @@
%%
%% Copyright Ericsson AB 2004-2009. All Rights Reserved.
%%
-%% Licensed under the Apache License, Version 2.0 (the "License");
-%% you may not use this file except in compliance with the License.
-%% You may obtain a copy of the License at
-%%
-%% http://www.apache.org/licenses/LICENSE-2.0
-%%
-%% Unless required by applicable law or agreed to in writing, software
-%% distributed under the License is distributed on an "AS IS" BASIS,
-%% WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-%% See the License for the specific language governing permissions and
-%% limitations under the License.
+%% The contents of this file are subject to the Erlang Public License,
+%% Version 1.1, (the "License"); you may not use this file except in
+%% compliance with the License. You should have received a copy of the
+%% Erlang Public License along with this software. If not, it can be
+%% retrieved online at http://www.erlang.org/.
+%%
+%% Software distributed under the License is distributed on an "AS IS"
+%% basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See
+%% the License for the specific language governing rights and limitations
+%% under the License.
%%
%% %CopyrightEnd%
%%
diff -Nru erlang-18.2-dfsg/bootstrap/lib/stdlib/include/zip.hrl erlang-17.3-dfsg/bootstrap/lib/stdlib/include/zip.hrl
--- erlang-18.2-dfsg/bootstrap/lib/stdlib/include/zip.hrl 2015-12-20 18:13:21.000000000 +0000
+++ erlang-17.3-dfsg/bootstrap/lib/stdlib/include/zip.hrl 2014-09-18 07:51:05.000000000 +0000
@@ -3,17 +3,16 @@
%%
%% Copyright Ericsson AB 2006-2011. All Rights Reserved.
%%
-%% Licensed under the Apache License, Version 2.0 (the "License");
-%% you may not use this file except in compliance with the License.
-%% You may obtain a copy of the License at
-%%
-%% http://www.apache.org/licenses/LICENSE-2.0
-%%
-%% Unless required by applicable law or agreed to in writing, software
-%% distributed under the License is distributed on an "AS IS" BASIS,
-%% WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-%% See the License for the specific language governing permissions and
-%% limitations under the License.
+%% The contents of this file are subject to the Erlang Public License,
+%% Version 1.1, (the "License"); you may not use this file except in
+%% compliance with the License. You should have received a copy of the
+%% Erlang Public License along with this software. If not, it can be
+%% retrieved online at http://www.erlang.org/.
+%%
+%% Software distributed under the License is distributed on an "AS IS"
+%% basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See
+%% the License for the specific language governing rights and limitations
+%% under the License.
%%
%% %CopyrightEnd%
%%
diff -Nru erlang-18.2-dfsg/configure erlang-17.3-dfsg/configure
--- erlang-18.2-dfsg/configure 2015-12-15 20:10:35.000000000 +0000
+++ erlang-17.3-dfsg/configure 2014-09-16 19:10:57.000000000 +0000
@@ -272,7 +272,7 @@
PACKAGE_BUGREPORT=
ac_subdirs_all="$ac_subdirs_all lib erts"
-ac_subst_vars='SHELL PATH_SEPARATOR PACKAGE_NAME PACKAGE_TARNAME PACKAGE_VERSION PACKAGE_STRING PACKAGE_BUGREPORT exec_prefix prefix program_transform_name bindir sbindir libexecdir datadir sysconfdir sharedstatedir localstatedir libdir includedir oldincludedir infodir mandir build_alias host_alias target_alias DEFS ECHO_C ECHO_N ECHO_T LIBS ERL_TOP CC CFLAGS STATIC_CFLAGS CFLAG_RUNTIME_LIBRARY_PATH CPP CPPFLAGS CXX CXXFLAGS LD LDFLAGS DED_LD DED_LDFLAGS DED_LD_FLAG_RUNTIME_LIBRARY_PATH LFS_CFLAGS LFS_LDFLAGS LFS_LIBS RANLIB AR GETCONF erl_xcomp_sysroot erl_xcomp_isysroot erl_xcomp_bigendian erl_xcomp_double_middle_endian erl_xcomp_linux_nptl erl_xcomp_linux_usable_sigusrx erl_xcomp_linux_usable_sigaltstack erl_xcomp_poll erl_xcomp_kqueue erl_xcomp_putenv_copy erl_xcomp_reliable_fpe erl_xcomp_getaddrinfo erl_xcomp_gethrvtime_procfs_ioctl erl_xcomp_clock_gettime_cpu_time erl_xcomp_after_morecore_hook erl_xcomp_dlsym_brk_wrappers erl_xcomp_ose_ldflags_pass1 erl_xcomp_ose_ldflags_pass2 erl_xcomp_ose_OSEROOT erl_xcomp_ose_STRIP erl_xcomp_ose_LM_POST_LINK erl_xcomp_ose_LM_SET_CONF erl_xcomp_ose_LM_ELF_SIZE erl_xcomp_ose_LM_LCF erl_xcomp_ose_BEAM_LM_CONF erl_xcomp_ose_EPMD_LM_CONF erl_xcomp_ose_RUN_ERL_LM_CONF erl_xcomp_ose_CONFD erl_xcomp_ose_CRT0_LM build build_cpu build_vendor build_os host host_cpu host_vendor host_os TARGET CROSS_COMPILING BOOTSTRAP_ONLY ac_ct_CC EXEEXT OBJEXT ac_ct_CXX ac_ct_LD MAKE_PROG INSTALL_PROGRAM INSTALL_SCRIPT INSTALL_DATA LN_S ac_ct_RANLIB ERTS_VSN OTP_REL OTP_VSN DEFAULT_VERBOSITY NATIVE_LIBS_ENABLED subdirs LIBOBJS LTLIBOBJS'
+ac_subst_vars='SHELL PATH_SEPARATOR PACKAGE_NAME PACKAGE_TARNAME PACKAGE_VERSION PACKAGE_STRING PACKAGE_BUGREPORT exec_prefix prefix program_transform_name bindir sbindir libexecdir datadir sysconfdir sharedstatedir localstatedir libdir includedir oldincludedir infodir mandir build_alias host_alias target_alias DEFS ECHO_C ECHO_N ECHO_T LIBS ERL_TOP CC CFLAGS STATIC_CFLAGS CFLAG_RUNTIME_LIBRARY_PATH CPP CPPFLAGS CXX CXXFLAGS LD LDFLAGS DED_LD DED_LDFLAGS DED_LD_FLAG_RUNTIME_LIBRARY_PATH LFS_CFLAGS LFS_LDFLAGS LFS_LIBS RANLIB AR GETCONF erl_xcomp_sysroot erl_xcomp_isysroot erl_xcomp_bigendian erl_xcomp_double_middle_endian erl_xcomp_linux_clock_gettime_correction erl_xcomp_linux_nptl erl_xcomp_linux_usable_sigusrx erl_xcomp_linux_usable_sigaltstack erl_xcomp_poll erl_xcomp_kqueue erl_xcomp_putenv_copy erl_xcomp_reliable_fpe erl_xcomp_getaddrinfo erl_xcomp_gethrvtime_procfs_ioctl erl_xcomp_clock_gettime_cpu_time erl_xcomp_after_morecore_hook erl_xcomp_dlsym_brk_wrappers erl_xcomp_ose_ldflags_pass1 erl_xcomp_ose_ldflags_pass2 erl_xcomp_ose_OSEROOT erl_xcomp_ose_STRIP erl_xcomp_ose_LM_POST_LINK erl_xcomp_ose_LM_SET_CONF erl_xcomp_ose_LM_ELF_SIZE erl_xcomp_ose_LM_LCF erl_xcomp_ose_BEAM_LM_CONF erl_xcomp_ose_EPMD_LM_CONF erl_xcomp_ose_RUN_ERL_LM_CONF erl_xcomp_ose_CONFD erl_xcomp_ose_CRT0_LM build build_cpu build_vendor build_os host host_cpu host_vendor host_os TARGET CROSS_COMPILING BOOTSTRAP_ONLY ac_ct_CC EXEEXT OBJEXT ac_ct_CXX ac_ct_LD MAKE_PROG INSTALL_PROGRAM INSTALL_SCRIPT INSTALL_DATA LN_S ac_ct_RANLIB ERTS_VSN OTP_REL OTP_VSN DEFAULT_VERBOSITY NATIVE_LIBS_ENABLED subdirs LIBOBJS LTLIBOBJS'
ac_subst_files=''
# Initialize some variables set by options.
@@ -813,6 +813,10 @@
ac_env_erl_xcomp_double_middle_endian_value=$erl_xcomp_double_middle_endian
ac_cv_env_erl_xcomp_double_middle_endian_set=${erl_xcomp_double_middle_endian+set}
ac_cv_env_erl_xcomp_double_middle_endian_value=$erl_xcomp_double_middle_endian
+ac_env_erl_xcomp_linux_clock_gettime_correction_set=${erl_xcomp_linux_clock_gettime_correction+set}
+ac_env_erl_xcomp_linux_clock_gettime_correction_value=$erl_xcomp_linux_clock_gettime_correction
+ac_cv_env_erl_xcomp_linux_clock_gettime_correction_set=${erl_xcomp_linux_clock_gettime_correction+set}
+ac_cv_env_erl_xcomp_linux_clock_gettime_correction_value=$erl_xcomp_linux_clock_gettime_correction
ac_env_erl_xcomp_linux_nptl_set=${erl_xcomp_linux_nptl+set}
ac_env_erl_xcomp_linux_nptl_value=$erl_xcomp_linux_nptl
ac_cv_env_erl_xcomp_linux_nptl_set=${erl_xcomp_linux_nptl+set}
@@ -1041,14 +1045,6 @@
--with-ssl=PATH specify location of OpenSSL include and lib
--with-ssl use SSL (default)
--without-ssl don't use SSL
- --with-ssl-incl=PATH location of OpenSSL include dir, if different than
- specified by --with-ssl=PATH
- --with-ssl-rpath=yes|no|PATHS
- runtime library path for OpenSSL. Default is 'yes',
- which equates to a number of standard locations. If
- 'no', then no runtime library paths wil be used.
- Anything else should be a comma separated list of
- paths.
--with-libatomic_ops=PATH
specify and prefer usage of libatomic_ops in the
ethread library
@@ -1094,6 +1090,9 @@
erl_xcomp_double_middle_endian
double-middle-endian system: yes|no (only used when cross
compiling)
+ erl_xcomp_linux_clock_gettime_correction
+ clock_gettime() can be used for time correction: yes|no (only
+ used when cross compiling)
erl_xcomp_linux_nptl
have Native POSIX Thread Library: yes|no (only used when cross
compiling)
@@ -1663,6 +1662,7 @@
+
default_cache_file=./config.cache
if test "x$no_recursion" != "xyes" -a "x$OVERRIDE_CONFIG_CACHE" = "x"; then
@@ -3547,20 +3547,6 @@
fi;
-
-# Check whether --with-ssl-incl or --without-ssl-incl was given.
-if test "${with_ssl_incl+set}" = set; then
- withval="$with_ssl_incl"
-
-fi;
-
-
-# Check whether --with-ssl-rpath or --without-ssl-rpath was given.
-if test "${with_ssl_rpath+set}" = set; then
- withval="$with_ssl_rpath"
-
-fi;
-
# Check whether --enable-dynamic-ssl-lib or --disable-dynamic-ssl-lib was given.
if test "${enable_dynamic_ssl_lib+set}" = set; then
enableval="$enable_dynamic_ssl_lib"
@@ -3721,7 +3707,7 @@
rm -f $ERL_TOP/lib/SKIP-APPLICATIONS
for app in `cd lib && ls -d *`; do
var=`eval echo \\$with_$app`
- if test X${var} = Xno; then
+ if test X${var} == Xno; then
echo "$app" >> $ERL_TOP/lib/SKIP-APPLICATIONS
fi
done
@@ -4398,6 +4384,7 @@
s,@erl_xcomp_isysroot@,$erl_xcomp_isysroot,;t t
s,@erl_xcomp_bigendian@,$erl_xcomp_bigendian,;t t
s,@erl_xcomp_double_middle_endian@,$erl_xcomp_double_middle_endian,;t t
+s,@erl_xcomp_linux_clock_gettime_correction@,$erl_xcomp_linux_clock_gettime_correction,;t t
s,@erl_xcomp_linux_nptl@,$erl_xcomp_linux_nptl,;t t
s,@erl_xcomp_linux_usable_sigusrx@,$erl_xcomp_linux_usable_sigusrx,;t t
s,@erl_xcomp_linux_usable_sigaltstack@,$erl_xcomp_linux_usable_sigaltstack,;t t
diff -Nru erlang-18.2-dfsg/configure.in erlang-17.3-dfsg/configure.in
--- erlang-18.2-dfsg/configure.in 2015-12-15 20:10:35.000000000 +0000
+++ erlang-17.3-dfsg/configure.in 2014-09-16 19:10:57.000000000 +0000
@@ -4,17 +4,16 @@
dnl
dnl Copyright Ericsson AB 1998-2014. All Rights Reserved.
dnl
-dnl Licensed under the Apache License, Version 2.0 (the "License");
-dnl you may not use this file except in compliance with the License.
-dnl You may obtain a copy of the License at
+dnl The contents of this file are subject to the Erlang Public License,
+dnl Version 1.1, (the "License"); you may not use this file except in
+dnl compliance with the License. You should have received a copy of the
+dnl Erlang Public License along with this software. If not, it can be
+dnl retrieved online at http://www.erlang.org/.
dnl
-dnl http://www.apache.org/licenses/LICENSE-2.0
-dnl
-dnl Unless required by applicable law or agreed to in writing, software
-dnl distributed under the License is distributed on an "AS IS" BASIS,
-dnl WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-dnl See the License for the specific language governing permissions and
-dnl limitations under the License.
+dnl Software distributed under the License is distributed on an "AS IS"
+dnl basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See
+dnl the License for the specific language governing rights and limitations
+dnl under the License.
dnl
dnl %CopyrightEnd%
@@ -263,17 +262,6 @@
AS_HELP_STRING([--with-ssl], [use SSL (default)])
AS_HELP_STRING([--without-ssl], [don't use SSL]))
-AC_ARG_WITH(ssl-incl,
-AS_HELP_STRING([--with-ssl-incl=PATH],
- [location of OpenSSL include dir, if different than specified by --with-ssl=PATH]))
-
-AC_ARG_WITH(ssl-rpath,
-AS_HELP_STRING([--with-ssl-rpath=yes|no|PATHS],
- [runtime library path for OpenSSL. Default is 'yes', which equates to a
- number of standard locations. If 'no', then no runtime
- library paths wil be used. Anything else should be a
- comma separated list of paths.]))
-
AC_ARG_ENABLE(dynamic-ssl-lib,
AS_HELP_STRING([--disable-dynamic-ssl-lib],
[disable using dynamic openssl libraries]))
@@ -424,7 +412,7 @@
rm -f $ERL_TOP/lib/SKIP-APPLICATIONS
for app in `cd lib && ls -d *`; do
var=`eval echo \\$with_$app`
- if test X${var} = Xno; then
+ if test X${var} == Xno; then
echo "$app" >> $ERL_TOP/lib/SKIP-APPLICATIONS
fi
done
diff -Nru erlang-18.2-dfsg/debian/changelog erlang-17.3-dfsg/debian/changelog
--- erlang-18.2-dfsg/debian/changelog 2016-03-12 09:01:04.000000000 +0000
+++ erlang-17.3-dfsg/debian/changelog 2016-03-17 23:22:59.000000000 +0000
@@ -1,146 +1,8 @@
-erlang (1:18.2-dfsg-2~14.04.1) trusty; urgency=medium
+erlang (1:17.3-dfsg-3ubuntu1~14.04.0) trusty; urgency=medium
* backport to trusty
- -- Richard Hansen Sat, 12 Mar 2016 02:58:19 -0500
-
-erlang (1:18.2-dfsg-2ubuntu1) xenial; urgency=low
-
- * Merge from Debian unstable. Remaining changes:
- - d/patches/fix-pointer-conversion.patch: Remove implicit integer to
- pointer conversion.
- - d/control: Drop libwxgtk3.0-dev build dependency. Wx isn't in main,
- and not supposed to.
- - d/control: Drop erlang-wx binary and associated dependencies from
- other erlang-* packages.
- - d/rules: Add "+debug_info" to ERL_COMPILE_FLAGS for debug builds.
- - d/p/bytecode-compat.patch: Specify source/target = 1.5 when compiling
- Java source code.
- - d/rules: Use "-DEPMD6" in CPPFLAGS and ensure this is passed to
- relevant bits of the build process, enabling IPv6 support.
- - d/control: Build erlang-base-hipe on ppc64 and ppc64el.
- - d/control: Drop BD on fop to support demotion to universe.
-
- -- James Page Thu, 14 Jan 2016 15:44:38 +0200
-
-erlang (1:18.2-dfsg-2) unstable; urgency=medium
-
- * Fixed FTBFS for GNU/kFreeBSD and GNU/Hurd due to incorrectly checked
- presence of gethostname_r() function.
- * Fixed FTBFS for X32 architecture due to incorrectly used inline assembly.
-
- -- Sergei Golovan Sun, 27 Dec 2015 12:40:53 +0300
-
-erlang (1:18.2-dfsg-1) unstable; urgency=medium
-
- * New upstream release.
-
- -- Sergei Golovan Sun, 20 Dec 2015 21:11:53 +0300
-
-erlang (1:18.1-dfsg-1) unstable; urgency=medium
-
- * New upstream release.
-
- -- Sergei Golovan Sat, 07 Nov 2015 10:33:50 +0300
-
-erlang (1:18.0-dfsg-2) unstable; urgency=medium
-
- * Added a patch from Chris Lamb which allows Erlang compiler to put
- a specified timestamp into the compiled binaries instead of the
- current time. This helps with reproducibility of Erlang binaries
- (closes: #795834).
-
- -- Sergei Golovan Mon, 17 Aug 2015 15:14:59 +0300
-
-erlang (1:18.0-dfsg-1ubuntu2) xenial; urgency=medium
-
- * d/control: Drop BD on fop to support demotion to universe.
-
- -- James Page Mon, 04 Jan 2016 13:56:48 +0000
-
-erlang (1:18.0-dfsg-1ubuntu1) wily; urgency=low
-
- * Merge from Debian unstable. Remaining changes:
- - d/patches/fix-pointer-conversion.patch: Remove implicit integer to
- pointer conversion.
- - d/control: Drop libwxgtk3.0-dev build dependency. Wx isn't in main,
- and not supposed to.
- - d/control: Drop erlang-wx binary and associated dependencies from
- other erlang-* packages.
- - d/rules: Add "+debug_info" to ERL_COMPILE_FLAGS for debug builds.
- - d/p/bytecode-compat.patch: Specify source/target = 1.5 when compiling
- Java source code.
- - d/rules: Use "-DEPMD6" in CPPFLAGS and ensure this is passed to
- relevant bits of the build process, enabling IPv6 support.
- - d/control: Build erlang-base-hipe on ppc64 and ppc64el.
-
- -- James Page Wed, 08 Jul 2015 13:52:33 +0100
-
-erlang (1:18.0-dfsg-1) unstable; urgency=medium
-
- * New upstream release.
- * Refreshed patches, removed patch which disables SSLv3 protocol in
- the ssl application because this protocol has been disabled upstream.
- * Changed the license in debian/copyright because upstream relicensed
- Erlang/OTP from Erlang public license to Apache 2.0 license.
-
- -- Sergei Golovan Sat, 27 Jun 2015 14:29:01 +0300
-
-erlang (1:17.5-dfsg-2ubuntu1) wily; urgency=low
-
- * Merge from Debian unstable. Remaining changes:
- - d/patches/fix-pointer-conversion.patch: Remove implicit integer to
- pointer conversion.
- - d/control: Drop libwxgtk3.0-dev build dependency. Wx isn't in main,
- and not supposed to.
- - d/control: Drop erlang-wx binary and associated dependencies from
- other erlang-* packages.
- - d/rules: Add "+debug_info" to ERL_COMPILE_FLAGS for debug builds.
- - d/p/bytecode-compat.patch: Specify source/target = 1.5 when compiling
- Java source code.
- - d/rules: Use "-DEPMD6" in CPPFLAGS and ensure this is passed to
- relevant bits of the build process, enabling IPv6 support.
- - d/control: Build erlang-base-hipe on ppc64 and ppc64el.
-
- -- James Page Tue, 07 Jul 2015 17:42:33 +0100
-
-erlang (1:17.5-dfsg-2) unstable; urgency=medium
-
- * Upload into unstable.
- * Removed the patch which fixes TLS POODLE vulnerability in the Erlang
- SSL application (CVE-2015-2774) because it has been applied upstream.
-
- -- Sergei Golovan Wed, 27 May 2015 08:18:40 +0300
-
-erlang (1:17.5-dfsg-1) experimental; urgency=medium
-
- * New upstream release.
- * Put erl_interface.app and erl_interface.appup into the erlang-dev package.
-
- -- Sergei Golovan Wed, 01 Apr 2015 12:04:55 +0300
-
-erlang (1:17.4-dfsg-1) experimental; urgency=medium
-
- * New upstream release.
- * Removed a patch which fixed empty SNI extension processing in the
- ssl application because it has been applied upstream.
- * Removed a patch which removes rpath from the crypto application binary
- and use the new --with-ssl-rpath=no configure option instead.
- * Search for an Erlang module manual page in section 3erl only in
- Emacs Erlang mode (closes: #772876).
-
- -- Sergei Golovan Sun, 14 Dec 2014 09:07:42 +0300
-
-erlang (1:17.3-dfsg-4) unstable; urgency=medium
-
- * Added a patch from upstream which fixes TLS POODLE vulnerability in
- the Erlang SSL application (CVE-2015-2774) (closes: #781839).
- * Fixed erts_gzinflate_buffer() declaration to prevent possible buffer
- overflow (closes: #747593).
- * Replaced libsystemd-daemon-dev by libsystemd-dev in build dependencies
- (closes: #779750).
-
- -- Sergei Golovan Sat, 04 Apr 2015 17:00:55 +0300
+ -- Richard Hansen Thu, 17 Mar 2016 19:20:14 -0400
erlang (1:17.3-dfsg-3ubuntu1) vivid; urgency=low
diff -Nru erlang-18.2-dfsg/debian/control erlang-17.3-dfsg/debian/control
--- erlang-18.2-dfsg/debian/control 2016-01-04 20:12:17.000000000 +0000
+++ erlang-17.3-dfsg/debian/control 2014-12-05 11:15:46.000000000 +0000
@@ -9,8 +9,8 @@
libncurses5-dev, autotools-dev, unixodbc-dev, bison, flex, ed,
dctrl-tools, xsltproc,
libgl1-mesa-dev | libgl-dev, libglu1-mesa-dev | libglu-dev,
- libsctp-dev [linux-any], libsystemd-dev [linux-any], dh-systemd
-Build-Depends-Indep: default-jdk | sun-java6-jdk
+ libsctp-dev [linux-any], libsystemd-daemon-dev [linux-any], dh-systemd
+Build-Depends-Indep: fop, default-jdk | sun-java6-jdk
Build-Conflicts: autoconf2.13, libwxgtk2.4-dev, libwxgtk2.6-dev, libwxgtk2.8-dev
Homepage: http://www.erlang.org/
Vcs-Svn: svn://anonscm.debian.org/pkg-erlang/erlang/trunk/
@@ -201,7 +201,7 @@
Replaces: erlang (<< ${source:Version}), erlang-base (<< ${binary:Version}), erlang-base-hipe (<< ${binary:Version}), erlang-nox (<< ${source:Version}), erlang-x11 (<< ${binary:Version}), erlang-src (<< ${source:Version}), erlang-dev (<< ${binary:Version}), erlang-examples (<< ${source:Version}), erlang-mode (<< 1:12.b.1-dfsg-2), erlang-doc (<< ${source:Upstream-Version}), erlang-doc (>> ${source:Upstream-Version}-999), erlang-manpages (<= 1:11.b.1-2)
Description: Erlang/OTP documentation stylesheets
The erl_docgen package includes XSLT stylesheets and document type
- definitions used for Erlang/OTP documentation. They allow one to
+ definitions used for Erlang/OTP documentation. They allow to
transform documentation to manpage, HTML, and PDF formats.
diff -Nru erlang-18.2-dfsg/debian/copyright erlang-17.3-dfsg/debian/copyright
--- erlang-18.2-dfsg/debian/copyright 2016-01-04 20:12:18.000000000 +0000
+++ erlang-17.3-dfsg/debian/copyright 2014-12-01 04:10:56.000000000 +0000
@@ -29,13 +29,9 @@
with prebuilt architecture-independent binaries. They are removed from the
source package (except for required bootstrap files).
-The files lib/diameter/doc/standards/*, lib/megaco/doc/standards/*,
-lib/ssh/doc/standards/* and lib/inets/doc/archive/* have been removed
+The files lib/megaco/standards/* and lib/ssh/standards/* have been removed
from the upstream tarball because they are not DFSG free.
-The files lib/common_test/priv/*.js have been removed from the upstream tarball
-because they are minified Javascript files.
-
============================================================================
This licence applies to lib/edoc and lib/syntax_tools
@@ -62,8 +58,6 @@
============================================================================
This licence applies to lib/eldap
-Copyright (c) 2010, Torbjorn Tornkvist
-
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
@@ -163,21 +157,291 @@
THE POSSIBILITY OF SUCH INJURY OR DAMAGE.
============================================================================
-This license applies to the rest of the Erlang/OTP source files
-Copyright Ericsson AB 2002-2013. All Rights Reserved.
+ERLANG PUBLIC LICENSE
+Version 1.1
-Licensed under the Apache License, Version 2.0 (the "License");
-you may not use this file except in compliance with the License.
-You may obtain a copy of the License at
+1. Definitions.
- http://www.apache.org/licenses/LICENSE-2.0
+1.1. ``Contributor'' means each entity that creates or contributes to
+the creation of Modifications.
-Unless required by applicable law or agreed to in writing, software
-distributed under the License is distributed on an "AS IS" BASIS,
-WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-See the License for the specific language governing permissions and
-limitations under the License.
+1.2. ``Contributor Version'' means the combination of the Original
+Code, prior Modifications used by a Contributor, and the Modifications
+made by that particular Contributor.
+
+1.3. ``Covered Code'' means the Original Code or Modifications or the
+combination of the Original Code and Modifications, in each case
+including portions thereof.
+
+1.4. ``Electronic Distribution Mechanism'' means a mechanism generally
+accepted in the software development community for the electronic
+transfer of data.
+
+1.5. ``Executable'' means Covered Code in any form other than Source
+Code.
+
+1.6. ``Initial Developer'' means the individual or entity identified
+as the Initial Developer in the Source Code notice required by Exhibit
+A.
+
+1.7. ``Larger Work'' means a work which combines Covered Code or
+portions thereof with code not governed by the terms of this License.
+
+1.8. ``License'' means this document.
+
+1.9. ``Modifications'' means any addition to or deletion from the
+substance or structure of either the Original Code or any previous
+Modifications. When Covered Code is released as a series of files, a
+Modification is:
+
+A. Any addition to or deletion from the contents of a file containing
+ Original Code or previous Modifications.
+
+B. Any new file that contains any part of the Original Code or
+ previous Modifications.
+
+1.10. ``Original Code'' means Source Code of computer software code
+which is described in the Source Code notice required by Exhibit A as
+Original Code, and which, at the time of its release under this
+License is not already Covered Code governed by this License.
+
+1.11. ``Source Code'' means the preferred form of the Covered Code for
+making modifications to it, including all modules it contains, plus
+any associated interface definition files, scripts used to control
+compilation and installation of an Executable, or a list of source
+code differential comparisons against either the Original Code or
+another well known, available Covered Code of the Contributor's
+choice. The Source Code can be in a compressed or archival form,
+provided the appropriate decompression or de-archiving software is
+widely available for no charge.
+
+1.12. ``You'' means an individual or a legal entity exercising rights
+under, and complying with all of the terms of, this License. For legal
+entities,``You'' includes any entity which controls, is controlled by,
+or is under common control with You. For purposes of this definition,
+``control'' means (a) the power, direct or indirect, to cause the
+direction or management of such entity, whether by contract or
+otherwise, or (b) ownership of fifty percent (50%) or more of the
+outstanding shares or beneficial ownership of such entity.
+
+2. Source Code License.
+
+2.1. The Initial Developer Grant.
+The Initial Developer hereby grants You a world-wide, royalty-free,
+non-exclusive license, subject to third party intellectual property
+claims:
+
+(a) to use, reproduce, modify, display, perform, sublicense and
+ distribute the Original Code (or portions thereof) with or without
+ Modifications, or as part of a Larger Work; and
+
+(b) under patents now or hereafter owned or controlled by Initial
+ Developer, to make, have made, use and sell (``Utilize'') the
+ Original Code (or portions thereof), but solely to the extent that
+ any such patent is reasonably necessary to enable You to Utilize
+ the Original Code (or portions thereof) and not to any greater
+ extent that may be necessary to Utilize further Modifications or
+ combinations.
+
+2.2. Contributor Grant.
+Each Contributor hereby grants You a world-wide, royalty-free,
+non-exclusive license, subject to third party intellectual property
+claims:
+
+(a) to use, reproduce, modify, display, perform, sublicense and
+ distribute the Modifications created by such Contributor (or
+ portions thereof) either on an unmodified basis, with other
+ Modifications, as Covered Code or as part of a Larger Work; and
+
+(b) under patents now or hereafter owned or controlled by Contributor,
+ to Utilize the Contributor Version (or portions thereof), but
+ solely to the extent that any such patent is reasonably necessary
+ to enable You to Utilize the Contributor Version (or portions
+ thereof), and not to any greater extent that may be necessary to
+ Utilize further Modifications or combinations.
+
+3. Distribution Obligations.
+
+3.1. Application of License.
+The Modifications which You contribute are governed by the terms of
+this License, including without limitation Section 2.2. The Source
+Code version of Covered Code may be distributed only under the terms
+of this License, and You must include a copy of this License with
+every copy of the Source Code You distribute. You may not offer or
+impose any terms on any Source Code version that alters or restricts
+the applicable version of this License or the recipients' rights
+hereunder. However, You may include an additional document offering
+the additional rights described in Section 3.5.
+
+3.2. Availability of Source Code.
+Any Modification which You contribute must be made available in Source
+Code form under the terms of this License either on the same media as
+an Executable version or via an accepted Electronic Distribution
+Mechanism to anyone to whom you made an Executable version available;
+and if made available via Electronic Distribution Mechanism, must
+remain available for at least twelve (12) months after the date it
+initially became available, or at least six (6) months after a
+subsequent version of that particular Modification has been made
+available to such recipients. You are responsible for ensuring that
+the Source Code version remains available even if the Electronic
+Distribution Mechanism is maintained by a third party.
+
+3.3. Description of Modifications.
+You must cause all Covered Code to which you contribute to contain a
+file documenting the changes You made to create that Covered Code and
+the date of any change. You must include a prominent statement that
+the Modification is derived, directly or indirectly, from Original
+Code provided by the Initial Developer and including the name of the
+Initial Developer in (a) the Source Code, and (b) in any notice in an
+Executable version or related documentation in which You describe the
+origin or ownership of the Covered Code.
+
+3.4. Intellectual Property Matters
+
+(a) Third Party Claims.
+ If You have knowledge that a party claims an intellectual property
+ right in particular functionality or code (or its utilization
+ under this License), you must include a text file with the source
+ code distribution titled ``LEGAL'' which describes the claim and
+ the party making the claim in sufficient detail that a recipient
+ will know whom to contact. If you obtain such knowledge after You
+ make Your Modification available as described in Section 3.2, You
+ shall promptly modify the LEGAL file in all copies You make
+ available thereafter and shall take other steps (such as notifying
+ appropriate mailing lists or newsgroups) reasonably calculated to
+ inform those who received the Covered Code that new knowledge has
+ been obtained.
+
+(b) Contributor APIs.
+ If Your Modification is an application programming interface and
+ You own or control patents which are reasonably necessary to
+ implement that API, you must also include this information in the
+ LEGAL file.
+
+3.5. Required Notices.
+You must duplicate the notice in Exhibit A in each file of the Source
+Code, and this License in any documentation for the Source Code, where
+You describe recipients' rights relating to Covered Code. If You
+created one or more Modification(s), You may add your name as a
+Contributor to the notice described in Exhibit A. If it is not
+possible to put such notice in a particular Source Code file due to
+its structure, then you must include such notice in a location (such
+as a relevant directory file) where a user would be likely to look for
+such a notice. You may choose to offer, and to charge a fee for,
+warranty, support, indemnity or liability obligations to one or more
+recipients of Covered Code. However, You may do so only on Your own
+behalf, and not on behalf of the Initial Developer or any
+Contributor. You must make it absolutely clear than any such warranty,
+support, indemnity or liability obligation is offered by You alone,
+and You hereby agree to indemnify the Initial Developer and every
+Contributor for any liability incurred by the Initial Developer or
+such Contributor as a result of warranty, support, indemnity or
+liability terms You offer.
+
+3.6. Distribution of Executable Versions.
+You may distribute Covered Code in Executable form only if the
+requirements of Section 3.1-3.5 have been met for that Covered Code,
+and if You include a notice stating that the Source Code version of
+the Covered Code is available under the terms of this License,
+including a description of how and where You have fulfilled the
+obligations of Section 3.2. The notice must be conspicuously included
+in any notice in an Executable version, related documentation or
+collateral in which You describe recipients' rights relating to the
+Covered Code. You may distribute the Executable version of Covered
+Code under a license of Your choice, which may contain terms different
+from this License, provided that You are in compliance with the terms
+of this License and that the license for the Executable version does
+not attempt to limit or alter the recipient's rights in the Source
+Code version from the rights set forth in this License. If You
+distribute the Executable version under a different license You must
+make it absolutely clear that any terms which differ from this License
+are offered by You alone, not by the Initial Developer or any
+Contributor. You hereby agree to indemnify the Initial Developer and
+every Contributor for any liability incurred by the Initial Developer
+or such Contributor as a result of any such terms You offer.
+
+3.7. Larger Works.
+You may create a Larger Work by combining Covered Code with other code
+not governed by the terms of this License and distribute the Larger
+Work as a single product. In such a case, You must make sure the
+requirements of this License are fulfilled for the Covered Code.
+
+4. Inability to Comply Due to Statute or Regulation.
+If it is impossible for You to comply with any of the terms of this
+License with respect to some or all of the Covered Code due to statute
+or regulation then You must: (a) comply with the terms of this License
+to the maximum extent possible; and (b) describe the limitations and
+the code they affect. Such description must be included in the LEGAL
+file described in Section 3.4 and must be included with all
+distributions of the Source Code. Except to the extent prohibited by
+statute or regulation, such description must be sufficiently detailed
+for a recipient of ordinary skill to be able to understand it.
+
+5. Application of this License.
+
+This License applies to code to which the Initial Developer has
+attached the notice in Exhibit A, and to related Covered Code.
+
+6. CONNECTION TO MOZILLA PUBLIC LICENSE
+
+This Erlang License is a derivative work of the Mozilla Public
+License, Version 1.0. It contains terms which differ from the Mozilla
+Public License, Version 1.0.
+
+7. DISCLAIMER OF WARRANTY.
+
+COVERED CODE IS PROVIDED UNDER THIS LICENSE ON AN ``AS IS'' BASIS,
+WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING,
+WITHOUT LIMITATION, WARRANTIES THAT THE COVERED CODE IS FREE OF
+DEFECTS, MERCHANTABLE, FIT FOR A PARTICULAR PURPOSE OR
+NON-INFRINGING. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF
+THE COVERED CODE IS WITH YOU. SHOULD ANY COVERED CODE PROVE DEFECTIVE
+IN ANY RESPECT, YOU (NOT THE INITIAL DEVELOPER OR ANY OTHER
+CONTRIBUTOR) ASSUME THE COST OF ANY NECESSARY SERVICING, REPAIR OR
+CORRECTION. THIS DISCLAIMER OF WARRANTY CONSTITUTES AN ESSENTIAL PART
+OF THIS LICENSE. NO USE OF ANY COVERED CODE IS AUTHORIZED HEREUNDER
+EXCEPT UNDER THIS DISCLAIMER.
+
+8. TERMINATION.
+This License and the rights granted hereunder will terminate
+automatically if You fail to comply with terms herein and fail to cure
+such breach within 30 days of becoming aware of the breach. All
+sublicenses to the Covered Code which are properly granted shall
+survive any termination of this License. Provisions which, by their
+nature, must remain in effect beyond the termination of this License
+shall survive.
+
+9. DISCLAIMER OF LIABILITY
+Any utilization of Covered Code shall not cause the Initial Developer
+or any Contributor to be liable for any damages (neither direct nor
+indirect).
+
+10. MISCELLANEOUS
+This License represents the complete agreement concerning the subject
+matter hereof. If any provision is held to be unenforceable, such
+provision shall be reformed only to the extent necessary to make it
+enforceable. This License shall be construed by and in accordance with
+the substantive laws of Sweden. Any dispute, controversy or claim
+arising out of or relating to this License, or the breach, termination
+or invalidity thereof, shall be subject to the exclusive jurisdiction
+of Swedish courts, with the Stockholm City Court as the first
+instance.
+
+EXHIBIT A.
+
+``The contents of this file are subject to the Erlang Public License,
+Version 1.1, (the "License"); you may not use this file except in
+compliance with the License. You should have received a copy of the
+Erlang Public License along with this software. If not, it can be
+retrieved via the world wide web at http://www.erlang.org/.
+
+Software distributed under the License is distributed on an "AS IS"
+basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See
+the License for the specific language governing rights and limitations
+under the License.
+
+The Initial Developer of the Original Code is Ericsson Utvecklings AB.
+Portions created by Ericsson are Copyright 1999, Ericsson Utvecklings
+AB. All Rights Reserved.''
-On a Debian system the complete text of the Apache-2.0 license can be
-found in /usr/share/common-licenses/Apache-2.0
diff -Nru erlang-18.2-dfsg/debian/patches/beamload.patch erlang-17.3-dfsg/debian/patches/beamload.patch
--- erlang-18.2-dfsg/debian/patches/beamload.patch 2016-01-04 20:12:18.000000000 +0000
+++ erlang-17.3-dfsg/debian/patches/beamload.patch 1970-01-01 00:00:00.000000000 +0000
@@ -1,15 +0,0 @@
-Author: Sergei Golovan
-Description: Patch fixes function declaration.
-Bugs-Debian: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=747593
-
---- a/erts/emulator/beam/beam_load.c
-+++ b/erts/emulator/beam/beam_load.c
-@@ -45,7 +45,7 @@
- #include "hipe_arch.h"
- #endif
-
--ErlDrvBinary* erts_gzinflate_buffer(char*, int);
-+ErlDrvBinary* erts_gzinflate_buffer(char*, uLong);
-
- #define MAX_OPARGS 8
- #define CALLED 0
diff -Nru erlang-18.2-dfsg/debian/patches/bytecode-compat.patch erlang-17.3-dfsg/debian/patches/bytecode-compat.patch
--- erlang-18.2-dfsg/debian/patches/bytecode-compat.patch 2016-01-14 12:33:45.000000000 +0000
+++ erlang-17.3-dfsg/debian/patches/bytecode-compat.patch 2013-07-10 09:29:30.000000000 +0000
@@ -10,7 +10,7 @@
--- a/lib/ic/java_src/com/ericsson/otp/ic/Makefile
+++ b/lib/ic/java_src/com/ericsson/otp/ic/Makefile
-@@ -91,7 +91,7 @@ ifneq ($(V),0)
+@@ -90,7 +90,7 @@ ifneq ($(V),0)
JARFLAGS= -cfv
endif
@@ -21,12 +21,12 @@
# Make Rules
--- a/lib/jinterface/java_src/com/ericsson/otp/erlang/Makefile
+++ b/lib/jinterface/java_src/com/ericsson/otp/erlang/Makefile
-@@ -79,7 +79,7 @@ ifneq ($(V),0)
+@@ -66,7 +66,7 @@ ifneq ($(V),0)
JARFLAGS=-cfv
endif
--JAVA_OPTIONS = -Xlint
-+JAVA_OPTIONS = -Xlint -source 1.5 -target 1.5
+-JAVA_OPTIONS =
++JAVA_OPTIONS = -source 1.5 -target 1.5
ifeq ($(TESTROOT),)
RELEASE_PATH="$(ERL_TOP)/release/$(TARGET)"
diff -Nru erlang-18.2-dfsg/debian/patches/clean.patch erlang-17.3-dfsg/debian/patches/clean.patch
--- erlang-18.2-dfsg/debian/patches/clean.patch 2016-01-04 20:12:18.000000000 +0000
+++ erlang-17.3-dfsg/debian/patches/clean.patch 2014-12-01 04:10:57.000000000 +0000
@@ -5,7 +5,7 @@
--- a/Makefile.in
+++ b/Makefile.in
-@@ -1093,6 +1093,7 @@
+@@ -1092,6 +1092,7 @@
rm -f *~ *.bak config.log config.status prebuilt.files ibin/*
cd erts && ERL_TOP=$(ERL_TOP) $(MAKE) clean
cd lib && ERL_TOP=$(ERL_TOP) $(MAKE) clean BUILD_ALL=true
@@ -13,7 +13,7 @@
distclean: clean
find . -type f -name SKIP -print | xargs $(RM)
-@@ -1134,3 +1135,209 @@
+@@ -1133,3 +1134,209 @@
|| $(MAKE) BOOTSTRAP_ROOT=$(BOOTSTRAP_ROOT) bootstrap_root_clean
# ----------------------------------------------------------------------
diff -Nru erlang-18.2-dfsg/debian/patches/docs.patch erlang-17.3-dfsg/debian/patches/docs.patch
--- erlang-18.2-dfsg/debian/patches/docs.patch 2016-01-04 20:12:18.000000000 +0000
+++ erlang-17.3-dfsg/debian/patches/docs.patch 2014-12-01 04:10:57.000000000 +0000
@@ -5,7 +5,7 @@
--- a/lib/erl_docgen/priv/xsl/db_man.xsl
+++ b/lib/erl_docgen/priv/xsl/db_man.xsl
-@@ -517,7 +517,7 @@
+@@ -516,7 +516,7 @@
.RS 2
.LP
@@ -14,7 +14,7 @@
-@@ -853,7 +853,7 @@
+@@ -824,7 +824,7 @@
.RS
@@ -25,7 +25,7 @@
--- a/lib/megaco/doc/src/Makefile
+++ b/lib/megaco/doc/src/Makefile
-@@ -170,8 +170,6 @@
+@@ -169,8 +169,6 @@
$(INSTALL_DATA) $(INFO_FILE) "$(RELSYSDIR)"
$(INSTALL_DIR) "$(RELEASE_PATH)/man/man3"
$(INSTALL_DATA) $(MAN3DIR)/* "$(RELEASE_PATH)/man/man3"
@@ -36,7 +36,7 @@
--- a/lib/stdlib/doc/src/re.xml
+++ b/lib/stdlib/doc/src/re.xml
-@@ -377,7 +377,7 @@
+@@ -372,7 +372,7 @@
metacharacter should not match before it. Setting this without
multiline (at compile time) causes circumflex never to
match. This option only affects the behavior of the circumflex
@@ -45,7 +45,7 @@
noteol
-@@ -386,8 +386,8 @@
+@@ -381,8 +381,8 @@
match it nor (except in multiline mode) a newline immediately
before it. Setting this without multiline (at compile time)
causes dollar never to match. This option affects only the
@@ -58,7 +58,7 @@
--- a/lib/tools/Makefile
+++ b/lib/tools/Makefile
-@@ -24,7 +24,7 @@
+@@ -23,7 +23,7 @@
# Macros
# ----------------------------------------------------
@@ -69,7 +69,7 @@
VSN = $(TOOLS_VSN)
--- a/system/doc/top/Makefile
+++ b/system/doc/top/Makefile
-@@ -35,7 +35,7 @@
+@@ -34,7 +34,7 @@
GIF_FILES =
diff -Nru erlang-18.2-dfsg/debian/patches/emacs.patch erlang-17.3-dfsg/debian/patches/emacs.patch
--- erlang-18.2-dfsg/debian/patches/emacs.patch 2016-01-04 20:12:18.000000000 +0000
+++ erlang-17.3-dfsg/debian/patches/emacs.patch 2014-12-01 04:10:57.000000000 +0000
@@ -5,7 +5,7 @@
--- a/lib/tools/emacs/erlang.el
+++ b/lib/tools/emacs/erlang.el
-@@ -498,8 +498,8 @@
+@@ -497,8 +497,8 @@
(defvar erlang-man-dirs
'(("Man - Commands" "/man/man1" t)
("Man - Modules" "/man/man3" t)
@@ -16,7 +16,7 @@
"*The man directories displayed in the Erlang menu.
Each item in the list should be a list with three elements, the first
-@@ -1292,23 +1292,22 @@
+@@ -1286,23 +1286,22 @@
(or (fboundp 'eval-when-compile)
(defmacro eval-when-compile (&rest rest) nil))
@@ -44,7 +44,7 @@
;; defvar some obsolete variables, which we still support for
;; backwards compatibility reasons.
-@@ -2031,7 +2030,7 @@
+@@ -2025,7 +2024,7 @@
(defun erlang-man-make-menu-item (file)
"Create a menu item containing the name of the man page."
@@ -53,7 +53,7 @@
(let ((page (substring file (match-beginning 1) (match-end 1))))
(list (capitalize page)
(list 'lambda '()
-@@ -2042,7 +2041,7 @@
+@@ -2036,7 +2035,7 @@
(defun erlang-man-get-files (dir)
"Return files in directory DIR."
@@ -62,16 +62,16 @@
(defun erlang-man-module (&optional module)
-@@ -2062,7 +2061,7 @@
+@@ -2056,7 +2055,7 @@
(if (or (null module) (string= module ""))
(error "No Erlang module name given"))
(let ((dir-list erlang-man-dirs)
- (pat (concat "/" (regexp-quote module) "\\.\\([124-9]\\|3\\(erl\\)?\\)\\(\\.gz\\)?$"))
-+ (pat (concat "/" (regexp-quote module) "\\.\\(3\\(erl\\)\\)\\(\\.gz\\)?$"))
++ (pat (concat "/" (regexp-quote module) "\\.\\([124-9]\\|3\\(erl\\)\\)\\(\\.gz\\)?$"))
(file nil)
file-list)
(while (and dir-list (null file))
-@@ -2203,9 +2202,9 @@
+@@ -2197,9 +2196,9 @@
(error nil))
(if file
(let ((process-environment (copy-sequence process-environment)))
diff -Nru erlang-18.2-dfsg/debian/patches/fix-pointer-converstion.patch erlang-17.3-dfsg/debian/patches/fix-pointer-converstion.patch
--- erlang-18.2-dfsg/debian/patches/fix-pointer-converstion.patch 2016-01-14 12:33:38.000000000 +0000
+++ erlang-17.3-dfsg/debian/patches/fix-pointer-converstion.patch 2013-07-10 09:29:30.000000000 +0000
@@ -2,9 +2,11 @@
Subject: resolve buildd failure "Function `erl_malloc' implicitly converted to pointer at legacy/erl_timeout.c:77"
Bug-Ubuntu: https://launchpad.net/bugs/778484
---- a/lib/erl_interface/src/legacy/erl_timeout.c
-+++ b/lib/erl_interface/src/legacy/erl_timeout.c
-@@ -46,6 +46,7 @@
+Index: erlang-14.b.4-dfsg-1ubuntu1/lib/erl_interface/src/legacy/erl_timeout.c
+===================================================================
+--- erlang-14.b.4-dfsg-1ubuntu1.orig/lib/erl_interface/src/legacy/erl_timeout.c 2011-12-15 16:39:50.958344893 -0800
++++ erlang-14.b.4-dfsg-1ubuntu1/lib/erl_interface/src/legacy/erl_timeout.c 2011-12-15 16:40:45.183171477 -0800
+@@ -45,6 +45,7 @@
#include "erl_interface.h"
#include "erl_timeout.h"
@@ -12,7 +14,7 @@
typedef struct jmp_s {
jmp_buf jmpbuf;
-@@ -76,7 +77,7 @@ jmp_buf *timeout_setup(int ms)
+@@ -75,7 +76,7 @@
t.it_value.tv_usec = (ms % 1000) * 1000;
/* get a jump buffer and save it */
diff -Nru erlang-18.2-dfsg/debian/patches/gethostbyname.patch erlang-17.3-dfsg/debian/patches/gethostbyname.patch
--- erlang-18.2-dfsg/debian/patches/gethostbyname.patch 2015-12-27 05:08:00.000000000 +0000
+++ erlang-17.3-dfsg/debian/patches/gethostbyname.patch 1970-01-01 00:00:00.000000000 +0000
@@ -1,15 +0,0 @@
-Author: Sergei Golovan
-Description: Patch fixes FTBFS on GNU/kFreeBSD and GNU/Hurd.
-Last-Modified: Sun, 27 Dec 2015 08:05:22 +0300
-
---- a/lib/erl_interface/src/connect/ei_resolve.c
-+++ b/lib/erl_interface/src/connect/ei_resolve.c
-@@ -607,7 +607,7 @@
- *
- * TODO: check this properly in configure.in
- */
--#if (defined(__linux__) || (__FreeBSD_version >= 602000) || defined(__DragonFly__))
-+#if (defined(__GLIBC__) || defined(__linux__) || (__FreeBSD_version >= 602000) || defined(__DragonFly__))
- #define HAVE_GETHOSTBYADDR_R_8 1
- #endif
-
diff -Nru erlang-18.2-dfsg/debian/patches/gnu.patch erlang-17.3-dfsg/debian/patches/gnu.patch
--- erlang-18.2-dfsg/debian/patches/gnu.patch 2016-01-04 20:12:18.000000000 +0000
+++ erlang-17.3-dfsg/debian/patches/gnu.patch 2014-12-01 04:10:57.000000000 +0000
@@ -13,7 +13,7 @@
--- a/erts/configure.in
+++ b/erts/configure.in
-@@ -464,7 +464,7 @@
+@@ -481,7 +481,7 @@
dnl NOTE: CPPFLAGS will be included in CFLAGS at the end
case $host_os in
@@ -22,7 +22,7 @@
win32)
# The ethread library requires _WIN32_WINNT of at least 0x0403.
# -D_WIN32_WINNT=* from CPPFLAGS is saved in ETHR_DEFS.
-@@ -1339,7 +1339,7 @@
+@@ -1334,7 +1334,7 @@
solaris*)
enable_child_waiter_thread=yes
;;
@@ -33,7 +33,7 @@
AC_DEFINE(ERTS_NEED_DLOPEN_BEFORE_DLERROR,[1],
--- a/lib/os_mon/c_src/memsup.c
+++ b/lib/os_mon/c_src/memsup.c
-@@ -99,6 +99,11 @@
+@@ -98,6 +98,11 @@
#include
#include
@@ -47,9 +47,9 @@
#include
--- a/erts/emulator/drivers/common/inet_drv.c
+++ b/erts/emulator/drivers/common/inet_drv.c
-@@ -723,6 +723,11 @@
- (((unsigned char*) (s))[1] << 8) | \
- (((unsigned char*) (s))[0]))
+@@ -692,6 +692,11 @@
+ inet_driver_select((d)->port, (ErlDrvEvent)(long)(d)->event, (flags), (onoff)); \
+ } while(0)
+#ifdef __GNU__
+#warning "Undefined AF_LINK for GNU/Hurd"
@@ -57,11 +57,11 @@
+#endif
+
- #ifdef VALGRIND
- # include
+ #endif /* !__WIN32__ && !__OSE__ */
+
--- a/erts/etc/common/erlexec.c
+++ b/erts/etc/common/erlexec.c
-@@ -1581,7 +1581,7 @@
+@@ -1561,7 +1561,7 @@
if (!bindir) {
/* Determine bindir from absolute path to executable */
char *p;
@@ -70,7 +70,7 @@
strncpy(buffer, argv[0], sizeof(buffer));
buffer[sizeof(buffer)-1] = '\0';
-@@ -1595,7 +1595,7 @@
+@@ -1575,7 +1575,7 @@
if (!rootdir) {
/* Determine rootdir from absolute path to bindir */
char *p;
@@ -81,7 +81,7 @@
--- a/erts/etc/common/escript.c
+++ b/erts/etc/common/escript.c
-@@ -55,7 +55,7 @@
+@@ -54,7 +54,7 @@
# define IS_DIRSEP(c) ((c) == '/')
# define DIRSEPSTR "/"
# define PATHSEPSTR ":"
@@ -92,7 +92,7 @@
--- a/erts/etc/unix/dyn_erl.c
+++ b/erts/etc/unix/dyn_erl.c
-@@ -150,8 +150,8 @@
+@@ -149,8 +149,8 @@
static char *
find_prog(char *origpath)
{
@@ -103,7 +103,7 @@
strcpy(relpath, origpath);
-@@ -162,7 +162,7 @@
+@@ -161,7 +161,7 @@
envpath = get_env("PATH");
if (envpath) {
/* Try to find the executable in the path */
@@ -112,7 +112,7 @@
char *beg = envpath;
char *end;
int sz;
-@@ -276,7 +276,7 @@
+@@ -275,7 +275,7 @@
/* List install dir and look for latest erts-vsn */
DIR *dp; /* Pointer to directory structure. */
struct dirent* dirp; /* Pointer to directory entry. */
@@ -121,7 +121,7 @@
dp = opendir(erl_top);
if (dp == NULL) {
-@@ -316,7 +316,7 @@
+@@ -315,7 +315,7 @@
char *p;
char *p2;
@@ -130,7 +130,7 @@
strcpy(buffer, erlpath);
-@@ -359,9 +359,9 @@
+@@ -358,9 +358,9 @@
char *p;
char *abspath;
char *bindir; /* Location of executables. */
diff -Nru erlang-18.2-dfsg/debian/patches/hppa.patch erlang-17.3-dfsg/debian/patches/hppa.patch
--- erlang-18.2-dfsg/debian/patches/hppa.patch 2016-01-04 20:12:18.000000000 +0000
+++ erlang-17.3-dfsg/debian/patches/hppa.patch 2014-12-01 04:10:57.000000000 +0000
@@ -8,7 +8,7 @@
--- a/erts/configure.in
+++ b/erts/configure.in
-@@ -2184,6 +2184,14 @@
+@@ -2160,6 +2160,14 @@
AC_CHECK_DECLS([posix2time, time2posix],,,[#include ])
disable_vfork=false
diff -Nru erlang-18.2-dfsg/debian/patches/java.patch erlang-17.3-dfsg/debian/patches/java.patch
--- erlang-18.2-dfsg/debian/patches/java.patch 2016-01-04 20:12:18.000000000 +0000
+++ erlang-17.3-dfsg/debian/patches/java.patch 2014-12-01 04:10:57.000000000 +0000
@@ -8,19 +8,19 @@
--- a/erts/configure.in
+++ b/erts/configure.in
-@@ -4761,7 +4761,8 @@
- dnl Make sure it's at least JDK 1.6
- AC_CACHE_CHECK(for JDK version 1.6,
- ac_cv_prog_javac_ver_1_6,
+@@ -4682,7 +4682,8 @@
+ dnl Make sure it's at least JDK 1.5
+ AC_CACHE_CHECK(for JDK version 1.5,
+ ac_cv_prog_javac_ver_1_5,
- [ERL_TRY_LINK_JAVA([], [for (String i : args);],
+ [ERL_TRY_LINK_JAVA([], [for (String i : args);
+ int[] values = {}; String s = new String(values, 0, values.length);],
- ac_cv_prog_javac_ver_1_6=yes, ac_cv_prog_javac_ver_1_6=no)])
- if test $ac_cv_prog_javac_ver_1_6 = no; then
+ ac_cv_prog_javac_ver_1_5=yes, ac_cv_prog_javac_ver_1_5=no)])
+ if test $ac_cv_prog_javac_ver_1_5 = no; then
unset -v JAVAC
--- a/lib/test_server/src/configure.in
+++ b/lib/test_server/src/configure.in
-@@ -485,7 +485,8 @@
+@@ -468,7 +468,8 @@
dnl Make sure it's at least JDK 1.5
AC_CACHE_CHECK(for JDK version 1.5,
ac_cv_prog_javac_ver_1_5,
diff -Nru erlang-18.2-dfsg/debian/patches/javascript.patch erlang-17.3-dfsg/debian/patches/javascript.patch
--- erlang-18.2-dfsg/debian/patches/javascript.patch 2016-01-04 20:12:18.000000000 +0000
+++ erlang-17.3-dfsg/debian/patches/javascript.patch 2014-12-01 04:10:57.000000000 +0000
@@ -1,6 +1,6 @@
--- a/lib/common_test/priv/Makefile.in
+++ b/lib/common_test/priv/Makefile.in
-@@ -61,7 +61,7 @@
+@@ -60,7 +60,7 @@
SCRIPTS =
IMAGES = tile1.jpg
CSS = ct_default.css
diff -Nru erlang-18.2-dfsg/debian/patches/man.patch erlang-17.3-dfsg/debian/patches/man.patch
--- erlang-18.2-dfsg/debian/patches/man.patch 2016-01-04 20:12:18.000000000 +0000
+++ erlang-17.3-dfsg/debian/patches/man.patch 2014-12-01 04:10:57.000000000 +0000
@@ -6,7 +6,7 @@
--- a/erts/etc/common/erlexec.c
+++ b/erts/etc/common/erlexec.c
-@@ -728,8 +728,10 @@
+@@ -722,8 +722,10 @@
error("-man not supported on Windows");
#else
argv[i] = "man";
diff -Nru erlang-18.2-dfsg/debian/patches/reproducible-build.patch erlang-17.3-dfsg/debian/patches/reproducible-build.patch
--- erlang-18.2-dfsg/debian/patches/reproducible-build.patch 2015-08-17 11:40:29.000000000 +0000
+++ erlang-17.3-dfsg/debian/patches/reproducible-build.patch 1970-01-01 00:00:00.000000000 +0000
@@ -1,23 +0,0 @@
-Author: Chris Lamb
-Description: Patch makes erlang compiler honor the SOURCE_DATE_EPOCH
- environment variable and use its value in build results instead of the
- current timestamp. The goal is to maintain reproducible builds. More info:
- https://wiki.debian.org/ReproducibleBuilds
-Bug-Debian: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=795834
-Last-modified: Mon, 17 Aug 2015 14:32:15 +0300
-
---- a/lib/compiler/src/beam_asm.erl
-+++ b/lib/compiler/src/beam_asm.erl
-@@ -226,7 +226,11 @@
- build_attributes(Opts, SourceFile, Attr, MD5) ->
- Misc = case member(slim, Opts) of
- false ->
-- {{Y,Mo,D},{H,Mi,S}} = erlang:universaltime(),
-+ {{Y,Mo,D},{H,Mi,S}} = case string:to_integer(os:getenv("SOURCE_DATE_EPOCH")) of
-+ {N,[]} ->calendar:gregorian_seconds_to_datetime(N +
-+ calendar:datetime_to_gregorian_seconds({{1970,1,1},{0,0,0}}));
-+ {_,_} -> erlang:universaltime()
-+ end,
- [{time,{Y,Mo,D,H,Mi,S}},{source,SourceFile}];
- true -> []
- end,
diff -Nru erlang-18.2-dfsg/debian/patches/rpath.patch erlang-17.3-dfsg/debian/patches/rpath.patch
--- erlang-18.2-dfsg/debian/patches/rpath.patch 1970-01-01 00:00:00.000000000 +0000
+++ erlang-17.3-dfsg/debian/patches/rpath.patch 2014-12-01 04:10:57.000000000 +0000
@@ -0,0 +1,21 @@
+Author: Sergei Golovan
+Description: A quick hack which removes rpath from crypto and ssl applications binaries to
+ satisfy Debian policy.
+Forwarded: no
+Last-modified:Sat, 27 Feb 2010 09:34:43 +0300
+
+--- a/erts/configure.in
++++ b/erts/configure.in
+@@ -4540,9 +4540,9 @@
+ SSL_CC_RUNTIME_LIBRARY_PATH=
+ SSL_LD_RUNTIME_LIBRARY_PATH=
+ SSL_DED_LD_RUNTIME_LIBRARY_PATH=
+-cc_rflg="$CFLAG_RUNTIME_LIBRARY_PATH"
+-ld_rflg="$LDFLAG_RUNTIME_LIBRARY_PATH"
+-ded_ld_rflg="$DED_LD_FLAG_RUNTIME_LIBRARY_PATH"
++cc_rflg=
++ld_rflg=
++ded_ld_rflg=
+
+ if test "$SSL_APP" != "" && test "$SSL_DYNAMIC_ONLY" = "yes" && \
+ { test "$cc_rflg" != "" || test "$ld_rflg" != "" || test "$ded_ld_rflg" != ""; } ; then
diff -Nru erlang-18.2-dfsg/debian/patches/series erlang-17.3-dfsg/debian/patches/series
--- erlang-18.2-dfsg/debian/patches/series 2016-01-14 12:32:56.000000000 +0000
+++ erlang-17.3-dfsg/debian/patches/series 2014-12-05 11:16:15.000000000 +0000
@@ -1,4 +1,5 @@
clean.patch
+rpath.patch
gnu.patch
sparc.patch
man.patch
@@ -7,12 +8,9 @@
java.patch
hppa.patch
javascript.patch
+ssl.patch
wx3.0-constants.patch
-beamload.patch
-reproducible-build.patch
-gethostbyname.patch
-x32.patch
-
+sslv3disable.patch
# Ubuntu patches
fix-pointer-converstion.patch
bytecode-compat.patch
diff -Nru erlang-18.2-dfsg/debian/patches/sparc.patch erlang-17.3-dfsg/debian/patches/sparc.patch
--- erlang-18.2-dfsg/debian/patches/sparc.patch 2016-01-04 20:12:18.000000000 +0000
+++ erlang-17.3-dfsg/debian/patches/sparc.patch 2014-12-01 04:10:57.000000000 +0000
@@ -7,7 +7,7 @@
--- a/erts/configure.in
+++ b/erts/configure.in
-@@ -645,7 +645,7 @@
+@@ -662,7 +662,7 @@
fi
case $chk_arch_ in
@@ -18,7 +18,7 @@
i86pc) ARCH=x86;;
--- a/erts/emulator/beam/beam_emu.c
+++ b/erts/emulator/beam/beam_emu.c
-@@ -997,16 +997,6 @@
+@@ -989,16 +989,6 @@
* in registers.
*/
@@ -35,7 +35,7 @@
# define REG_x0
# define REG_xregs
# define REG_htop
-@@ -1015,7 +1005,6 @@
+@@ -1007,7 +997,6 @@
# define REG_fcalls
# define REG_tmp_arg1
# define REG_tmp_arg2
diff -Nru erlang-18.2-dfsg/debian/patches/ssl.patch erlang-17.3-dfsg/debian/patches/ssl.patch
--- erlang-18.2-dfsg/debian/patches/ssl.patch 1970-01-01 00:00:00.000000000 +0000
+++ erlang-17.3-dfsg/debian/patches/ssl.patch 2014-09-27 15:06:21.000000000 +0000
@@ -0,0 +1,13 @@
+--- a/lib/ssl/src/ssl_handshake.erl
++++ b/lib/ssl/src/ssl_handshake.erl
+@@ -1732,6 +1732,10 @@
+ #ec_point_formats{ec_point_format_list =
+ ECPointFormats}});
+
++dec_hello_extensions(<>, Acc) when Len == 0 ->
++ dec_hello_extensions(Rest, Acc#hello_extensions{sni = ""}); %% Server may send an empy SNI
++
++
+ dec_hello_extensions(<>, Acc) ->
+ <> = ExtData,
diff -Nru erlang-18.2-dfsg/debian/patches/sslv3disable.patch erlang-17.3-dfsg/debian/patches/sslv3disable.patch
--- erlang-18.2-dfsg/debian/patches/sslv3disable.patch 1970-01-01 00:00:00.000000000 +0000
+++ erlang-17.3-dfsg/debian/patches/sslv3disable.patch 2014-11-30 19:38:28.000000000 +0000
@@ -0,0 +1,90 @@
+Description: Patch removes support for SSLv3 protocol because it is proved to
+ be insecure and nobody should use it anymore.
+Author Sergei Golovan
+Bug-Debian: https://bugs.debian.org/771359
+Last-Update: Sun, 30 Nov 2014 20:20:41 +0300
+
+--- a/lib/ssl/doc/src/ssl_app.xml
++++ b/lib/ssl/doc/src/ssl_app.xml
+@@ -47,10 +47,10 @@
+
+ Note that the environment parameters can be set on the command line,
+ for instance,
+- erl ... -ssl protocol_version '[sslv3, tlsv1]' ....
++
erl ... -ssl protocol_version '[tlsv1.1, tlsv1]' ....
+
+
+- ]]>.
++ ]]>.
+ -
+
Protocol that will be supported by started clients and
+ servers. If this option is not set it will default to all
+@@ -58,6 +58,9 @@
+ Note that this option may be overridden by the version option
+ to ssl:connect/[2,3] and ssl:listen/2.
+
++ For Debian GNU/Linux distribution the sslv3 protocol was
++ disabled due to its security issues.
++
+
+
+ ]]>
+--- a/lib/ssl/doc/src/ssl.xml
++++ b/lib/ssl/doc/src/ssl.xml
+@@ -123,7 +123,7 @@
+
+ sslsocket() - opaque to the user.
+
+- protocol() = sslv3 | tlsv1 | 'tlsv1.1' | 'tlsv1.2'
++ protocol() = tlsv1 | 'tlsv1.1' | 'tlsv1.2'
+
+ ciphers() = [ciphersuite()] | string() (according to old API)
+
+--- a/lib/ssl/src/ssl_internal.hrl
++++ b/lib/ssl/src/ssl_internal.hrl
+@@ -64,8 +64,8 @@
+ -define(TRUE, 0).
+ -define(FALSE, 1).
+
+--define(ALL_SUPPORTED_VERSIONS, ['tlsv1.2', 'tlsv1.1', tlsv1, sslv3]).
+--define(MIN_SUPPORTED_VERSIONS, ['tlsv1.1', tlsv1, sslv3]).
++-define(ALL_SUPPORTED_VERSIONS, ['tlsv1.2', 'tlsv1.1', tlsv1]).
++-define(MIN_SUPPORTED_VERSIONS, ['tlsv1.1', tlsv1]).
+ -define(ALL_DATAGRAM_SUPPORTED_VERSIONS, ['dtlsv1.2', dtlsv1]).
+ -define(MIN_DATAGRAM_SUPPORTED_VERSIONS, ['dtlsv1.2', dtlsv1]).
+
+--- a/lib/ssl/src/ssl_record.hrl
++++ b/lib/ssl/src/ssl_record.hrl
+@@ -144,6 +144,7 @@
+ %% }).
+
+ -define(LOWEST_MAJOR_SUPPORTED_VERSION, 3).
++-define(LOWEST_MINOR_SUPPORTED_VERSION, 1).
+
+
+ -record(generic_stream_cipher, {
+--- a/lib/ssl/src/tls_record.erl
++++ b/lib/ssl/src/tls_record.erl
+@@ -276,14 +276,20 @@
+ %%--------------------------------------------------------------------
+ -spec is_acceptable_version(tls_version()) -> boolean().
+ is_acceptable_version({N,_})
+- when N >= ?LOWEST_MAJOR_SUPPORTED_VERSION ->
++ when N > ?LOWEST_MAJOR_SUPPORTED_VERSION ->
++ true;
++is_acceptable_version({N,M})
++ when N == ?LOWEST_MAJOR_SUPPORTED_VERSION andalso M >= ?LOWEST_MINOR_SUPPORTED_VERSION ->
+ true;
+ is_acceptable_version(_) ->
+ false.
+
+ -spec is_acceptable_version(tls_version(), Supported :: [tls_version()]) -> boolean().
+ is_acceptable_version({N,_} = Version, Versions)
+- when N >= ?LOWEST_MAJOR_SUPPORTED_VERSION ->
++ when N > ?LOWEST_MAJOR_SUPPORTED_VERSION ->
++ lists:member(Version, Versions);
++is_acceptable_version({N,M} = Version, Versions)
++ when N == ?LOWEST_MAJOR_SUPPORTED_VERSION andalso M >= ?LOWEST_MINOR_SUPPORTED_VERSION ->
+ lists:member(Version, Versions);
+ is_acceptable_version(_,_) ->
+ false.
diff -Nru erlang-18.2-dfsg/debian/patches/wx3.0-constants.patch erlang-17.3-dfsg/debian/patches/wx3.0-constants.patch
--- erlang-18.2-dfsg/debian/patches/wx3.0-constants.patch 2016-01-04 20:12:18.000000000 +0000
+++ erlang-17.3-dfsg/debian/patches/wx3.0-constants.patch 2014-11-30 19:38:28.000000000 +0000
@@ -8,7 +8,7 @@
--- a/lib/wx/include/wx.hrl
+++ b/lib/wx/include/wx.hrl
-@@ -771,7 +771,7 @@
+@@ -744,7 +744,7 @@
% From "checkbox.h"
-define(wxCHK_ALLOW_3RD_STATE_FOR_USER, 8192).
-define(wxCHK_3STATE, 4096).
@@ -17,7 +17,7 @@
% From "checkbox.h": wxCheckBoxState
-define(wxCHK_UNCHECKED, 0).
-define(wxCHK_CHECKED, 1).
-@@ -1018,10 +1018,10 @@
+@@ -991,10 +991,10 @@
-define(wxSIZE_AUTO_WIDTH, 1).
-define(wxSETUP, 131072).
-define(wxMORE, 65536).
@@ -32,7 +32,7 @@
-define(wxICON_MASK, (16#00000100 bor 16#00000200 bor 16#00000400 bor 16#00000800)).
-define(wxICON_ASTERISK, ?wxICON_INFORMATION).
-define(wxICON_STOP, ?wxICON_HAND).
-@@ -1053,8 +1053,8 @@
+@@ -1026,8 +1026,8 @@
-define(wxTC_TOP, 0).
-define(wxTC_FIXEDWIDTH, 32).
-define(wxTC_RIGHTJUSTIFY, 16).
@@ -43,7 +43,7 @@
-define(wxSP_VERTICAL, ?wxVERTICAL).
-define(wxSP_HORIZONTAL, ?wxHORIZONTAL).
-define(wxSB_VERTICAL, ?wxVERTICAL).
-@@ -1075,8 +1075,8 @@
+@@ -1048,8 +1048,8 @@
-define(wxCB_SIMPLE, 4).
-define(wxLB_INT_HEIGHT, 2048).
-define(wxLB_HSCROLL, ?wxHSCROLL).
@@ -54,7 +54,7 @@
-define(wxLB_OWNERDRAW, 256).
-define(wxLB_EXTENDED, 128).
-define(wxLB_MULTIPLE, 64).
-@@ -1552,7 +1552,7 @@
+@@ -1525,7 +1525,7 @@
-define(wxUPDATE_UI_FROMIDLE, 2).
% From "dialog.h"
-define(wxDEFAULT_DIALOG_STYLE, (?wxCAPTION bor ?wxSYSTEM_MENU bor ?wxCLOSE_BOX)).
@@ -63,7 +63,425 @@
% From "dirctrlg.h"
-define(wxDIRCTRL_DIR_ONLY, 16).
-define(wxDIRCTRL_SELECT_FIRST, 32).
-@@ -3732,7 +3732,7 @@
+@@ -2013,212 +2013,212 @@
+ -define(wxLANGUAGE_ARABIC_YEMEN, 24).
+ -define(wxLANGUAGE_ARMENIAN, 25).
+ -define(wxLANGUAGE_ASSAMESE, 26).
+--define(wxLANGUAGE_AYMARA, 27).
+--define(wxLANGUAGE_AZERI, 28).
+--define(wxLANGUAGE_AZERI_CYRILLIC, 29).
+--define(wxLANGUAGE_AZERI_LATIN, 30).
+--define(wxLANGUAGE_BASHKIR, 31).
+--define(wxLANGUAGE_BASQUE, 32).
+--define(wxLANGUAGE_BELARUSIAN, 33).
+--define(wxLANGUAGE_BENGALI, 34).
+--define(wxLANGUAGE_BHUTANI, 35).
+--define(wxLANGUAGE_BIHARI, 36).
+--define(wxLANGUAGE_BISLAMA, 37).
+--define(wxLANGUAGE_BRETON, 38).
+--define(wxLANGUAGE_BULGARIAN, 39).
+--define(wxLANGUAGE_BURMESE, 40).
+--define(wxLANGUAGE_CAMBODIAN, 41).
+--define(wxLANGUAGE_CATALAN, 42).
+--define(wxLANGUAGE_CHINESE, 43).
+--define(wxLANGUAGE_CHINESE_SIMPLIFIED, 44).
+--define(wxLANGUAGE_CHINESE_TRADITIONAL, 45).
+--define(wxLANGUAGE_CHINESE_HONGKONG, 46).
+--define(wxLANGUAGE_CHINESE_MACAU, 47).
+--define(wxLANGUAGE_CHINESE_SINGAPORE, 48).
+--define(wxLANGUAGE_CHINESE_TAIWAN, 49).
+--define(wxLANGUAGE_CORSICAN, 50).
+--define(wxLANGUAGE_CROATIAN, 51).
+--define(wxLANGUAGE_CZECH, 52).
+--define(wxLANGUAGE_DANISH, 53).
+--define(wxLANGUAGE_DUTCH, 54).
+--define(wxLANGUAGE_DUTCH_BELGIAN, 55).
+--define(wxLANGUAGE_ENGLISH, 56).
+--define(wxLANGUAGE_ENGLISH_UK, 57).
+--define(wxLANGUAGE_ENGLISH_US, 58).
+--define(wxLANGUAGE_ENGLISH_AUSTRALIA, 59).
+--define(wxLANGUAGE_ENGLISH_BELIZE, 60).
+--define(wxLANGUAGE_ENGLISH_BOTSWANA, 61).
+--define(wxLANGUAGE_ENGLISH_CANADA, 62).
+--define(wxLANGUAGE_ENGLISH_CARIBBEAN, 63).
+--define(wxLANGUAGE_ENGLISH_DENMARK, 64).
+--define(wxLANGUAGE_ENGLISH_EIRE, 65).
+--define(wxLANGUAGE_ENGLISH_JAMAICA, 66).
+--define(wxLANGUAGE_ENGLISH_NEW_ZEALAND, 67).
+--define(wxLANGUAGE_ENGLISH_PHILIPPINES, 68).
+--define(wxLANGUAGE_ENGLISH_SOUTH_AFRICA, 69).
+--define(wxLANGUAGE_ENGLISH_TRINIDAD, 70).
+--define(wxLANGUAGE_ENGLISH_ZIMBABWE, 71).
+--define(wxLANGUAGE_ESPERANTO, 72).
+--define(wxLANGUAGE_ESTONIAN, 73).
+--define(wxLANGUAGE_FAEROESE, 74).
+--define(wxLANGUAGE_FARSI, 75).
+--define(wxLANGUAGE_FIJI, 76).
+--define(wxLANGUAGE_FINNISH, 77).
+--define(wxLANGUAGE_FRENCH, 78).
+--define(wxLANGUAGE_FRENCH_BELGIAN, 79).
+--define(wxLANGUAGE_FRENCH_CANADIAN, 80).
+--define(wxLANGUAGE_FRENCH_LUXEMBOURG, 81).
+--define(wxLANGUAGE_FRENCH_MONACO, 82).
+--define(wxLANGUAGE_FRENCH_SWISS, 83).
+--define(wxLANGUAGE_FRISIAN, 84).
+--define(wxLANGUAGE_GALICIAN, 85).
+--define(wxLANGUAGE_GEORGIAN, 86).
+--define(wxLANGUAGE_GERMAN, 87).
+--define(wxLANGUAGE_GERMAN_AUSTRIAN, 88).
+--define(wxLANGUAGE_GERMAN_BELGIUM, 89).
+--define(wxLANGUAGE_GERMAN_LIECHTENSTEIN, 90).
+--define(wxLANGUAGE_GERMAN_LUXEMBOURG, 91).
+--define(wxLANGUAGE_GERMAN_SWISS, 92).
+--define(wxLANGUAGE_GREEK, 93).
+--define(wxLANGUAGE_GREENLANDIC, 94).
+--define(wxLANGUAGE_GUARANI, 95).
+--define(wxLANGUAGE_GUJARATI, 96).
+--define(wxLANGUAGE_HAUSA, 97).
+--define(wxLANGUAGE_HEBREW, 98).
+--define(wxLANGUAGE_HINDI, 99).
+--define(wxLANGUAGE_HUNGARIAN, 100).
+--define(wxLANGUAGE_ICELANDIC, 101).
+--define(wxLANGUAGE_INDONESIAN, 102).
+--define(wxLANGUAGE_INTERLINGUA, 103).
+--define(wxLANGUAGE_INTERLINGUE, 104).
+--define(wxLANGUAGE_INUKTITUT, 105).
+--define(wxLANGUAGE_INUPIAK, 106).
+--define(wxLANGUAGE_IRISH, 107).
+--define(wxLANGUAGE_ITALIAN, 108).
+--define(wxLANGUAGE_ITALIAN_SWISS, 109).
+--define(wxLANGUAGE_JAPANESE, 110).
+--define(wxLANGUAGE_JAVANESE, 111).
+--define(wxLANGUAGE_KANNADA, 112).
+--define(wxLANGUAGE_KASHMIRI, 113).
+--define(wxLANGUAGE_KASHMIRI_INDIA, 114).
+--define(wxLANGUAGE_KAZAKH, 115).
+--define(wxLANGUAGE_KERNEWEK, 116).
+--define(wxLANGUAGE_KINYARWANDA, 117).
+--define(wxLANGUAGE_KIRGHIZ, 118).
+--define(wxLANGUAGE_KIRUNDI, 119).
+--define(wxLANGUAGE_KONKANI, 120).
+--define(wxLANGUAGE_KOREAN, 121).
+--define(wxLANGUAGE_KURDISH, 122).
+--define(wxLANGUAGE_LAOTHIAN, 123).
+--define(wxLANGUAGE_LATIN, 124).
+--define(wxLANGUAGE_LATVIAN, 125).
+--define(wxLANGUAGE_LINGALA, 126).
+--define(wxLANGUAGE_LITHUANIAN, 127).
+--define(wxLANGUAGE_MACEDONIAN, 128).
+--define(wxLANGUAGE_MALAGASY, 129).
+--define(wxLANGUAGE_MALAY, 130).
+--define(wxLANGUAGE_MALAYALAM, 131).
+--define(wxLANGUAGE_MALAY_BRUNEI_DARUSSALAM, 132).
+--define(wxLANGUAGE_MALAY_MALAYSIA, 133).
+--define(wxLANGUAGE_MALTESE, 134).
+--define(wxLANGUAGE_MANIPURI, 135).
+--define(wxLANGUAGE_MAORI, 136).
+--define(wxLANGUAGE_MARATHI, 137).
+--define(wxLANGUAGE_MOLDAVIAN, 138).
+--define(wxLANGUAGE_MONGOLIAN, 139).
+--define(wxLANGUAGE_NAURU, 140).
+--define(wxLANGUAGE_NEPALI, 141).
+--define(wxLANGUAGE_NEPALI_INDIA, 142).
+--define(wxLANGUAGE_NORWEGIAN_BOKMAL, 143).
+--define(wxLANGUAGE_NORWEGIAN_NYNORSK, 144).
+--define(wxLANGUAGE_OCCITAN, 145).
+--define(wxLANGUAGE_ORIYA, 146).
+--define(wxLANGUAGE_OROMO, 147).
+--define(wxLANGUAGE_PASHTO, 148).
+--define(wxLANGUAGE_POLISH, 149).
+--define(wxLANGUAGE_PORTUGUESE, 150).
+--define(wxLANGUAGE_PORTUGUESE_BRAZILIAN, 151).
+--define(wxLANGUAGE_PUNJABI, 152).
+--define(wxLANGUAGE_QUECHUA, 153).
+--define(wxLANGUAGE_RHAETO_ROMANCE, 154).
+--define(wxLANGUAGE_ROMANIAN, 155).
+--define(wxLANGUAGE_RUSSIAN, 156).
+--define(wxLANGUAGE_RUSSIAN_UKRAINE, 157).
+--define(wxLANGUAGE_SAMOAN, 158).
+--define(wxLANGUAGE_SANGHO, 159).
+--define(wxLANGUAGE_SANSKRIT, 160).
+--define(wxLANGUAGE_SCOTS_GAELIC, 161).
+--define(wxLANGUAGE_SERBIAN, 162).
+--define(wxLANGUAGE_SERBIAN_CYRILLIC, 163).
+--define(wxLANGUAGE_SERBIAN_LATIN, 164).
+--define(wxLANGUAGE_SERBO_CROATIAN, 165).
+--define(wxLANGUAGE_SESOTHO, 166).
+--define(wxLANGUAGE_SETSWANA, 167).
+--define(wxLANGUAGE_SHONA, 168).
+--define(wxLANGUAGE_SINDHI, 169).
+--define(wxLANGUAGE_SINHALESE, 170).
+--define(wxLANGUAGE_SISWATI, 171).
+--define(wxLANGUAGE_SLOVAK, 172).
+--define(wxLANGUAGE_SLOVENIAN, 173).
+--define(wxLANGUAGE_SOMALI, 174).
+--define(wxLANGUAGE_SPANISH, 175).
+--define(wxLANGUAGE_SPANISH_ARGENTINA, 176).
+--define(wxLANGUAGE_SPANISH_BOLIVIA, 177).
+--define(wxLANGUAGE_SPANISH_CHILE, 178).
+--define(wxLANGUAGE_SPANISH_COLOMBIA, 179).
+--define(wxLANGUAGE_SPANISH_COSTA_RICA, 180).
+--define(wxLANGUAGE_SPANISH_DOMINICAN_REPUBLIC, 181).
+--define(wxLANGUAGE_SPANISH_ECUADOR, 182).
+--define(wxLANGUAGE_SPANISH_EL_SALVADOR, 183).
+--define(wxLANGUAGE_SPANISH_GUATEMALA, 184).
+--define(wxLANGUAGE_SPANISH_HONDURAS, 185).
+--define(wxLANGUAGE_SPANISH_MEXICAN, 186).
+--define(wxLANGUAGE_SPANISH_MODERN, 187).
+--define(wxLANGUAGE_SPANISH_NICARAGUA, 188).
+--define(wxLANGUAGE_SPANISH_PANAMA, 189).
+--define(wxLANGUAGE_SPANISH_PARAGUAY, 190).
+--define(wxLANGUAGE_SPANISH_PERU, 191).
+--define(wxLANGUAGE_SPANISH_PUERTO_RICO, 192).
+--define(wxLANGUAGE_SPANISH_URUGUAY, 193).
+--define(wxLANGUAGE_SPANISH_US, 194).
+--define(wxLANGUAGE_SPANISH_VENEZUELA, 195).
+--define(wxLANGUAGE_SUNDANESE, 196).
+--define(wxLANGUAGE_SWAHILI, 197).
+--define(wxLANGUAGE_SWEDISH, 198).
+--define(wxLANGUAGE_SWEDISH_FINLAND, 199).
+--define(wxLANGUAGE_TAGALOG, 200).
+--define(wxLANGUAGE_TAJIK, 201).
+--define(wxLANGUAGE_TAMIL, 202).
+--define(wxLANGUAGE_TATAR, 203).
+--define(wxLANGUAGE_TELUGU, 204).
+--define(wxLANGUAGE_THAI, 205).
+--define(wxLANGUAGE_TIBETAN, 206).
+--define(wxLANGUAGE_TIGRINYA, 207).
+--define(wxLANGUAGE_TONGA, 208).
+--define(wxLANGUAGE_TSONGA, 209).
+--define(wxLANGUAGE_TURKISH, 210).
+--define(wxLANGUAGE_TURKMEN, 211).
+--define(wxLANGUAGE_TWI, 212).
+--define(wxLANGUAGE_UIGHUR, 213).
+--define(wxLANGUAGE_UKRAINIAN, 214).
+--define(wxLANGUAGE_URDU, 215).
+--define(wxLANGUAGE_URDU_INDIA, 216).
+--define(wxLANGUAGE_URDU_PAKISTAN, 217).
+--define(wxLANGUAGE_UZBEK, 218).
+--define(wxLANGUAGE_UZBEK_CYRILLIC, 219).
+--define(wxLANGUAGE_UZBEK_LATIN, 220).
+--define(wxLANGUAGE_VIETNAMESE, 221).
+--define(wxLANGUAGE_VOLAPUK, 222).
+--define(wxLANGUAGE_WELSH, 223).
+--define(wxLANGUAGE_WOLOF, 224).
+--define(wxLANGUAGE_XHOSA, 225).
+--define(wxLANGUAGE_YIDDISH, 226).
+--define(wxLANGUAGE_YORUBA, 227).
+--define(wxLANGUAGE_ZHUANG, 228).
+--define(wxLANGUAGE_ZULU, 229).
++-define(wxLANGUAGE_AYMARA, 28).
++-define(wxLANGUAGE_AZERI, 29).
++-define(wxLANGUAGE_AZERI_CYRILLIC, 30).
++-define(wxLANGUAGE_AZERI_LATIN, 31).
++-define(wxLANGUAGE_BASHKIR, 32).
++-define(wxLANGUAGE_BASQUE, 33).
++-define(wxLANGUAGE_BELARUSIAN, 34).
++-define(wxLANGUAGE_BENGALI, 35).
++-define(wxLANGUAGE_BHUTANI, 36).
++-define(wxLANGUAGE_BIHARI, 37).
++-define(wxLANGUAGE_BISLAMA, 38).
++-define(wxLANGUAGE_BRETON, 40).
++-define(wxLANGUAGE_BULGARIAN, 41).
++-define(wxLANGUAGE_BURMESE, 42).
++-define(wxLANGUAGE_CAMBODIAN, 43).
++-define(wxLANGUAGE_CATALAN, 44).
++-define(wxLANGUAGE_CHINESE, 45).
++-define(wxLANGUAGE_CHINESE_SIMPLIFIED, 46).
++-define(wxLANGUAGE_CHINESE_TRADITIONAL, 47).
++-define(wxLANGUAGE_CHINESE_HONGKONG, 48).
++-define(wxLANGUAGE_CHINESE_MACAU, 49).
++-define(wxLANGUAGE_CHINESE_SINGAPORE, 50).
++-define(wxLANGUAGE_CHINESE_TAIWAN, 51).
++-define(wxLANGUAGE_CORSICAN, 52).
++-define(wxLANGUAGE_CROATIAN, 53).
++-define(wxLANGUAGE_CZECH, 54).
++-define(wxLANGUAGE_DANISH, 55).
++-define(wxLANGUAGE_DUTCH, 56).
++-define(wxLANGUAGE_DUTCH_BELGIAN, 57).
++-define(wxLANGUAGE_ENGLISH, 58).
++-define(wxLANGUAGE_ENGLISH_UK, 59).
++-define(wxLANGUAGE_ENGLISH_US, 60).
++-define(wxLANGUAGE_ENGLISH_AUSTRALIA, 61).
++-define(wxLANGUAGE_ENGLISH_BELIZE, 62).
++-define(wxLANGUAGE_ENGLISH_BOTSWANA, 63).
++-define(wxLANGUAGE_ENGLISH_CANADA, 64).
++-define(wxLANGUAGE_ENGLISH_CARIBBEAN, 65).
++-define(wxLANGUAGE_ENGLISH_DENMARK, 66).
++-define(wxLANGUAGE_ENGLISH_EIRE, 67).
++-define(wxLANGUAGE_ENGLISH_JAMAICA, 68).
++-define(wxLANGUAGE_ENGLISH_NEW_ZEALAND, 69).
++-define(wxLANGUAGE_ENGLISH_PHILIPPINES, 70).
++-define(wxLANGUAGE_ENGLISH_SOUTH_AFRICA, 71).
++-define(wxLANGUAGE_ENGLISH_TRINIDAD, 72).
++-define(wxLANGUAGE_ENGLISH_ZIMBABWE, 73).
++-define(wxLANGUAGE_ESPERANTO, 74).
++-define(wxLANGUAGE_ESTONIAN, 75).
++-define(wxLANGUAGE_FAEROESE, 76).
++-define(wxLANGUAGE_FARSI, 77).
++-define(wxLANGUAGE_FIJI, 78).
++-define(wxLANGUAGE_FINNISH, 79).
++-define(wxLANGUAGE_FRENCH, 80).
++-define(wxLANGUAGE_FRENCH_BELGIAN, 81).
++-define(wxLANGUAGE_FRENCH_CANADIAN, 82).
++-define(wxLANGUAGE_FRENCH_LUXEMBOURG, 83).
++-define(wxLANGUAGE_FRENCH_MONACO, 84).
++-define(wxLANGUAGE_FRENCH_SWISS, 85).
++-define(wxLANGUAGE_FRISIAN, 86).
++-define(wxLANGUAGE_GALICIAN, 87).
++-define(wxLANGUAGE_GEORGIAN, 88).
++-define(wxLANGUAGE_GERMAN, 89).
++-define(wxLANGUAGE_GERMAN_AUSTRIAN, 90).
++-define(wxLANGUAGE_GERMAN_BELGIUM, 91).
++-define(wxLANGUAGE_GERMAN_LIECHTENSTEIN, 92).
++-define(wxLANGUAGE_GERMAN_LUXEMBOURG, 93).
++-define(wxLANGUAGE_GERMAN_SWISS, 94).
++-define(wxLANGUAGE_GREEK, 95).
++-define(wxLANGUAGE_GREENLANDIC, 96).
++-define(wxLANGUAGE_GUARANI, 97).
++-define(wxLANGUAGE_GUJARATI, 98).
++-define(wxLANGUAGE_HAUSA, 99).
++-define(wxLANGUAGE_HEBREW, 100).
++-define(wxLANGUAGE_HINDI, 101).
++-define(wxLANGUAGE_HUNGARIAN, 102).
++-define(wxLANGUAGE_ICELANDIC, 103).
++-define(wxLANGUAGE_INDONESIAN, 104).
++-define(wxLANGUAGE_INTERLINGUA, 105).
++-define(wxLANGUAGE_INTERLINGUE, 106).
++-define(wxLANGUAGE_INUKTITUT, 107).
++-define(wxLANGUAGE_INUPIAK, 108).
++-define(wxLANGUAGE_IRISH, 109).
++-define(wxLANGUAGE_ITALIAN, 110).
++-define(wxLANGUAGE_ITALIAN_SWISS, 111).
++-define(wxLANGUAGE_JAPANESE, 112).
++-define(wxLANGUAGE_JAVANESE, 113).
++-define(wxLANGUAGE_KANNADA, 114).
++-define(wxLANGUAGE_KASHMIRI, 115).
++-define(wxLANGUAGE_KASHMIRI_INDIA, 116).
++-define(wxLANGUAGE_KAZAKH, 117).
++-define(wxLANGUAGE_KERNEWEK, 118).
++-define(wxLANGUAGE_KINYARWANDA, 119).
++-define(wxLANGUAGE_KIRGHIZ, 120).
++-define(wxLANGUAGE_KIRUNDI, 121).
++-define(wxLANGUAGE_KONKANI, 122).
++-define(wxLANGUAGE_KOREAN, 123).
++-define(wxLANGUAGE_KURDISH, 124).
++-define(wxLANGUAGE_LAOTHIAN, 125).
++-define(wxLANGUAGE_LATIN, 126).
++-define(wxLANGUAGE_LATVIAN, 127).
++-define(wxLANGUAGE_LINGALA, 128).
++-define(wxLANGUAGE_LITHUANIAN, 129).
++-define(wxLANGUAGE_MACEDONIAN, 130).
++-define(wxLANGUAGE_MALAGASY, 131).
++-define(wxLANGUAGE_MALAY, 132).
++-define(wxLANGUAGE_MALAYALAM, 133).
++-define(wxLANGUAGE_MALAY_BRUNEI_DARUSSALAM, 134).
++-define(wxLANGUAGE_MALAY_MALAYSIA, 135).
++-define(wxLANGUAGE_MALTESE, 136).
++-define(wxLANGUAGE_MANIPURI, 137).
++-define(wxLANGUAGE_MAORI, 138).
++-define(wxLANGUAGE_MARATHI, 139).
++-define(wxLANGUAGE_MOLDAVIAN, 140).
++-define(wxLANGUAGE_MONGOLIAN, 141).
++-define(wxLANGUAGE_NAURU, 142).
++-define(wxLANGUAGE_NEPALI, 143).
++-define(wxLANGUAGE_NEPALI_INDIA, 144).
++-define(wxLANGUAGE_NORWEGIAN_BOKMAL, 145).
++-define(wxLANGUAGE_NORWEGIAN_NYNORSK, 146).
++-define(wxLANGUAGE_OCCITAN, 147).
++-define(wxLANGUAGE_ORIYA, 148).
++-define(wxLANGUAGE_OROMO, 149).
++-define(wxLANGUAGE_PASHTO, 150).
++-define(wxLANGUAGE_POLISH, 151).
++-define(wxLANGUAGE_PORTUGUESE, 152).
++-define(wxLANGUAGE_PORTUGUESE_BRAZILIAN, 153).
++-define(wxLANGUAGE_PUNJABI, 154).
++-define(wxLANGUAGE_QUECHUA, 155).
++-define(wxLANGUAGE_RHAETO_ROMANCE, 156).
++-define(wxLANGUAGE_ROMANIAN, 157).
++-define(wxLANGUAGE_RUSSIAN, 158).
++-define(wxLANGUAGE_RUSSIAN_UKRAINE, 159).
++-define(wxLANGUAGE_SAMOAN, 161).
++-define(wxLANGUAGE_SANGHO, 162).
++-define(wxLANGUAGE_SANSKRIT, 163).
++-define(wxLANGUAGE_SCOTS_GAELIC, 164).
++-define(wxLANGUAGE_SERBIAN, 165).
++-define(wxLANGUAGE_SERBIAN_CYRILLIC, 166).
++-define(wxLANGUAGE_SERBIAN_LATIN, 167).
++-define(wxLANGUAGE_SERBO_CROATIAN, 168).
++-define(wxLANGUAGE_SESOTHO, 169).
++-define(wxLANGUAGE_SETSWANA, 170).
++-define(wxLANGUAGE_SHONA, 171).
++-define(wxLANGUAGE_SINDHI, 172).
++-define(wxLANGUAGE_SINHALESE, 173).
++-define(wxLANGUAGE_SISWATI, 174).
++-define(wxLANGUAGE_SLOVAK, 175).
++-define(wxLANGUAGE_SLOVENIAN, 176).
++-define(wxLANGUAGE_SOMALI, 177).
++-define(wxLANGUAGE_SPANISH, 178).
++-define(wxLANGUAGE_SPANISH_ARGENTINA, 179).
++-define(wxLANGUAGE_SPANISH_BOLIVIA, 180).
++-define(wxLANGUAGE_SPANISH_CHILE, 181).
++-define(wxLANGUAGE_SPANISH_COLOMBIA, 182).
++-define(wxLANGUAGE_SPANISH_COSTA_RICA, 183).
++-define(wxLANGUAGE_SPANISH_DOMINICAN_REPUBLIC, 184).
++-define(wxLANGUAGE_SPANISH_ECUADOR, 185).
++-define(wxLANGUAGE_SPANISH_EL_SALVADOR, 186).
++-define(wxLANGUAGE_SPANISH_GUATEMALA, 187).
++-define(wxLANGUAGE_SPANISH_HONDURAS, 188).
++-define(wxLANGUAGE_SPANISH_MEXICAN, 189).
++-define(wxLANGUAGE_SPANISH_MODERN, 190).
++-define(wxLANGUAGE_SPANISH_NICARAGUA, 191).
++-define(wxLANGUAGE_SPANISH_PANAMA, 192).
++-define(wxLANGUAGE_SPANISH_PARAGUAY, 193).
++-define(wxLANGUAGE_SPANISH_PERU, 194).
++-define(wxLANGUAGE_SPANISH_PUERTO_RICO, 195).
++-define(wxLANGUAGE_SPANISH_URUGUAY, 196).
++-define(wxLANGUAGE_SPANISH_US, 197).
++-define(wxLANGUAGE_SPANISH_VENEZUELA, 198).
++-define(wxLANGUAGE_SUNDANESE, 199).
++-define(wxLANGUAGE_SWAHILI, 200).
++-define(wxLANGUAGE_SWEDISH, 201).
++-define(wxLANGUAGE_SWEDISH_FINLAND, 202).
++-define(wxLANGUAGE_TAGALOG, 203).
++-define(wxLANGUAGE_TAJIK, 204).
++-define(wxLANGUAGE_TAMIL, 205).
++-define(wxLANGUAGE_TATAR, 206).
++-define(wxLANGUAGE_TELUGU, 207).
++-define(wxLANGUAGE_THAI, 208).
++-define(wxLANGUAGE_TIBETAN, 209).
++-define(wxLANGUAGE_TIGRINYA, 210).
++-define(wxLANGUAGE_TONGA, 211).
++-define(wxLANGUAGE_TSONGA, 212).
++-define(wxLANGUAGE_TURKISH, 213).
++-define(wxLANGUAGE_TURKMEN, 214).
++-define(wxLANGUAGE_TWI, 215).
++-define(wxLANGUAGE_UIGHUR, 216).
++-define(wxLANGUAGE_UKRAINIAN, 217).
++-define(wxLANGUAGE_URDU, 218).
++-define(wxLANGUAGE_URDU_INDIA, 219).
++-define(wxLANGUAGE_URDU_PAKISTAN, 220).
++-define(wxLANGUAGE_UZBEK, 221).
++-define(wxLANGUAGE_UZBEK_CYRILLIC, 222).
++-define(wxLANGUAGE_UZBEK_LATIN, 223).
++-define(wxLANGUAGE_VIETNAMESE, 225).
++-define(wxLANGUAGE_VOLAPUK, 226).
++-define(wxLANGUAGE_WELSH, 227).
++-define(wxLANGUAGE_WOLOF, 228).
++-define(wxLANGUAGE_XHOSA, 229).
++-define(wxLANGUAGE_YIDDISH, 230).
++-define(wxLANGUAGE_YORUBA, 231).
++-define(wxLANGUAGE_ZHUANG, 232).
++-define(wxLANGUAGE_ZULU, 233).
+ -define(wxLANGUAGE_USER_DEFINED, 230).
+--define(wxLANGUAGE_VALENCIAN, 536870911).
+--define(wxLANGUAGE_SAMI, 536870912).
++-define(wxLANGUAGE_VALENCIAN, 224).
++-define(wxLANGUAGE_SAMI, 160).
+ % From "intl.h": wxLayoutDirection
+ -define(wxLayout_Default, 0).
+ -define(wxLayout_LeftToRight, 1).
+@@ -3705,7 +3705,7 @@
-define(wxSTC_KEY_LEFT, 302).
-define(wxSTC_KEY_UP, 301).
-define(wxSTC_KEY_DOWN, 300).
@@ -72,7 +490,7 @@
-define(wxSTC_MULTILINEUNDOREDO, 4096).
-define(wxSTC_MOD_BEFOREDELETE, 2048).
-define(wxSTC_MOD_BEFOREINSERT, 1024).
-@@ -3814,7 +3814,7 @@
+@@ -3787,7 +3787,7 @@
-define(wxSTC_INDIC_TT, 2).
-define(wxSTC_INDIC_SQUIGGLE, 1).
-define(wxSTC_INDIC_PLAIN, 0).
@@ -81,7 +499,7 @@
-define(wxSTC_CASE_LOWER, 2).
-define(wxSTC_CASE_UPPER, 1).
-define(wxSTC_CASE_MIXED, 0).
-@@ -3839,7 +3839,7 @@
+@@ -3812,7 +3812,7 @@
-define(wxSTC_CHARSET_BALTIC, 186).
-define(wxSTC_CHARSET_DEFAULT, 1).
-define(wxSTC_CHARSET_ANSI, 0).
@@ -90,7 +508,7 @@
-define(wxSTC_STYLE_LASTPREDEFINED, 39).
-define(wxSTC_STYLE_CALLTIP, 38).
-define(wxSTC_STYLE_INDENTGUIDE, 37).
-@@ -3938,9 +3938,9 @@
+@@ -3911,9 +3911,9 @@
-define(wxTE_PROCESS_TAB, 64).
-define(wxTE_MULTILINE, 32).
-define(wxTE_READONLY, 16).
@@ -102,7 +520,7 @@
% From "textctrl.h": wxTextAttrAlignment
-define(wxTEXT_ALIGNMENT_DEFAULT, 0).
-define(wxTEXT_ALIGNMENT_LEFT, 1).
-@@ -3990,7 +3990,7 @@
+@@ -3963,7 +3963,7 @@
-define(wxDEFAULT_FRAME_STYLE, (?wxSYSTEM_MENU bor ?wxRESIZE_BORDER bor ?wxMINIMIZE_BOX bor ?wxMAXIMIZE_BOX bor ?wxCLOSE_BOX bor ?wxCAPTION bor ?wxCLIP_CHILDREN)).
-define(wxRESIZE_BORDER, 64).
-define(wxTINY_CAPTION_VERT, 128).
diff -Nru erlang-18.2-dfsg/debian/patches/x32.patch erlang-17.3-dfsg/debian/patches/x32.patch
--- erlang-18.2-dfsg/debian/patches/x32.patch 2016-01-14 12:33:34.000000000 +0000
+++ erlang-17.3-dfsg/debian/patches/x32.patch 1970-01-01 00:00:00.000000000 +0000
@@ -1,54 +0,0 @@
-Author: Sergei Golovan
-Description: This (not yet thoroughly tested) patch fixes FTBFS for x86_x32
- architecture (x86_64 with 32-bit integers, longs and pointers).
-Last-Modified: Sun, 27 Dec 2015 12:39:07 +0300
-
---- a/erts/lib_src/pthread/ethread.c
-+++ b/erts/lib_src/pthread/ethread.c
-@@ -195,13 +195,25 @@ ethr_x86_cpuid__(int *eax, int *ebx, int
- * we have the cpuid instruction.
- */
- __asm__ ("pushf\n\t"
-+#if __x86_64__ || (__x86_64__ && __ILP32__)
-+ "popq %%rax\n\t"
-+#else /* i386 */
- "popl %%eax\n\t"
-+#endif
- "movl %%eax, %%ecx\n\t"
- "xorl $0x200000, %%eax\n\t"
-+#if __x86_64__ || (__x86_64__ && __ILP32__)
-+ "pushq %%rax\n\t"
-+#else /* i386 */
- "pushl %%eax\n\t"
-+#endif
- "popf\n\t"
- "pushf\n\t"
-+#if __x86_64__ || (__x86_64__ && __ILP32__)
-+ "popq %%rax\n\t"
-+#else /* i386 */
- "popl %%eax\n\t"
-+#endif
- "movl $0x0, %0\n\t"
- "xorl %%ecx, %%eax\n\t"
- "jz no_cpuid\n\t"
-@@ -223,10 +235,19 @@ ethr_x86_cpuid__(int *eax, int *ebx, int
- * B register explicitly (for some reason gcc doesn't provide this
- * service to us).
- */
-- __asm__ ("pushl %%ebx\n\t"
-+ __asm__ (
-+#if __x86_64__ || (__x86_64__ && __ILP32__)
-+ "pushq %%rbx\n\t"
-+#else /* i386 */
-+ "pushl %%ebx\n\t"
-+#endif
- "cpuid\n\t"
- "movl %%ebx, %1\n\t"
-+#if __x86_64__ || (__x86_64__ && __ILP32__)
-+ "popq %%rbx\n\t"
-+#else /* i386 */
- "popl %%ebx\n\t"
-+#endif
- : "=a"(*eax), "=r"(*ebx), "=c"(*ecx), "=d"(*edx)
- : "0"(*eax)
- : "cc");
diff -Nru erlang-18.2-dfsg/debian/patterns/erlang-dev.patterns erlang-17.3-dfsg/debian/patterns/erlang-dev.patterns
--- erlang-18.2-dfsg/debian/patterns/erlang-dev.patterns 2016-01-04 20:12:18.000000000 +0000
+++ erlang-17.3-dfsg/debian/patterns/erlang-dev.patterns 2014-12-01 04:10:57.000000000 +0000
@@ -12,7 +12,6 @@
./usr/lib/erlang/lib/diameter-.*/include/
./usr/lib/erlang/lib/edoc-.*/include/
./usr/lib/erlang/lib/eldap-.*/include/
-./usr/lib/erlang/lib/erl_interface-.*/ebin/
./usr/lib/erlang/lib/erl_interface-.*/include/
./usr/lib/erlang/lib/erl_interface-.*/lib/
./usr/lib/erlang/lib/et-.*/include/
diff -Nru erlang-18.2-dfsg/debian/rules erlang-17.3-dfsg/debian/rules
--- erlang-18.2-dfsg/debian/rules 2016-01-04 20:12:17.000000000 +0000
+++ erlang-17.3-dfsg/debian/rules 2014-12-01 04:10:56.000000000 +0000
@@ -201,7 +201,6 @@
--enable-sctp \
$(CLOCK_GETTIME_OPT) \
--enable-dynamic-ssl-lib \
- --with-ssl-rpath=no \
--enable-ethread-pre-pentium4-compatibility \
--enable-shared-zlib \
--without-ssl-zlib
@@ -234,7 +233,6 @@
--enable-sctp \
$(CLOCK_GETTIME_OPT) \
--enable-dynamic-ssl-lib \
- --with-ssl-rpath=no \
--enable-ethread-pre-pentium4-compatibility \
--enable-shared-zlib \
--without-ssl-zlib
@@ -324,6 +322,9 @@
#
touch manpages-stamp
+# CC_R_FLAG and LD_R_FLAG are empty because Debian doesn't recommend
+# RPATH definition in binaries
+# CC_R_OPT is used in percept
build-hipe: build-hipe-stamp
build-hipe-stamp: configure-hipe-stamp
dh_testdir
@@ -512,7 +513,7 @@
binary: binary-indep binary-arch
-REL=18.2
+REL=17.3
RELDIR=$(REL)
DEB_REL=$(REL)-dfsg
diff -Nru erlang-18.2-dfsg/EPLICENCE erlang-17.3-dfsg/EPLICENCE
--- erlang-18.2-dfsg/EPLICENCE 1970-01-01 00:00:00.000000000 +0000
+++ erlang-17.3-dfsg/EPLICENCE 2014-09-16 19:10:57.000000000 +0000
@@ -0,0 +1,286 @@
+ERLANG PUBLIC LICENSE
+Version 1.1
+
+1. Definitions.
+
+1.1. ``Contributor'' means each entity that creates or contributes to
+the creation of Modifications.
+
+1.2. ``Contributor Version'' means the combination of the Original
+Code, prior Modifications used by a Contributor, and the Modifications
+made by that particular Contributor.
+
+1.3. ``Covered Code'' means the Original Code or Modifications or the
+combination of the Original Code and Modifications, in each case
+including portions thereof.
+
+1.4. ``Electronic Distribution Mechanism'' means a mechanism generally
+accepted in the software development community for the electronic
+transfer of data.
+
+1.5. ``Executable'' means Covered Code in any form other than Source
+Code.
+
+1.6. ``Initial Developer'' means the individual or entity identified
+as the Initial Developer in the Source Code notice required by Exhibit
+A.
+
+1.7. ``Larger Work'' means a work which combines Covered Code or
+portions thereof with code not governed by the terms of this License.
+
+1.8. ``License'' means this document.
+
+1.9. ``Modifications'' means any addition to or deletion from the
+substance or structure of either the Original Code or any previous
+Modifications. When Covered Code is released as a series of files, a
+Modification is:
+
+A. Any addition to or deletion from the contents of a file containing
+ Original Code or previous Modifications.
+
+B. Any new file that contains any part of the Original Code or
+ previous Modifications.
+
+1.10. ``Original Code'' means Source Code of computer software code
+which is described in the Source Code notice required by Exhibit A as
+Original Code, and which, at the time of its release under this
+License is not already Covered Code governed by this License.
+
+1.11. ``Source Code'' means the preferred form of the Covered Code for
+making modifications to it, including all modules it contains, plus
+any associated interface definition files, scripts used to control
+compilation and installation of an Executable, or a list of source
+code differential comparisons against either the Original Code or
+another well known, available Covered Code of the Contributor's
+choice. The Source Code can be in a compressed or archival form,
+provided the appropriate decompression or de-archiving software is
+widely available for no charge.
+
+1.12. ``You'' means an individual or a legal entity exercising rights
+under, and complying with all of the terms of, this License. For legal
+entities,``You'' includes any entity which controls, is controlled by,
+or is under common control with You. For purposes of this definition,
+``control'' means (a) the power, direct or indirect, to cause the
+direction or management of such entity, whether by contract or
+otherwise, or (b) ownership of fifty percent (50%) or more of the
+outstanding shares or beneficial ownership of such entity.
+
+2. Source Code License.
+
+2.1. The Initial Developer Grant.
+The Initial Developer hereby grants You a world-wide, royalty-free,
+non-exclusive license, subject to third party intellectual property
+claims:
+
+(a) to use, reproduce, modify, display, perform, sublicense and
+ distribute the Original Code (or portions thereof) with or without
+ Modifications, or as part of a Larger Work; and
+
+(b) under patents now or hereafter owned or controlled by Initial
+ Developer, to make, have made, use and sell (``Utilize'') the
+ Original Code (or portions thereof), but solely to the extent that
+ any such patent is reasonably necessary to enable You to Utilize
+ the Original Code (or portions thereof) and not to any greater
+ extent that may be necessary to Utilize further Modifications or
+ combinations.
+
+2.2. Contributor Grant.
+Each Contributor hereby grants You a world-wide, royalty-free,
+non-exclusive license, subject to third party intellectual property
+claims:
+
+(a) to use, reproduce, modify, display, perform, sublicense and
+ distribute the Modifications created by such Contributor (or
+ portions thereof) either on an unmodified basis, with other
+ Modifications, as Covered Code or as part of a Larger Work; and
+
+(b) under patents now or hereafter owned or controlled by Contributor,
+ to Utilize the Contributor Version (or portions thereof), but
+ solely to the extent that any such patent is reasonably necessary
+ to enable You to Utilize the Contributor Version (or portions
+ thereof), and not to any greater extent that may be necessary to
+ Utilize further Modifications or combinations.
+
+3. Distribution Obligations.
+
+3.1. Application of License.
+The Modifications which You contribute are governed by the terms of
+this License, including without limitation Section 2.2. The Source
+Code version of Covered Code may be distributed only under the terms
+of this License, and You must include a copy of this License with
+every copy of the Source Code You distribute. You may not offer or
+impose any terms on any Source Code version that alters or restricts
+the applicable version of this License or the recipients' rights
+hereunder. However, You may include an additional document offering
+the additional rights described in Section 3.5.
+
+3.2. Availability of Source Code.
+Any Modification which You contribute must be made available in Source
+Code form under the terms of this License either on the same media as
+an Executable version or via an accepted Electronic Distribution
+Mechanism to anyone to whom you made an Executable version available;
+and if made available via Electronic Distribution Mechanism, must
+remain available for at least twelve (12) months after the date it
+initially became available, or at least six (6) months after a
+subsequent version of that particular Modification has been made
+available to such recipients. You are responsible for ensuring that
+the Source Code version remains available even if the Electronic
+Distribution Mechanism is maintained by a third party.
+
+3.3. Description of Modifications.
+You must cause all Covered Code to which you contribute to contain a
+file documenting the changes You made to create that Covered Code and
+the date of any change. You must include a prominent statement that
+the Modification is derived, directly or indirectly, from Original
+Code provided by the Initial Developer and including the name of the
+Initial Developer in (a) the Source Code, and (b) in any notice in an
+Executable version or related documentation in which You describe the
+origin or ownership of the Covered Code.
+
+3.4. Intellectual Property Matters
+
+(a) Third Party Claims.
+ If You have knowledge that a party claims an intellectual property
+ right in particular functionality or code (or its utilization
+ under this License), you must include a text file with the source
+ code distribution titled ``LEGAL'' which describes the claim and
+ the party making the claim in sufficient detail that a recipient
+ will know whom to contact. If you obtain such knowledge after You
+ make Your Modification available as described in Section 3.2, You
+ shall promptly modify the LEGAL file in all copies You make
+ available thereafter and shall take other steps (such as notifying
+ appropriate mailing lists or newsgroups) reasonably calculated to
+ inform those who received the Covered Code that new knowledge has
+ been obtained.
+
+(b) Contributor APIs.
+ If Your Modification is an application programming interface and
+ You own or control patents which are reasonably necessary to
+ implement that API, you must also include this information in the
+ LEGAL file.
+
+3.5. Required Notices.
+You must duplicate the notice in Exhibit A in each file of the Source
+Code, and this License in any documentation for the Source Code, where
+You describe recipients' rights relating to Covered Code. If You
+created one or more Modification(s), You may add your name as a
+Contributor to the notice described in Exhibit A. If it is not
+possible to put such notice in a particular Source Code file due to
+its structure, then you must include such notice in a location (such
+as a relevant directory file) where a user would be likely to look for
+such a notice. You may choose to offer, and to charge a fee for,
+warranty, support, indemnity or liability obligations to one or more
+recipients of Covered Code. However, You may do so only on Your own
+behalf, and not on behalf of the Initial Developer or any
+Contributor. You must make it absolutely clear than any such warranty,
+support, indemnity or liability obligation is offered by You alone,
+and You hereby agree to indemnify the Initial Developer and every
+Contributor for any liability incurred by the Initial Developer or
+such Contributor as a result of warranty, support, indemnity or
+liability terms You offer.
+
+3.6. Distribution of Executable Versions.
+You may distribute Covered Code in Executable form only if the
+requirements of Section 3.1-3.5 have been met for that Covered Code,
+and if You include a notice stating that the Source Code version of
+the Covered Code is available under the terms of this License,
+including a description of how and where You have fulfilled the
+obligations of Section 3.2. The notice must be conspicuously included
+in any notice in an Executable version, related documentation or
+collateral in which You describe recipients' rights relating to the
+Covered Code. You may distribute the Executable version of Covered
+Code under a license of Your choice, which may contain terms different
+from this License, provided that You are in compliance with the terms
+of this License and that the license for the Executable version does
+not attempt to limit or alter the recipient's rights in the Source
+Code version from the rights set forth in this License. If You
+distribute the Executable version under a different license You must
+make it absolutely clear that any terms which differ from this License
+are offered by You alone, not by the Initial Developer or any
+Contributor. You hereby agree to indemnify the Initial Developer and
+every Contributor for any liability incurred by the Initial Developer
+or such Contributor as a result of any such terms You offer.
+
+3.7. Larger Works.
+You may create a Larger Work by combining Covered Code with other code
+not governed by the terms of this License and distribute the Larger
+Work as a single product. In such a case, You must make sure the
+requirements of this License are fulfilled for the Covered Code.
+
+4. Inability to Comply Due to Statute or Regulation.
+If it is impossible for You to comply with any of the terms of this
+License with respect to some or all of the Covered Code due to statute
+or regulation then You must: (a) comply with the terms of this License
+to the maximum extent possible; and (b) describe the limitations and
+the code they affect. Such description must be included in the LEGAL
+file described in Section 3.4 and must be included with all
+distributions of the Source Code. Except to the extent prohibited by
+statute or regulation, such description must be sufficiently detailed
+for a recipient of ordinary skill to be able to understand it.
+
+5. Application of this License.
+
+This License applies to code to which the Initial Developer has
+attached the notice in Exhibit A, and to related Covered Code.
+
+6. CONNECTION TO MOZILLA PUBLIC LICENSE
+
+This Erlang License is a derivative work of the Mozilla Public
+License, Version 1.0. It contains terms which differ from the Mozilla
+Public License, Version 1.0.
+
+7. DISCLAIMER OF WARRANTY.
+
+COVERED CODE IS PROVIDED UNDER THIS LICENSE ON AN ``AS IS'' BASIS,
+WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING,
+WITHOUT LIMITATION, WARRANTIES THAT THE COVERED CODE IS FREE OF
+DEFECTS, MERCHANTABLE, FIT FOR A PARTICULAR PURPOSE OR
+NON-INFRINGING. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF
+THE COVERED CODE IS WITH YOU. SHOULD ANY COVERED CODE PROVE DEFECTIVE
+IN ANY RESPECT, YOU (NOT THE INITIAL DEVELOPER OR ANY OTHER
+CONTRIBUTOR) ASSUME THE COST OF ANY NECESSARY SERVICING, REPAIR OR
+CORRECTION. THIS DISCLAIMER OF WARRANTY CONSTITUTES AN ESSENTIAL PART
+OF THIS LICENSE. NO USE OF ANY COVERED CODE IS AUTHORIZED HEREUNDER
+EXCEPT UNDER THIS DISCLAIMER.
+
+8. TERMINATION.
+This License and the rights granted hereunder will terminate
+automatically if You fail to comply with terms herein and fail to cure
+such breach within 30 days of becoming aware of the breach. All
+sublicenses to the Covered Code which are properly granted shall
+survive any termination of this License. Provisions which, by their
+nature, must remain in effect beyond the termination of this License
+shall survive.
+
+9. DISCLAIMER OF LIABILITY
+Any utilization of Covered Code shall not cause the Initial Developer
+or any Contributor to be liable for any damages (neither direct nor
+indirect).
+
+10. MISCELLANEOUS
+This License represents the complete agreement concerning the subject
+matter hereof. If any provision is held to be unenforceable, such
+provision shall be reformed only to the extent necessary to make it
+enforceable. This License shall be construed by and in accordance with
+the substantive laws of Sweden. Any dispute, controversy or claim
+arising out of or relating to this License, or the breach, termination
+or invalidity thereof, shall be subject to the exclusive jurisdiction
+of Swedish courts, with the Stockholm City Court as the first
+instance.
+
+EXHIBIT A.
+
+``The contents of this file are subject to the Erlang Public License,
+Version 1.1, (the "License"); you may not use this file except in
+compliance with the License. You should have received a copy of the
+Erlang Public License along with this software. If not, it can be
+retrieved via the world wide web at http://www.erlang.org/.
+
+Software distributed under the License is distributed on an "AS IS"
+basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See
+the License for the specific language governing rights and limitations
+under the License.
+
+The Initial Developer of the Original Code is Ericsson Utvecklings AB.
+Portions created by Ericsson are Copyright 1999, Ericsson Utvecklings
+AB. All Rights Reserved.''
diff -Nru erlang-18.2-dfsg/erl-build-tool-vars.sh erlang-17.3-dfsg/erl-build-tool-vars.sh
--- erlang-18.2-dfsg/erl-build-tool-vars.sh 2015-12-15 20:10:35.000000000 +0000
+++ erlang-17.3-dfsg/erl-build-tool-vars.sh 2014-09-16 19:10:57.000000000 +0000
@@ -3,17 +3,16 @@
#
# Copyright Ericsson AB 2010. All Rights Reserved.
#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
+# The contents of this file are subject to the Erlang Public License,
+# Version 1.1, (the "License"); you may not use this file except in
+# compliance with the License. You should have received a copy of the
+# Erlang Public License along with this software. If not, it can be
+# retrieved online at http://www.erlang.org/.
+#
+# Software distributed under the License is distributed on an "AS IS"
+# basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See
+# the License for the specific language governing rights and limitations
+# under the License.
#
# %CopyrightEnd%
#
diff -Nru erlang-18.2-dfsg/erts/aclocal.m4 erlang-17.3-dfsg/erts/aclocal.m4
--- erlang-18.2-dfsg/erts/aclocal.m4 2015-12-15 20:10:35.000000000 +0000
+++ erlang-17.3-dfsg/erts/aclocal.m4 2014-09-16 19:10:57.000000000 +0000
@@ -1,19 +1,18 @@
dnl
dnl %CopyrightBegin%
dnl
-dnl Copyright Ericsson AB 1998-2015. All Rights Reserved.
+dnl Copyright Ericsson AB 1998-2013. All Rights Reserved.
dnl
-dnl Licensed under the Apache License, Version 2.0 (the "License");
-dnl you may not use this file except in compliance with the License.
-dnl You may obtain a copy of the License at
-dnl
-dnl http://www.apache.org/licenses/LICENSE-2.0
-dnl
-dnl Unless required by applicable law or agreed to in writing, software
-dnl distributed under the License is distributed on an "AS IS" BASIS,
-dnl WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-dnl See the License for the specific language governing permissions and
-dnl limitations under the License.
+dnl The contents of this file are subject to the Erlang Public License,
+dnl Version 1.1, (the "License"); you may not use this file except in
+dnl compliance with the License. You should have received a copy of the
+dnl Erlang Public License along with this software. If not, it can be
+dnl retrieved online at http://www.erlang.org/.
+dnl
+dnl Software distributed under the License is distributed on an "AS IS"
+dnl basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See
+dnl the License for the specific language governing rights and limitations
+dnl under the License.
dnl
dnl %CopyrightEnd%
dnl
@@ -61,6 +60,7 @@
dnl Cross compilation variables
AC_ARG_VAR(erl_xcomp_bigendian, [big endian system: yes|no (only used when cross compiling)])
AC_ARG_VAR(erl_xcomp_double_middle_endian, [double-middle-endian system: yes|no (only used when cross compiling)])
+AC_ARG_VAR(erl_xcomp_linux_clock_gettime_correction, [clock_gettime() can be used for time correction: yes|no (only used when cross compiling)])
AC_ARG_VAR(erl_xcomp_linux_nptl, [have Native POSIX Thread Library: yes|no (only used when cross compiling)])
AC_ARG_VAR(erl_xcomp_linux_usable_sigusrx, [SIGUSR1 and SIGUSR2 can be used: yes|no (only used when cross compiling)])
AC_ARG_VAR(erl_xcomp_linux_usable_sigaltstack, [have working sigaltstack(): yes|no (only used when cross compiling)])
@@ -142,18 +142,18 @@
AC_MSG_CHECKING(for mixed cygwin or msys and native VC++ environment)
if test "X$host" = "Xwin32" -a "x$GCC" != "xyes"; then
- if test -x /usr/bin/msys-?.0.dll; then
- CFLAGS="-O2"
- MIXED_MSYS=yes
- AC_MSG_RESULT([MSYS and VC])
- MIXED_MSYS_VC=yes
- CPPFLAGS="$CPPFLAGS -DERTS_MIXED_MSYS_VC"
- elif test -x /usr/bin/cygpath; then
+ if test -x /usr/bin/cygpath; then
CFLAGS="-O2"
MIXED_CYGWIN=yes
AC_MSG_RESULT([Cygwin and VC])
MIXED_CYGWIN_VC=yes
CPPFLAGS="$CPPFLAGS -DERTS_MIXED_CYGWIN_VC"
+ elif test -x /usr/bin/msysinfo; then
+ CFLAGS="-O2"
+ MIXED_MSYS=yes
+ AC_MSG_RESULT([MSYS and VC])
+ MIXED_MSYS_VC=yes
+ CPPFLAGS="$CPPFLAGS -DERTS_MIXED_MSYS_VC"
else
AC_MSG_RESULT([undeterminable])
AC_MSG_ERROR(Seems to be mixed windows but not with cygwin, cannot handle this!)
@@ -246,31 +246,31 @@
return 1;
lbl2:
return 2;
-],ac_cv_prog_emu_cc="$CC",ac_cv_prog_emu_cc=no)
+],ac_cv_prog_emu_cc=$CC,ac_cv_prog_emu_cc=no)
-if test "$ac_cv_prog_emu_cc" = no; then
+if test $ac_cv_prog_emu_cc = no; then
for ac_progname in emu_cc.sh gcc-4.2 gcc; do
IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
ac_dummy="$PATH"
for ac_dir in $ac_dummy; do
test -z "$ac_dir" && ac_dir=.
- if test -f "$ac_dir/$ac_progname"; then
- ac_cv_prog_emu_cc="$ac_dir/$ac_progname"
+ if test -f $ac_dir/$ac_progname; then
+ ac_cv_prog_emu_cc=$ac_dir/$ac_progname
break
fi
done
IFS="$ac_save_ifs"
- if test "$ac_cv_prog_emu_cc" != no; then
+ if test $ac_cv_prog_emu_cc != no; then
break
fi
done
fi
-if test "$ac_cv_prog_emu_cc" != no; then
- save_CC="$CC"
+if test $ac_cv_prog_emu_cc != no; then
+ save_CC=$CC
save_CFLAGS=$CFLAGS
save_CPPFLAGS=$CPPFLAGS
- CC="$ac_cv_prog_emu_cc"
+ CC=$ac_cv_prog_emu_cc
CFLAGS=""
CPPFLAGS=""
AC_TRY_COMPILE([],[
@@ -291,17 +291,17 @@
return 1;
lbl2:
return 2;
- ],ac_cv_prog_emu_cc="$CC",ac_cv_prog_emu_cc=no)
+ ],ac_cv_prog_emu_cc=$CC,ac_cv_prog_emu_cc=no)
CC=$save_CC
CFLAGS=$save_CFLAGS
CPPFLAGS=$save_CPPFLAGS
fi
])
-if test "$ac_cv_prog_emu_cc" = no; then
+if test $ac_cv_prog_emu_cc = no; then
AC_DEFINE(NO_JUMP_TABLE,[],[Defined if no found C compiler can handle jump tables])
- EMU_CC="$CC"
+ EMU_CC=$CC
else
- EMU_CC="$ac_cv_prog_emu_cc"
+ EMU_CC=$ac_cv_prog_emu_cc
fi
AC_SUBST(EMU_CC)
])
@@ -559,7 +559,7 @@
AC_DEFUN(LM_SYS_MULTICAST,
[AC_CACHE_CHECK([for multicast support], ac_cv_sys_multicast_support,
-[AC_EGREP_CPP(^yes$,
+[AC_EGREP_CPP(yes,
[#include
#include
#include
@@ -724,250 +724,6 @@
])# AC_C_DOUBLE_MIDDLE_ENDIAN
-AC_DEFUN(ERL_MONOTONIC_CLOCK,
-[
- if test "$3" = "yes"; then
- default_resolution_clock_gettime_monotonic="CLOCK_HIGHRES CLOCK_BOOTTIME CLOCK_MONOTONIC"
- low_resolution_clock_gettime_monotonic="CLOCK_MONOTONIC_COARSE CLOCK_MONOTONIC_FAST"
- high_resolution_clock_gettime_monotonic="CLOCK_MONOTONIC_PRECISE"
- else
- default_resolution_clock_gettime_monotonic="CLOCK_HIGHRES CLOCK_UPTIME CLOCK_MONOTONIC"
- low_resolution_clock_gettime_monotonic="CLOCK_MONOTONIC_COARSE CLOCK_UPTIME_FAST"
- high_resolution_clock_gettime_monotonic="CLOCK_UPTIME_PRECISE"
- fi
-
- case "$1" in
- high_resolution)
- check_msg="high resolution "
- prefer_resolution_clock_gettime_monotonic="$high_resolution_clock_gettime_monotonic"
- ;;
- low_resolution)
- check_msg="low resolution "
- prefer_resolution_clock_gettime_monotonic="$low_resolution_clock_gettime_monotonic"
- ;;
- custom_resolution)
- check_msg="custom resolution "
- prefer_resolution_clock_gettime_monotonic="$2"
- ;;
- *)
- check_msg="custom "
- prefer_resolution_clock_gettime_monotonic="$2"
- ;;
- esac
-
- AC_CACHE_CHECK([for clock_gettime(CLOCK_MONOTONIC_RAW, _)], erl_cv_clock_gettime_monotonic_raw,
- [
- AC_TRY_COMPILE([
-#include
- ],
- [
- struct timespec ts;
- long long result;
- clock_gettime(CLOCK_MONOTONIC_RAW, &ts);
- result = ((long long) ts.tv_sec) * 1000000000LL +
- ((long long) ts.tv_nsec);
- ],
- erl_cv_clock_gettime_monotonic_raw=yes,
- erl_cv_clock_gettime_monotonic_raw=no)
- ])
-
- AC_CACHE_CHECK([for clock_gettime() with ${check_msg}monotonic clock type], erl_cv_clock_gettime_monotonic_$1,
- [
- for clock_type in $prefer_resolution_clock_gettime_monotonic $default_resolution_clock_gettime_monotonic $high_resolution_clock_gettime_monotonic $low_resolution_clock_gettime_monotonic; do
- AC_TRY_COMPILE([
-#include
- ],
- [
- struct timespec ts;
- long long result;
- clock_gettime($clock_type,&ts);
- result = ((long long) ts.tv_sec) * 1000000000LL +
- ((long long) ts.tv_nsec);
- ],
- erl_cv_clock_gettime_monotonic_$1=$clock_type,
- erl_cv_clock_gettime_monotonic_$1=no)
- test $erl_cv_clock_gettime_monotonic_$1 = no || break
- done
- ])
-
- AC_CHECK_FUNCS([clock_getres clock_get_attributes gethrtime])
-
- AC_CACHE_CHECK([for mach clock_get_time() with monotonic clock type], erl_cv_mach_clock_get_time_monotonic,
- [
- AC_TRY_COMPILE([
-#include
-#include
- ],
- [
- kern_return_t res;
- clock_serv_t clk_srv;
- mach_timespec_t time_spec;
-
- host_get_clock_service(mach_host_self(), SYSTEM_CLOCK, &clk_srv);
- res = clock_get_time(clk_srv, &time_spec);
- mach_port_deallocate(mach_task_self(), clk_srv);
- ],
- erl_cv_mach_clock_get_time_monotonic=yes,
- erl_cv_mach_clock_get_time_monotonic=no)
- ])
-
- erl_corrected_monotonic_clock=no
- case $erl_cv_clock_gettime_monotonic_$1-$ac_cv_func_gethrtime-$erl_cv_mach_clock_get_time_monotonic-$host_os in
- *-*-*-win32)
- erl_monotonic_clock_func=WindowsAPI
- ;;
- CLOCK_*-*-*-linux*)
- case $erl_cv_clock_gettime_monotonic_$1-$erl_cv_clock_gettime_monotonic_raw in
- CLOCK_BOOTTIME-yes|CLOCK_MONOTONIC-yes)
- erl_corrected_monotonic_clock=yes
- ;;
- *)
- # We don't trust CLOCK_MONOTONIC to be NTP
- # adjusted on linux systems that do not have
- # CLOCK_MONOTONIC_RAW (although it seems to
- # be...)
- ;;
- esac
- erl_monotonic_clock_func=clock_gettime
- ;;
- no-no-no-linux*)
- erl_monotonic_clock_func=times
- ;;
- CLOCK_*-*-*-*)
- erl_monotonic_clock_func=clock_gettime
- ;;
- no-yes-*-*)
- erl_monotonic_clock_func=gethrtime
- ;;
- no-no-yes-*)
- erl_monotonic_clock_func=mach_clock_get_time
- ;;
- no-no-no-*)
- erl_monotonic_clock_func=none
- ;;
- esac
-
- erl_monotonic_clock_low_resolution=no
- erl_monotonic_clock_lib=
- erl_monotonic_clock_id=
- case $erl_monotonic_clock_func in
- clock_gettime)
- erl_monotonic_clock_id=$erl_cv_clock_gettime_monotonic_$1
- for low_res_id in $low_resolution_clock_gettime_monotonic; do
- if test $erl_monotonic_clock_id = $low_res_id; then
- erl_monotonic_clock_low_resolution=yes
- break
- fi
- done
- AC_CHECK_LIB(rt, clock_gettime, [erl_monotonic_clock_lib="-lrt"])
- ;;
- mach_clock_get_time)
- erl_monotonic_clock_id=SYSTEM_CLOCK
- ;;
- times)
- erl_monotonic_clock_low_resolution=yes
- ;;
- *)
- ;;
- esac
-
-])
-
-AC_DEFUN(ERL_WALL_CLOCK,
-[
- default_resolution_clock_gettime_wall="CLOCK_REALTIME"
- low_resolution_clock_gettime_wall="CLOCK_REALTIME_COARSE CLOCK_REALTIME_FAST"
- high_resolution_clock_gettime_wall="CLOCK_REALTIME_PRECISE"
-
- case "$1" in
- high_resolution)
- check_msg="high resolution "
- prefer_resolution_clock_gettime_wall="$high_resolution_clock_gettime_wall"
- ;;
- low_resolution)
- check_msg="low resolution "
- prefer_resolution_clock_gettime_wall="$low_resolution_clock_gettime_wall"
- ;;
- custom_resolution)
- check_msg="custom resolution "
- prefer_resolution_clock_gettime_wall="$2"
- ;;
- *)
- check_msg=""
- prefer_resolution_clock_gettime_wall=
- ;;
- esac
-
- AC_CACHE_CHECK([for clock_gettime() with ${check_msg}wall clock type], erl_cv_clock_gettime_wall_$1,
- [
- for clock_type in $prefer_resolution_clock_gettime_wall $default_resolution_clock_gettime_wall $high_resolution_clock_gettime_wall $low_resolution_clock_gettime_wall; do
- AC_TRY_COMPILE([
-#include
- ],
- [
- struct timespec ts;
- long long result;
- clock_gettime($clock_type,&ts);
- result = ((long long) ts.tv_sec) * 1000000000LL +
- ((long long) ts.tv_nsec);
- ],
- erl_cv_clock_gettime_wall_$1=$clock_type,
- erl_cv_clock_gettime_wall_$1=no)
- test $erl_cv_clock_gettime_wall_$1 = no || break
- done
- ])
-
- AC_CHECK_FUNCS([clock_getres clock_get_attributes gettimeofday])
-
- AC_CACHE_CHECK([for mach clock_get_time() with wall clock type], erl_cv_mach_clock_get_time_wall,
- [
- AC_TRY_COMPILE([
-#include
-#include
- ],
- [
- kern_return_t res;
- clock_serv_t clk_srv;
- mach_timespec_t time_spec;
-
- host_get_clock_service(mach_host_self(), CALENDAR_CLOCK, &clk_srv);
- res = clock_get_time(clk_srv, &time_spec);
- mach_port_deallocate(mach_task_self(), clk_srv);
- ],
- erl_cv_mach_clock_get_time_wall=yes,
- erl_cv_mach_clock_get_time_wall=no)
- ])
-
- erl_wall_clock_low_resolution=no
- erl_wall_clock_id=
- case $1-$erl_cv_clock_gettime_wall_$1-$erl_cv_mach_clock_get_time_wall-$ac_cv_func_gettimeofday-$host_os in
- *-*-*-*-win32)
- erl_wall_clock_func=WindowsAPI
- erl_wall_clock_low_resolution=yes
- ;;
- high_resolution-no-yes-*-*)
- erl_wall_clock_func=mach_clock_get_time
- erl_wall_clock_id=CALENDAR_CLOCK
- ;;
- *-CLOCK_*-*-*-*)
- erl_wall_clock_func=clock_gettime
- erl_wall_clock_id=$erl_cv_clock_gettime_wall_$1
- for low_res_id in $low_resolution_clock_gettime_wall; do
- if test $erl_wall_clock_id = $low_res_id; then
- erl_wall_clock_low_resolution=yes
- break
- fi
- done
- ;;
- *-no-*-yes-*)
- erl_wall_clock_func=gettimeofday
- ;;
- *)
- erl_wall_clock_func=none
- ;;
- esac
-])
-
dnl ----------------------------------------------------------------------
dnl
dnl LM_CHECK_THR_LIB
@@ -1152,226 +908,24 @@
])
-AC_DEFUN(ETHR_CHK_GCC_ATOMIC_OP__,
-[
- # $1 - atomic_op
-
- for atomic_bit_size in 32 64 128; do
- case $atomic_bit_size in
- 32) gcc_atomic_type="$gcc_atomic_type32";;
- 64) gcc_atomic_type="$gcc_atomic_type64";;
- 128) gcc_atomic_type="$gcc_atomic_type128";;
- esac
- gcc_atomic_lockfree="int x[[(2*__atomic_always_lock_free(sizeof($gcc_atomic_type), 0))-1]]"
- case $1 in
- __sync_add_and_fetch | __sync_fetch_and_and | __sync_fetch_and_or)
- atomic_call="volatile $gcc_atomic_type var; $gcc_atomic_type res = $1(&var, ($gcc_atomic_type) 0);"
- ;;
- __sync_val_compare_and_swap)
- atomic_call="volatile $gcc_atomic_type var; $gcc_atomic_type res = $1(&var, ($gcc_atomic_type) 0, ($gcc_atomic_type) 0);"
- ;;
- __atomic_store_n)
- atomic_call="$gcc_atomic_lockfree; volatile $gcc_atomic_type var; $1(&var, ($gcc_atomic_type) 0, __ATOMIC_RELAXED); $1(&var, ($gcc_atomic_type) 0, __ATOMIC_RELEASE);"
- ;;
- __atomic_load_n)
- atomic_call="$gcc_atomic_lockfree; volatile $gcc_atomic_type var; $gcc_atomic_type res = $1(&var, __ATOMIC_RELAXED); res = $1(&var, __ATOMIC_ACQUIRE);"
- ;;
- __atomic_add_fetch| __atomic_fetch_and | __atomic_fetch_or)
- atomic_call="$gcc_atomic_lockfree; volatile $gcc_atomic_type var; $gcc_atomic_type res = $1(&var, ($gcc_atomic_type) 0, __ATOMIC_RELAXED); res = $1(&var, ($gcc_atomic_type) 0, __ATOMIC_ACQUIRE); res = $1(&var, ($gcc_atomic_type) 0, __ATOMIC_RELEASE);"
- ;;
- __atomic_compare_exchange_n)
- atomic_call="$gcc_atomic_lockfree; volatile $gcc_atomic_type var; $gcc_atomic_type val; int res = $1(&var, &val, ($gcc_atomic_type) 0, 0, __ATOMIC_RELAXED, __ATOMIC_RELAXED); res = $1(&var, &val, ($gcc_atomic_type) 0, 0, __ATOMIC_ACQUIRE, __ATOMIC_ACQUIRE);"
- ;;
- *)
- AC_MSG_ERROR([Internal error: missing implementation for $1])
- ;;
- esac
- eval atomic${atomic_bit_size}_call=\"$atomic_call\"
- done
-
- AC_CACHE_CHECK([for 32-bit $1()], ethr_cv_32bit_$1,
- [
- ethr_cv_32bit_$1=no
- AC_TRY_LINK([], [$atomic32_call], [ethr_cv_32bit_$1=yes])
- ])
- AC_CACHE_CHECK([for 64-bit $1()], ethr_cv_64bit_$1,
- [
- ethr_cv_64bit_$1=no
- AC_TRY_LINK([], [$atomic64_call], [ethr_cv_64bit_$1=yes])
- ])
- AC_CACHE_CHECK([for 128-bit $1()], ethr_cv_128bit_$1,
- [
- ethr_cv_128bit_$1=no
- AC_TRY_LINK([], [$atomic128_call], [ethr_cv_128bit_$1=yes])
- ])
-
- case $ethr_cv_128bit_$1-$ethr_cv_64bit_$1-$ethr_cv_32bit_$1 in
- no-no-no)
- have_atomic_ops=0;;
- no-no-yes)
- have_atomic_ops=4;;
- no-yes-no)
- have_atomic_ops=8;;
- no-yes-yes)
- have_atomic_ops=12;;
- yes-no-no)
- have_atomic_ops=16;;
- yes-no-yes)
- have_atomic_ops=20;;
- yes-yes-no)
- have_atomic_ops=24;;
- yes-yes-yes)
- have_atomic_ops=28;;
- esac
- AC_DEFINE_UNQUOTED([ETHR_HAVE_$1], [$have_atomic_ops], [Define as a bitmask corresponding to the word sizes that $1() can handle on your system])
-])
-
-AC_DEFUN(ETHR_CHK_IF_NOOP,
+AC_DEFUN(ETHR_CHK_SYNC_OP,
[
- ethr_test_filename="chk_if_$1$3_noop_config1test.$$"
- cat > "${ethr_test_filename}.c" < "${ethr_test_filename}.c" </dev/null 2>&1; then
- ethr_$1$3_noop=yes
- else
- ethr_$1$3_noop=no
- fi
- rm -f "${ethr_test_filename}.c" "${ethr_test_filename}1.o" "${ethr_test_filename}2.o"
-])
-
-AC_DEFUN(ETHR_CHK_GCC_ATOMIC_OPS,
-[
- AC_CHECK_SIZEOF(short)
- AC_CHECK_SIZEOF(int)
- AC_CHECK_SIZEOF(long)
- AC_CHECK_SIZEOF(long long)
- AC_CHECK_SIZEOF(__int128_t)
-
- if test "$ac_cv_sizeof_short" = "4"; then
- gcc_atomic_type32="short"
- elif test "$ac_cv_sizeof_int" = "4"; then
- gcc_atomic_type32="int"
- elif test "$ac_cv_sizeof_long" = "4"; then
- gcc_atomic_type32="long"
- else
- AC_MSG_ERROR([No 32-bit type found])
- fi
-
- if test "$ac_cv_sizeof_int" = "8"; then
- gcc_atomic_type64="int"
- elif test "$ac_cv_sizeof_long" = "8"; then
- gcc_atomic_type64="long"
- elif test "$ac_cv_sizeof_long_long" = "8"; then
- gcc_atomic_type64="long long"
- else
- AC_MSG_ERROR([No 64-bit type found])
- fi
-
- if test "$ac_cv_sizeof___int128_t" = "16"; then
- gcc_atomic_type128="__int128_t"
- else
- gcc_atomic_type128="#error "
- fi
- AC_CACHE_CHECK([for a working __sync_synchronize()], ethr_cv___sync_synchronize,
- [
- ethr_cv___sync_synchronize=no
- AC_TRY_LINK([],
- [ __sync_synchronize(); ],
- [ethr_cv___sync_synchronize=yes])
- if test $ethr_cv___sync_synchronize = yes; then
- #
- # Old gcc versions on at least x86 have a buggy
- # __sync_synchronize() which does not emit a
- # memory barrier. We try to detect this by
- # compiling to assembly with and without
- # __sync_synchronize() and compare the results.
- #
- ETHR_CHK_IF_NOOP(__sync_synchronize, [()], [])
- if test $ethr___sync_synchronize_noop = yes; then
- # Got a buggy implementation of
- # __sync_synchronize...
- ethr_cv___sync_synchronize="no; buggy implementation"
- fi
- fi
- ])
-
- if test "$ethr_cv___sync_synchronize" = "yes"; then
- have_sync_synchronize_value="~0"
- else
- have_sync_synchronize_value="0"
- fi
- AC_DEFINE_UNQUOTED([ETHR_HAVE___sync_synchronize], [$have_sync_synchronize_value], [Define as a bitmask corresponding to the word sizes that __sync_synchronize() can handle on your system])
-
- ETHR_CHK_GCC_ATOMIC_OP__(__sync_add_and_fetch)
- ETHR_CHK_GCC_ATOMIC_OP__(__sync_fetch_and_and)
- ETHR_CHK_GCC_ATOMIC_OP__(__sync_fetch_and_or)
- ETHR_CHK_GCC_ATOMIC_OP__(__sync_val_compare_and_swap)
-
- ETHR_CHK_GCC_ATOMIC_OP__(__atomic_store_n)
- ETHR_CHK_GCC_ATOMIC_OP__(__atomic_load_n)
- ETHR_CHK_GCC_ATOMIC_OP__(__atomic_add_fetch)
- ETHR_CHK_GCC_ATOMIC_OP__(__atomic_fetch_and)
- ETHR_CHK_GCC_ATOMIC_OP__(__atomic_fetch_or)
- ETHR_CHK_GCC_ATOMIC_OP__(__atomic_compare_exchange_n)
-
- ethr_have_gcc_native_atomics=no
- ethr_arm_dbm_instr_val=0
- case "$GCC-$host_cpu" in
- yes-arm*)
- AC_CACHE_CHECK([for ARM DMB instruction], ethr_cv_arm_dbm_instr,
- [
- ethr_cv_arm_dbm_instr=no
- AC_TRY_LINK([],
- [
- __asm__ __volatile__("dmb sy" : : : "memory");
- __asm__ __volatile__("dmb st" : : : "memory");
- ],
- [ethr_cv_arm_dbm_instr=yes])
- ])
- if test $ethr_cv_arm_dbm_instr = yes; then
- ethr_arm_dbm_instr_val=1
- test $ethr_cv_64bit___atomic_compare_exchange_n = yes &&
- ethr_have_gcc_native_atomics=yes
- fi;;
- *)
- ;;
+ AC_MSG_CHECKING([for $3-bit $1()])
+ case "$2" in
+ "1") sync_call="$1(&var);";;
+ "2") sync_call="$1(&var, ($4) 0);";;
+ "3") sync_call="$1(&var, ($4) 0, ($4) 0);";;
esac
- AC_DEFINE_UNQUOTED([ETHR_HAVE_GCC_ASM_ARM_DMB_INSTRUCTION], [$ethr_arm_dbm_instr_val], [Define as a boolean indicating whether you have a gcc compatible compiler capable of generating the ARM DMB instruction, and are compiling for an ARM processor with ARM DMB instruction support, or not])
- test $ethr_cv_32bit___sync_val_compare_and_swap = yes &&
- ethr_have_gcc_native_atomics=yes
- test $ethr_cv_64bit___sync_val_compare_and_swap = yes &&
- ethr_have_gcc_native_atomics=yes
- if test "$ethr_cv___sync_synchronize" = "yes"; then
- test $ethr_cv_64bit___atomic_compare_exchange_n = yes &&
- ethr_have_gcc_native_atomics=yes
- test $ethr_cv_32bit___atomic_compare_exchange_n = yes &&
- ethr_have_gcc_native_atomics=yes
- fi
- ethr_have_gcc_atomic_builtins=0
- if test $ethr_have_gcc_native_atomics = yes; then
- ethr_native_atomic_implementation=gcc_sync
- test $ethr_cv_32bit___atomic_compare_exchange_n = yes && ethr_have_gcc_atomic_builtins=1
- test $ethr_cv_64bit___atomic_compare_exchange_n = yes && ethr_have_gcc_atomic_builtins=1
- test $ethr_have_gcc_atomic_builtins = 1 && ethr_native_atomic_implementation=gcc_atomic_sync
- fi
- AC_DEFINE_UNQUOTED([ETHR_HAVE_GCC___ATOMIC_BUILTINS], [$ethr_have_gcc_atomic_builtins], [Define as a boolean indicating whether you have a gcc __atomic builtins or not])
- test $ethr_have_gcc_native_atomics = yes && ethr_have_native_atomics=yes
+ have_sync_op=no
+ AC_TRY_LINK([],
+ [
+ $4 res;
+ volatile $4 var;
+ res = $sync_call
+ ],
+ [have_sync_op=yes])
+ test $have_sync_op = yes && $5
+ AC_MSG_RESULT([$have_sync_op])
])
AC_DEFUN(ETHR_CHK_INTERLOCKED,
@@ -1451,16 +1005,6 @@
test $enable_prefer_gcc_native_ethr_impls = yes &&
AC_DEFINE(ETHR_PREFER_GCC_NATIVE_IMPLS, 1, [Define if you prefer gcc native ethread implementations])
-AC_ARG_ENABLE(trust-gcc-atomic-builtins-memory-barriers,
- AS_HELP_STRING([--enable-trust-gcc-atomic-builtins-memory-barriers],
- [trust gcc atomic builtins memory barriers]),
-[ case "$enableval" in
- yes) trust_gcc_atomic_builtins_mbs=1 ;;
- *) trust_gcc_atomic_builtins_mbs=0 ;;
- esac ], trust_gcc_atomic_builtins_mbs=0)
-
-AC_DEFINE_UNQUOTED(ETHR_TRUST_GCC_ATOMIC_BUILTINS_MEMORY_BARRIERS, [$trust_gcc_atomic_builtins_mbs], [Define as a boolean indicating whether you trust gcc's __atomic_* builtins memory barrier implementations, or not])
-
AC_ARG_WITH(libatomic_ops,
AS_HELP_STRING([--with-libatomic_ops=PATH],
[specify and prefer usage of libatomic_ops in the ethread library]))
@@ -1472,33 +1016,12 @@
LM_CHECK_THR_LIB
ERL_INTERNAL_LIBS
-ERL_MONOTONIC_CLOCK(try_find_pthread_compatible, CLOCK_HIGHRES CLOCK_MONOTONIC, no)
-
-case $erl_monotonic_clock_func in
- clock_gettime)
- AC_DEFINE(ETHR_HAVE_CLOCK_GETTIME_MONOTONIC, [1], [Define if you have a clock_gettime() with a monotonic clock])
- ;;
- mach_clock_get_time)
- AC_DEFINE(ETHR_HAVE_MACH_CLOCK_GET_TIME, [1], [Define if you have a mach clock_get_time() with a monotonic clock])
- ;;
- gethrtime)
- AC_DEFINE(ETHR_HAVE_GETHRTIME, [1], [Define if you have a monotonic gethrtime()])
- ;;
- *)
- ;;
-esac
-
-if test "x$erl_monotonic_clock_id" != "x"; then
- AC_DEFINE_UNQUOTED(ETHR_MONOTONIC_CLOCK_ID, [$erl_monotonic_clock_id], [Define to the monotonic clock id to use])
-fi
-
-ethr_native_atomic_implementation=none
ethr_have_native_atomics=no
ethr_have_native_spinlock=no
ETHR_THR_LIB_BASE="$THR_LIB_NAME"
ETHR_THR_LIB_BASE_TYPE="$THR_LIB_TYPE"
ETHR_DEFS="$THR_DEFS"
-ETHR_X_LIBS="$THR_LIBS $ERTS_INTERNAL_X_LIBS $erl_monotonic_clock_lib"
+ETHR_X_LIBS="$THR_LIBS $ERTS_INTERNAL_X_LIBS"
ETHR_LIBS=
ETHR_LIB_NAME=
@@ -1577,10 +1100,7 @@
ETHR_CHK_INTERLOCKED([_InterlockedCompareExchange128], [4], [__int64], AC_DEFINE_UNQUOTED(ETHR_HAVE__INTERLOCKEDCOMPAREEXCHANGE128, 1, [Define if you have _InterlockedCompareExchange128()]))
fi
- if test "$ethr_have_native_atomics" = "yes"; then
- ethr_native_atomic_implementation=windows
- ethr_have_native_spinlock=yes
- fi
+ test "$ethr_have_native_atomics" = "yes" && ethr_have_native_spinlock=yes
;;
pthread|ose_threads)
@@ -1809,50 +1329,6 @@
AC_DEFINE(ETHR_HAVE_PTHREAD_ATTR_SETGUARDSIZE, 1, \
[Define if you have the pthread_attr_setguardsize function.]))
- if test "x$erl_monotonic_clock_id" != "x"; then
- AC_MSG_CHECKING(whether pthread_cond_timedwait() can use the monotonic clock $erl_monotonic_clock_id for timeout)
- pthread_cond_timedwait_monotonic=no
- AC_TRY_LINK([
- #if defined(ETHR_NEED_NPTL_PTHREAD_H)
- # include
- #elif defined(ETHR_HAVE_MIT_PTHREAD_H)
- # include
- #elif defined(ETHR_HAVE_PTHREAD_H)
- # include
- #endif
- #ifdef ETHR_TIME_WITH_SYS_TIME
- # include
- # include
- #else
- # ifdef ETHR_HAVE_SYS_TIME_H
- # include
- # else
- # include
- # endif
- #endif
- #if defined(ETHR_HAVE_MACH_CLOCK_GET_TIME)
- # include
- # include
- #endif
- ],
- [
- int res;
- pthread_condattr_t attr;
- pthread_cond_t cond;
- struct timespec cond_timeout;
- pthread_mutex_t mutex;
- res = pthread_condattr_init(&attr);
- res = pthread_condattr_setclock(&attr, ETHR_MONOTONIC_CLOCK_ID);
- res = pthread_cond_init(&cond, &attr);
- res = pthread_cond_timedwait(&cond, &mutex, &cond_timeout);
- ],
- [pthread_cond_timedwait_monotonic=yes])
- AC_MSG_RESULT([$pthread_cond_timedwait_monotonic])
- if test $pthread_cond_timedwait_monotonic = yes; then
- AC_DEFINE(ETHR_HAVE_PTHREAD_COND_TIMEDWAIT_MONOTONIC, [1], [Define if pthread_cond_timedwait() can be used with a monotonic clock])
- fi
- fi
-
linux_futex=no
AC_MSG_CHECKING([for Linux futexes])
AC_TRY_LINK([
@@ -1873,62 +1349,56 @@
AC_MSG_RESULT([$linux_futex])
test $linux_futex = yes && AC_DEFINE(ETHR_HAVE_LINUX_FUTEX, 1, [Define if you have a linux futex implementation.])
- pthread_setname=no
- AC_MSG_CHECKING([for pthread_setname_np])
- old_CFLAGS=$CFLAGS
- CFLAGS="$CFLAGS -Werror"
- AC_TRY_LINK([#define __USE_GNU
- #include ],
- [pthread_setname_np(pthread_self(), "name");],
- pthread_setname=linux)
- AC_TRY_LINK([#define __USE_GNU
- #include ],
- [pthread_set_name_np(pthread_self(), "name");],
- pthread_setname=bsd)
- AC_TRY_LINK([#define _DARWIN_C_SOURCE
- #include ],
- [pthread_setname_np("name");],
- pthread_setname=darwin)
- AC_MSG_RESULT([$pthread_setname])
- case $pthread_setname in
- linux) AC_DEFINE(ETHR_HAVE_PTHREAD_SETNAME_NP_2, 1,
- [Define if you have linux style pthread_setname_np]);;
- bsd) AC_DEFINE(ETHR_HAVE_PTHREAD_SET_NAME_NP_2, 1,
- [Define if you have bsd style pthread_set_name_np]);;
- darwin) AC_DEFINE(ETHR_HAVE_PTHREAD_SETNAME_NP_1, 1,
- [Define if you have darwin style pthread_setname_np]);;
- *) ;;
- esac
+ fi
- pthread_getname=no
- AC_MSG_CHECKING([for pthread_getname_np])
- AC_TRY_LINK([#define __USE_GNU
- #define _DARWIN_C_SOURCE
- #include ],
- [char buff[256]; pthread_getname_np(pthread_self(), buff, 256);],
- pthread_getname=linux)
- AC_TRY_LINK([#define __USE_GNU
- #define _DARWIN_C_SOURCE
- #include ],
- [char buff[256]; pthread_getname_np(pthread_self(), buff);],
- pthread_getname=ibm)
- AC_MSG_RESULT([$pthread_getname])
- case $pthread_getname in
- linux) AC_DEFINE(ETHR_HAVE_PTHREAD_GETNAME_NP_3, 1,
- [Define if you have linux style pthread_getname_np]);;
- ibm) AC_DEFINE(ETHR_HAVE_PTHREAD_GETNAME_NP_2, 1,
- [Define if you have ibm style pthread_getname_np]);;
- *) ;;
- esac
- CFLAGS=$old_CFLAGS
+ AC_CHECK_SIZEOF(int)
+ AC_CHECK_SIZEOF(long)
+ AC_CHECK_SIZEOF(long long)
+ AC_CHECK_SIZEOF(__int128_t)
+
+ if test "$ac_cv_sizeof_int" = "4"; then
+ int32="int"
+ elif test "$ac_cv_sizeof_long" = "4"; then
+ int32="long"
+ elif test "$ac_cv_sizeof_long_long" = "4"; then
+ int32="long long"
+ else
+ AC_MSG_ERROR([No 32-bit type found])
+ fi
- fi ## test "x$THR_LIB_NAME" = "xpthread"
+ if test "$ac_cv_sizeof_int" = "8"; then
+ int64="int"
+ elif test "$ac_cv_sizeof_long" = "8"; then
+ int64="long"
+ elif test "$ac_cv_sizeof_long_long" = "8"; then
+ int64="long long"
+ else
+ AC_MSG_ERROR([No 64-bit type found])
+ fi
+
+ int128=no
+ if test "$ac_cv_sizeof___int128_t" = "16"; then
+ int128="__int128_t"
+ fi
if test "X$disable_native_ethr_impls" = "Xyes"; then
ethr_have_native_atomics=no
else
+ ETHR_CHK_SYNC_OP([__sync_val_compare_and_swap], [3], [32], [$int32], AC_DEFINE(ETHR_HAVE___SYNC_VAL_COMPARE_AND_SWAP32, 1, [Define if you have __sync_val_compare_and_swap() for 32-bit integers]))
+ test "$have_sync_op" = "yes" && ethr_have_native_atomics=yes
+ ETHR_CHK_SYNC_OP([__sync_add_and_fetch], [2], [32], [$int32], AC_DEFINE(ETHR_HAVE___SYNC_ADD_AND_FETCH32, 1, [Define if you have __sync_add_and_fetch() for 32-bit integers]))
+ ETHR_CHK_SYNC_OP([__sync_fetch_and_and], [2], [32], [$int32], AC_DEFINE(ETHR_HAVE___SYNC_FETCH_AND_AND32, 1, [Define if you have __sync_fetch_and_and() for 32-bit integers]))
+ ETHR_CHK_SYNC_OP([__sync_fetch_and_or], [2], [32], [$int32], AC_DEFINE(ETHR_HAVE___SYNC_FETCH_AND_OR32, 1, [Define if you have __sync_fetch_and_or() for 32-bit integers]))
+
+ ETHR_CHK_SYNC_OP([__sync_val_compare_and_swap], [3], [64], [$int64], AC_DEFINE(ETHR_HAVE___SYNC_VAL_COMPARE_AND_SWAP64, 1, [Define if you have __sync_val_compare_and_swap() for 64-bit integers]))
+ test "$have_sync_op" = "yes" && ethr_have_native_atomics=yes
+ ETHR_CHK_SYNC_OP([__sync_add_and_fetch], [2], [64], [$int64], AC_DEFINE(ETHR_HAVE___SYNC_ADD_AND_FETCH64, 1, [Define if you have __sync_add_and_fetch() for 64-bit integers]))
+ ETHR_CHK_SYNC_OP([__sync_fetch_and_and], [2], [64], [$int64], AC_DEFINE(ETHR_HAVE___SYNC_FETCH_AND_AND64, 1, [Define if you have __sync_fetch_and_and() for 64-bit integers]))
+ ETHR_CHK_SYNC_OP([__sync_fetch_and_or], [2], [64], [$int64], AC_DEFINE(ETHR_HAVE___SYNC_FETCH_AND_OR64, 1, [Define if you have __sync_fetch_and_or() for 64-bit integers]))
- ETHR_CHK_GCC_ATOMIC_OPS([])
+ if test $int128 != no; then
+ ETHR_CHK_SYNC_OP([__sync_val_compare_and_swap], [3], [128], [$int128], AC_DEFINE(ETHR_HAVE___SYNC_VAL_COMPARE_AND_SWAP128, 1, [Define if you have __sync_val_compare_and_swap() for 128-bit integers]))
+ fi
AC_MSG_CHECKING([for a usable libatomic_ops implementation])
case "x$with_libatomic_ops" in
@@ -1951,34 +1421,11 @@
int z;
AO_nop_full();
-#if defined(AO_HAVE_store)
AO_store(&x, (AO_t) 0);
-#elif defined(AO_HAVE_store_release)
- AO_store_release(&x, (AO_t) 0);
-#else
-#error No store
-#endif
-#if defined(AO_HAVE_load)
z = AO_load(&x);
-#elif defined(AO_HAVE_load_acquire)
- z = AO_load_acquire(&x);
-#else
-#error No load
-#endif
-#if defined(AO_HAVE_compare_and_swap_full)
z = AO_compare_and_swap_full(&x, (AO_t) 0, (AO_t) 1);
-#elif defined(AO_HAVE_compare_and_swap_release)
- z = AO_compare_and_swap_release(&x, (AO_t) 0, (AO_t) 1);
-#elif defined(AO_HAVE_compare_and_swap_acquire)
- z = AO_compare_and_swap_acquire(&x, (AO_t) 0, (AO_t) 1);
-#elif defined(AO_HAVE_compare_and_swap)
- z = AO_compare_and_swap(&x, (AO_t) 0, (AO_t) 1);
-#else
-#error No compare_and_swap
-#endif
],
[ethr_have_native_atomics=yes
- ethr_native_atomic_implementation=libatomic_ops
ethr_have_libatomic_ops=yes])
AC_MSG_RESULT([$ethr_have_libatomic_ops])
if test $ethr_have_libatomic_ops = yes; then
@@ -2010,19 +1457,15 @@
*)
AC_MSG_ERROR([Unsupported Sparc memory order: $with_sparc_memory_order]);;
esac
- ethr_native_atomic_implementation=ethread
ethr_have_native_atomics=yes;;
i86pc | i*86 | x86_64 | amd64)
if test "$enable_x86_out_of_order" = "yes"; then
AC_DEFINE(ETHR_X86_OUT_OF_ORDER, 1, [Define if x86/x86_64 out of order instructions should be synchronized])
fi
- ethr_native_atomic_implementation=ethread
ethr_have_native_atomics=yes;;
macppc | ppc | powerpc | "Power Macintosh")
- ethr_native_atomic_implementation=ethread
ethr_have_native_atomics=yes;;
tile)
- ethr_native_atomic_implementation=ethread
ethr_have_native_atomics=yes;;
*)
;;
@@ -2195,233 +1638,109 @@
])
+
dnl ----------------------------------------------------------------------
dnl
dnl ERL_TIME_CORRECTION
dnl
-dnl Check for primitives that can be used for implementing
-dnl erts_os_monotonic_time() and erts_os_system_time()
+dnl In the presence of a high resolution realtime timer Erlang can adapt
+dnl its view of time relative to this timer. On solaris such a timer is
+dnl available with the syscall gethrtime(). On other OS's a fallback
+dnl solution using times() is implemented. (However on e.g. FreeBSD times()
+dnl is implemented using gettimeofday so it doesn't make much sense to
+dnl use it there...) On second thought, it seems to be safer to do it the
+dnl other way around. I.e. only use times() on OS's where we know it will
+dnl work...
dnl
AC_DEFUN(ERL_TIME_CORRECTION,
-[
-
-AC_ARG_WITH(clock-resolution,
-AS_HELP_STRING([--with-clock-resolution=high|low|default],
- [specify wanted clock resolution]))
-
-AC_ARG_WITH(clock-gettime-realtime-id,
-AS_HELP_STRING([--with-clock-gettime-realtime-id=CLOCKID],
- [specify clock id to use with clock_gettime() for realtime time)]))
-
-AC_ARG_WITH(clock-gettime-monotonic-id,
-AS_HELP_STRING([--with-clock-gettime-monotonic-id=CLOCKID],
- [specify clock id to use with clock_gettime() for monotonic time)]))
-
-AC_ARG_ENABLE(prefer-elapsed-monotonic-time-during-suspend,
-AS_HELP_STRING([--enable-prefer-elapsed-monotonic-time-during-suspend],
- [Prefer an OS monotonic time source with elapsed time during suspend])
-AS_HELP_STRING([--disable-prefer-elapsed-monotonic-time-during-suspend],
- [Do not prefer an OS monotonic time source with elapsed time during suspend]),
-[ case "$enableval" in
- yes) prefer_elapsed_monotonic_time_during_suspend=yes ;;
- *) prefer_elapsed_monotonic_time_during_suspend=no ;;
- esac ], prefer_elapsed_monotonic_time_during_suspend=no)
-
-AC_ARG_ENABLE(gettimeofday-as-os-system-time,
- AS_HELP_STRING([--enable-gettimeofday-as-os-system-time],
- [Force usage of gettimeofday() for OS system time]),
-[ case "$enableval" in
- yes) force_gettimeofday_os_system_time=yes ;;
- *) force_gettimeofday_os_system_time=no ;;
- esac ], force_gettimeofday_os_system_time=no)
-
-case "$with_clock_resolution" in
- ""|no|yes)
- with_clock_resolution=default;;
- high|low|default)
- ;;
- *)
- AC_MSG_ERROR([Invalid wanted clock resolution: $with_clock_resolution])
- ;;
-esac
-
-if test "$force_gettimeofday_os_system_time" = "yes"; then
-
- AC_CHECK_FUNCS([gettimeofday])
- if test "$ac_cv_func_gettimeofday" = "yes"; then
- AC_DEFINE(OS_SYSTEM_TIME_GETTIMEOFDAY, [1], [Define if you want to implement erts_os_system_time() using gettimeofday()])
- else
- AC_MSG_ERROR([No gettimeofday() available])
- fi
-
-else # $force_gettimeofday_os_system_time != yes
-
-case "$with_clock_gettime_realtime_id" in
- ""|no)
- with_clock_gettime_realtime_id=no
- ;;
- CLOCK_*CPUTIME*)
- AC_MSG_ERROR([Invalid clock_gettime() realtime clock id: Refusing to use the cputime clock id $with_clock_gettime_realtime_id as realtime clock id])
- ;;
- CLOCK_MONOTONIC*|CLOCK_BOOTTIME*|CLOCK_UPTIME*|CLOCK_HIGHRES*)
- AC_MSG_ERROR([Invalid clock_gettime() realtime clock id: Refusing to use the monotonic clock id $with_clock_gettime_realtime_id as realtime clock id])
- ;;
- CLOCK_*)
- ;;
- *)
- AC_MSG_ERROR([Invalid clock_gettime() clock id: $with_clock_gettime_realtime_id])
- ;;
-esac
-
-case "$with_clock_resolution-$with_clock_gettime_realtime_id" in
- high-no)
- ERL_WALL_CLOCK(high_resolution);;
- low-no)
- ERL_WALL_CLOCK(low_resolution);;
- default-no)
- ERL_WALL_CLOCK(default_resolution);;
- *)
- ERL_WALL_CLOCK(custom_resolution, $with_clock_gettime_realtime_id);;
-esac
-
-case "$erl_wall_clock_func-$erl_wall_clock_id-$with_clock_gettime_realtime_id" in
- *-*-no)
- ;;
- clock_gettime-$with_clock_gettime_realtime_id-$with_clock_gettime_realtime_id)
- ;;
- *)
- AC_MSG_ERROR([$with_clock_gettime_realtime_id as clock id to clock_gettime() doesn't compile])
- ;;
-esac
-
-case $erl_wall_clock_func in
- none)
- AC_MSG_ERROR([No wall clock source found])
- ;;
- mach_clock_get_time)
- AC_DEFINE(OS_SYSTEM_TIME_USING_MACH_CLOCK_GET_TIME, [1], [Define if you want to implement erts_os_system_time() using mach clock_get_time()])
- ;;
- clock_gettime)
- AC_DEFINE(OS_SYSTEM_TIME_USING_CLOCK_GETTIME, [1], [Define if you want to implement erts_os_system_time() using clock_gettime()])
- ;;
- gettimeofday)
- AC_DEFINE(OS_SYSTEM_TIME_GETTIMEOFDAY, [1], [Define if you want to implement erts_os_system_time() using gettimeofday()])
- ;;
- *)
- ;;
-esac
-
-if test "x$erl_wall_clock_id" != "x"; then
- AC_DEFINE_UNQUOTED(WALL_CLOCK_ID_STR, ["$erl_wall_clock_id"], [Define as a string of wall clock id to use])
- AC_DEFINE_UNQUOTED(WALL_CLOCK_ID, [$erl_wall_clock_id], [Define to wall clock id to use])
-fi
-
-fi # $force_gettimeofday_os_system_time != yes
-
-case "$with_clock_gettime_monotonic_id" in
- ""|no)
- with_clock_gettime_monotonic_id=no
- ;;
- CLOCK_*CPUTIME*)
- AC_MSG_ERROR([Invalid clock_gettime() monotonic clock id: Refusing to use the cputime clock id $with_clock_gettime_monotonic_id as monotonic clock id])
- ;;
- CLOCK_REALTIME*|CLOCK_TAI*)
- AC_MSG_ERROR([Invalid clock_gettime() monotonic clock id: Refusing to use the realtime clock id $with_clock_gettime_monotonic_id as monotonic clock id])
- ;;
- CLOCK_*)
- ;;
- *)
- AC_MSG_ERROR([Invalid clock_gettime() clock id: $with_clock_gettime_monotonic_id])
- ;;
-esac
-
-case "$with_clock_resolution-$with_clock_gettime_monotonic_id" in
- high-no)
- ERL_MONOTONIC_CLOCK(high_resolution, undefined, $prefer_elapsed_monotonic_time_during_suspend);;
- low-no)
- ERL_MONOTONIC_CLOCK(low_resolution, undefined, $prefer_elapsed_monotonic_time_during_suspend);;
- default-no)
- ERL_MONOTONIC_CLOCK(default_resolution, undefined, $prefer_elapsed_monotonic_time_during_suspend);;
- *)
- ERL_MONOTONIC_CLOCK(custom_resolution, $with_clock_gettime_monotonic_id, $prefer_elapsed_monotonic_time_during_suspend);;
-esac
-
-case "$erl_monotonic_clock_func-$erl_monotonic_clock_id-$with_clock_gettime_monotonic_id" in
- *-*-no)
- ;;
- clock_gettime-$with_clock_gettime_monotonic_id-$with_clock_gettime_monotonic_id)
- ;;
- *)
- AC_MSG_ERROR([$with_clock_gettime_monotonic_id as clock id to clock_gettime() doesn't compile])
- ;;
-esac
-
-case $erl_monotonic_clock_func in
- times)
- AC_DEFINE(OS_MONOTONIC_TIME_USING_TIMES, [1], [Define if you want to implement erts_os_monotonic_time() using times()])
- ;;
- mach_clock_get_time)
- AC_DEFINE(OS_MONOTONIC_TIME_USING_MACH_CLOCK_GET_TIME, [1], [Define if you want to implement erts_os_monotonic_time() using mach clock_get_time()])
- ;;
- clock_gettime)
- AC_DEFINE(OS_MONOTONIC_TIME_USING_CLOCK_GETTIME, [1], [Define if you want to implement erts_os_monotonic_time() using clock_gettime()])
- ;;
- gethrtime)
- AC_DEFINE(OS_MONOTONIC_TIME_USING_GETHRTIME, [1], [Define if you want to implement erts_os_monotonic_time() using gethrtime()])
- ;;
- *)
- ;;
-esac
-
-if test $erl_corrected_monotonic_clock = yes; then
- AC_DEFINE(ERTS_HAVE_CORRECTED_OS_MONOTONIC_TIME, [1], [Define if OS monotonic clock is corrected])
-fi
-
-if test $erl_monotonic_clock_low_resolution = yes; then
- AC_DEFINE(ERTS_HAVE_LOW_RESOLUTION_OS_MONOTONIC_LOW, [1], [Define if you have a low resolution OS monotonic clock])
-fi
-
-xrtlib="$erl_monotonic_clock_lib"
-if test "x$erl_monotonic_clock_id" != "x"; then
- AC_DEFINE_UNQUOTED(MONOTONIC_CLOCK_ID_STR, ["$erl_monotonic_clock_id"], [Define as a string of monotonic clock id to use])
- AC_DEFINE_UNQUOTED(MONOTONIC_CLOCK_ID, [$erl_monotonic_clock_id], [Define to monotonic clock id to use])
+[if test x$ac_cv_func_gethrtime = x; then
+ AC_CHECK_FUNC(gethrtime)
fi
-
-if test $erl_cv_clock_gettime_monotonic_raw = yes; then
- AC_DEFINE(HAVE_CLOCK_GETTIME_MONOTONIC_RAW, [1], [Define if you have clock_gettime(CLOCK_MONOTONIC_RAW, _)])
+if test x$clock_gettime_correction = xunknown; then
+ AC_TRY_COMPILE([#include ],
+ [struct timespec ts;
+ long long result;
+ clock_gettime(CLOCK_MONOTONIC,&ts);
+ result = ((long long) ts.tv_sec) * 1000000000LL +
+ ((long long) ts.tv_nsec);],
+ clock_gettime_compiles=yes,
+ clock_gettime_compiles=no)
+else
+ clock_gettime_compiles=no
fi
+
-ERL_MONOTONIC_CLOCK(high_resolution, undefined, no)
+AC_CACHE_CHECK([how to correct for time adjustments], erl_cv_time_correction,
+[
+case $clock_gettime_correction in
+ yes)
+ erl_cv_time_correction=clock_gettime;;
+ no|unknown)
+ case $ac_cv_func_gethrtime in
+ yes)
+ erl_cv_time_correction=hrtime ;;
+ no)
+ case $host_os in
+ linux*)
+ case $clock_gettime_correction in
+ unknown)
+ if test x$clock_gettime_compiles = xyes; then
+ if test X$cross_compiling != Xyes; then
+ linux_kernel_vsn_=`uname -r`
+ case $linux_kernel_vsn_ in
+ [[0-1]].*|2.[[0-5]]|2.[[0-5]].*)
+ erl_cv_time_correction=times ;;
+ *)
+ erl_cv_time_correction=clock_gettime;;
+ esac
+ else
+ case X$erl_xcomp_linux_clock_gettime_correction in
+ X)
+ erl_cv_time_correction=cross;;
+ Xyes|Xno)
+ if test $erl_xcomp_linux_clock_gettime_correction = yes; then
+ erl_cv_time_correction=clock_gettime
+ else
+ erl_cv_time_correction=times
+ fi;;
+ *)
+ AC_MSG_ERROR([Bad erl_xcomp_linux_clock_gettime_correction value: $erl_xcomp_linux_clock_gettime_correction]);;
+ esac
+ fi
+ else
+ erl_cv_time_correction=times
+ fi
+ ;;
+ *)
+ erl_cv_time_correction=times ;;
+ esac
+ ;;
+ *)
+ erl_cv_time_correction=none ;;
+ esac
+ ;;
+ esac
+ ;;
+esac
+])
-case $$erl_monotonic_clock_low_resolution-$erl_monotonic_clock_func in
- no-mach_clock_get_time)
- monotonic_hrtime=yes
- AC_DEFINE(SYS_HRTIME_USING_MACH_CLOCK_GET_TIME, [1], [Define if you want to implement erts_os_hrtime() using mach clock_get_time()])
- ;;
- no-clock_gettime)
- monotonic_hrtime=yes
- AC_DEFINE(SYS_HRTIME_USING_CLOCK_GETTIME, [1], [Define if you want to implement erts_os_hrtime() using clock_gettime()])
- ;;
- no-gethrtime)
- monotonic_hrtime=yes
- AC_DEFINE(SYS_HRTIME_USING_GETHRTIME, [1], [Define if you want to implement erts_os_hrtime() using gethrtime()])
+xrtlib=""
+case $erl_cv_time_correction in
+ times)
+ AC_DEFINE(CORRECT_USING_TIMES,[],
+ [Define if you do not have a high-res. timer & want to use times() instead])
;;
- *)
- monotonic_hrtime=no
+ clock_gettime|cross)
+ if test $erl_cv_time_correction = cross; then
+ erl_cv_time_correction=clock_gettime
+ AC_MSG_WARN([result clock_gettime guessed because of cross compilation])
+ fi
+ xrtlib="-lrt"
+ AC_DEFINE(GETHRTIME_WITH_CLOCK_GETTIME,[1],
+ [Define if you want to use clock_gettime to simulate gethrtime])
;;
esac
-
-if test $monotonic_hrtime = yes; then
- AC_DEFINE(HAVE_MONOTONIC_ERTS_SYS_HRTIME, [1], [Define if you have a monotonic erts_os_hrtime() implementation])
-fi
-
-if test "x$erl_monotonic_clock_id" != "x"; then
- AC_DEFINE_UNQUOTED(HRTIME_CLOCK_ID_STR, ["$erl_monotonic_clock_id"], [Define as a string of monotonic clock id to use])
- AC_DEFINE_UNQUOTED(HRTIME_CLOCK_ID, [$erl_monotonic_clock_id], [Define to monotonic clock id to use])
-fi
-
-
dnl
dnl Check if gethrvtime is working, and if to use procfs ioctl
dnl or (yet to be written) write to the procfs ctl file.
@@ -2494,7 +1813,6 @@
esac
])
-LIBRT=$xrtlib
case $erl_gethrvtime in
procfs_ioctl)
AC_DEFINE(HAVE_GETHRVTIME_PROCFS_IOCTL,[1],
@@ -2541,33 +1859,43 @@
exit(0); return 0;
}
],
- erl_clock_gettime_cpu_time=yes,
- erl_clock_gettime_cpu_time=no,
+ erl_clock_gettime=yes,
+ erl_clock_gettime=no,
[
case X$erl_xcomp_clock_gettime_cpu_time in
- X) erl_clock_gettime_cpu_time=cross;;
- Xyes|Xno) erl_clock_gettime_cpu_time=$erl_xcomp_clock_gettime_cpu_time;;
+ X) erl_clock_gettime=cross;;
+ Xyes|Xno) erl_clock_gettime=$erl_xcomp_clock_gettime_cpu_time;;
*) AC_MSG_ERROR([Bad erl_xcomp_clock_gettime_cpu_time value: $erl_xcomp_clock_gettime_cpu_time]);;
esac
])
LIBS=$save_libs
- AC_MSG_RESULT($erl_clock_gettime_cpu_time)
- case $erl_clock_gettime_cpu_time in
- yes)
- AC_DEFINE(HAVE_CLOCK_GETTIME_CPU_TIME,[],
- [define if clock_gettime() works for getting process time])
- LIBRT=-lrt
- ;;
- cross)
- erl_clock_gettime_cpu_time=no
- AC_MSG_WARN([result no guessed because of cross compilation])
+ case $host_os in
+ linux*)
+ AC_MSG_RESULT([no; not stable])
+ LIBRT=$xrtlib
;;
*)
+ AC_MSG_RESULT($erl_clock_gettime)
+ case $erl_clock_gettime in
+ yes)
+ AC_DEFINE(HAVE_CLOCK_GETTIME,[],
+ [define if clock_gettime() works for getting process time])
+ LIBRT=-lrt
+ ;;
+ cross)
+ erl_clock_gettime=no
+ AC_MSG_WARN([result no guessed because of cross compilation])
+ LIBRT=$xrtlib
+ ;;
+ *)
+ LIBRT=$xrtlib
+ ;;
+ esac
;;
esac
+ AC_SUBST(LIBRT)
;;
esac
-AC_SUBST(LIBRT)
])dnl
dnl ----------------------------------------------------------------------
diff -Nru erlang-18.2-dfsg/erts/AUTHORS erlang-17.3-dfsg/erts/AUTHORS
--- erlang-18.2-dfsg/erts/AUTHORS 2015-12-15 20:10:35.000000000 +0000
+++ erlang-17.3-dfsg/erts/AUTHORS 2014-09-16 19:10:57.000000000 +0000
@@ -3,17 +3,16 @@
Copyright Ericsson AB 1999-2009. All Rights Reserved.
- Licensed under the Apache License, Version 2.0 (the "License");
- you may not use this file except in compliance with the License.
- You may obtain a copy of the License at
+ The contents of this file are subject to the Erlang Public License,
+ Version 1.1, (the "License"); you may not use this file except in
+ compliance with the License. You should have received a copy of the
+ Erlang Public License along with this software. If not, it can be
+ retrieved online at http://www.erlang.org/.
- http://www.apache.org/licenses/LICENSE-2.0
-
- Unless required by applicable law or agreed to in writing, software
- distributed under the License is distributed on an "AS IS" BASIS,
- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- See the License for the specific language governing permissions and
- limitations under the License.
+ Software distributed under the License is distributed on an "AS IS"
+ basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See
+ the License for the specific language governing rights and limitations
+ under the License.
%CopyrightEnd%
diff -Nru erlang-18.2-dfsg/erts/autoconf/config.guess erlang-17.3-dfsg/erts/autoconf/config.guess
--- erlang-18.2-dfsg/erts/autoconf/config.guess 2015-12-15 20:10:35.000000000 +0000
+++ erlang-17.3-dfsg/erts/autoconf/config.guess 2014-09-16 19:10:57.000000000 +0000
@@ -1,8 +1,8 @@
#! /bin/sh
# Attempt to guess a canonical system name.
-# Copyright 1992-2015 Free Software Foundation, Inc.
+# Copyright 1992-2013 Free Software Foundation, Inc.
-timestamp='2015-03-04'
+timestamp='2013-02-12'
# This file is free software; you can redistribute it and/or modify it
# under the terms of the GNU General Public License as published by
@@ -24,12 +24,12 @@
# program. This Exception is an additional permission under section 7
# of the GNU General Public License, version 3 ("GPLv3").
#
-# Originally written by Per Bothner; maintained since 2000 by Ben Elliston.
+# Originally written by Per Bothner.
#
# You can get the latest version of this script from:
# http://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.guess;hb=HEAD
#
-# Please send patches to .
+# Please send patches with a ChangeLog entry to config-patches@gnu.org.
me=`echo "$0" | sed -e 's,.*/,,'`
@@ -50,7 +50,7 @@
GNU config.guess ($timestamp)
Originally written by Per Bothner.
-Copyright 1992-2015 Free Software Foundation, Inc.
+Copyright 1992-2013 Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE."
@@ -132,27 +132,6 @@
UNAME_SYSTEM=`(uname -s) 2>/dev/null` || UNAME_SYSTEM=unknown
UNAME_VERSION=`(uname -v) 2>/dev/null` || UNAME_VERSION=unknown
-case "${UNAME_SYSTEM}" in
-Linux|GNU|GNU/*)
- # If the system lacks a compiler, then just pick glibc.
- # We could probably try harder.
- LIBC=gnu
-
- eval $set_cc_for_build
- cat <<-EOF > $dummy.c
- #include
- #if defined(__UCLIBC__)
- LIBC=uclibc
- #elif defined(__dietlibc__)
- LIBC=dietlibc
- #else
- LIBC=gnu
- #endif
- EOF
- eval `$CC_FOR_BUILD -E $dummy.c 2>/dev/null | grep '^LIBC' | sed 's, ,,g'`
- ;;
-esac
-
# Note: order is significant - the case branches are not exclusive.
case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in
@@ -168,27 +147,20 @@
# Note: NetBSD doesn't particularly care about the vendor
# portion of the name. We always set it to "unknown".
sysctl="sysctl -n hw.machine_arch"
- UNAME_MACHINE_ARCH=`(uname -p 2>/dev/null || \
- /sbin/$sysctl 2>/dev/null || \
- /usr/sbin/$sysctl 2>/dev/null || \
- echo unknown)`
+ UNAME_MACHINE_ARCH=`(/sbin/$sysctl 2>/dev/null || \
+ /usr/sbin/$sysctl 2>/dev/null || echo unknown)`
case "${UNAME_MACHINE_ARCH}" in
armeb) machine=armeb-unknown ;;
arm*) machine=arm-unknown ;;
sh3el) machine=shl-unknown ;;
sh3eb) machine=sh-unknown ;;
sh5el) machine=sh5le-unknown ;;
- earmv*)
- arch=`echo ${UNAME_MACHINE_ARCH} | sed -e 's,^e\(armv[0-9]\).*$,\1,'`
- endian=`echo ${UNAME_MACHINE_ARCH} | sed -ne 's,^.*\(eb\)$,\1,p'`
- machine=${arch}${endian}-unknown
- ;;
*) machine=${UNAME_MACHINE_ARCH}-unknown ;;
esac
# The Operating System including object format, if it has switched
# to ELF recently, or will in the future.
case "${UNAME_MACHINE_ARCH}" in
- arm*|earm*|i386|m68k|ns32k|sh3*|sparc|vax)
+ arm*|i386|m68k|ns32k|sh3*|sparc|vax)
eval $set_cc_for_build
if echo __ELF__ | $CC_FOR_BUILD -E - 2>/dev/null \
| grep -q __ELF__
@@ -204,13 +176,6 @@
os=netbsd
;;
esac
- # Determine ABI tags.
- case "${UNAME_MACHINE_ARCH}" in
- earm*)
- expr='s/^earmv[0-9]/-eabi/;s/eb$//'
- abi=`echo ${UNAME_MACHINE_ARCH} | sed -e "$expr"`
- ;;
- esac
# The OS release
# Debian GNU/NetBSD machines have a different userland, and
# thus, need a distinct triplet. However, they do not need
@@ -227,7 +192,7 @@
# Since CPU_TYPE-MANUFACTURER-KERNEL-OPERATING_SYSTEM:
# contains redundant information, the shorter form:
# CPU_TYPE-MANUFACTURER-OPERATING_SYSTEM is used.
- echo "${machine}-${os}${release}${abi}"
+ echo "${machine}-${os}${release}"
exit ;;
*:Bitrig:*:*)
UNAME_MACHINE_ARCH=`arch | sed 's/Bitrig.//'`
@@ -593,9 +558,8 @@
else
IBM_ARCH=powerpc
fi
- if [ -x /usr/bin/lslpp ] ; then
- IBM_REV=`/usr/bin/lslpp -Lqc bos.rte.libc |
- awk -F: '{ print $3 }' | sed s/[0-9]*$/0/`
+ if [ -x /usr/bin/oslevel ] ; then
+ IBM_REV=`/usr/bin/oslevel`
else
IBM_REV=${UNAME_VERSION}.${UNAME_RELEASE}
fi
@@ -841,7 +805,7 @@
*:MINGW*:*)
echo ${UNAME_MACHINE}-pc-mingw32
exit ;;
- *:MSYS*:*)
+ i*:MSYS*:*)
echo ${UNAME_MACHINE}-pc-msys
exit ;;
i*:windows32*:*)
@@ -889,21 +853,21 @@
exit ;;
*:GNU:*:*)
# the GNU system
- echo `echo ${UNAME_MACHINE}|sed -e 's,[-/].*$,,'`-unknown-${LIBC}`echo ${UNAME_RELEASE}|sed -e 's,/.*$,,'`
+ echo `echo ${UNAME_MACHINE}|sed -e 's,[-/].*$,,'`-unknown-gnu`echo ${UNAME_RELEASE}|sed -e 's,/.*$,,'`
exit ;;
*:GNU/*:*:*)
# other systems with GNU libc and userland
- echo ${UNAME_MACHINE}-unknown-`echo ${UNAME_SYSTEM} | sed 's,^[^/]*/,,' | tr '[A-Z]' '[a-z]'``echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'`-${LIBC}
+ echo ${UNAME_MACHINE}-unknown-`echo ${UNAME_SYSTEM} | sed 's,^[^/]*/,,' | tr '[A-Z]' '[a-z]'``echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'`-gnu
exit ;;
i*86:Minix:*:*)
echo ${UNAME_MACHINE}-pc-minix
exit ;;
aarch64:Linux:*:*)
- echo ${UNAME_MACHINE}-unknown-linux-${LIBC}
+ echo ${UNAME_MACHINE}-unknown-linux-gnu
exit ;;
aarch64_be:Linux:*:*)
UNAME_MACHINE=aarch64_be
- echo ${UNAME_MACHINE}-unknown-linux-${LIBC}
+ echo ${UNAME_MACHINE}-unknown-linux-gnu
exit ;;
alpha:Linux:*:*)
case `sed -n '/^cpu model/s/^.*: \(.*\)/\1/p' < /proc/cpuinfo` in
@@ -916,57 +880,59 @@
EV68*) UNAME_MACHINE=alphaev68 ;;
esac
objdump --private-headers /bin/sh | grep -q ld.so.1
- if test "$?" = 0 ; then LIBC="gnulibc1" ; fi
- echo ${UNAME_MACHINE}-unknown-linux-${LIBC}
- exit ;;
- arc:Linux:*:* | arceb:Linux:*:*)
- echo ${UNAME_MACHINE}-unknown-linux-${LIBC}
+ if test "$?" = 0 ; then LIBC="libc1" ; else LIBC="" ; fi
+ echo ${UNAME_MACHINE}-unknown-linux-gnu${LIBC}
exit ;;
arm*:Linux:*:*)
eval $set_cc_for_build
if echo __ARM_EABI__ | $CC_FOR_BUILD -E - 2>/dev/null \
| grep -q __ARM_EABI__
then
- echo ${UNAME_MACHINE}-unknown-linux-${LIBC}
+ echo ${UNAME_MACHINE}-unknown-linux-gnu
else
if echo __ARM_PCS_VFP | $CC_FOR_BUILD -E - 2>/dev/null \
| grep -q __ARM_PCS_VFP
then
- echo ${UNAME_MACHINE}-unknown-linux-${LIBC}eabi
+ echo ${UNAME_MACHINE}-unknown-linux-gnueabi
else
- echo ${UNAME_MACHINE}-unknown-linux-${LIBC}eabihf
+ echo ${UNAME_MACHINE}-unknown-linux-gnueabihf
fi
fi
exit ;;
avr32*:Linux:*:*)
- echo ${UNAME_MACHINE}-unknown-linux-${LIBC}
+ echo ${UNAME_MACHINE}-unknown-linux-gnu
exit ;;
cris:Linux:*:*)
- echo ${UNAME_MACHINE}-axis-linux-${LIBC}
+ echo ${UNAME_MACHINE}-axis-linux-gnu
exit ;;
crisv32:Linux:*:*)
- echo ${UNAME_MACHINE}-axis-linux-${LIBC}
- exit ;;
- e2k:Linux:*:*)
- echo ${UNAME_MACHINE}-unknown-linux-${LIBC}
+ echo ${UNAME_MACHINE}-axis-linux-gnu
exit ;;
frv:Linux:*:*)
- echo ${UNAME_MACHINE}-unknown-linux-${LIBC}
+ echo ${UNAME_MACHINE}-unknown-linux-gnu
exit ;;
hexagon:Linux:*:*)
- echo ${UNAME_MACHINE}-unknown-linux-${LIBC}
+ echo ${UNAME_MACHINE}-unknown-linux-gnu
exit ;;
i*86:Linux:*:*)
- echo ${UNAME_MACHINE}-pc-linux-${LIBC}
+ LIBC=gnu
+ eval $set_cc_for_build
+ sed 's/^ //' << EOF >$dummy.c
+ #ifdef __dietlibc__
+ LIBC=dietlibc
+ #endif
+EOF
+ eval `$CC_FOR_BUILD -E $dummy.c 2>/dev/null | grep '^LIBC'`
+ echo "${UNAME_MACHINE}-pc-linux-${LIBC}"
exit ;;
ia64:Linux:*:*)
- echo ${UNAME_MACHINE}-unknown-linux-${LIBC}
+ echo ${UNAME_MACHINE}-unknown-linux-gnu
exit ;;
m32r*:Linux:*:*)
- echo ${UNAME_MACHINE}-unknown-linux-${LIBC}
+ echo ${UNAME_MACHINE}-unknown-linux-gnu
exit ;;
m68*:Linux:*:*)
- echo ${UNAME_MACHINE}-unknown-linux-${LIBC}
+ echo ${UNAME_MACHINE}-unknown-linux-gnu
exit ;;
mips:Linux:*:* | mips64:Linux:*:*)
eval $set_cc_for_build
@@ -985,63 +951,57 @@
#endif
EOF
eval `$CC_FOR_BUILD -E $dummy.c 2>/dev/null | grep '^CPU'`
- test x"${CPU}" != x && { echo "${CPU}-unknown-linux-${LIBC}"; exit; }
+ test x"${CPU}" != x && { echo "${CPU}-unknown-linux-gnu"; exit; }
;;
- openrisc*:Linux:*:*)
- echo or1k-unknown-linux-${LIBC}
+ or1k:Linux:*:*)
+ echo ${UNAME_MACHINE}-unknown-linux-gnu
exit ;;
- or32:Linux:*:* | or1k*:Linux:*:*)
- echo ${UNAME_MACHINE}-unknown-linux-${LIBC}
+ or32:Linux:*:*)
+ echo ${UNAME_MACHINE}-unknown-linux-gnu
exit ;;
padre:Linux:*:*)
- echo sparc-unknown-linux-${LIBC}
+ echo sparc-unknown-linux-gnu
exit ;;
parisc64:Linux:*:* | hppa64:Linux:*:*)
- echo hppa64-unknown-linux-${LIBC}
+ echo hppa64-unknown-linux-gnu
exit ;;
parisc:Linux:*:* | hppa:Linux:*:*)
# Look for CPU level
case `grep '^cpu[^a-z]*:' /proc/cpuinfo 2>/dev/null | cut -d' ' -f2` in
- PA7*) echo hppa1.1-unknown-linux-${LIBC} ;;
- PA8*) echo hppa2.0-unknown-linux-${LIBC} ;;
- *) echo hppa-unknown-linux-${LIBC} ;;
+ PA7*) echo hppa1.1-unknown-linux-gnu ;;
+ PA8*) echo hppa2.0-unknown-linux-gnu ;;
+ *) echo hppa-unknown-linux-gnu ;;
esac
exit ;;
ppc64:Linux:*:*)
- echo powerpc64-unknown-linux-${LIBC}
+ echo powerpc64-unknown-linux-gnu
exit ;;
ppc:Linux:*:*)
- echo powerpc-unknown-linux-${LIBC}
- exit ;;
- ppc64le:Linux:*:*)
- echo powerpc64le-unknown-linux-${LIBC}
- exit ;;
- ppcle:Linux:*:*)
- echo powerpcle-unknown-linux-${LIBC}
+ echo powerpc-unknown-linux-gnu
exit ;;
s390:Linux:*:* | s390x:Linux:*:*)
- echo ${UNAME_MACHINE}-ibm-linux-${LIBC}
+ echo ${UNAME_MACHINE}-ibm-linux
exit ;;
sh64*:Linux:*:*)
- echo ${UNAME_MACHINE}-unknown-linux-${LIBC}
+ echo ${UNAME_MACHINE}-unknown-linux-gnu
exit ;;
sh*:Linux:*:*)
- echo ${UNAME_MACHINE}-unknown-linux-${LIBC}
+ echo ${UNAME_MACHINE}-unknown-linux-gnu
exit ;;
sparc:Linux:*:* | sparc64:Linux:*:*)
- echo ${UNAME_MACHINE}-unknown-linux-${LIBC}
+ echo ${UNAME_MACHINE}-unknown-linux-gnu
exit ;;
tile*:Linux:*:*)
- echo ${UNAME_MACHINE}-unknown-linux-${LIBC}
+ echo ${UNAME_MACHINE}-unknown-linux-gnu
exit ;;
vax:Linux:*:*)
- echo ${UNAME_MACHINE}-dec-linux-${LIBC}
+ echo ${UNAME_MACHINE}-dec-linux-gnu
exit ;;
x86_64:Linux:*:*)
- echo ${UNAME_MACHINE}-unknown-linux-${LIBC}
+ echo ${UNAME_MACHINE}-unknown-linux-gnu
exit ;;
xtensa*:Linux:*:*)
- echo ${UNAME_MACHINE}-unknown-linux-${LIBC}
+ echo ${UNAME_MACHINE}-unknown-linux-gnu
exit ;;
i*86:DYNIX/ptx:4*:*)
# ptx 4.0 does uname -s correctly, with DYNIX/ptx in there.
@@ -1274,31 +1234,19 @@
exit ;;
*:Darwin:*:*)
UNAME_PROCESSOR=`uname -p` || UNAME_PROCESSOR=unknown
- eval $set_cc_for_build
- if test "$UNAME_PROCESSOR" = unknown ; then
- UNAME_PROCESSOR=powerpc
- fi
- if test `echo "$UNAME_RELEASE" | sed -e 's/\..*//'` -le 10 ; then
- if [ "$CC_FOR_BUILD" != 'no_compiler_found' ]; then
- if (echo '#ifdef __LP64__'; echo IS_64BIT_ARCH; echo '#endif') | \
- (CCOPTS= $CC_FOR_BUILD -E - 2>/dev/null) | \
- grep IS_64BIT_ARCH >/dev/null
- then
- case $UNAME_PROCESSOR in
- i386) UNAME_PROCESSOR=x86_64 ;;
- powerpc) UNAME_PROCESSOR=powerpc64 ;;
- esac
- fi
- fi
- elif test "$UNAME_PROCESSOR" = i386 ; then
- # Avoid executing cc on OS X 10.9, as it ships with a stub
- # that puts up a graphical alert prompting to install
- # developer tools. Any system running Mac OS X 10.7 or
- # later (Darwin 11 and later) is required to have a 64-bit
- # processor. This is not true of the ARM version of Darwin
- # that Apple uses in portable devices.
- UNAME_PROCESSOR=x86_64
- fi
+ case $UNAME_PROCESSOR in
+ i386)
+ eval $set_cc_for_build
+ if [ "$CC_FOR_BUILD" != 'no_compiler_found' ]; then
+ if (echo '#ifdef __LP64__'; echo IS_64BIT_ARCH; echo '#endif') | \
+ (CCOPTS= $CC_FOR_BUILD -E - 2>/dev/null) | \
+ grep IS_64BIT_ARCH >/dev/null
+ then
+ UNAME_PROCESSOR="x86_64"
+ fi
+ fi ;;
+ unknown) UNAME_PROCESSOR=powerpc ;;
+ esac
echo ${UNAME_PROCESSOR}-apple-darwin${UNAME_RELEASE}
exit ;;
*:procnto*:*:* | *:QNX:[0123456789]*:*)
@@ -1389,6 +1337,154 @@
exit ;;
esac
+eval $set_cc_for_build
+cat >$dummy.c <
+# include
+#endif
+main ()
+{
+#if defined (sony)
+#if defined (MIPSEB)
+ /* BFD wants "bsd" instead of "newsos". Perhaps BFD should be changed,
+ I don't know.... */
+ printf ("mips-sony-bsd\n"); exit (0);
+#else
+#include
+ printf ("m68k-sony-newsos%s\n",
+#ifdef NEWSOS4
+ "4"
+#else
+ ""
+#endif
+ ); exit (0);
+#endif
+#endif
+
+#if defined (__arm) && defined (__acorn) && defined (__unix)
+ printf ("arm-acorn-riscix\n"); exit (0);
+#endif
+
+#if defined (hp300) && !defined (hpux)
+ printf ("m68k-hp-bsd\n"); exit (0);
+#endif
+
+#if defined (NeXT)
+#if !defined (__ARCHITECTURE__)
+#define __ARCHITECTURE__ "m68k"
+#endif
+ int version;
+ version=`(hostinfo | sed -n 's/.*NeXT Mach \([0-9]*\).*/\1/p') 2>/dev/null`;
+ if (version < 4)
+ printf ("%s-next-nextstep%d\n", __ARCHITECTURE__, version);
+ else
+ printf ("%s-next-openstep%d\n", __ARCHITECTURE__, version);
+ exit (0);
+#endif
+
+#if defined (MULTIMAX) || defined (n16)
+#if defined (UMAXV)
+ printf ("ns32k-encore-sysv\n"); exit (0);
+#else
+#if defined (CMU)
+ printf ("ns32k-encore-mach\n"); exit (0);
+#else
+ printf ("ns32k-encore-bsd\n"); exit (0);
+#endif
+#endif
+#endif
+
+#if defined (__386BSD__)
+ printf ("i386-pc-bsd\n"); exit (0);
+#endif
+
+#if defined (sequent)
+#if defined (i386)
+ printf ("i386-sequent-dynix\n"); exit (0);
+#endif
+#if defined (ns32000)
+ printf ("ns32k-sequent-dynix\n"); exit (0);
+#endif
+#endif
+
+#if defined (_SEQUENT_)
+ struct utsname un;
+
+ uname(&un);
+
+ if (strncmp(un.version, "V2", 2) == 0) {
+ printf ("i386-sequent-ptx2\n"); exit (0);
+ }
+ if (strncmp(un.version, "V1", 2) == 0) { /* XXX is V1 correct? */
+ printf ("i386-sequent-ptx1\n"); exit (0);
+ }
+ printf ("i386-sequent-ptx\n"); exit (0);
+
+#endif
+
+#if defined (vax)
+# if !defined (ultrix)
+# include
+# if defined (BSD)
+# if BSD == 43
+ printf ("vax-dec-bsd4.3\n"); exit (0);
+# else
+# if BSD == 199006
+ printf ("vax-dec-bsd4.3reno\n"); exit (0);
+# else
+ printf ("vax-dec-bsd\n"); exit (0);
+# endif
+# endif
+# else
+ printf ("vax-dec-bsd\n"); exit (0);
+# endif
+# else
+ printf ("vax-dec-ultrix\n"); exit (0);
+# endif
+#endif
+
+#if defined (alliant) && defined (i860)
+ printf ("i860-alliant-bsd\n"); exit (0);
+#endif
+
+ exit (1);
+}
+EOF
+
+$CC_FOR_BUILD -o $dummy $dummy.c 2>/dev/null && SYSTEM_NAME=`$dummy` &&
+ { echo "$SYSTEM_NAME"; exit; }
+
+# Apollos put the system type in the environment.
+
+test -d /usr/apollo && { echo ${ISP}-apollo-${SYSTYPE}; exit; }
+
+# Convex versions that predate uname can use getsysinfo(1)
+
+if [ -x /usr/convex/getsysinfo ]
+then
+ case `getsysinfo -f cpu_type` in
+ c1*)
+ echo c1-convex-bsd
+ exit ;;
+ c2*)
+ if getsysinfo -f scalar_acc
+ then echo c32-convex-bsd
+ else echo c2-convex-bsd
+ fi
+ exit ;;
+ c34*)
+ echo c34-convex-bsd
+ exit ;;
+ c38*)
+ echo c38-convex-bsd
+ exit ;;
+ c4*)
+ echo c4-convex-bsd
+ exit ;;
+ esac
+fi
+
cat >&2 <.
+# Please send patches with a ChangeLog entry to config-patches@gnu.org.
#
# Configuration subroutine to validate and canonicalize a configuration type.
# Supply the specified configuration type as an argument.
@@ -68,7 +68,7 @@
version="\
GNU config.sub ($timestamp)
-Copyright 1992-2015 Free Software Foundation, Inc.
+Copyright 1992-2013 Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE."
@@ -117,7 +117,7 @@
case $maybe_os in
nto-qnx* | linux-gnu* | linux-android* | linux-dietlibc | linux-newlib* | \
linux-musl* | linux-uclibc* | uclinux-uclibc* | uclinux-gnu* | kfreebsd*-gnu* | \
- knetbsd*-gnu* | netbsd*-gnu* | netbsd*-eabi* | \
+ knetbsd*-gnu* | netbsd*-gnu* | \
kopensolaris*-gnu* | \
storm-chaos* | os2-emx* | rtmk-nova*)
os=-$maybe_os
@@ -252,20 +252,19 @@
| alpha | alphaev[4-8] | alphaev56 | alphaev6[78] | alphapca5[67] \
| alpha64 | alpha64ev[4-8] | alpha64ev56 | alpha64ev6[78] | alpha64pca5[67] \
| am33_2.0 \
- | arc | arceb \
+ | arc \
| arm | arm[bl]e | arme[lb] | armv[2-8] | armv[3-8][lb] | armv7[arm] \
| avr | avr32 \
| be32 | be64 \
| bfin \
- | c4x | c8051 | clipper \
+ | c4x | clipper \
| d10v | d30v | dlx | dsp16xx \
- | e2k | epiphany \
- | fido | fr30 | frv | ft32 \
+ | epiphany \
+ | fido | fr30 | frv \
| h8300 | h8500 | hppa | hppa1.[01] | hppa2.0 | hppa2.0[nw] | hppa64 \
| hexagon \
| i370 | i860 | i960 | ia64 \
| ip2k | iq2000 \
- | k1om \
| le32 | le64 \
| lm32 \
| m32c | m32r | m32rle | m68000 | m68k | m88k \
@@ -283,10 +282,8 @@
| mips64vr5900 | mips64vr5900el \
| mipsisa32 | mipsisa32el \
| mipsisa32r2 | mipsisa32r2el \
- | mipsisa32r6 | mipsisa32r6el \
| mipsisa64 | mipsisa64el \
| mipsisa64r2 | mipsisa64r2el \
- | mipsisa64r6 | mipsisa64r6el \
| mipsisa64sb1 | mipsisa64sb1el \
| mipsisa64sr71k | mipsisa64sr71kel \
| mipsr5900 | mipsr5900el \
@@ -298,11 +295,11 @@
| nds32 | nds32le | nds32be \
| nios | nios2 | nios2eb | nios2el \
| ns16k | ns32k \
- | open8 | or1k | or1knd | or32 \
+ | open8 \
+ | or1k | or32 \
| pdp10 | pdp11 | pj | pjl \
| powerpc | powerpc64 | powerpc64le | powerpcle \
| pyramid \
- | riscv32 | riscv64 \
| rl78 | rx \
| score \
| sh | sh[1234] | sh[24]a | sh[24]aeb | sh[23]e | sh[34]eb | sheb | shbe | shle | sh[1234]le | sh3ele \
@@ -313,7 +310,6 @@
| tahoe | tic4x | tic54x | tic55x | tic6x | tic80 | tron \
| ubicom32 \
| v850 | v850e | v850e1 | v850e2 | v850es | v850e2v3 \
- | visium \
| we32k \
| x86 | xc16x | xstormy16 | xtensa \
| z8k | z80)
@@ -328,10 +324,7 @@
c6x)
basic_machine=tic6x-unknown
;;
- leon|leon[3-9])
- basic_machine=sparc-$basic_machine
- ;;
- m6811 | m68hc11 | m6812 | m68hc12 | m68hcs12x | nvptx | picochip)
+ m6811 | m68hc11 | m6812 | m68hc12 | m68hcs12x | picochip)
basic_machine=$basic_machine-unknown
os=-none
;;
@@ -373,22 +366,21 @@
| aarch64-* | aarch64_be-* \
| alpha-* | alphaev[4-8]-* | alphaev56-* | alphaev6[78]-* \
| alpha64-* | alpha64ev[4-8]-* | alpha64ev56-* | alpha64ev6[78]-* \
- | alphapca5[67]-* | alpha64pca5[67]-* | arc-* | arceb-* \
+ | alphapca5[67]-* | alpha64pca5[67]-* | arc-* \
| arm-* | armbe-* | armle-* | armeb-* | armv*-* \
| avr-* | avr32-* \
| be32-* | be64-* \
| bfin-* | bs2000-* \
| c[123]* | c30-* | [cjt]90-* | c4x-* \
- | c8051-* | clipper-* | craynv-* | cydra-* \
+ | clipper-* | craynv-* | cydra-* \
| d10v-* | d30v-* | dlx-* \
- | e2k-* | elxsi-* \
+ | elxsi-* \
| f30[01]-* | f700-* | fido-* | fr30-* | frv-* | fx80-* \
| h8300-* | h8500-* \
| hppa-* | hppa1.[01]-* | hppa2.0-* | hppa2.0[nw]-* | hppa64-* \
| hexagon-* \
| i*86-* | i860-* | i960-* | ia64-* \
| ip2k-* | iq2000-* \
- | k1om-* \
| le32-* | le64-* \
| lm32-* \
| m32c-* | m32r-* | m32rle-* \
@@ -408,10 +400,8 @@
| mips64vr5900-* | mips64vr5900el-* \
| mipsisa32-* | mipsisa32el-* \
| mipsisa32r2-* | mipsisa32r2el-* \
- | mipsisa32r6-* | mipsisa32r6el-* \
| mipsisa64-* | mipsisa64el-* \
| mipsisa64r2-* | mipsisa64r2el-* \
- | mipsisa64r6-* | mipsisa64r6el-* \
| mipsisa64sb1-* | mipsisa64sb1el-* \
| mipsisa64sr71k-* | mipsisa64sr71kel-* \
| mipsr5900-* | mipsr5900el-* \
@@ -423,7 +413,6 @@
| nios-* | nios2-* | nios2eb-* | nios2el-* \
| none-* | np1-* | ns16k-* | ns32k-* \
| open8-* \
- | or1k*-* \
| orion-* \
| pdp10-* | pdp11-* | pj-* | pjl-* | pn-* | power-* \
| powerpc-* | powerpc64-* | powerpc64le-* | powerpcle-* \
@@ -441,7 +430,6 @@
| ubicom32-* \
| v850-* | v850e-* | v850e1-* | v850es-* | v850e2-* | v850e2v3-* \
| vax-* \
- | visium-* \
| we32k-* \
| x86-* | x86_64-* | xc16x-* | xps100-* \
| xstormy16-* | xtensa*-* \
@@ -518,9 +506,6 @@
basic_machine=i386-pc
os=-aros
;;
- asmjs)
- basic_machine=asmjs-unknown
- ;;
aux)
basic_machine=m68k-apple
os=-aux
@@ -782,9 +767,6 @@
basic_machine=m68k-isi
os=-sysv
;;
- leon-*|leon[3-9]-*)
- basic_machine=sparc-`echo $basic_machine | sed 's/-.*//'`
- ;;
m68knommu)
basic_machine=m68k-unknown
os=-linux
@@ -812,7 +794,7 @@
os=-mingw64
;;
mingw32)
- basic_machine=i686-pc
+ basic_machine=i386-pc
os=-mingw32
;;
mingw32ce)
@@ -840,10 +822,6 @@
basic_machine=powerpc-unknown
os=-morphos
;;
- moxiebox)
- basic_machine=moxie-unknown
- os=-moxiebox
- ;;
msdos)
basic_machine=i386-pc
os=-msdos
@@ -852,7 +830,7 @@
basic_machine=`echo $basic_machine | sed -e 's/ms1-/mt-/'`
;;
msys)
- basic_machine=i686-pc
+ basic_machine=i386-pc
os=-msys
;;
mvs)
@@ -1376,7 +1354,7 @@
| -hpux* | -unos* | -osf* | -luna* | -dgux* | -auroraux* | -solaris* \
| -sym* | -kopensolaris* | -plan9* \
| -amigaos* | -amigados* | -msdos* | -newsos* | -unicos* | -aof* \
- | -aos* | -aros* | -cloudabi* \
+ | -aos* | -aros* \
| -nindy* | -vxsim* | -vxworks* | -ebmon* | -hms* | -mvs* \
| -clix* | -riscos* | -uniplus* | -iris* | -rtu* | -xenix* \
| -hiux* | -386bsd* | -knetbsd* | -mirbsd* | -netbsd* \
@@ -1389,14 +1367,14 @@
| -cygwin* | -msys* | -pe* | -psos* | -moss* | -proelf* | -rtems* \
| -mingw32* | -mingw64* | -linux-gnu* | -linux-android* \
| -linux-newlib* | -linux-musl* | -linux-uclibc* \
- | -uxpv* | -beos* | -mpeix* | -udk* | -moxiebox* \
+ | -uxpv* | -beos* | -mpeix* | -udk* \
| -interix* | -uwin* | -mks* | -rhapsody* | -darwin* | -opened* \
| -openstep* | -oskit* | -conix* | -pw32* | -nonstopux* \
| -storm-chaos* | -tops10* | -tenex* | -tops20* | -its* \
| -os2* | -vos* | -palmos* | -uclinux* | -nucleus* \
| -morphos* | -superux* | -rtmk* | -rtmk-nova* | -windiss* \
| -powermax* | -dnix* | -nx6 | -nx7 | -sei* | -dragonfly* \
- | -skyos* | -haiku* | -rdos* | -toppers* | -drops* | -es* | -tirtos*)
+ | -skyos* | -haiku* | -rdos* | -toppers* | -drops* | -es*)
# Remember, each alternative MUST END IN *, to match a version number.
;;
-qnx*)
@@ -1568,9 +1546,6 @@
c4x-* | tic4x-*)
os=-coff
;;
- c8051-*)
- os=-elf
- ;;
hexagon-*)
os=-elf
;;
@@ -1614,6 +1589,9 @@
mips*-*)
os=-elf
;;
+ or1k-*)
+ os=-elf
+ ;;
or32-*)
os=-coff
;;
@@ -1808,3 +1786,4 @@
# time-stamp-format: "%:y-%02m-%02d"
# time-stamp-end: "'"
# End:
+
diff -Nru erlang-18.2-dfsg/erts/autoconf/configure.vxworks erlang-17.3-dfsg/erts/autoconf/configure.vxworks
--- erlang-18.2-dfsg/erts/autoconf/configure.vxworks 2015-12-15 20:10:35.000000000 +0000
+++ erlang-17.3-dfsg/erts/autoconf/configure.vxworks 2014-09-16 19:10:57.000000000 +0000
@@ -4,17 +4,16 @@
#
# Copyright Ericsson AB 1997-2011. All Rights Reserved.
#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
+# The contents of this file are subject to the Erlang Public License,
+# Version 1.1, (the "License"); you may not use this file except in
+# compliance with the License. You should have received a copy of the
+# Erlang Public License along with this software. If not, it can be
+# retrieved online at http://www.erlang.org/.
+#
+# Software distributed under the License is distributed on an "AS IS"
+# basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See
+# the License for the specific language governing rights and limitations
+# under the License.
#
# %CopyrightEnd%
#
diff -Nru erlang-18.2-dfsg/erts/autoconf/vxworks/sed.general erlang-17.3-dfsg/erts/autoconf/vxworks/sed.general
--- erlang-18.2-dfsg/erts/autoconf/vxworks/sed.general 2015-12-15 20:10:35.000000000 +0000
+++ erlang-17.3-dfsg/erts/autoconf/vxworks/sed.general 2014-09-16 19:10:57.000000000 +0000
@@ -3,17 +3,16 @@
#
# Copyright Ericsson AB 1997-2013. All Rights Reserved.
#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
+# The contents of this file are subject to the Erlang Public License,
+# Version 1.1, (the "License"); you may not use this file except in
+# compliance with the License. You should have received a copy of the
+# Erlang Public License along with this software. If not, it can be
+# retrieved online at http://www.erlang.org/.
+#
+# Software distributed under the License is distributed on an "AS IS"
+# basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See
+# the License for the specific language governing rights and limitations
+# under the License.
#
# %CopyrightEnd%
#
@@ -79,6 +78,8 @@
# HiPE
s|@HIPE_ENABLED@||
+s|@PERFCTR_PATH@||
+s|@USE_PERFCTR@||
# m4
s|@OPSYS@|noopsys|
diff -Nru erlang-18.2-dfsg/erts/autoconf/vxworks/sed.vxworks_cpu32 erlang-17.3-dfsg/erts/autoconf/vxworks/sed.vxworks_cpu32
--- erlang-18.2-dfsg/erts/autoconf/vxworks/sed.vxworks_cpu32 2015-12-15 20:10:35.000000000 +0000
+++ erlang-17.3-dfsg/erts/autoconf/vxworks/sed.vxworks_cpu32 2014-09-16 19:10:57.000000000 +0000
@@ -3,17 +3,16 @@
#
# Copyright Ericsson AB 1997-2010. All Rights Reserved.
#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
+# The contents of this file are subject to the Erlang Public License,
+# Version 1.1, (the "License"); you may not use this file except in
+# compliance with the License. You should have received a copy of the
+# Erlang Public License along with this software. If not, it can be
+# retrieved online at http://www.erlang.org/.
#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
+# Software distributed under the License is distributed on an "AS IS"
+# basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See
+# the License for the specific language governing rights and limitations
+# under the License.
#
# %CopyrightEnd%
#
diff -Nru erlang-18.2-dfsg/erts/autoconf/vxworks/sed.vxworks_ppc32 erlang-17.3-dfsg/erts/autoconf/vxworks/sed.vxworks_ppc32
--- erlang-18.2-dfsg/erts/autoconf/vxworks/sed.vxworks_ppc32 2015-12-15 20:10:35.000000000 +0000
+++ erlang-17.3-dfsg/erts/autoconf/vxworks/sed.vxworks_ppc32 2014-09-16 19:10:57.000000000 +0000
@@ -3,17 +3,16 @@
#
# Copyright Ericsson AB 2006-2013. All Rights Reserved.
#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
+# The contents of this file are subject to the Erlang Public License,
+# Version 1.1, (the "License"); you may not use this file except in
+# compliance with the License. You should have received a copy of the
+# Erlang Public License along with this software. If not, it can be
+# retrieved online at http://www.erlang.org/.
#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
+# Software distributed under the License is distributed on an "AS IS"
+# basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See
+# the License for the specific language governing rights and limitations
+# under the License.
#
# %CopyrightEnd%
#
diff -Nru erlang-18.2-dfsg/erts/autoconf/vxworks/sed.vxworks_ppc603 erlang-17.3-dfsg/erts/autoconf/vxworks/sed.vxworks_ppc603
--- erlang-18.2-dfsg/erts/autoconf/vxworks/sed.vxworks_ppc603 2015-12-15 20:10:35.000000000 +0000
+++ erlang-17.3-dfsg/erts/autoconf/vxworks/sed.vxworks_ppc603 2014-09-16 19:10:57.000000000 +0000
@@ -3,17 +3,16 @@
#
# Copyright Ericsson AB 2000-2010. All Rights Reserved.
#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
+# The contents of this file are subject to the Erlang Public License,
+# Version 1.1, (the "License"); you may not use this file except in
+# compliance with the License. You should have received a copy of the
+# Erlang Public License along with this software. If not, it can be
+# retrieved online at http://www.erlang.org/.
#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
+# Software distributed under the License is distributed on an "AS IS"
+# basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See
+# the License for the specific language governing rights and limitations
+# under the License.
#
# %CopyrightEnd%
#
diff -Nru erlang-18.2-dfsg/erts/autoconf/vxworks/sed.vxworks_ppc603_nolongcall erlang-17.3-dfsg/erts/autoconf/vxworks/sed.vxworks_ppc603_nolongcall
--- erlang-18.2-dfsg/erts/autoconf/vxworks/sed.vxworks_ppc603_nolongcall 2015-12-15 20:10:35.000000000 +0000
+++ erlang-17.3-dfsg/erts/autoconf/vxworks/sed.vxworks_ppc603_nolongcall 2014-09-16 19:10:57.000000000 +0000
@@ -3,17 +3,16 @@
#
# Copyright Ericsson AB 1997-2010. All Rights Reserved.
#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
+# The contents of this file are subject to the Erlang Public License,
+# Version 1.1, (the "License"); you may not use this file except in
+# compliance with the License. You should have received a copy of the
+# Erlang Public License along with this software. If not, it can be
+# retrieved online at http://www.erlang.org/.
#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
+# Software distributed under the License is distributed on an "AS IS"
+# basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See
+# the License for the specific language governing rights and limitations
+# under the License.
#
# %CopyrightEnd%
#
diff -Nru erlang-18.2-dfsg/erts/autoconf/vxworks/sed.vxworks_ppc860 erlang-17.3-dfsg/erts/autoconf/vxworks/sed.vxworks_ppc860
--- erlang-18.2-dfsg/erts/autoconf/vxworks/sed.vxworks_ppc860 2015-12-15 20:10:35.000000000 +0000
+++ erlang-17.3-dfsg/erts/autoconf/vxworks/sed.vxworks_ppc860 2014-09-16 19:10:57.000000000 +0000
@@ -3,17 +3,16 @@
#
# Copyright Ericsson AB 1997-2010. All Rights Reserved.
#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
+# The contents of this file are subject to the Erlang Public License,
+# Version 1.1, (the "License"); you may not use this file except in
+# compliance with the License. You should have received a copy of the
+# Erlang Public License along with this software. If not, it can be
+# retrieved online at http://www.erlang.org/.
#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
+# Software distributed under the License is distributed on an "AS IS"
+# basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See
+# the License for the specific language governing rights and limitations
+# under the License.
#
# %CopyrightEnd%
#
diff -Nru erlang-18.2-dfsg/erts/autoconf/vxworks/sed.vxworks_simlinux erlang-17.3-dfsg/erts/autoconf/vxworks/sed.vxworks_simlinux
--- erlang-18.2-dfsg/erts/autoconf/vxworks/sed.vxworks_simlinux 2015-12-15 20:10:35.000000000 +0000
+++ erlang-17.3-dfsg/erts/autoconf/vxworks/sed.vxworks_simlinux 2014-09-16 19:10:57.000000000 +0000
@@ -3,17 +3,16 @@
#
# Copyright Ericsson AB 2008-2013. All Rights Reserved.
#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
+# The contents of this file are subject to the Erlang Public License,
+# Version 1.1, (the "License"); you may not use this file except in
+# compliance with the License. You should have received a copy of the
+# Erlang Public License along with this software. If not, it can be
+# retrieved online at http://www.erlang.org/.
#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
+# Software distributed under the License is distributed on an "AS IS"
+# basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See
+# the License for the specific language governing rights and limitations
+# under the License.
#
# %CopyrightEnd%
#
diff -Nru erlang-18.2-dfsg/erts/autoconf/vxworks/sed.vxworks_simso erlang-17.3-dfsg/erts/autoconf/vxworks/sed.vxworks_simso
--- erlang-18.2-dfsg/erts/autoconf/vxworks/sed.vxworks_simso 2015-12-15 20:10:35.000000000 +0000
+++ erlang-17.3-dfsg/erts/autoconf/vxworks/sed.vxworks_simso 2014-09-16 19:10:57.000000000 +0000
@@ -3,17 +3,16 @@
#
# Copyright Ericsson AB 2005-2013. All Rights Reserved.
#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
+# The contents of this file are subject to the Erlang Public License,
+# Version 1.1, (the "License"); you may not use this file except in
+# compliance with the License. You should have received a copy of the
+# Erlang Public License along with this software. If not, it can be
+# retrieved online at http://www.erlang.org/.
#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
+# Software distributed under the License is distributed on an "AS IS"
+# basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See
+# the License for the specific language governing rights and limitations
+# under the License.
#
# %CopyrightEnd%
#
diff -Nru erlang-18.2-dfsg/erts/autoconf/vxworks/sed.vxworks_sparc erlang-17.3-dfsg/erts/autoconf/vxworks/sed.vxworks_sparc
--- erlang-18.2-dfsg/erts/autoconf/vxworks/sed.vxworks_sparc 2015-12-15 20:10:35.000000000 +0000
+++ erlang-17.3-dfsg/erts/autoconf/vxworks/sed.vxworks_sparc 2014-09-16 19:10:57.000000000 +0000
@@ -3,17 +3,16 @@
#
# Copyright Ericsson AB 1997-2009. All Rights Reserved.
#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
+# The contents of this file are subject to the Erlang Public License,
+# Version 1.1, (the "License"); you may not use this file except in
+# compliance with the License. You should have received a copy of the
+# Erlang Public License along with this software. If not, it can be
+# retrieved online at http://www.erlang.org/.
+#
+# Software distributed under the License is distributed on an "AS IS"
+# basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See
+# the License for the specific language governing rights and limitations
+# under the License.
#
# %CopyrightEnd%
#
diff -Nru erlang-18.2-dfsg/erts/autoconf/win32.config.cache.static erlang-17.3-dfsg/erts/autoconf/win32.config.cache.static
--- erlang-18.2-dfsg/erts/autoconf/win32.config.cache.static 2015-12-15 20:10:35.000000000 +0000
+++ erlang-17.3-dfsg/erts/autoconf/win32.config.cache.static 2014-09-16 19:10:57.000000000 +0000
@@ -221,6 +221,7 @@
ac_cv_type_uid_t=${ac_cv_type_uid_t=no}
ac_cv_type_void_p=${ac_cv_type_void_p=yes}
ac_cv_working_alloca_h=${ac_cv_working_alloca_h=no}
+erl_cv_time_correction=${erl_cv_time_correction=none}
erts_cv___after_morecore_hook_can_track_malloc=${erts_cv___after_morecore_hook_can_track_malloc=no}
erts_cv_fwrite_unlocked=${erts_cv_fwrite_unlocked=no}
erts_cv_have__end_symbol=${erts_cv_have__end_symbol=no}
diff -Nru erlang-18.2-dfsg/erts/autoconf/win64.config.cache.static erlang-17.3-dfsg/erts/autoconf/win64.config.cache.static
--- erlang-18.2-dfsg/erts/autoconf/win64.config.cache.static 2015-12-15 20:10:35.000000000 +0000
+++ erlang-17.3-dfsg/erts/autoconf/win64.config.cache.static 2014-09-16 19:10:57.000000000 +0000
@@ -262,6 +262,7 @@
ac_cv_type_size_t=${ac_cv_type_size_t=yes}
ac_cv_type_uid_t=${ac_cv_type_uid_t=no}
ac_cv_working_alloca_h=${ac_cv_working_alloca_h=no}
+erl_cv_time_correction=${erl_cv_time_correction=none}
erts_cv___after_morecore_hook_can_track_malloc=${erts_cv___after_morecore_hook_can_track_malloc=no}
erts_cv_fwrite_unlocked=${erts_cv_fwrite_unlocked=no}
erts_cv_have__end_symbol=${erts_cv_have__end_symbol=no}
diff -Nru erlang-18.2-dfsg/erts/config.h.in erlang-17.3-dfsg/erts/config.h.in
--- erlang-18.2-dfsg/erts/config.h.in 2015-12-15 20:10:35.000000000 +0000
+++ erlang-17.3-dfsg/erts/config.h.in 2014-09-16 19:10:57.000000000 +0000
@@ -15,6 +15,10 @@
/* Define the brk() return type. */
#undef BRK_RET_TYPE
+/* Define if you do not have a high-res. timer & want to use times() instead
+ */
+#undef CORRECT_USING_TIMES
+
/* Modern style mcontext_t in MacOSX */
#undef DARWIN_MODERN_MCONTEXT
@@ -59,21 +63,12 @@
/* Define if you have kernel poll and want to use it */
#undef ERTS_ENABLE_KERNEL_POLL
-/* Define if OS monotonic clock is corrected */
-#undef ERTS_HAVE_CORRECTED_OS_MONOTONIC_TIME
-
-/* Define if you have a low resolution OS monotonic clock */
-#undef ERTS_HAVE_LOW_RESOLUTION_OS_MONOTONIC_LOW
-
/* Define if the smp emulator is built */
#undef ERTS_HAVE_SMP_EMU
/* Define if dlopen() needs to be called before first call to dlerror() */
#undef ERTS_NEED_DLOPEN_BEFORE_DLERROR
-/* Save compile time? */
-#undef ERTS_SAVED_COMPILE_TIME
-
/* Define if poll() should be used instead of select() */
#undef ERTS_USE_POLL
@@ -101,48 +96,21 @@
asm statements */
#undef ETHR_GCC_HAVE_SSE2_ASM_SUPPORT
-/* Define if you have a clock_gettime() with a monotonic clock */
-#undef ETHR_HAVE_CLOCK_GETTIME_MONOTONIC
-
/* Define if you have all ethread defines */
#undef ETHR_HAVE_ETHREAD_DEFINES
-/* Define as a boolean indicating whether you have a gcc compatible compiler
- capable of generating the ARM DMB instruction, and are compiling for an ARM
- processor with ARM DMB instruction support, or not */
-#undef ETHR_HAVE_GCC_ASM_ARM_DMB_INSTRUCTION
-
-/* Define as a boolean indicating whether you have a gcc __atomic builtins or
- not */
-#undef ETHR_HAVE_GCC___ATOMIC_BUILTINS
-
-/* Define if you have a monotonic gethrtime() */
-#undef ETHR_HAVE_GETHRTIME
-
/* Define if you have libatomic_ops atomic operations */
#undef ETHR_HAVE_LIBATOMIC_OPS
/* Define if you have a linux futex implementation. */
#undef ETHR_HAVE_LINUX_FUTEX
-/* Define if you have a mach clock_get_time() with a monotonic clock */
-#undef ETHR_HAVE_MACH_CLOCK_GET_TIME
-
/* Define if the pthread.h header file is in pthread/mit directory. */
#undef ETHR_HAVE_MIT_PTHREAD_H
/* Define if you have the pthread_attr_setguardsize function. */
#undef ETHR_HAVE_PTHREAD_ATTR_SETGUARDSIZE
-/* Define if pthread_cond_timedwait() can be used with a monotonic clock */
-#undef ETHR_HAVE_PTHREAD_COND_TIMEDWAIT_MONOTONIC
-
-/* Define if you have ibm style pthread_getname_np */
-#undef ETHR_HAVE_PTHREAD_GETNAME_NP_2
-
-/* Define if you have linux style pthread_getname_np */
-#undef ETHR_HAVE_PTHREAD_GETNAME_NP_3
-
/* Define if you have the header file. */
#undef ETHR_HAVE_PTHREAD_H
@@ -153,15 +121,6 @@
attribute. */
#undef ETHR_HAVE_PTHREAD_RWLOCK_PREFER_WRITER_NONRECURSIVE_NP
-/* Define if you have darwin style pthread_setname_np */
-#undef ETHR_HAVE_PTHREAD_SETNAME_NP_1
-
-/* Define if you have linux style pthread_setname_np */
-#undef ETHR_HAVE_PTHREAD_SETNAME_NP_2
-
-/* Define if you have bsd style pthread_set_name_np */
-#undef ETHR_HAVE_PTHREAD_SET_NAME_NP_2
-
/* Define if you have the pthread_spin_lock function. */
#undef ETHR_HAVE_PTHREAD_SPIN_LOCK
@@ -252,56 +211,36 @@
/* Define if you have _InterlockedOr64() */
#undef ETHR_HAVE__INTERLOCKEDOR64
-/* Define as a bitmask corresponding to the word sizes that
- __atomic_add_fetch() can handle on your system */
-#undef ETHR_HAVE___atomic_add_fetch
-
-/* Define as a bitmask corresponding to the word sizes that
- __atomic_compare_exchange_n() can handle on your system */
-#undef ETHR_HAVE___atomic_compare_exchange_n
-
-/* Define as a bitmask corresponding to the word sizes that
- __atomic_fetch_and() can handle on your system */
-#undef ETHR_HAVE___atomic_fetch_and
-
-/* Define as a bitmask corresponding to the word sizes that
- __atomic_fetch_or() can handle on your system */
-#undef ETHR_HAVE___atomic_fetch_or
-
-/* Define as a bitmask corresponding to the word sizes that __atomic_load_n()
- can handle on your system */
-#undef ETHR_HAVE___atomic_load_n
-
-/* Define as a bitmask corresponding to the word sizes that __atomic_store_n()
- can handle on your system */
-#undef ETHR_HAVE___atomic_store_n
-
-/* Define as a bitmask corresponding to the word sizes that
- __sync_add_and_fetch() can handle on your system */
-#undef ETHR_HAVE___sync_add_and_fetch
-
-/* Define as a bitmask corresponding to the word sizes that
- __sync_fetch_and_and() can handle on your system */
-#undef ETHR_HAVE___sync_fetch_and_and
-
-/* Define as a bitmask corresponding to the word sizes that
- __sync_fetch_and_or() can handle on your system */
-#undef ETHR_HAVE___sync_fetch_and_or
-
-/* Define as a bitmask corresponding to the word sizes that
- __sync_synchronize() can handle on your system */
-#undef ETHR_HAVE___sync_synchronize
-
-/* Define as a bitmask corresponding to the word sizes that
- __sync_val_compare_and_swap() can handle on your system */
-#undef ETHR_HAVE___sync_val_compare_and_swap
+/* Define if you have __sync_add_and_fetch() for 32-bit integers */
+#undef ETHR_HAVE___SYNC_ADD_AND_FETCH32
+
+/* Define if you have __sync_add_and_fetch() for 64-bit integers */
+#undef ETHR_HAVE___SYNC_ADD_AND_FETCH64
+
+/* Define if you have __sync_fetch_and_and() for 32-bit integers */
+#undef ETHR_HAVE___SYNC_FETCH_AND_AND32
+
+/* Define if you have __sync_fetch_and_and() for 64-bit integers */
+#undef ETHR_HAVE___SYNC_FETCH_AND_AND64
+
+/* Define if you have __sync_fetch_and_or() for 32-bit integers */
+#undef ETHR_HAVE___SYNC_FETCH_AND_OR32
+
+/* Define if you have __sync_fetch_and_or() for 64-bit integers */
+#undef ETHR_HAVE___SYNC_FETCH_AND_OR64
+
+/* Define if you have __sync_val_compare_and_swap() for 128-bit integers */
+#undef ETHR_HAVE___SYNC_VAL_COMPARE_AND_SWAP128
+
+/* Define if you have __sync_val_compare_and_swap() for 32-bit integers */
+#undef ETHR_HAVE___SYNC_VAL_COMPARE_AND_SWAP32
+
+/* Define if you have __sync_val_compare_and_swap() for 64-bit integers */
+#undef ETHR_HAVE___SYNC_VAL_COMPARE_AND_SWAP64
/* Define if you want to modify the default stack size */
#undef ETHR_MODIFIED_DEFAULT_STACK_SIZE
-/* Define to the monotonic clock id to use */
-#undef ETHR_MONOTONIC_CLOCK_ID
-
/* Define if you need the header file. */
#undef ETHR_NEED_NPTL_PTHREAD_H
@@ -359,16 +298,15 @@
/* Define if you can safely include both and . */
#undef ETHR_TIME_WITH_SYS_TIME
-/* Define as a boolean indicating whether you trust gcc's __atomic_* builtins
- memory barrier implementations, or not */
-#undef ETHR_TRUST_GCC_ATOMIC_BUILTINS_MEMORY_BARRIERS
-
/* Define if you have win32 threads */
#undef ETHR_WIN32_THREADS
/* Define if x86/x86_64 out of order instructions should be synchronized */
#undef ETHR_X86_OUT_OF_ORDER
+/* Define if you want to use clock_gettime to simulate gethrtime */
+#undef GETHRTIME_WITH_CLOCK_GETTIME
+
/* Define if building a halfword-heap 64bit emulator */
#undef HALFWORD_HEAP_EMULATOR
@@ -378,17 +316,8 @@
/* Define to 1 if you have the `brk' function. */
#undef HAVE_BRK
-/* Define to 1 if you have the `clock_getres' function. */
-#undef HAVE_CLOCK_GETRES
-
/* define if clock_gettime() works for getting process time */
-#undef HAVE_CLOCK_GETTIME_CPU_TIME
-
-/* Define if you have clock_gettime(CLOCK_MONOTONIC_RAW, _) */
-#undef HAVE_CLOCK_GETTIME_MONOTONIC_RAW
-
-/* Define to 1 if you have the `clock_get_attributes' function. */
-#undef HAVE_CLOCK_GET_ATTRIBUTES
+#undef HAVE_CLOCK_GETTIME
/* Define to 1 if you have the `closefrom' function. */
#undef HAVE_CLOSEFROM
@@ -534,10 +463,6 @@
if you don't. */
#undef HAVE_DECL_SCTP_SHUTDOWN_SENT
-/* Define to 1 if you have the declaration of `SCTP_UNCONFIRMED', and to 0 if
- you don't. */
-#undef HAVE_DECL_SCTP_UNCONFIRMED
-
/* Define to 1 if you have the declaration of `SCTP_UNORDERED', and to 0 if
you don't. */
#undef HAVE_DECL_SCTP_UNORDERED
@@ -620,9 +545,6 @@
/* Define to 1 if you have a good `getnameinfo' function. */
#undef HAVE_GETNAMEINFO
-/* Define to 1 if you have the `gettimeofday' function. */
-#undef HAVE_GETTIMEOFDAY
-
/* Define to 1 if you have the `gmtime_r' function. */
#undef HAVE_GMTIME_R
@@ -653,9 +575,6 @@
/* Early linux used in_addr6 instead of in6_addr, define if you have this */
#undef HAVE_IN_ADDR6_STRUCT
-/* Define to 1 if you have the `isfinite' function. */
-#undef HAVE_ISFINITE
-
/* Define to 1 if you have the `isinf' function. */
#undef HAVE_ISINF
@@ -698,9 +617,6 @@
/* Define to 1 if you have the `localtime_r' function. */
#undef HAVE_LOCALTIME_R
-/* Define to 1 if you have the `log2' function. */
-#undef HAVE_LOG2
-
/* Define to 1 if you have the header file. */
#undef HAVE_MALLOC_H
@@ -725,9 +641,6 @@
/* Define to 1 if you have the `mmap' function. */
#undef HAVE_MMAP
-/* Define if you have a monotonic erts_os_hrtime() implementation */
-#undef HAVE_MONOTONIC_ERTS_SYS_HRTIME
-
/* Define to 1 if you have the `mremap' function. */
#undef HAVE_MREMAP
@@ -776,9 +689,6 @@
/* Define to 1 if you have the `posix_memalign' function. */
#undef HAVE_POSIX_MEMALIGN
-/* Define to 1 if you have the `ppoll' function. */
-#undef HAVE_PPOLL
-
/* Define to 1 if you have the `pread' function. */
#undef HAVE_PREAD
@@ -964,9 +874,6 @@
/* Define to 1 if you have the header file. */
#undef HAVE_SYS_SYSCTL_H
-/* Define to 1 if you have the header file. */
-#undef HAVE_SYS_TIMERFD_H
-
/* Define to 1 if you have the header file. */
#undef HAVE_SYS_TIME_H
@@ -1045,21 +952,9 @@
/* Define to enable HiPE */
#undef HIPE
-/* Define to monotonic clock id to use */
-#undef HRTIME_CLOCK_ID
-
-/* Define as a string of monotonic clock id to use */
-#undef HRTIME_CLOCK_ID_STR
-
/* define if h_errno is declared (in some way) in a system header file */
#undef H_ERRNO_DECLARED
-/* Define to monotonic clock id to use */
-#undef MONOTONIC_CLOCK_ID
-
-/* Define as a string of monotonic clock id to use */
-#undef MONOTONIC_CLOCK_ID_STR
-
/* Define if netdb.h needs struct sockaddr_in ans in.h CAN be included before
*/
#undef NETDB_H_NEEDS_IN_H
@@ -1073,33 +968,6 @@
/* Define if you dont have salen */
#undef NO_SA_LEN
-/* Define if you want to implement erts_os_monotonic_time() using
- clock_gettime() */
-#undef OS_MONOTONIC_TIME_USING_CLOCK_GETTIME
-
-/* Define if you want to implement erts_os_monotonic_time() using gethrtime()
- */
-#undef OS_MONOTONIC_TIME_USING_GETHRTIME
-
-/* Define if you want to implement erts_os_monotonic_time() using mach
- clock_get_time() */
-#undef OS_MONOTONIC_TIME_USING_MACH_CLOCK_GET_TIME
-
-/* Define if you want to implement erts_os_monotonic_time() using times() */
-#undef OS_MONOTONIC_TIME_USING_TIMES
-
-/* Define if you want to implement erts_os_system_time() using gettimeofday()
- */
-#undef OS_SYSTEM_TIME_GETTIMEOFDAY
-
-/* Define if you want to implement erts_os_system_time() using clock_gettime()
- */
-#undef OS_SYSTEM_TIME_USING_CLOCK_GETTIME
-
-/* Define if you want to implement erts_os_system_time() using mach
- clock_get_time() */
-#undef OS_SYSTEM_TIME_USING_MACH_CLOCK_GET_TIME
-
/* Define to the address where bug reports for this package should be sent. */
#undef PACKAGE_BUGREPORT
@@ -1170,16 +1038,6 @@
/* define if the variable sys_errlist is declared in a system header file */
#undef SYS_ERRLIST_DECLARED
-/* Define if you want to implement erts_os_hrtime() using clock_gettime() */
-#undef SYS_HRTIME_USING_CLOCK_GETTIME
-
-/* Define if you want to implement erts_os_hrtime() using gethrtime() */
-#undef SYS_HRTIME_USING_GETHRTIME
-
-/* Define if you want to implement erts_os_hrtime() using mach
- clock_get_time() */
-#undef SYS_HRTIME_USING_MACH_CLOCK_GET_TIME
-
/* Define to 1 if you can safely include both and . */
#undef TIME_WITH_SYS_TIME
@@ -1195,6 +1053,9 @@
/* Define if you have matherr() function and struct exception type */
#undef USE_MATHERR
+/* Define to enable hrvtime() on Linux systems with perfctr extension */
+#undef USE_PERFCTR
+
/* Define if select() should be used instead of poll() */
#undef USE_SELECT
@@ -1204,12 +1065,6 @@
/* Define to enable VM dynamic trace probes */
#undef USE_VM_PROBES
-/* Define to wall clock id to use */
-#undef WALL_CLOCK_ID
-
-/* Define as a string of wall clock id to use */
-#undef WALL_CLOCK_ID_STR
-
/* Define if windows.h includes winsock2.h */
#undef WINDOWS_H_INCLUDES_WINSOCK2_H
@@ -1252,7 +1107,7 @@
#define HAVE_GETHRVTIME
#endif
-#if !defined(HAVE_ISFINITE) && !defined(HAVE_FINITE)
+#ifndef HAVE_FINITE
# if defined(HAVE_ISINF) && defined(HAVE_ISNAN)
# define USE_ISINF_ISNAN
# endif
diff -Nru erlang-18.2-dfsg/erts/configure erlang-17.3-dfsg/erts/configure
--- erlang-18.2-dfsg/erts/configure 2015-12-15 20:10:35.000000000 +0000
+++ erlang-17.3-dfsg/erts/configure 2014-09-16 19:10:57.000000000 +0000
@@ -309,7 +309,7 @@
# include
#endif"
-ac_subst_vars='SHELL PATH_SEPARATOR PACKAGE_NAME PACKAGE_TARNAME PACKAGE_VERSION PACKAGE_STRING PACKAGE_BUGREPORT exec_prefix prefix program_transform_name bindir sbindir libexecdir datadir sysconfdir sharedstatedir localstatedir libdir includedir oldincludedir infodir mandir build_alias host_alias target_alias DEFS ECHO_C ECHO_N ECHO_T LIBS ERL_TOP CC CFLAGS STATIC_CFLAGS CFLAG_RUNTIME_LIBRARY_PATH CPP CPPFLAGS CXX CXXFLAGS LD LDFLAGS DED_LD DED_LDFLAGS DED_LD_FLAG_RUNTIME_LIBRARY_PATH LFS_CFLAGS LFS_LDFLAGS LFS_LIBS RANLIB AR GETCONF erl_xcomp_sysroot erl_xcomp_isysroot erl_xcomp_bigendian erl_xcomp_double_middle_endian erl_xcomp_linux_nptl erl_xcomp_linux_usable_sigusrx erl_xcomp_linux_usable_sigaltstack erl_xcomp_poll erl_xcomp_kqueue erl_xcomp_putenv_copy erl_xcomp_reliable_fpe erl_xcomp_getaddrinfo erl_xcomp_gethrvtime_procfs_ioctl erl_xcomp_clock_gettime_cpu_time erl_xcomp_after_morecore_hook erl_xcomp_dlsym_brk_wrappers erl_xcomp_ose_ldflags_pass1 erl_xcomp_ose_ldflags_pass2 erl_xcomp_ose_OSEROOT erl_xcomp_ose_STRIP erl_xcomp_ose_LM_POST_LINK erl_xcomp_ose_LM_SET_CONF erl_xcomp_ose_LM_ELF_SIZE erl_xcomp_ose_LM_LCF erl_xcomp_ose_BEAM_LM_CONF erl_xcomp_ose_EPMD_LM_CONF erl_xcomp_ose_RUN_ERL_LM_CONF erl_xcomp_ose_CONFD erl_xcomp_ose_CRT0_LM build build_cpu build_vendor build_os host host_cpu host_vendor host_os CROSS_COMPILING ac_ct_CC EXEEXT OBJEXT ENABLE_ALLOC_TYPE_VARS USE_VM_PROBES OTP_RELEASE SYSTEM_VSN OTP_VERSION STATIC_NIFS STATIC_DRIVERS GCC MIXED_CYGWIN_VC MIXED_MSYS_VC MIXED_VC MIXED_CYGWIN_MINGW MIXED_CYGWIN MIXED_MSYS ac_pt_GETCONF DEBUG_FLAGS DEBUG_CFLAGS WFLAGS WERRORFLAGS EGREP EXTERNAL_WORD_SIZE OPSYS ARCH LIBCARBON ac_ct_RANLIB YACC PERL LN_S ac_ct_AR RM MKDIR XSLTPROC FOP XMLLINT INSTALL_PROGRAM INSTALL_SCRIPT INSTALL_DATA INSTALL_DIR HCC HCFLAGS vxworks_reclaim LDFLAG_RUNTIME_LIBRARY_PATH ERLANG_OSTYPE DEXPORT ERTS_INTERNAL_X_LIBS ETHR_X_LIBS ETHR_LIBS ETHR_LIB_NAME ETHR_DEFS ETHR_THR_LIB_BASE ETHR_THR_LIB_BASE_DIR ETHR_X86_SSE2_ASM ERTS_BUILD_SMP_EMU EMU_THR_LIB_NAME EMU_THR_X_LIBS EMU_THR_LIBS EMU_THR_DEFS EMU_LOCK_CHECKING THR_LIBS THR_DEFS TERMCAP_LIB Z_LIB SYSTEMD_DAEMON_LIBS LIBSCTP HAVE_VALGRIND BITS64 LIBRT M4 HIPE_HELPERS HIPE_ENABLED NATIVE_LIBS_ENABLED ERTS_ENABLE_KERNEL_POLL ac_ct_DED_LD DED_EXT DED_SYS_INCLUDE DED_CFLAGS DED_STATIC_CFLAGS DED_THR_DEFS DED_EMU_THR_DEFS EMU_CC DTRACE ac_ct_DTRACE DTRACE_CPP DTRACE_ENABLED DTRACE_ENABLED_2STEP SSL_INCLUDE SSL_INCDIR SSL_LIBDIR SSL_CRYPTO_LIBNAME SSL_SSL_LIBNAME SSL_CC_RUNTIME_LIBRARY_PATH SSL_LD_RUNTIME_LIBRARY_PATH SSL_DED_LD_RUNTIME_LIBRARY_PATH SSL_DYNAMIC_ONLY SSL_LINK_WITH_KERBEROS STATIC_KERBEROS_LIBS SSL_LINK_WITH_ZLIB STATIC_ZLIB_LIBS REGTOOL os_mon_programs CPU_SUP_LIBS JAVAC ac_ct_CXX CC32 CFLAGS32 LIBOBJS LTLIBOBJS'
+ac_subst_vars='SHELL PATH_SEPARATOR PACKAGE_NAME PACKAGE_TARNAME PACKAGE_VERSION PACKAGE_STRING PACKAGE_BUGREPORT exec_prefix prefix program_transform_name bindir sbindir libexecdir datadir sysconfdir sharedstatedir localstatedir libdir includedir oldincludedir infodir mandir build_alias host_alias target_alias DEFS ECHO_C ECHO_N ECHO_T LIBS ERL_TOP CC CFLAGS STATIC_CFLAGS CFLAG_RUNTIME_LIBRARY_PATH CPP CPPFLAGS CXX CXXFLAGS LD LDFLAGS DED_LD DED_LDFLAGS DED_LD_FLAG_RUNTIME_LIBRARY_PATH LFS_CFLAGS LFS_LDFLAGS LFS_LIBS RANLIB AR GETCONF erl_xcomp_sysroot erl_xcomp_isysroot erl_xcomp_bigendian erl_xcomp_double_middle_endian erl_xcomp_linux_clock_gettime_correction erl_xcomp_linux_nptl erl_xcomp_linux_usable_sigusrx erl_xcomp_linux_usable_sigaltstack erl_xcomp_poll erl_xcomp_kqueue erl_xcomp_putenv_copy erl_xcomp_reliable_fpe erl_xcomp_getaddrinfo erl_xcomp_gethrvtime_procfs_ioctl erl_xcomp_clock_gettime_cpu_time erl_xcomp_after_morecore_hook erl_xcomp_dlsym_brk_wrappers erl_xcomp_ose_ldflags_pass1 erl_xcomp_ose_ldflags_pass2 erl_xcomp_ose_OSEROOT erl_xcomp_ose_STRIP erl_xcomp_ose_LM_POST_LINK erl_xcomp_ose_LM_SET_CONF erl_xcomp_ose_LM_ELF_SIZE erl_xcomp_ose_LM_LCF erl_xcomp_ose_BEAM_LM_CONF erl_xcomp_ose_EPMD_LM_CONF erl_xcomp_ose_RUN_ERL_LM_CONF erl_xcomp_ose_CONFD erl_xcomp_ose_CRT0_LM build build_cpu build_vendor build_os host host_cpu host_vendor host_os CROSS_COMPILING ac_ct_CC EXEEXT OBJEXT ENABLE_ALLOC_TYPE_VARS PERFCTR_PATH USE_VM_PROBES OTP_RELEASE SYSTEM_VSN OTP_VERSION STATIC_NIFS STATIC_DRIVERS GCC MIXED_CYGWIN_VC MIXED_MSYS_VC MIXED_VC MIXED_CYGWIN_MINGW MIXED_CYGWIN MIXED_MSYS ac_pt_GETCONF DEBUG_FLAGS DEBUG_CFLAGS WFLAGS WERRORFLAGS EGREP EXTERNAL_WORD_SIZE OPSYS ARCH LIBCARBON ac_ct_RANLIB YACC PERL LN_S ac_ct_AR RM MKDIR XSLTPROC FOP XMLLINT INSTALL_PROGRAM INSTALL_SCRIPT INSTALL_DATA INSTALL_DIR HCC HCFLAGS vxworks_reclaim LDFLAG_RUNTIME_LIBRARY_PATH ERLANG_OSTYPE DEXPORT ERTS_INTERNAL_X_LIBS ETHR_X_LIBS ETHR_LIBS ETHR_LIB_NAME ETHR_DEFS ETHR_THR_LIB_BASE ETHR_THR_LIB_BASE_DIR ETHR_X86_SSE2_ASM ERTS_BUILD_SMP_EMU EMU_THR_LIB_NAME EMU_THR_X_LIBS EMU_THR_LIBS EMU_THR_DEFS EMU_LOCK_CHECKING THR_LIBS THR_DEFS TERMCAP_LIB Z_LIB SYSTEMD_DAEMON_LIBS LIBSCTP HAVE_VALGRIND BITS64 LIBRT M4 HIPE_HELPERS HIPE_ENABLED NATIVE_LIBS_ENABLED USE_PERFCTR ERTS_ENABLE_KERNEL_POLL ac_ct_DED_LD DED_EXT DED_SYS_INCLUDE DED_CFLAGS DED_STATIC_CFLAGS DED_THR_DEFS DED_EMU_THR_DEFS EMU_CC DTRACE ac_ct_DTRACE DTRACE_CPP DTRACE_ENABLED DTRACE_ENABLED_2STEP SSL_INCLUDE SSL_ROOT SSL_LIBDIR SSL_CRYPTO_LIBNAME SSL_SSL_LIBNAME SSL_CC_RUNTIME_LIBRARY_PATH SSL_LD_RUNTIME_LIBRARY_PATH SSL_DED_LD_RUNTIME_LIBRARY_PATH SSL_DYNAMIC_ONLY SSL_LINK_WITH_KERBEROS STATIC_KERBEROS_LIBS SSL_LINK_WITH_ZLIB STATIC_ZLIB_LIBS REGTOOL os_mon_programs CPU_SUP_LIBS JAVAC ac_ct_CXX CC32 CFLAGS32 LIBOBJS LTLIBOBJS'
ac_subst_files=''
# Initialize some variables set by options.
@@ -850,6 +850,10 @@
ac_env_erl_xcomp_double_middle_endian_value=$erl_xcomp_double_middle_endian
ac_cv_env_erl_xcomp_double_middle_endian_set=${erl_xcomp_double_middle_endian+set}
ac_cv_env_erl_xcomp_double_middle_endian_value=$erl_xcomp_double_middle_endian
+ac_env_erl_xcomp_linux_clock_gettime_correction_set=${erl_xcomp_linux_clock_gettime_correction+set}
+ac_env_erl_xcomp_linux_clock_gettime_correction_value=$erl_xcomp_linux_clock_gettime_correction
+ac_cv_env_erl_xcomp_linux_clock_gettime_correction_set=${erl_xcomp_linux_clock_gettime_correction+set}
+ac_cv_env_erl_xcomp_linux_clock_gettime_correction_value=$erl_xcomp_linux_clock_gettime_correction
ac_env_erl_xcomp_linux_nptl_set=${erl_xcomp_linux_nptl+set}
ac_env_erl_xcomp_linux_nptl_value=$erl_xcomp_linux_nptl
ac_cv_env_erl_xcomp_linux_nptl_set=${erl_xcomp_linux_nptl+set}
@@ -1057,9 +1061,8 @@
--enable-vm-probes add dynamic trace probes to the Beam VM (only
possible if --with-dynamic-trace is enabled, and
then default)
+ --enable-clock-gettime use clock-gettime for time correction
--enable-systemd enable systemd support in epmd
- --disable-saved-compile-time
- disable saved compile time
--enable-static-nifs link nifs statically. If yes then all nifs in all
Erlang/OTP applications will be statically linked
into the main binary. It is also possible to give a
@@ -1084,17 +1087,7 @@
disabled)
--enable-prefer-gcc-native-ethr-impls
prefer gcc native ethread implementations
- --enable-trust-gcc-atomic-builtins-memory-barriers
- trust gcc atomic builtins memory barriers
--enable-builtin-zlib force use of our own built-in zlib
- --enable-prefer-elapsed-monotonic-time-during-suspend
- Prefer an OS monotonic time source with elapsed time
- during suspend
- --disable-prefer-elapsed-monotonic-time-during-suspend
- Do not prefer an OS monotonic time source with
- elapsed time during suspend
- --enable-gettimeofday-as-os-system-time
- Force usage of gettimeofday() for OS system time
--disable-dynamic-ssl-lib
disable using dynamic openssl libraries
--enable-sanitizers[=comma-separated list of sanitizers]
@@ -1106,6 +1099,8 @@
--with-termcap use termcap (default)
--without-termcap do not use any termcap libraries
(ncurses,curses,termcap,termlib)
+ --with-perfctr=PATH specify location of perfctr include and lib
+ --without-perfctr don't use perfctr (default)
--with-dynamic-trace={dtrace|systemtap}
specify use of dynamic trace framework, dtrace or
systemtap
@@ -1125,28 +1120,12 @@
ethread library
--with-sparc-memory-order=TSO|PSO|RMO
specify sparc memory order (defaults to RMO)
- --with-clock-resolution=high|low|default
- specify wanted clock resolution
- --with-clock-gettime-realtime-id=CLOCKID
- specify clock id to use with clock_gettime() for
- realtime time)
- --with-clock-gettime-monotonic-id=CLOCKID
- specify clock id to use with clock_gettime() for
- monotonic time)
--with-ssl-zlib=PATH specify location of ZLib to be used by OpenSSL
--with-ssl-zlib link SSL with Zlib (default if found)
--without-ssl-zlib don't link SSL with ZLib
--with-ssl=PATH specify location of OpenSSL include and lib
--with-ssl use SSL (default)
--without-ssl don't use SSL
- --with-ssl-incl=PATH location of OpenSSL include dir, if different than
- specified by --with-ssl=PATH
- --with-ssl-rpath=yes|no|PATHS
- runtime library path for OpenSSL. Default is "yes",
- which equates to a number of standard locations. If
- "no", then no runtime library paths wil be used.
- Anything else should be a comma separated list of
- paths.
--with-javac=JAVAC specify Java compiler to use
--with-javac use a Java compiler if found (default)
--without-javac don't use any Java compiler
@@ -1192,6 +1171,9 @@
erl_xcomp_double_middle_endian
double-middle-endian system: yes|no (only used when cross
compiling)
+ erl_xcomp_linux_clock_gettime_correction
+ clock_gettime() can be used for time correction: yes|no (only
+ used when cross compiling)
erl_xcomp_linux_nptl
have Native POSIX Thread Library: yes|no (only used when cross
compiling)
@@ -1762,6 +1744,7 @@
+
if test "x$no_recursion" != "xyes" -a "x$OVERRIDE_CONFIG_CACHE" = "x"; then
# We do not want to use a common cache!
cache_file=/dev/null
@@ -3192,6 +3175,31 @@
fi;
+
+# Check whether --with-perfctr or --without-perfctr was given.
+if test "${with_perfctr+set}" = set; then
+ withval="$with_perfctr"
+
+fi;
+
+if test "x$with_perfctr" = "xno" -o "x$with_perfctr" = "x" ; then
+ PERFCTR_PATH=
+else
+ if test ! -f "$with_perfctr/usr.lib/libperfctr.a" ; then
+ { { echo "$as_me:$LINENO: error: Invalid path to option --with-perfctr=PATH" >&5
+echo "$as_me: error: Invalid path to option --with-perfctr=PATH" >&2;}
+ { (exit 1); exit 1; }; }
+ fi
+ PERFCTR_PATH="$with_perfctr"
+
+cat >>confdefs.h <<\_ACEOF
+#define USE_PERFCTR 1
+_ACEOF
+
+fi
+
+
+
# Check whether --with-dynamic-trace or --without-dynamic-trace was given.
if test "${with_dynamic_trace+set}" = set; then
withval="$with_dynamic_trace"
@@ -3265,6 +3273,18 @@
fi
+# Check whether --enable-clock-gettime or --disable-clock-gettime was given.
+if test "${enable_clock_gettime+set}" = set; then
+ enableval="$enable_clock_gettime"
+ case "$enableval" in
+ no) clock_gettime_correction=no ;;
+ *) clock_gettime_correction=yes ;;
+ esac
+else
+ clock_gettime_correction=unknown
+fi;
+
+
# Check whether --with-assumed-cache-line-size or --without-assumed-cache-line-size was given.
if test "${with_assumed_cache_line_size+set}" = set; then
withval="$with_assumed_cache_line_size"
@@ -3297,23 +3317,6 @@
enable_systemd=no
fi;
-# Check whether --enable-saved-compile-time or --disable-saved-compile-time was given.
-if test "${enable_saved_compile_time+set}" = set; then
- enableval="$enable_saved_compile_time"
- case "$enableval" in
- no) save_compile_time=0 ;;
- *) save_compile_time=1 ;;
- esac
-else
- save_compile_time=1
-fi;
-
-
-cat >>confdefs.h <<_ACEOF
-#define ERTS_SAVED_COMPILE_TIME $save_compile_time
-_ACEOF
-
-
OTP_RELEASE=
if test "${ERLANG_COMMERCIAL_BUILD}" != ""; then
OTP_EXTRA_FLAGS=-DOTP_RELEASE
@@ -4186,20 +4189,20 @@
echo "$as_me:$LINENO: checking for mixed cygwin or msys and native VC++ environment" >&5
echo $ECHO_N "checking for mixed cygwin or msys and native VC++ environment... $ECHO_C" >&6
if test "X$host" = "Xwin32" -a "x$GCC" != "xyes"; then
- if test -x /usr/bin/msys-?.0.dll; then
- CFLAGS="-O2"
- MIXED_MSYS=yes
- echo "$as_me:$LINENO: result: MSYS and VC" >&5
-echo "${ECHO_T}MSYS and VC" >&6
- MIXED_MSYS_VC=yes
- CPPFLAGS="$CPPFLAGS -DERTS_MIXED_MSYS_VC"
- elif test -x /usr/bin/cygpath; then
+ if test -x /usr/bin/cygpath; then
CFLAGS="-O2"
MIXED_CYGWIN=yes
echo "$as_me:$LINENO: result: Cygwin and VC" >&5
echo "${ECHO_T}Cygwin and VC" >&6
MIXED_CYGWIN_VC=yes
CPPFLAGS="$CPPFLAGS -DERTS_MIXED_CYGWIN_VC"
+ elif test -x /usr/bin/msysinfo; then
+ CFLAGS="-O2"
+ MIXED_MSYS=yes
+ echo "$as_me:$LINENO: result: MSYS and VC" >&5
+echo "${ECHO_T}MSYS and VC" >&6
+ MIXED_MSYS_VC=yes
+ CPPFLAGS="$CPPFLAGS -DERTS_MIXED_MSYS_VC"
else
echo "$as_me:$LINENO: result: undeterminable" >&5
echo "${ECHO_T}undeterminable" >&6
@@ -5598,7 +5601,7 @@
case $chk_opsys_ in
win32) OPSYS=win32;;
solaris2.*|SunOS5.*) OPSYS=sol2;;
- linux*|Linux) OPSYS=linux;;
+ linux|Linux) OPSYS=linux;;
darwin|Darwin) OPSYS=darwin;;
freebsd|FreeBSD) OPSYS=freebsd;;
*) OPSYS=noopsys
@@ -5625,7 +5628,6 @@
powerpc) ARCH=ppc;;
ppc) ARCH=ppc;;
ppc64) ARCH=ppc64;;
- ppc64le) ARCH=ppc64;;
"Power Macintosh") ARCH=ppc;;
armv5b) ARCH=arm;;
armv5teb) ARCH=arm;;
@@ -7213,23 +7215,6 @@
_ACEOF
-# Check whether --enable-trust-gcc-atomic-builtins-memory-barriers or --disable-trust-gcc-atomic-builtins-memory-barriers was given.
-if test "${enable_trust_gcc_atomic_builtins_memory_barriers+set}" = set; then
- enableval="$enable_trust_gcc_atomic_builtins_memory_barriers"
- case "$enableval" in
- yes) trust_gcc_atomic_builtins_mbs=1 ;;
- *) trust_gcc_atomic_builtins_mbs=0 ;;
- esac
-else
- trust_gcc_atomic_builtins_mbs=0
-fi;
-
-
-cat >>confdefs.h <<_ACEOF
-#define ETHR_TRUST_GCC_ATOMIC_BUILTINS_MEMORY_BARRIERS $trust_gcc_atomic_builtins_mbs
-_ACEOF
-
-
# Check whether --with-libatomic_ops or --without-libatomic_ops was given.
if test "${with_libatomic_ops+set}" = set; then
@@ -8496,509 +8481,12 @@
-
- if test "no" = "yes"; then
- default_resolution_clock_gettime_monotonic="CLOCK_HIGHRES CLOCK_BOOTTIME CLOCK_MONOTONIC"
- low_resolution_clock_gettime_monotonic="CLOCK_MONOTONIC_COARSE CLOCK_MONOTONIC_FAST"
- high_resolution_clock_gettime_monotonic="CLOCK_MONOTONIC_PRECISE"
- else
- default_resolution_clock_gettime_monotonic="CLOCK_HIGHRES CLOCK_UPTIME CLOCK_MONOTONIC"
- low_resolution_clock_gettime_monotonic="CLOCK_MONOTONIC_COARSE CLOCK_UPTIME_FAST"
- high_resolution_clock_gettime_monotonic="CLOCK_UPTIME_PRECISE"
- fi
-
- case "try_find_pthread_compatible" in
- high_resolution)
- check_msg="high resolution "
- prefer_resolution_clock_gettime_monotonic="$high_resolution_clock_gettime_monotonic"
- ;;
- low_resolution)
- check_msg="low resolution "
- prefer_resolution_clock_gettime_monotonic="$low_resolution_clock_gettime_monotonic"
- ;;
- custom_resolution)
- check_msg="custom resolution "
- prefer_resolution_clock_gettime_monotonic="CLOCK_HIGHRES CLOCK_MONOTONIC"
- ;;
- *)
- check_msg="custom "
- prefer_resolution_clock_gettime_monotonic="CLOCK_HIGHRES CLOCK_MONOTONIC"
- ;;
- esac
-
- echo "$as_me:$LINENO: checking for clock_gettime(CLOCK_MONOTONIC_RAW, _)" >&5
-echo $ECHO_N "checking for clock_gettime(CLOCK_MONOTONIC_RAW, _)... $ECHO_C" >&6
-if test "${erl_cv_clock_gettime_monotonic_raw+set}" = set; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-
- cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h. */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h. */
-
-#include
-
-int
-main ()
-{
-
- struct timespec ts;
- long long result;
- clock_gettime(CLOCK_MONOTONIC_RAW, &ts);
- result = ((long long) ts.tv_sec) * 1000000000LL +
- ((long long) ts.tv_nsec);
-
- ;
- return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
- (eval $ac_compile) 2>conftest.er1
- ac_status=$?
- grep -v '^ *+' conftest.er1 >conftest.err
- rm -f conftest.er1
- cat conftest.err >&5
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -z "$ac_c_werror_flag"
- || test ! -s conftest.err'
- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); }; } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
- erl_cv_clock_gettime_monotonic_raw=yes
-else
- echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-erl_cv_clock_gettime_monotonic_raw=no
-fi
-rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
-
-fi
-echo "$as_me:$LINENO: result: $erl_cv_clock_gettime_monotonic_raw" >&5
-echo "${ECHO_T}$erl_cv_clock_gettime_monotonic_raw" >&6
-
- echo "$as_me:$LINENO: checking for clock_gettime() with ${check_msg}monotonic clock type" >&5
-echo $ECHO_N "checking for clock_gettime() with ${check_msg}monotonic clock type... $ECHO_C" >&6
-if test "${erl_cv_clock_gettime_monotonic_try_find_pthread_compatible+set}" = set; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-
- for clock_type in $prefer_resolution_clock_gettime_monotonic $default_resolution_clock_gettime_monotonic $high_resolution_clock_gettime_monotonic $low_resolution_clock_gettime_monotonic; do
- cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h. */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h. */
-
-#include
-
-int
-main ()
-{
-
- struct timespec ts;
- long long result;
- clock_gettime($clock_type,&ts);
- result = ((long long) ts.tv_sec) * 1000000000LL +
- ((long long) ts.tv_nsec);
-
- ;
- return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
- (eval $ac_compile) 2>conftest.er1
- ac_status=$?
- grep -v '^ *+' conftest.er1 >conftest.err
- rm -f conftest.er1
- cat conftest.err >&5
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -z "$ac_c_werror_flag"
- || test ! -s conftest.err'
- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); }; } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
- erl_cv_clock_gettime_monotonic_try_find_pthread_compatible=$clock_type
-else
- echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-erl_cv_clock_gettime_monotonic_try_find_pthread_compatible=no
-fi
-rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
- test $erl_cv_clock_gettime_monotonic_try_find_pthread_compatible = no || break
- done
-
-fi
-echo "$as_me:$LINENO: result: $erl_cv_clock_gettime_monotonic_try_find_pthread_compatible" >&5
-echo "${ECHO_T}$erl_cv_clock_gettime_monotonic_try_find_pthread_compatible" >&6
-
-
-
-
-for ac_func in clock_getres clock_get_attributes gethrtime
-do
-as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
-echo "$as_me:$LINENO: checking for $ac_func" >&5
-echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
-if eval "test \"\${$as_ac_var+set}\" = set"; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
-else
- cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h. */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h. */
-/* Define $ac_func to an innocuous variant, in case declares $ac_func.
- For example, HP-UX 11i declares gettimeofday. */
-#define $ac_func innocuous_$ac_func
-
-/* System header to define __stub macros and hopefully few prototypes,
- which can conflict with char $ac_func (); below.
- Prefer to if __STDC__ is defined, since
- exists even on freestanding compilers. */
-
-#ifdef __STDC__
-# include
-#else
-# include
-#endif
-
-#undef $ac_func
-
-/* Override any gcc2 internal prototype to avoid an error. */
-#ifdef __cplusplus
-extern "C"
-{
-#endif
-/* We use char because int might match the return type of a gcc2
- builtin and then its argument prototype would still apply. */
-char $ac_func ();
-/* The GNU C library defines this for functions which it implements
- to always fail with ENOSYS. Some functions are actually named
- something starting with __ and the normal name is an alias. */
-#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
-choke me
-#else
-char (*f) () = $ac_func;
-#endif
-#ifdef __cplusplus
-}
-#endif
-
-int
-main ()
-{
-return f != $ac_func;
- ;
- return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
- (eval $ac_link) 2>conftest.er1
- ac_status=$?
- grep -v '^ *+' conftest.er1 >conftest.err
- rm -f conftest.er1
- cat conftest.err >&5
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -z "$ac_c_werror_flag"
- || test ! -s conftest.err'
- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); }; } &&
- { ac_try='test -s conftest$ac_exeext'
- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
- eval "$as_ac_var=yes"
-else
- echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-eval "$as_ac_var=no"
-fi
-rm -f conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-fi
-echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
-echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
-if test `eval echo '${'$as_ac_var'}'` = yes; then
- cat >>confdefs.h <<_ACEOF
-#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
-_ACEOF
-
-fi
-done
-
-
- echo "$as_me:$LINENO: checking for mach clock_get_time() with monotonic clock type" >&5
-echo $ECHO_N "checking for mach clock_get_time() with monotonic clock type... $ECHO_C" >&6
-if test "${erl_cv_mach_clock_get_time_monotonic+set}" = set; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-
- cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h. */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h. */
-
-#include
-#include
-
-int
-main ()
-{
-
- kern_return_t res;
- clock_serv_t clk_srv;
- mach_timespec_t time_spec;
-
- host_get_clock_service(mach_host_self(), SYSTEM_CLOCK, &clk_srv);
- res = clock_get_time(clk_srv, &time_spec);
- mach_port_deallocate(mach_task_self(), clk_srv);
-
- ;
- return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
- (eval $ac_compile) 2>conftest.er1
- ac_status=$?
- grep -v '^ *+' conftest.er1 >conftest.err
- rm -f conftest.er1
- cat conftest.err >&5
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -z "$ac_c_werror_flag"
- || test ! -s conftest.err'
- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); }; } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
- erl_cv_mach_clock_get_time_monotonic=yes
-else
- echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-erl_cv_mach_clock_get_time_monotonic=no
-fi
-rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
-
-fi
-echo "$as_me:$LINENO: result: $erl_cv_mach_clock_get_time_monotonic" >&5
-echo "${ECHO_T}$erl_cv_mach_clock_get_time_monotonic" >&6
-
- erl_corrected_monotonic_clock=no
- case $erl_cv_clock_gettime_monotonic_try_find_pthread_compatible-$ac_cv_func_gethrtime-$erl_cv_mach_clock_get_time_monotonic-$host_os in
- *-*-*-win32)
- erl_monotonic_clock_func=WindowsAPI
- ;;
- CLOCK_*-*-*-linux*)
- case $erl_cv_clock_gettime_monotonic_try_find_pthread_compatible-$erl_cv_clock_gettime_monotonic_raw in
- CLOCK_BOOTTIME-yes|CLOCK_MONOTONIC-yes)
- erl_corrected_monotonic_clock=yes
- ;;
- *)
- # We don't trust CLOCK_MONOTONIC to be NTP
- # adjusted on linux systems that do not have
- # CLOCK_MONOTONIC_RAW (although it seems to
- # be...)
- ;;
- esac
- erl_monotonic_clock_func=clock_gettime
- ;;
- no-no-no-linux*)
- erl_monotonic_clock_func=times
- ;;
- CLOCK_*-*-*-*)
- erl_monotonic_clock_func=clock_gettime
- ;;
- no-yes-*-*)
- erl_monotonic_clock_func=gethrtime
- ;;
- no-no-yes-*)
- erl_monotonic_clock_func=mach_clock_get_time
- ;;
- no-no-no-*)
- erl_monotonic_clock_func=none
- ;;
- esac
-
- erl_monotonic_clock_low_resolution=no
- erl_monotonic_clock_lib=
- erl_monotonic_clock_id=
- case $erl_monotonic_clock_func in
- clock_gettime)
- erl_monotonic_clock_id=$erl_cv_clock_gettime_monotonic_try_find_pthread_compatible
- for low_res_id in $low_resolution_clock_gettime_monotonic; do
- if test $erl_monotonic_clock_id = $low_res_id; then
- erl_monotonic_clock_low_resolution=yes
- break
- fi
- done
- echo "$as_me:$LINENO: checking for clock_gettime in -lrt" >&5
-echo $ECHO_N "checking for clock_gettime in -lrt... $ECHO_C" >&6
-if test "${ac_cv_lib_rt_clock_gettime+set}" = set; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
-else
- ac_check_lib_save_LIBS=$LIBS
-LIBS="-lrt $LIBS"
-cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h. */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h. */
-
-/* Override any gcc2 internal prototype to avoid an error. */
-#ifdef __cplusplus
-extern "C"
-#endif
-/* We use char because int might match the return type of a gcc2
- builtin and then its argument prototype would still apply. */
-char clock_gettime ();
-int
-main ()
-{
-clock_gettime ();
- ;
- return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
- (eval $ac_link) 2>conftest.er1
- ac_status=$?
- grep -v '^ *+' conftest.er1 >conftest.err
- rm -f conftest.er1
- cat conftest.err >&5
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -z "$ac_c_werror_flag"
- || test ! -s conftest.err'
- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); }; } &&
- { ac_try='test -s conftest$ac_exeext'
- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
- ac_cv_lib_rt_clock_gettime=yes
-else
- echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-ac_cv_lib_rt_clock_gettime=no
-fi
-rm -f conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
-fi
-echo "$as_me:$LINENO: result: $ac_cv_lib_rt_clock_gettime" >&5
-echo "${ECHO_T}$ac_cv_lib_rt_clock_gettime" >&6
-if test $ac_cv_lib_rt_clock_gettime = yes; then
- erl_monotonic_clock_lib="-lrt"
-fi
-
- ;;
- mach_clock_get_time)
- erl_monotonic_clock_id=SYSTEM_CLOCK
- ;;
- times)
- erl_monotonic_clock_low_resolution=yes
- ;;
- *)
- ;;
- esac
-
-
-
-case $erl_monotonic_clock_func in
- clock_gettime)
-
-cat >>confdefs.h <<\_ACEOF
-#define ETHR_HAVE_CLOCK_GETTIME_MONOTONIC 1
-_ACEOF
-
- ;;
- mach_clock_get_time)
-
-cat >>confdefs.h <<\_ACEOF
-#define ETHR_HAVE_MACH_CLOCK_GET_TIME 1
-_ACEOF
-
- ;;
- gethrtime)
-
-cat >>confdefs.h <<\_ACEOF
-#define ETHR_HAVE_GETHRTIME 1
-_ACEOF
-
- ;;
- *)
- ;;
-esac
-
-if test "x$erl_monotonic_clock_id" != "x"; then
-
-cat >>confdefs.h <<_ACEOF
-#define ETHR_MONOTONIC_CLOCK_ID $erl_monotonic_clock_id
-_ACEOF
-
-fi
-
-ethr_native_atomic_implementation=none
ethr_have_native_atomics=no
ethr_have_native_spinlock=no
ETHR_THR_LIB_BASE="$THR_LIB_NAME"
ETHR_THR_LIB_BASE_TYPE="$THR_LIB_TYPE"
ETHR_DEFS="$THR_DEFS"
-ETHR_X_LIBS="$THR_LIBS $ERTS_INTERNAL_X_LIBS $erl_monotonic_clock_lib"
+ETHR_X_LIBS="$THR_LIBS $ERTS_INTERNAL_X_LIBS"
ETHR_LIBS=
ETHR_LIB_NAME=
@@ -10907,10 +10395,7 @@
echo "${ECHO_T}$have_interlocked_op" >&6
fi
- if test "$ethr_have_native_atomics" = "yes"; then
- ethr_native_atomic_implementation=windows
- ethr_have_native_spinlock=yes
- fi
+ test "$ethr_have_native_atomics" = "yes" && ethr_have_native_spinlock=yes
;;
pthread|ose_threads)
@@ -12699,98 +12184,6 @@
fi
- if test "x$erl_monotonic_clock_id" != "x"; then
- echo "$as_me:$LINENO: checking whether pthread_cond_timedwait() can use the monotonic clock $erl_monotonic_clock_id for timeout" >&5
-echo $ECHO_N "checking whether pthread_cond_timedwait() can use the monotonic clock $erl_monotonic_clock_id for timeout... $ECHO_C" >&6
- pthread_cond_timedwait_monotonic=no
- cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h. */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h. */
-
- #if defined(ETHR_NEED_NPTL_PTHREAD_H)
- # include
- #elif defined(ETHR_HAVE_MIT_PTHREAD_H)
- # include
- #elif defined(ETHR_HAVE_PTHREAD_H)
- # include
- #endif
- #ifdef ETHR_TIME_WITH_SYS_TIME
- # include
- # include
- #else
- # ifdef ETHR_HAVE_SYS_TIME_H
- # include
- # else
- # include
- # endif
- #endif
- #if defined(ETHR_HAVE_MACH_CLOCK_GET_TIME)
- # include
- # include
- #endif
-
-int
-main ()
-{
-
- int res;
- pthread_condattr_t attr;
- pthread_cond_t cond;
- struct timespec cond_timeout;
- pthread_mutex_t mutex;
- res = pthread_condattr_init(&attr);
- res = pthread_condattr_setclock(&attr, ETHR_MONOTONIC_CLOCK_ID);
- res = pthread_cond_init(&cond, &attr);
- res = pthread_cond_timedwait(&cond, &mutex, &cond_timeout);
-
- ;
- return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
- (eval $ac_link) 2>conftest.er1
- ac_status=$?
- grep -v '^ *+' conftest.er1 >conftest.err
- rm -f conftest.er1
- cat conftest.err >&5
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -z "$ac_c_werror_flag"
- || test ! -s conftest.err'
- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); }; } &&
- { ac_try='test -s conftest$ac_exeext'
- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
- pthread_cond_timedwait_monotonic=yes
-else
- echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-fi
-rm -f conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
- echo "$as_me:$LINENO: result: $pthread_cond_timedwait_monotonic" >&5
-echo "${ECHO_T}$pthread_cond_timedwait_monotonic" >&6
- if test $pthread_cond_timedwait_monotonic = yes; then
-
-cat >>confdefs.h <<\_ACEOF
-#define ETHR_HAVE_PTHREAD_COND_TIMEDWAIT_MONOTONIC 1
-_ACEOF
-
- fi
- fi
-
linux_futex=no
echo "$as_me:$LINENO: checking for Linux futexes" >&5
echo $ECHO_N "checking for Linux futexes... $ECHO_C" >&6
@@ -12859,30 +12252,34 @@
_ACEOF
- pthread_setname=no
- echo "$as_me:$LINENO: checking for pthread_setname_np" >&5
-echo $ECHO_N "checking for pthread_setname_np... $ECHO_C" >&6
- old_CFLAGS=$CFLAGS
- CFLAGS="$CFLAGS -Werror"
- cat >conftest.$ac_ext <<_ACEOF
+ fi
+
+ echo "$as_me:$LINENO: checking for int" >&5
+echo $ECHO_N "checking for int... $ECHO_C" >&6
+if test "${ac_cv_type_int+set}" = set; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+ cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
-#define __USE_GNU
- #include
+$ac_includes_default
int
main ()
{
-pthread_setname_np(pthread_self(), "name");
+if ((int *) 0)
+ return 0;
+if (sizeof (int))
+ return 0;
;
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
- (eval $ac_link) 2>conftest.er1
+rm -f conftest.$ac_objext
+if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
+ (eval $ac_compile) 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
@@ -12896,317 +12293,30 @@
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; } &&
- { ac_try='test -s conftest$ac_exeext'
+ { ac_try='test -s conftest.$ac_objext'
{ (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; }; then
- pthread_setname=linux
+ ac_cv_type_int=yes
else
echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
-fi
-rm -f conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
- cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h. */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h. */
-#define __USE_GNU
- #include
-int
-main ()
-{
-pthread_set_name_np(pthread_self(), "name");
- ;
- return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
- (eval $ac_link) 2>conftest.er1
- ac_status=$?
- grep -v '^ *+' conftest.er1 >conftest.err
- rm -f conftest.er1
- cat conftest.err >&5
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -z "$ac_c_werror_flag"
- || test ! -s conftest.err'
- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); }; } &&
- { ac_try='test -s conftest$ac_exeext'
- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
- pthread_setname=bsd
-else
- echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-fi
-rm -f conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
- cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h. */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h. */
-#define _DARWIN_C_SOURCE
- #include
-int
-main ()
-{
-pthread_setname_np("name");
- ;
- return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
- (eval $ac_link) 2>conftest.er1
- ac_status=$?
- grep -v '^ *+' conftest.er1 >conftest.err
- rm -f conftest.er1
- cat conftest.err >&5
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -z "$ac_c_werror_flag"
- || test ! -s conftest.err'
- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); }; } &&
- { ac_try='test -s conftest$ac_exeext'
- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
- pthread_setname=darwin
-else
- echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-fi
-rm -f conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
- echo "$as_me:$LINENO: result: $pthread_setname" >&5
-echo "${ECHO_T}$pthread_setname" >&6
- case $pthread_setname in
- linux)
-cat >>confdefs.h <<\_ACEOF
-#define ETHR_HAVE_PTHREAD_SETNAME_NP_2 1
-_ACEOF
-;;
- bsd)
-cat >>confdefs.h <<\_ACEOF
-#define ETHR_HAVE_PTHREAD_SET_NAME_NP_2 1
-_ACEOF
-;;
- darwin)
-cat >>confdefs.h <<\_ACEOF
-#define ETHR_HAVE_PTHREAD_SETNAME_NP_1 1
-_ACEOF
-;;
- *) ;;
- esac
-
- pthread_getname=no
- echo "$as_me:$LINENO: checking for pthread_getname_np" >&5
-echo $ECHO_N "checking for pthread_getname_np... $ECHO_C" >&6
- cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h. */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h. */
-#define __USE_GNU
- #define _DARWIN_C_SOURCE
- #include
-int
-main ()
-{
-char buff[256]; pthread_getname_np(pthread_self(), buff, 256);
- ;
- return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
- (eval $ac_link) 2>conftest.er1
- ac_status=$?
- grep -v '^ *+' conftest.er1 >conftest.err
- rm -f conftest.er1
- cat conftest.err >&5
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -z "$ac_c_werror_flag"
- || test ! -s conftest.err'
- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); }; } &&
- { ac_try='test -s conftest$ac_exeext'
- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
- pthread_getname=linux
-else
- echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-fi
-rm -f conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
- cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h. */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h. */
-#define __USE_GNU
- #define _DARWIN_C_SOURCE
- #include
-int
-main ()
-{
-char buff[256]; pthread_getname_np(pthread_self(), buff);
- ;
- return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
- (eval $ac_link) 2>conftest.er1
- ac_status=$?
- grep -v '^ *+' conftest.er1 >conftest.err
- rm -f conftest.er1
- cat conftest.err >&5
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -z "$ac_c_werror_flag"
- || test ! -s conftest.err'
- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); }; } &&
- { ac_try='test -s conftest$ac_exeext'
- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
- pthread_getname=ibm
-else
- echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-fi
-rm -f conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
- echo "$as_me:$LINENO: result: $pthread_getname" >&5
-echo "${ECHO_T}$pthread_getname" >&6
- case $pthread_getname in
- linux)
-cat >>confdefs.h <<\_ACEOF
-#define ETHR_HAVE_PTHREAD_GETNAME_NP_3 1
-_ACEOF
-;;
- ibm)
-cat >>confdefs.h <<\_ACEOF
-#define ETHR_HAVE_PTHREAD_GETNAME_NP_2 1
-_ACEOF
-;;
- *) ;;
- esac
- CFLAGS=$old_CFLAGS
-
- fi ## test "x$THR_LIB_NAME" = "xpthread"
-
- if test "X$disable_native_ethr_impls" = "Xyes"; then
- ethr_have_native_atomics=no
- else
-
-
- echo "$as_me:$LINENO: checking for short" >&5
-echo $ECHO_N "checking for short... $ECHO_C" >&6
-if test "${ac_cv_type_short+set}" = set; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
-else
- cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h. */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h. */
-$ac_includes_default
-int
-main ()
-{
-if ((short *) 0)
- return 0;
-if (sizeof (short))
- return 0;
- ;
- return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
- (eval $ac_compile) 2>conftest.er1
- ac_status=$?
- grep -v '^ *+' conftest.er1 >conftest.err
- rm -f conftest.er1
- cat conftest.err >&5
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -z "$ac_c_werror_flag"
- || test ! -s conftest.err'
- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); }; } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
- ac_cv_type_short=yes
-else
- echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-ac_cv_type_short=no
+ac_cv_type_int=no
fi
rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
fi
-echo "$as_me:$LINENO: result: $ac_cv_type_short" >&5
-echo "${ECHO_T}$ac_cv_type_short" >&6
+echo "$as_me:$LINENO: result: $ac_cv_type_int" >&5
+echo "${ECHO_T}$ac_cv_type_int" >&6
-echo "$as_me:$LINENO: checking size of short" >&5
-echo $ECHO_N "checking size of short... $ECHO_C" >&6
-if test "${ac_cv_sizeof_short+set}" = set; then
+echo "$as_me:$LINENO: checking size of int" >&5
+echo $ECHO_N "checking size of int... $ECHO_C" >&6
+if test "${ac_cv_sizeof_int+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
- if test "$ac_cv_type_short" = yes; then
+ if test "$ac_cv_type_int" = yes; then
# The cast to unsigned long works around a bug in the HP C Compiler
# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
@@ -13223,7 +12333,7 @@
int
main ()
{
-static int test_array [1 - 2 * !(((long) (sizeof (short))) >= 0)];
+static int test_array [1 - 2 * !(((long) (sizeof (int))) >= 0)];
test_array [0] = 0
;
@@ -13264,7 +12374,7 @@
int
main ()
{
-static int test_array [1 - 2 * !(((long) (sizeof (short))) <= $ac_mid)];
+static int test_array [1 - 2 * !(((long) (sizeof (int))) <= $ac_mid)];
test_array [0] = 0
;
@@ -13321,7 +12431,7 @@
int
main ()
{
-static int test_array [1 - 2 * !(((long) (sizeof (short))) < 0)];
+static int test_array [1 - 2 * !(((long) (sizeof (int))) < 0)];
test_array [0] = 0
;
@@ -13362,7 +12472,7 @@
int
main ()
{
-static int test_array [1 - 2 * !(((long) (sizeof (short))) >= $ac_mid)];
+static int test_array [1 - 2 * !(((long) (sizeof (int))) >= $ac_mid)];
test_array [0] = 0
;
@@ -13427,7 +12537,7 @@
int
main ()
{
-static int test_array [1 - 2 * !(((long) (sizeof (short))) <= $ac_mid)];
+static int test_array [1 - 2 * !(((long) (sizeof (int))) <= $ac_mid)];
test_array [0] = 0
;
@@ -13466,10 +12576,10 @@
rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
done
case $ac_lo in
-?*) ac_cv_sizeof_short=$ac_lo;;
-'') { { echo "$as_me:$LINENO: error: cannot compute sizeof (short), 77
+?*) ac_cv_sizeof_int=$ac_lo;;
+'') { { echo "$as_me:$LINENO: error: cannot compute sizeof (int), 77
See \`config.log' for more details." >&5
-echo "$as_me: error: cannot compute sizeof (short), 77
+echo "$as_me: error: cannot compute sizeof (int), 77
See \`config.log' for more details." >&2;}
{ (exit 1); exit 1; }; } ;;
esac
@@ -13488,8 +12598,8 @@
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
$ac_includes_default
-long longval () { return (long) (sizeof (short)); }
-unsigned long ulongval () { return (long) (sizeof (short)); }
+long longval () { return (long) (sizeof (int)); }
+unsigned long ulongval () { return (long) (sizeof (int)); }
#include
#include
int
@@ -13499,17 +12609,17 @@
FILE *f = fopen ("conftest.val", "w");
if (! f)
exit (1);
- if (((long) (sizeof (short))) < 0)
+ if (((long) (sizeof (int))) < 0)
{
long i = longval ();
- if (i != ((long) (sizeof (short))))
+ if (i != ((long) (sizeof (int))))
exit (1);
fprintf (f, "%ld\n", i);
}
else
{
unsigned long i = ulongval ();
- if (i != ((long) (sizeof (short))))
+ if (i != ((long) (sizeof (int))))
exit (1);
fprintf (f, "%lu\n", i);
}
@@ -13530,16 +12640,16 @@
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; }; then
- ac_cv_sizeof_short=`cat conftest.val`
+ ac_cv_sizeof_int=`cat conftest.val`
else
echo "$as_me: program exited with status $ac_status" >&5
echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
( exit $ac_status )
-{ { echo "$as_me:$LINENO: error: cannot compute sizeof (short), 77
+{ { echo "$as_me:$LINENO: error: cannot compute sizeof (int), 77
See \`config.log' for more details." >&5
-echo "$as_me: error: cannot compute sizeof (short), 77
+echo "$as_me: error: cannot compute sizeof (int), 77
See \`config.log' for more details." >&2;}
{ (exit 1); exit 1; }; }
fi
@@ -13548,19 +12658,19 @@
fi
rm -f conftest.val
else
- ac_cv_sizeof_short=0
+ ac_cv_sizeof_int=0
fi
fi
-echo "$as_me:$LINENO: result: $ac_cv_sizeof_short" >&5
-echo "${ECHO_T}$ac_cv_sizeof_short" >&6
+echo "$as_me:$LINENO: result: $ac_cv_sizeof_int" >&5
+echo "${ECHO_T}$ac_cv_sizeof_int" >&6
cat >>confdefs.h <<_ACEOF
-#define SIZEOF_SHORT $ac_cv_sizeof_short
+#define SIZEOF_INT $ac_cv_sizeof_int
_ACEOF
- echo "$as_me:$LINENO: checking for int" >&5
-echo $ECHO_N "checking for int... $ECHO_C" >&6
-if test "${ac_cv_type_int+set}" = set; then
+ echo "$as_me:$LINENO: checking for long" >&5
+echo $ECHO_N "checking for long... $ECHO_C" >&6
+if test "${ac_cv_type_long+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
cat >conftest.$ac_ext <<_ACEOF
@@ -13573,9 +12683,9 @@
int
main ()
{
-if ((int *) 0)
+if ((long *) 0)
return 0;
-if (sizeof (int))
+if (sizeof (long))
return 0;
;
return 0;
@@ -13603,24 +12713,24 @@
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; }; then
- ac_cv_type_int=yes
+ ac_cv_type_long=yes
else
echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
-ac_cv_type_int=no
+ac_cv_type_long=no
fi
rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
fi
-echo "$as_me:$LINENO: result: $ac_cv_type_int" >&5
-echo "${ECHO_T}$ac_cv_type_int" >&6
+echo "$as_me:$LINENO: result: $ac_cv_type_long" >&5
+echo "${ECHO_T}$ac_cv_type_long" >&6
-echo "$as_me:$LINENO: checking size of int" >&5
-echo $ECHO_N "checking size of int... $ECHO_C" >&6
-if test "${ac_cv_sizeof_int+set}" = set; then
+echo "$as_me:$LINENO: checking size of long" >&5
+echo $ECHO_N "checking size of long... $ECHO_C" >&6
+if test "${ac_cv_sizeof_long+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
- if test "$ac_cv_type_int" = yes; then
+ if test "$ac_cv_type_long" = yes; then
# The cast to unsigned long works around a bug in the HP C Compiler
# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
@@ -13637,7 +12747,7 @@
int
main ()
{
-static int test_array [1 - 2 * !(((long) (sizeof (int))) >= 0)];
+static int test_array [1 - 2 * !(((long) (sizeof (long))) >= 0)];
test_array [0] = 0
;
@@ -13678,7 +12788,7 @@
int
main ()
{
-static int test_array [1 - 2 * !(((long) (sizeof (int))) <= $ac_mid)];
+static int test_array [1 - 2 * !(((long) (sizeof (long))) <= $ac_mid)];
test_array [0] = 0
;
@@ -13735,7 +12845,7 @@
int
main ()
{
-static int test_array [1 - 2 * !(((long) (sizeof (int))) < 0)];
+static int test_array [1 - 2 * !(((long) (sizeof (long))) < 0)];
test_array [0] = 0
;
@@ -13776,7 +12886,7 @@
int
main ()
{
-static int test_array [1 - 2 * !(((long) (sizeof (int))) >= $ac_mid)];
+static int test_array [1 - 2 * !(((long) (sizeof (long))) >= $ac_mid)];
test_array [0] = 0
;
@@ -13841,7 +12951,7 @@
int
main ()
{
-static int test_array [1 - 2 * !(((long) (sizeof (int))) <= $ac_mid)];
+static int test_array [1 - 2 * !(((long) (sizeof (long))) <= $ac_mid)];
test_array [0] = 0
;
@@ -13880,10 +12990,10 @@
rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
done
case $ac_lo in
-?*) ac_cv_sizeof_int=$ac_lo;;
-'') { { echo "$as_me:$LINENO: error: cannot compute sizeof (int), 77
+?*) ac_cv_sizeof_long=$ac_lo;;
+'') { { echo "$as_me:$LINENO: error: cannot compute sizeof (long), 77
See \`config.log' for more details." >&5
-echo "$as_me: error: cannot compute sizeof (int), 77
+echo "$as_me: error: cannot compute sizeof (long), 77
See \`config.log' for more details." >&2;}
{ (exit 1); exit 1; }; } ;;
esac
@@ -13902,8 +13012,8 @@
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
$ac_includes_default
-long longval () { return (long) (sizeof (int)); }
-unsigned long ulongval () { return (long) (sizeof (int)); }
+long longval () { return (long) (sizeof (long)); }
+unsigned long ulongval () { return (long) (sizeof (long)); }
#include
#include
int
@@ -13913,17 +13023,17 @@
FILE *f = fopen ("conftest.val", "w");
if (! f)
exit (1);
- if (((long) (sizeof (int))) < 0)
+ if (((long) (sizeof (long))) < 0)
{
long i = longval ();
- if (i != ((long) (sizeof (int))))
+ if (i != ((long) (sizeof (long))))
exit (1);
fprintf (f, "%ld\n", i);
}
else
{
unsigned long i = ulongval ();
- if (i != ((long) (sizeof (int))))
+ if (i != ((long) (sizeof (long))))
exit (1);
fprintf (f, "%lu\n", i);
}
@@ -13944,16 +13054,16 @@
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; }; then
- ac_cv_sizeof_int=`cat conftest.val`
+ ac_cv_sizeof_long=`cat conftest.val`
else
echo "$as_me: program exited with status $ac_status" >&5
echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
( exit $ac_status )
-{ { echo "$as_me:$LINENO: error: cannot compute sizeof (int), 77
+{ { echo "$as_me:$LINENO: error: cannot compute sizeof (long), 77
See \`config.log' for more details." >&5
-echo "$as_me: error: cannot compute sizeof (int), 77
+echo "$as_me: error: cannot compute sizeof (long), 77
See \`config.log' for more details." >&2;}
{ (exit 1); exit 1; }; }
fi
@@ -13962,19 +13072,19 @@
fi
rm -f conftest.val
else
- ac_cv_sizeof_int=0
+ ac_cv_sizeof_long=0
fi
fi
-echo "$as_me:$LINENO: result: $ac_cv_sizeof_int" >&5
-echo "${ECHO_T}$ac_cv_sizeof_int" >&6
+echo "$as_me:$LINENO: result: $ac_cv_sizeof_long" >&5
+echo "${ECHO_T}$ac_cv_sizeof_long" >&6
cat >>confdefs.h <<_ACEOF
-#define SIZEOF_INT $ac_cv_sizeof_int
+#define SIZEOF_LONG $ac_cv_sizeof_long
_ACEOF
- echo "$as_me:$LINENO: checking for long" >&5
-echo $ECHO_N "checking for long... $ECHO_C" >&6
-if test "${ac_cv_type_long+set}" = set; then
+ echo "$as_me:$LINENO: checking for long long" >&5
+echo $ECHO_N "checking for long long... $ECHO_C" >&6
+if test "${ac_cv_type_long_long+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
cat >conftest.$ac_ext <<_ACEOF
@@ -13987,9 +13097,9 @@
int
main ()
{
-if ((long *) 0)
+if ((long long *) 0)
return 0;
-if (sizeof (long))
+if (sizeof (long long))
return 0;
;
return 0;
@@ -14017,24 +13127,24 @@
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; }; then
- ac_cv_type_long=yes
+ ac_cv_type_long_long=yes
else
echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
-ac_cv_type_long=no
+ac_cv_type_long_long=no
fi
rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
fi
-echo "$as_me:$LINENO: result: $ac_cv_type_long" >&5
-echo "${ECHO_T}$ac_cv_type_long" >&6
+echo "$as_me:$LINENO: result: $ac_cv_type_long_long" >&5
+echo "${ECHO_T}$ac_cv_type_long_long" >&6
-echo "$as_me:$LINENO: checking size of long" >&5
-echo $ECHO_N "checking size of long... $ECHO_C" >&6
-if test "${ac_cv_sizeof_long+set}" = set; then
+echo "$as_me:$LINENO: checking size of long long" >&5
+echo $ECHO_N "checking size of long long... $ECHO_C" >&6
+if test "${ac_cv_sizeof_long_long+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
- if test "$ac_cv_type_long" = yes; then
+ if test "$ac_cv_type_long_long" = yes; then
# The cast to unsigned long works around a bug in the HP C Compiler
# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
@@ -14051,7 +13161,7 @@
int
main ()
{
-static int test_array [1 - 2 * !(((long) (sizeof (long))) >= 0)];
+static int test_array [1 - 2 * !(((long) (sizeof (long long))) >= 0)];
test_array [0] = 0
;
@@ -14092,7 +13202,7 @@
int
main ()
{
-static int test_array [1 - 2 * !(((long) (sizeof (long))) <= $ac_mid)];
+static int test_array [1 - 2 * !(((long) (sizeof (long long))) <= $ac_mid)];
test_array [0] = 0
;
@@ -14149,7 +13259,7 @@
int
main ()
{
-static int test_array [1 - 2 * !(((long) (sizeof (long))) < 0)];
+static int test_array [1 - 2 * !(((long) (sizeof (long long))) < 0)];
test_array [0] = 0
;
@@ -14190,7 +13300,7 @@
int
main ()
{
-static int test_array [1 - 2 * !(((long) (sizeof (long))) >= $ac_mid)];
+static int test_array [1 - 2 * !(((long) (sizeof (long long))) >= $ac_mid)];
test_array [0] = 0
;
@@ -14255,7 +13365,7 @@
int
main ()
{
-static int test_array [1 - 2 * !(((long) (sizeof (long))) <= $ac_mid)];
+static int test_array [1 - 2 * !(((long) (sizeof (long long))) <= $ac_mid)];
test_array [0] = 0
;
@@ -14294,10 +13404,10 @@
rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
done
case $ac_lo in
-?*) ac_cv_sizeof_long=$ac_lo;;
-'') { { echo "$as_me:$LINENO: error: cannot compute sizeof (long), 77
+?*) ac_cv_sizeof_long_long=$ac_lo;;
+'') { { echo "$as_me:$LINENO: error: cannot compute sizeof (long long), 77
See \`config.log' for more details." >&5
-echo "$as_me: error: cannot compute sizeof (long), 77
+echo "$as_me: error: cannot compute sizeof (long long), 77
See \`config.log' for more details." >&2;}
{ (exit 1); exit 1; }; } ;;
esac
@@ -14316,8 +13426,8 @@
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
$ac_includes_default
-long longval () { return (long) (sizeof (long)); }
-unsigned long ulongval () { return (long) (sizeof (long)); }
+long longval () { return (long) (sizeof (long long)); }
+unsigned long ulongval () { return (long) (sizeof (long long)); }
#include
#include
int
@@ -14327,17 +13437,17 @@
FILE *f = fopen ("conftest.val", "w");
if (! f)
exit (1);
- if (((long) (sizeof (long))) < 0)
+ if (((long) (sizeof (long long))) < 0)
{
long i = longval ();
- if (i != ((long) (sizeof (long))))
+ if (i != ((long) (sizeof (long long))))
exit (1);
fprintf (f, "%ld\n", i);
}
else
{
unsigned long i = ulongval ();
- if (i != ((long) (sizeof (long))))
+ if (i != ((long) (sizeof (long long))))
exit (1);
fprintf (f, "%lu\n", i);
}
@@ -14358,16 +13468,16 @@
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; }; then
- ac_cv_sizeof_long=`cat conftest.val`
+ ac_cv_sizeof_long_long=`cat conftest.val`
else
echo "$as_me: program exited with status $ac_status" >&5
echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
( exit $ac_status )
-{ { echo "$as_me:$LINENO: error: cannot compute sizeof (long), 77
+{ { echo "$as_me:$LINENO: error: cannot compute sizeof (long long), 77
See \`config.log' for more details." >&5
-echo "$as_me: error: cannot compute sizeof (long), 77
+echo "$as_me: error: cannot compute sizeof (long long), 77
See \`config.log' for more details." >&2;}
{ (exit 1); exit 1; }; }
fi
@@ -14376,19 +13486,19 @@
fi
rm -f conftest.val
else
- ac_cv_sizeof_long=0
+ ac_cv_sizeof_long_long=0
fi
fi
-echo "$as_me:$LINENO: result: $ac_cv_sizeof_long" >&5
-echo "${ECHO_T}$ac_cv_sizeof_long" >&6
+echo "$as_me:$LINENO: result: $ac_cv_sizeof_long_long" >&5
+echo "${ECHO_T}$ac_cv_sizeof_long_long" >&6
cat >>confdefs.h <<_ACEOF
-#define SIZEOF_LONG $ac_cv_sizeof_long
+#define SIZEOF_LONG_LONG $ac_cv_sizeof_long_long
_ACEOF
- echo "$as_me:$LINENO: checking for long long" >&5
-echo $ECHO_N "checking for long long... $ECHO_C" >&6
-if test "${ac_cv_type_long_long+set}" = set; then
+ echo "$as_me:$LINENO: checking for __int128_t" >&5
+echo $ECHO_N "checking for __int128_t... $ECHO_C" >&6
+if test "${ac_cv_type___int128_t+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
cat >conftest.$ac_ext <<_ACEOF
@@ -14401,9 +13511,9 @@
int
main ()
{
-if ((long long *) 0)
+if ((__int128_t *) 0)
return 0;
-if (sizeof (long long))
+if (sizeof (__int128_t))
return 0;
;
return 0;
@@ -14431,24 +13541,24 @@
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; }; then
- ac_cv_type_long_long=yes
+ ac_cv_type___int128_t=yes
else
echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
-ac_cv_type_long_long=no
+ac_cv_type___int128_t=no
fi
rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
fi
-echo "$as_me:$LINENO: result: $ac_cv_type_long_long" >&5
-echo "${ECHO_T}$ac_cv_type_long_long" >&6
+echo "$as_me:$LINENO: result: $ac_cv_type___int128_t" >&5
+echo "${ECHO_T}$ac_cv_type___int128_t" >&6
-echo "$as_me:$LINENO: checking size of long long" >&5
-echo $ECHO_N "checking size of long long... $ECHO_C" >&6
-if test "${ac_cv_sizeof_long_long+set}" = set; then
+echo "$as_me:$LINENO: checking size of __int128_t" >&5
+echo $ECHO_N "checking size of __int128_t... $ECHO_C" >&6
+if test "${ac_cv_sizeof___int128_t+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
- if test "$ac_cv_type_long_long" = yes; then
+ if test "$ac_cv_type___int128_t" = yes; then
# The cast to unsigned long works around a bug in the HP C Compiler
# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
@@ -14465,7 +13575,7 @@
int
main ()
{
-static int test_array [1 - 2 * !(((long) (sizeof (long long))) >= 0)];
+static int test_array [1 - 2 * !(((long) (sizeof (__int128_t))) >= 0)];
test_array [0] = 0
;
@@ -14506,7 +13616,7 @@
int
main ()
{
-static int test_array [1 - 2 * !(((long) (sizeof (long long))) <= $ac_mid)];
+static int test_array [1 - 2 * !(((long) (sizeof (__int128_t))) <= $ac_mid)];
test_array [0] = 0
;
@@ -14563,7 +13673,7 @@
int
main ()
{
-static int test_array [1 - 2 * !(((long) (sizeof (long long))) < 0)];
+static int test_array [1 - 2 * !(((long) (sizeof (__int128_t))) < 0)];
test_array [0] = 0
;
@@ -14604,7 +13714,7 @@
int
main ()
{
-static int test_array [1 - 2 * !(((long) (sizeof (long long))) >= $ac_mid)];
+static int test_array [1 - 2 * !(((long) (sizeof (__int128_t))) >= $ac_mid)];
test_array [0] = 0
;
@@ -14669,7 +13779,7 @@
int
main ()
{
-static int test_array [1 - 2 * !(((long) (sizeof (long long))) <= $ac_mid)];
+static int test_array [1 - 2 * !(((long) (sizeof (__int128_t))) <= $ac_mid)];
test_array [0] = 0
;
@@ -14708,10 +13818,10 @@
rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
done
case $ac_lo in
-?*) ac_cv_sizeof_long_long=$ac_lo;;
-'') { { echo "$as_me:$LINENO: error: cannot compute sizeof (long long), 77
+?*) ac_cv_sizeof___int128_t=$ac_lo;;
+'') { { echo "$as_me:$LINENO: error: cannot compute sizeof (__int128_t), 77
See \`config.log' for more details." >&5
-echo "$as_me: error: cannot compute sizeof (long long), 77
+echo "$as_me: error: cannot compute sizeof (__int128_t), 77
See \`config.log' for more details." >&2;}
{ (exit 1); exit 1; }; } ;;
esac
@@ -14730,8 +13840,8 @@
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
$ac_includes_default
-long longval () { return (long) (sizeof (long long)); }
-unsigned long ulongval () { return (long) (sizeof (long long)); }
+long longval () { return (long) (sizeof (__int128_t)); }
+unsigned long ulongval () { return (long) (sizeof (__int128_t)); }
#include
#include
int
@@ -14741,17 +13851,17 @@
FILE *f = fopen ("conftest.val", "w");
if (! f)
exit (1);
- if (((long) (sizeof (long long))) < 0)
+ if (((long) (sizeof (__int128_t))) < 0)
{
long i = longval ();
- if (i != ((long) (sizeof (long long))))
+ if (i != ((long) (sizeof (__int128_t))))
exit (1);
fprintf (f, "%ld\n", i);
}
else
{
unsigned long i = ulongval ();
- if (i != ((long) (sizeof (long long))))
+ if (i != ((long) (sizeof (__int128_t))))
exit (1);
fprintf (f, "%lu\n", i);
}
@@ -14772,16 +13882,16 @@
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; }; then
- ac_cv_sizeof_long_long=`cat conftest.val`
+ ac_cv_sizeof___int128_t=`cat conftest.val`
else
echo "$as_me: program exited with status $ac_status" >&5
echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
( exit $ac_status )
-{ { echo "$as_me:$LINENO: error: cannot compute sizeof (long long), 77
+{ { echo "$as_me:$LINENO: error: cannot compute sizeof (__int128_t), 77
See \`config.log' for more details." >&5
-echo "$as_me: error: cannot compute sizeof (long long), 77
+echo "$as_me: error: cannot compute sizeof (__int128_t), 77
See \`config.log' for more details." >&2;}
{ (exit 1); exit 1; }; }
fi
@@ -14790,105 +13900,80 @@
fi
rm -f conftest.val
else
- ac_cv_sizeof_long_long=0
+ ac_cv_sizeof___int128_t=0
fi
fi
-echo "$as_me:$LINENO: result: $ac_cv_sizeof_long_long" >&5
-echo "${ECHO_T}$ac_cv_sizeof_long_long" >&6
+echo "$as_me:$LINENO: result: $ac_cv_sizeof___int128_t" >&5
+echo "${ECHO_T}$ac_cv_sizeof___int128_t" >&6
cat >>confdefs.h <<_ACEOF
-#define SIZEOF_LONG_LONG $ac_cv_sizeof_long_long
+#define SIZEOF___INT128_T $ac_cv_sizeof___int128_t
_ACEOF
- echo "$as_me:$LINENO: checking for __int128_t" >&5
-echo $ECHO_N "checking for __int128_t... $ECHO_C" >&6
-if test "${ac_cv_type___int128_t+set}" = set; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
-else
- cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h. */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h. */
-$ac_includes_default
-int
-main ()
-{
-if ((__int128_t *) 0)
- return 0;
-if (sizeof (__int128_t))
- return 0;
- ;
- return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
- (eval $ac_compile) 2>conftest.er1
- ac_status=$?
- grep -v '^ *+' conftest.er1 >conftest.err
- rm -f conftest.er1
- cat conftest.err >&5
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -z "$ac_c_werror_flag"
- || test ! -s conftest.err'
- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); }; } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
- ac_cv_type___int128_t=yes
-else
- echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-ac_cv_type___int128_t=no
-fi
-rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-echo "$as_me:$LINENO: result: $ac_cv_type___int128_t" >&5
-echo "${ECHO_T}$ac_cv_type___int128_t" >&6
+ if test "$ac_cv_sizeof_int" = "4"; then
+ int32="int"
+ elif test "$ac_cv_sizeof_long" = "4"; then
+ int32="long"
+ elif test "$ac_cv_sizeof_long_long" = "4"; then
+ int32="long long"
+ else
+ { { echo "$as_me:$LINENO: error: No 32-bit type found" >&5
+echo "$as_me: error: No 32-bit type found" >&2;}
+ { (exit 1); exit 1; }; }
+ fi
-echo "$as_me:$LINENO: checking size of __int128_t" >&5
-echo $ECHO_N "checking size of __int128_t... $ECHO_C" >&6
-if test "${ac_cv_sizeof___int128_t+set}" = set; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
-else
- if test "$ac_cv_type___int128_t" = yes; then
- # The cast to unsigned long works around a bug in the HP C Compiler
- # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
- # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
- # This bug is HP SR number 8606223364.
- if test "$cross_compiling" = yes; then
- # Depending upon the size, compute the lo and hi bounds.
-cat >conftest.$ac_ext <<_ACEOF
+ if test "$ac_cv_sizeof_int" = "8"; then
+ int64="int"
+ elif test "$ac_cv_sizeof_long" = "8"; then
+ int64="long"
+ elif test "$ac_cv_sizeof_long_long" = "8"; then
+ int64="long long"
+ else
+ { { echo "$as_me:$LINENO: error: No 64-bit type found" >&5
+echo "$as_me: error: No 64-bit type found" >&2;}
+ { (exit 1); exit 1; }; }
+ fi
+
+ int128=no
+ if test "$ac_cv_sizeof___int128_t" = "16"; then
+ int128="__int128_t"
+ fi
+
+ if test "X$disable_native_ethr_impls" = "Xyes"; then
+ ethr_have_native_atomics=no
+ else
+
+ echo "$as_me:$LINENO: checking for 32-bit __sync_val_compare_and_swap()" >&5
+echo $ECHO_N "checking for 32-bit __sync_val_compare_and_swap()... $ECHO_C" >&6
+ case "3" in
+ "1") sync_call="__sync_val_compare_and_swap(&var);";;
+ "2") sync_call="__sync_val_compare_and_swap(&var, ($int32) 0);";;
+ "3") sync_call="__sync_val_compare_and_swap(&var, ($int32) 0, ($int32) 0);";;
+ esac
+ have_sync_op=no
+ cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
-$ac_includes_default
+
int
main ()
{
-static int test_array [1 - 2 * !(((long) (sizeof (__int128_t))) >= 0)];
-test_array [0] = 0
+
+ $int32 res;
+ volatile $int32 var;
+ res = $sync_call
;
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
- (eval $ac_compile) 2>conftest.er1
+rm -f conftest.$ac_objext conftest$ac_exeext
+if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
+ (eval $ac_link) 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
@@ -14902,34 +13987,60 @@
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; } &&
- { ac_try='test -s conftest.$ac_objext'
+ { ac_try='test -s conftest$ac_exeext'
{ (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; }; then
- ac_lo=0 ac_mid=0
- while :; do
+ have_sync_op=yes
+else
+ echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+fi
+rm -f conftest.err conftest.$ac_objext \
+ conftest$ac_exeext conftest.$ac_ext
+ test $have_sync_op = yes &&
+cat >>confdefs.h <<\_ACEOF
+#define ETHR_HAVE___SYNC_VAL_COMPARE_AND_SWAP32 1
+_ACEOF
+
+ echo "$as_me:$LINENO: result: $have_sync_op" >&5
+echo "${ECHO_T}$have_sync_op" >&6
+
+ test "$have_sync_op" = "yes" && ethr_have_native_atomics=yes
+
+ echo "$as_me:$LINENO: checking for 32-bit __sync_add_and_fetch()" >&5
+echo $ECHO_N "checking for 32-bit __sync_add_and_fetch()... $ECHO_C" >&6
+ case "2" in
+ "1") sync_call="__sync_add_and_fetch(&var);";;
+ "2") sync_call="__sync_add_and_fetch(&var, ($int32) 0);";;
+ "3") sync_call="__sync_add_and_fetch(&var, ($int32) 0, ($int32) 0);";;
+ esac
+ have_sync_op=no
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
-$ac_includes_default
+
int
main ()
{
-static int test_array [1 - 2 * !(((long) (sizeof (__int128_t))) <= $ac_mid)];
-test_array [0] = 0
+
+ $int32 res;
+ volatile $int32 var;
+ res = $sync_call
;
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
- (eval $ac_compile) 2>conftest.er1
+rm -f conftest.$ac_objext conftest$ac_exeext
+if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
+ (eval $ac_link) 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
@@ -14943,50 +14054,59 @@
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; } &&
- { ac_try='test -s conftest.$ac_objext'
+ { ac_try='test -s conftest$ac_exeext'
{ (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; }; then
- ac_hi=$ac_mid; break
+ have_sync_op=yes
else
echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
-ac_lo=`expr $ac_mid + 1`
- if test $ac_lo -le $ac_mid; then
- ac_lo= ac_hi=
- break
- fi
- ac_mid=`expr 2 '*' $ac_mid + 1`
fi
-rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
- done
-else
- echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
+rm -f conftest.err conftest.$ac_objext \
+ conftest$ac_exeext conftest.$ac_ext
+ test $have_sync_op = yes &&
+cat >>confdefs.h <<\_ACEOF
+#define ETHR_HAVE___SYNC_ADD_AND_FETCH32 1
+_ACEOF
-cat >conftest.$ac_ext <<_ACEOF
+ echo "$as_me:$LINENO: result: $have_sync_op" >&5
+echo "${ECHO_T}$have_sync_op" >&6
+
+
+ echo "$as_me:$LINENO: checking for 32-bit __sync_fetch_and_and()" >&5
+echo $ECHO_N "checking for 32-bit __sync_fetch_and_and()... $ECHO_C" >&6
+ case "2" in
+ "1") sync_call="__sync_fetch_and_and(&var);";;
+ "2") sync_call="__sync_fetch_and_and(&var, ($int32) 0);";;
+ "3") sync_call="__sync_fetch_and_and(&var, ($int32) 0, ($int32) 0);";;
+ esac
+ have_sync_op=no
+ cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
-$ac_includes_default
+
int
main ()
{
-static int test_array [1 - 2 * !(((long) (sizeof (__int128_t))) < 0)];
-test_array [0] = 0
+
+ $int32 res;
+ volatile $int32 var;
+ res = $sync_call
;
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
- (eval $ac_compile) 2>conftest.er1
+rm -f conftest.$ac_objext conftest$ac_exeext
+if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
+ (eval $ac_link) 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
@@ -15000,34 +14120,59 @@
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; } &&
- { ac_try='test -s conftest.$ac_objext'
+ { ac_try='test -s conftest$ac_exeext'
{ (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; }; then
- ac_hi=-1 ac_mid=-1
- while :; do
+ have_sync_op=yes
+else
+ echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+fi
+rm -f conftest.err conftest.$ac_objext \
+ conftest$ac_exeext conftest.$ac_ext
+ test $have_sync_op = yes &&
+cat >>confdefs.h <<\_ACEOF
+#define ETHR_HAVE___SYNC_FETCH_AND_AND32 1
+_ACEOF
+
+ echo "$as_me:$LINENO: result: $have_sync_op" >&5
+echo "${ECHO_T}$have_sync_op" >&6
+
+
+ echo "$as_me:$LINENO: checking for 32-bit __sync_fetch_and_or()" >&5
+echo $ECHO_N "checking for 32-bit __sync_fetch_and_or()... $ECHO_C" >&6
+ case "2" in
+ "1") sync_call="__sync_fetch_and_or(&var);";;
+ "2") sync_call="__sync_fetch_and_or(&var, ($int32) 0);";;
+ "3") sync_call="__sync_fetch_and_or(&var, ($int32) 0, ($int32) 0);";;
+ esac
+ have_sync_op=no
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
-$ac_includes_default
+
int
main ()
{
-static int test_array [1 - 2 * !(((long) (sizeof (__int128_t))) >= $ac_mid)];
-test_array [0] = 0
+
+ $int32 res;
+ volatile $int32 var;
+ res = $sync_call
;
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
- (eval $ac_compile) 2>conftest.er1
+rm -f conftest.$ac_objext conftest$ac_exeext
+if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
+ (eval $ac_link) 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
@@ -15041,58 +14186,60 @@
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; } &&
- { ac_try='test -s conftest.$ac_objext'
+ { ac_try='test -s conftest$ac_exeext'
{ (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; }; then
- ac_lo=$ac_mid; break
+ have_sync_op=yes
else
echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
-ac_hi=`expr '(' $ac_mid ')' - 1`
- if test $ac_mid -le $ac_hi; then
- ac_lo= ac_hi=
- break
- fi
- ac_mid=`expr 2 '*' $ac_mid`
fi
-rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
- done
-else
- echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
+rm -f conftest.err conftest.$ac_objext \
+ conftest$ac_exeext conftest.$ac_ext
+ test $have_sync_op = yes &&
+cat >>confdefs.h <<\_ACEOF
+#define ETHR_HAVE___SYNC_FETCH_AND_OR32 1
+_ACEOF
-ac_lo= ac_hi=
-fi
-rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
-# Binary search between lo and hi bounds.
-while test "x$ac_lo" != "x$ac_hi"; do
- ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
- cat >conftest.$ac_ext <<_ACEOF
+ echo "$as_me:$LINENO: result: $have_sync_op" >&5
+echo "${ECHO_T}$have_sync_op" >&6
+
+
+
+ echo "$as_me:$LINENO: checking for 64-bit __sync_val_compare_and_swap()" >&5
+echo $ECHO_N "checking for 64-bit __sync_val_compare_and_swap()... $ECHO_C" >&6
+ case "3" in
+ "1") sync_call="__sync_val_compare_and_swap(&var);";;
+ "2") sync_call="__sync_val_compare_and_swap(&var, ($int64) 0);";;
+ "3") sync_call="__sync_val_compare_and_swap(&var, ($int64) 0, ($int64) 0);";;
+ esac
+ have_sync_op=no
+ cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
-$ac_includes_default
+
int
main ()
{
-static int test_array [1 - 2 * !(((long) (sizeof (__int128_t))) <= $ac_mid)];
-test_array [0] = 0
+
+ $int64 res;
+ volatile $int64 var;
+ res = $sync_call
;
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
- (eval $ac_compile) 2>conftest.er1
+rm -f conftest.$ac_objext conftest$ac_exeext
+if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
+ (eval $ac_link) 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
@@ -15106,152 +14253,39 @@
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; } &&
- { ac_try='test -s conftest.$ac_objext'
+ { ac_try='test -s conftest$ac_exeext'
{ (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; }; then
- ac_hi=$ac_mid
+ have_sync_op=yes
else
echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
-ac_lo=`expr '(' $ac_mid ')' + 1`
-fi
-rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
-done
-case $ac_lo in
-?*) ac_cv_sizeof___int128_t=$ac_lo;;
-'') { { echo "$as_me:$LINENO: error: cannot compute sizeof (__int128_t), 77
-See \`config.log' for more details." >&5
-echo "$as_me: error: cannot compute sizeof (__int128_t), 77
-See \`config.log' for more details." >&2;}
- { (exit 1); exit 1; }; } ;;
-esac
-else
- if test "$cross_compiling" = yes; then
- { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling
-See \`config.log' for more details." >&5
-echo "$as_me: error: cannot run test program while cross compiling
-See \`config.log' for more details." >&2;}
- { (exit 1); exit 1; }; }
-else
- cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h. */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h. */
-$ac_includes_default
-long longval () { return (long) (sizeof (__int128_t)); }
-unsigned long ulongval () { return (long) (sizeof (__int128_t)); }
-#include
-#include
-int
-main ()
-{
-
- FILE *f = fopen ("conftest.val", "w");
- if (! f)
- exit (1);
- if (((long) (sizeof (__int128_t))) < 0)
- {
- long i = longval ();
- if (i != ((long) (sizeof (__int128_t))))
- exit (1);
- fprintf (f, "%ld\n", i);
- }
- else
- {
- unsigned long i = ulongval ();
- if (i != ((long) (sizeof (__int128_t))))
- exit (1);
- fprintf (f, "%lu\n", i);
- }
- exit (ferror (f) || fclose (f) != 0);
-
- ;
- return 0;
-}
-_ACEOF
-rm -f conftest$ac_exeext
-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
- (eval $ac_link) 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
- ac_cv_sizeof___int128_t=`cat conftest.val`
-else
- echo "$as_me: program exited with status $ac_status" >&5
-echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-( exit $ac_status )
-{ { echo "$as_me:$LINENO: error: cannot compute sizeof (__int128_t), 77
-See \`config.log' for more details." >&5
-echo "$as_me: error: cannot compute sizeof (__int128_t), 77
-See \`config.log' for more details." >&2;}
- { (exit 1); exit 1; }; }
-fi
-rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
fi
-fi
-rm -f conftest.val
-else
- ac_cv_sizeof___int128_t=0
-fi
-fi
-echo "$as_me:$LINENO: result: $ac_cv_sizeof___int128_t" >&5
-echo "${ECHO_T}$ac_cv_sizeof___int128_t" >&6
-cat >>confdefs.h <<_ACEOF
-#define SIZEOF___INT128_T $ac_cv_sizeof___int128_t
+rm -f conftest.err conftest.$ac_objext \
+ conftest$ac_exeext conftest.$ac_ext
+ test $have_sync_op = yes &&
+cat >>confdefs.h <<\_ACEOF
+#define ETHR_HAVE___SYNC_VAL_COMPARE_AND_SWAP64 1
_ACEOF
+ echo "$as_me:$LINENO: result: $have_sync_op" >&5
+echo "${ECHO_T}$have_sync_op" >&6
+ test "$have_sync_op" = "yes" && ethr_have_native_atomics=yes
- if test "$ac_cv_sizeof_short" = "4"; then
- gcc_atomic_type32="short"
- elif test "$ac_cv_sizeof_int" = "4"; then
- gcc_atomic_type32="int"
- elif test "$ac_cv_sizeof_long" = "4"; then
- gcc_atomic_type32="long"
- else
- { { echo "$as_me:$LINENO: error: No 32-bit type found" >&5
-echo "$as_me: error: No 32-bit type found" >&2;}
- { (exit 1); exit 1; }; }
- fi
-
- if test "$ac_cv_sizeof_int" = "8"; then
- gcc_atomic_type64="int"
- elif test "$ac_cv_sizeof_long" = "8"; then
- gcc_atomic_type64="long"
- elif test "$ac_cv_sizeof_long_long" = "8"; then
- gcc_atomic_type64="long long"
- else
- { { echo "$as_me:$LINENO: error: No 64-bit type found" >&5
-echo "$as_me: error: No 64-bit type found" >&2;}
- { (exit 1); exit 1; }; }
- fi
-
- if test "$ac_cv_sizeof___int128_t" = "16"; then
- gcc_atomic_type128="__int128_t"
- else
- gcc_atomic_type128="#error "
- fi
- echo "$as_me:$LINENO: checking for a working __sync_synchronize()" >&5
-echo $ECHO_N "checking for a working __sync_synchronize()... $ECHO_C" >&6
-if test "${ethr_cv___sync_synchronize+set}" = set; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-
- ethr_cv___sync_synchronize=no
- cat >conftest.$ac_ext <<_ACEOF
+ echo "$as_me:$LINENO: checking for 64-bit __sync_add_and_fetch()" >&5
+echo $ECHO_N "checking for 64-bit __sync_add_and_fetch()... $ECHO_C" >&6
+ case "2" in
+ "1") sync_call="__sync_add_and_fetch(&var);";;
+ "2") sync_call="__sync_add_and_fetch(&var, ($int64) 0);";;
+ "3") sync_call="__sync_add_and_fetch(&var, ($int64) 0, ($int64) 0);";;
+ esac
+ have_sync_op=no
+ cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
@@ -15261,7 +14295,11 @@
int
main ()
{
- __sync_synchronize();
+
+ $int64 res;
+ volatile $int64 var;
+ res = $sync_call
+
;
return 0;
}
@@ -15288,7 +14326,7 @@
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; }; then
- ethr_cv___sync_synchronize=yes
+ have_sync_op=yes
else
echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
@@ -15296,109 +14334,24 @@
fi
rm -f conftest.err conftest.$ac_objext \
conftest$ac_exeext conftest.$ac_ext
- if test $ethr_cv___sync_synchronize = yes; then
- #
- # Old gcc versions on at least x86 have a buggy
- # __sync_synchronize() which does not emit a
- # memory barrier. We try to detect this by
- # compiling to assembly with and without
- # __sync_synchronize() and compare the results.
- #
-
- ethr_test_filename="chk_if___sync_synchronize_noop_config1test.$$"
- cat > "${ethr_test_filename}.c" < "${ethr_test_filename}.c" </dev/null 2>&1; then
- ethr___sync_synchronize_noop=yes
- else
- ethr___sync_synchronize_noop=no
- fi
- rm -f "${ethr_test_filename}.c" "${ethr_test_filename}1.o" "${ethr_test_filename}2.o"
-
- if test $ethr___sync_synchronize_noop = yes; then
- # Got a buggy implementation of
- # __sync_synchronize...
- ethr_cv___sync_synchronize="no; buggy implementation"
- fi
- fi
-
-fi
-echo "$as_me:$LINENO: result: $ethr_cv___sync_synchronize" >&5
-echo "${ECHO_T}$ethr_cv___sync_synchronize" >&6
-
- if test "$ethr_cv___sync_synchronize" = "yes"; then
- have_sync_synchronize_value="~0"
- else
- have_sync_synchronize_value="0"
- fi
-
-cat >>confdefs.h <<_ACEOF
-#define ETHR_HAVE___sync_synchronize $have_sync_synchronize_value
+ test $have_sync_op = yes &&
+cat >>confdefs.h <<\_ACEOF
+#define ETHR_HAVE___SYNC_ADD_AND_FETCH64 1
_ACEOF
+ echo "$as_me:$LINENO: result: $have_sync_op" >&5
+echo "${ECHO_T}$have_sync_op" >&6
- # __sync_add_and_fetch - atomic_op
-
- for atomic_bit_size in 32 64 128; do
- case $atomic_bit_size in
- 32) gcc_atomic_type="$gcc_atomic_type32";;
- 64) gcc_atomic_type="$gcc_atomic_type64";;
- 128) gcc_atomic_type="$gcc_atomic_type128";;
- esac
- gcc_atomic_lockfree="int x[(2*__atomic_always_lock_free(sizeof($gcc_atomic_type), 0))-1]"
- case __sync_add_and_fetch in
- __sync_add_and_fetch | __sync_fetch_and_and | __sync_fetch_and_or)
- atomic_call="volatile $gcc_atomic_type var; $gcc_atomic_type res = __sync_add_and_fetch(&var, ($gcc_atomic_type) 0);"
- ;;
- __sync_val_compare_and_swap)
- atomic_call="volatile $gcc_atomic_type var; $gcc_atomic_type res = __sync_add_and_fetch(&var, ($gcc_atomic_type) 0, ($gcc_atomic_type) 0);"
- ;;
- __atomic_store_n)
- atomic_call="$gcc_atomic_lockfree; volatile $gcc_atomic_type var; __sync_add_and_fetch(&var, ($gcc_atomic_type) 0, __ATOMIC_RELAXED); __sync_add_and_fetch(&var, ($gcc_atomic_type) 0, __ATOMIC_RELEASE);"
- ;;
- __atomic_load_n)
- atomic_call="$gcc_atomic_lockfree; volatile $gcc_atomic_type var; $gcc_atomic_type res = __sync_add_and_fetch(&var, __ATOMIC_RELAXED); res = __sync_add_and_fetch(&var, __ATOMIC_ACQUIRE);"
- ;;
- __atomic_add_fetch| __atomic_fetch_and | __atomic_fetch_or)
- atomic_call="$gcc_atomic_lockfree; volatile $gcc_atomic_type var; $gcc_atomic_type res = __sync_add_and_fetch(&var, ($gcc_atomic_type) 0, __ATOMIC_RELAXED); res = __sync_add_and_fetch(&var, ($gcc_atomic_type) 0, __ATOMIC_ACQUIRE); res = __sync_add_and_fetch(&var, ($gcc_atomic_type) 0, __ATOMIC_RELEASE);"
- ;;
- __atomic_compare_exchange_n)
- atomic_call="$gcc_atomic_lockfree; volatile $gcc_atomic_type var; $gcc_atomic_type val; int res = __sync_add_and_fetch(&var, &val, ($gcc_atomic_type) 0, 0, __ATOMIC_RELAXED, __ATOMIC_RELAXED); res = __sync_add_and_fetch(&var, &val, ($gcc_atomic_type) 0, 0, __ATOMIC_ACQUIRE, __ATOMIC_ACQUIRE);"
- ;;
- *)
- { { echo "$as_me:$LINENO: error: Internal error: missing implementation for __sync_add_and_fetch" >&5
-echo "$as_me: error: Internal error: missing implementation for __sync_add_and_fetch" >&2;}
- { (exit 1); exit 1; }; }
- ;;
- esac
- eval atomic${atomic_bit_size}_call=\"$atomic_call\"
- done
-
- echo "$as_me:$LINENO: checking for 32-bit __sync_add_and_fetch()" >&5
-echo $ECHO_N "checking for 32-bit __sync_add_and_fetch()... $ECHO_C" >&6
-if test "${ethr_cv_32bit___sync_add_and_fetch+set}" = set; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-
- ethr_cv_32bit___sync_add_and_fetch=no
- cat >conftest.$ac_ext <<_ACEOF
+ echo "$as_me:$LINENO: checking for 64-bit __sync_fetch_and_and()" >&5
+echo $ECHO_N "checking for 64-bit __sync_fetch_and_and()... $ECHO_C" >&6
+ case "2" in
+ "1") sync_call="__sync_fetch_and_and(&var);";;
+ "2") sync_call="__sync_fetch_and_and(&var, ($int64) 0);";;
+ "3") sync_call="__sync_fetch_and_and(&var, ($int64) 0, ($int64) 0);";;
+ esac
+ have_sync_op=no
+ cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
@@ -15408,7 +14361,11 @@
int
main ()
{
-$atomic32_call
+
+ $int64 res;
+ volatile $int64 var;
+ res = $sync_call
+
;
return 0;
}
@@ -15435,7 +14392,7 @@
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; }; then
- ethr_cv_32bit___sync_add_and_fetch=yes
+ have_sync_op=yes
else
echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
@@ -15443,18 +14400,24 @@
fi
rm -f conftest.err conftest.$ac_objext \
conftest$ac_exeext conftest.$ac_ext
+ test $have_sync_op = yes &&
+cat >>confdefs.h <<\_ACEOF
+#define ETHR_HAVE___SYNC_FETCH_AND_AND64 1
+_ACEOF
+
+ echo "$as_me:$LINENO: result: $have_sync_op" >&5
+echo "${ECHO_T}$have_sync_op" >&6
-fi
-echo "$as_me:$LINENO: result: $ethr_cv_32bit___sync_add_and_fetch" >&5
-echo "${ECHO_T}$ethr_cv_32bit___sync_add_and_fetch" >&6
- echo "$as_me:$LINENO: checking for 64-bit __sync_add_and_fetch()" >&5
-echo $ECHO_N "checking for 64-bit __sync_add_and_fetch()... $ECHO_C" >&6
-if test "${ethr_cv_64bit___sync_add_and_fetch+set}" = set; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
-else
- ethr_cv_64bit___sync_add_and_fetch=no
- cat >conftest.$ac_ext <<_ACEOF
+ echo "$as_me:$LINENO: checking for 64-bit __sync_fetch_and_or()" >&5
+echo $ECHO_N "checking for 64-bit __sync_fetch_and_or()... $ECHO_C" >&6
+ case "2" in
+ "1") sync_call="__sync_fetch_and_or(&var);";;
+ "2") sync_call="__sync_fetch_and_or(&var, ($int64) 0);";;
+ "3") sync_call="__sync_fetch_and_or(&var, ($int64) 0, ($int64) 0);";;
+ esac
+ have_sync_op=no
+ cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
@@ -15464,7 +14427,11 @@
int
main ()
{
-$atomic64_call
+
+ $int64 res;
+ volatile $int64 var;
+ res = $sync_call
+
;
return 0;
}
@@ -15491,7 +14458,7 @@
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; }; then
- ethr_cv_64bit___sync_add_and_fetch=yes
+ have_sync_op=yes
else
echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
@@ -15499,18 +14466,26 @@
fi
rm -f conftest.err conftest.$ac_objext \
conftest$ac_exeext conftest.$ac_ext
+ test $have_sync_op = yes &&
+cat >>confdefs.h <<\_ACEOF
+#define ETHR_HAVE___SYNC_FETCH_AND_OR64 1
+_ACEOF
-fi
-echo "$as_me:$LINENO: result: $ethr_cv_64bit___sync_add_and_fetch" >&5
-echo "${ECHO_T}$ethr_cv_64bit___sync_add_and_fetch" >&6
- echo "$as_me:$LINENO: checking for 128-bit __sync_add_and_fetch()" >&5
-echo $ECHO_N "checking for 128-bit __sync_add_and_fetch()... $ECHO_C" >&6
-if test "${ethr_cv_128bit___sync_add_and_fetch+set}" = set; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
-else
+ echo "$as_me:$LINENO: result: $have_sync_op" >&5
+echo "${ECHO_T}$have_sync_op" >&6
- ethr_cv_128bit___sync_add_and_fetch=no
- cat >conftest.$ac_ext <<_ACEOF
+
+ if test $int128 != no; then
+
+ echo "$as_me:$LINENO: checking for 128-bit __sync_val_compare_and_swap()" >&5
+echo $ECHO_N "checking for 128-bit __sync_val_compare_and_swap()... $ECHO_C" >&6
+ case "3" in
+ "1") sync_call="__sync_val_compare_and_swap(&var);";;
+ "2") sync_call="__sync_val_compare_and_swap(&var, ($int128) 0);";;
+ "3") sync_call="__sync_val_compare_and_swap(&var, ($int128) 0, ($int128) 0);";;
+ esac
+ have_sync_op=no
+ cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
@@ -15520,7 +14495,11 @@
int
main ()
{
-$atomic128_call
+
+ $int128 res;
+ volatile $int128 var;
+ res = $sync_call
+
;
return 0;
}
@@ -15547,7 +14526,7 @@
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; }; then
- ethr_cv_128bit___sync_add_and_fetch=yes
+ have_sync_op=yes
else
echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
@@ -15555,91 +14534,53 @@
fi
rm -f conftest.err conftest.$ac_objext \
conftest$ac_exeext conftest.$ac_ext
-
-fi
-echo "$as_me:$LINENO: result: $ethr_cv_128bit___sync_add_and_fetch" >&5
-echo "${ECHO_T}$ethr_cv_128bit___sync_add_and_fetch" >&6
-
- case $ethr_cv_128bit___sync_add_and_fetch-$ethr_cv_64bit___sync_add_and_fetch-$ethr_cv_32bit___sync_add_and_fetch in
- no-no-no)
- have_atomic_ops=0;;
- no-no-yes)
- have_atomic_ops=4;;
- no-yes-no)
- have_atomic_ops=8;;
- no-yes-yes)
- have_atomic_ops=12;;
- yes-no-no)
- have_atomic_ops=16;;
- yes-no-yes)
- have_atomic_ops=20;;
- yes-yes-no)
- have_atomic_ops=24;;
- yes-yes-yes)
- have_atomic_ops=28;;
- esac
-
-cat >>confdefs.h <<_ACEOF
-#define ETHR_HAVE___sync_add_and_fetch $have_atomic_ops
+ test $have_sync_op = yes &&
+cat >>confdefs.h <<\_ACEOF
+#define ETHR_HAVE___SYNC_VAL_COMPARE_AND_SWAP128 1
_ACEOF
+ echo "$as_me:$LINENO: result: $have_sync_op" >&5
+echo "${ECHO_T}$have_sync_op" >&6
+ fi
- # __sync_fetch_and_and - atomic_op
-
- for atomic_bit_size in 32 64 128; do
- case $atomic_bit_size in
- 32) gcc_atomic_type="$gcc_atomic_type32";;
- 64) gcc_atomic_type="$gcc_atomic_type64";;
- 128) gcc_atomic_type="$gcc_atomic_type128";;
- esac
- gcc_atomic_lockfree="int x[(2*__atomic_always_lock_free(sizeof($gcc_atomic_type), 0))-1]"
- case __sync_fetch_and_and in
- __sync_add_and_fetch | __sync_fetch_and_and | __sync_fetch_and_or)
- atomic_call="volatile $gcc_atomic_type var; $gcc_atomic_type res = __sync_fetch_and_and(&var, ($gcc_atomic_type) 0);"
- ;;
- __sync_val_compare_and_swap)
- atomic_call="volatile $gcc_atomic_type var; $gcc_atomic_type res = __sync_fetch_and_and(&var, ($gcc_atomic_type) 0, ($gcc_atomic_type) 0);"
- ;;
- __atomic_store_n)
- atomic_call="$gcc_atomic_lockfree; volatile $gcc_atomic_type var; __sync_fetch_and_and(&var, ($gcc_atomic_type) 0, __ATOMIC_RELAXED); __sync_fetch_and_and(&var, ($gcc_atomic_type) 0, __ATOMIC_RELEASE);"
- ;;
- __atomic_load_n)
- atomic_call="$gcc_atomic_lockfree; volatile $gcc_atomic_type var; $gcc_atomic_type res = __sync_fetch_and_and(&var, __ATOMIC_RELAXED); res = __sync_fetch_and_and(&var, __ATOMIC_ACQUIRE);"
- ;;
- __atomic_add_fetch| __atomic_fetch_and | __atomic_fetch_or)
- atomic_call="$gcc_atomic_lockfree; volatile $gcc_atomic_type var; $gcc_atomic_type res = __sync_fetch_and_and(&var, ($gcc_atomic_type) 0, __ATOMIC_RELAXED); res = __sync_fetch_and_and(&var, ($gcc_atomic_type) 0, __ATOMIC_ACQUIRE); res = __sync_fetch_and_and(&var, ($gcc_atomic_type) 0, __ATOMIC_RELEASE);"
- ;;
- __atomic_compare_exchange_n)
- atomic_call="$gcc_atomic_lockfree; volatile $gcc_atomic_type var; $gcc_atomic_type val; int res = __sync_fetch_and_and(&var, &val, ($gcc_atomic_type) 0, 0, __ATOMIC_RELAXED, __ATOMIC_RELAXED); res = __sync_fetch_and_and(&var, &val, ($gcc_atomic_type) 0, 0, __ATOMIC_ACQUIRE, __ATOMIC_ACQUIRE);"
- ;;
- *)
- { { echo "$as_me:$LINENO: error: Internal error: missing implementation for __sync_fetch_and_and" >&5
-echo "$as_me: error: Internal error: missing implementation for __sync_fetch_and_and" >&2;}
+ echo "$as_me:$LINENO: checking for a usable libatomic_ops implementation" >&5
+echo $ECHO_N "checking for a usable libatomic_ops implementation... $ECHO_C" >&6
+ case "x$with_libatomic_ops" in
+ xno | xyes | x)
+ libatomic_ops_include=
+ ;;
+ *)
+ if test -d "${with_libatomic_ops}/include"; then
+ libatomic_ops_include="-I$with_libatomic_ops/include"
+ CPPFLAGS="$CPPFLAGS $libatomic_ops_include"
+ else
+ { { echo "$as_me:$LINENO: error: libatomic_ops include directory $with_libatomic_ops/include not found" >&5
+echo "$as_me: error: libatomic_ops include directory $with_libatomic_ops/include not found" >&2;}
{ (exit 1); exit 1; }; }
- ;;
- esac
- eval atomic${atomic_bit_size}_call=\"$atomic_call\"
- done
-
- echo "$as_me:$LINENO: checking for 32-bit __sync_fetch_and_and()" >&5
-echo $ECHO_N "checking for 32-bit __sync_fetch_and_and()... $ECHO_C" >&6
-if test "${ethr_cv_32bit___sync_fetch_and_and+set}" = set; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-
- ethr_cv_32bit___sync_fetch_and_and=no
- cat >conftest.$ac_ext <<_ACEOF
+ fi;;
+ esac
+ ethr_have_libatomic_ops=no
+ cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
-
+#include "atomic_ops.h"
int
main ()
{
-$atomic32_call
+
+ volatile AO_t x;
+ AO_t y;
+ int z;
+
+ AO_nop_full();
+ AO_store(&x, (AO_t) 0);
+ z = AO_load(&x);
+ z = AO_compare_and_swap_full(&x, (AO_t) 0, (AO_t) 1);
+
;
return 0;
}
@@ -15666,7 +14607,8 @@
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; }; then
- ethr_cv_32bit___sync_fetch_and_and=yes
+ ethr_have_native_atomics=yes
+ ethr_have_libatomic_ops=yes
else
echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
@@ -15674,35 +14616,39 @@
fi
rm -f conftest.err conftest.$ac_objext \
conftest$ac_exeext conftest.$ac_ext
-
-fi
-echo "$as_me:$LINENO: result: $ethr_cv_32bit___sync_fetch_and_and" >&5
-echo "${ECHO_T}$ethr_cv_32bit___sync_fetch_and_and" >&6
- echo "$as_me:$LINENO: checking for 64-bit __sync_fetch_and_and()" >&5
-echo $ECHO_N "checking for 64-bit __sync_fetch_and_and()... $ECHO_C" >&6
-if test "${ethr_cv_64bit___sync_fetch_and_and+set}" = set; then
+ echo "$as_me:$LINENO: result: $ethr_have_libatomic_ops" >&5
+echo "${ECHO_T}$ethr_have_libatomic_ops" >&6
+ if test $ethr_have_libatomic_ops = yes; then
+ echo "$as_me:$LINENO: checking for AO_t" >&5
+echo $ECHO_N "checking for AO_t... $ECHO_C" >&6
+if test "${ac_cv_type_AO_t+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
-
- ethr_cv_64bit___sync_fetch_and_and=no
- cat >conftest.$ac_ext <<_ACEOF
+ cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
+ #include
+ #include "atomic_ops.h"
+
+
int
main ()
{
-$atomic64_call
+if ((AO_t *) 0)
+ return 0;
+if (sizeof (AO_t))
+ return 0;
;
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
- (eval $ac_link) 2>conftest.er1
+rm -f conftest.$ac_objext
+if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
+ (eval $ac_compile) 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
@@ -15716,49 +14662,60 @@
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; } &&
- { ac_try='test -s conftest$ac_exeext'
+ { ac_try='test -s conftest.$ac_objext'
{ (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; }; then
- ethr_cv_64bit___sync_fetch_and_and=yes
+ ac_cv_type_AO_t=yes
else
echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
+ac_cv_type_AO_t=no
fi
-rm -f conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-
+rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
fi
-echo "$as_me:$LINENO: result: $ethr_cv_64bit___sync_fetch_and_and" >&5
-echo "${ECHO_T}$ethr_cv_64bit___sync_fetch_and_and" >&6
- echo "$as_me:$LINENO: checking for 128-bit __sync_fetch_and_and()" >&5
-echo $ECHO_N "checking for 128-bit __sync_fetch_and_and()... $ECHO_C" >&6
-if test "${ethr_cv_128bit___sync_fetch_and_and+set}" = set; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
-else
+echo "$as_me:$LINENO: result: $ac_cv_type_AO_t" >&5
+echo "${ECHO_T}$ac_cv_type_AO_t" >&6
- ethr_cv_128bit___sync_fetch_and_and=no
- cat >conftest.$ac_ext <<_ACEOF
+echo "$as_me:$LINENO: checking size of AO_t" >&5
+echo $ECHO_N "checking size of AO_t... $ECHO_C" >&6
+if test "${ac_cv_sizeof_AO_t+set}" = set; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+ if test "$ac_cv_type_AO_t" = yes; then
+ # The cast to unsigned long works around a bug in the HP C Compiler
+ # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
+ # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
+ # This bug is HP SR number 8606223364.
+ if test "$cross_compiling" = yes; then
+ # Depending upon the size, compute the lo and hi bounds.
+cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
+ #include
+ #include "atomic_ops.h"
+
+
int
main ()
{
-$atomic128_call
+static int test_array [1 - 2 * !(((long) (sizeof (AO_t))) >= 0)];
+test_array [0] = 0
+
;
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
- (eval $ac_link) 2>conftest.er1
+rm -f conftest.$ac_objext
+if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
+ (eval $ac_compile) 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
@@ -15772,112 +14729,38 @@
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; } &&
- { ac_try='test -s conftest$ac_exeext'
+ { ac_try='test -s conftest.$ac_objext'
{ (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; }; then
- ethr_cv_128bit___sync_fetch_and_and=yes
-else
- echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-fi
-rm -f conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-
-fi
-echo "$as_me:$LINENO: result: $ethr_cv_128bit___sync_fetch_and_and" >&5
-echo "${ECHO_T}$ethr_cv_128bit___sync_fetch_and_and" >&6
-
- case $ethr_cv_128bit___sync_fetch_and_and-$ethr_cv_64bit___sync_fetch_and_and-$ethr_cv_32bit___sync_fetch_and_and in
- no-no-no)
- have_atomic_ops=0;;
- no-no-yes)
- have_atomic_ops=4;;
- no-yes-no)
- have_atomic_ops=8;;
- no-yes-yes)
- have_atomic_ops=12;;
- yes-no-no)
- have_atomic_ops=16;;
- yes-no-yes)
- have_atomic_ops=20;;
- yes-yes-no)
- have_atomic_ops=24;;
- yes-yes-yes)
- have_atomic_ops=28;;
- esac
-
-cat >>confdefs.h <<_ACEOF
-#define ETHR_HAVE___sync_fetch_and_and $have_atomic_ops
-_ACEOF
-
-
-
- # __sync_fetch_and_or - atomic_op
-
- for atomic_bit_size in 32 64 128; do
- case $atomic_bit_size in
- 32) gcc_atomic_type="$gcc_atomic_type32";;
- 64) gcc_atomic_type="$gcc_atomic_type64";;
- 128) gcc_atomic_type="$gcc_atomic_type128";;
- esac
- gcc_atomic_lockfree="int x[(2*__atomic_always_lock_free(sizeof($gcc_atomic_type), 0))-1]"
- case __sync_fetch_and_or in
- __sync_add_and_fetch | __sync_fetch_and_and | __sync_fetch_and_or)
- atomic_call="volatile $gcc_atomic_type var; $gcc_atomic_type res = __sync_fetch_and_or(&var, ($gcc_atomic_type) 0);"
- ;;
- __sync_val_compare_and_swap)
- atomic_call="volatile $gcc_atomic_type var; $gcc_atomic_type res = __sync_fetch_and_or(&var, ($gcc_atomic_type) 0, ($gcc_atomic_type) 0);"
- ;;
- __atomic_store_n)
- atomic_call="$gcc_atomic_lockfree; volatile $gcc_atomic_type var; __sync_fetch_and_or(&var, ($gcc_atomic_type) 0, __ATOMIC_RELAXED); __sync_fetch_and_or(&var, ($gcc_atomic_type) 0, __ATOMIC_RELEASE);"
- ;;
- __atomic_load_n)
- atomic_call="$gcc_atomic_lockfree; volatile $gcc_atomic_type var; $gcc_atomic_type res = __sync_fetch_and_or(&var, __ATOMIC_RELAXED); res = __sync_fetch_and_or(&var, __ATOMIC_ACQUIRE);"
- ;;
- __atomic_add_fetch| __atomic_fetch_and | __atomic_fetch_or)
- atomic_call="$gcc_atomic_lockfree; volatile $gcc_atomic_type var; $gcc_atomic_type res = __sync_fetch_and_or(&var, ($gcc_atomic_type) 0, __ATOMIC_RELAXED); res = __sync_fetch_and_or(&var, ($gcc_atomic_type) 0, __ATOMIC_ACQUIRE); res = __sync_fetch_and_or(&var, ($gcc_atomic_type) 0, __ATOMIC_RELEASE);"
- ;;
- __atomic_compare_exchange_n)
- atomic_call="$gcc_atomic_lockfree; volatile $gcc_atomic_type var; $gcc_atomic_type val; int res = __sync_fetch_and_or(&var, &val, ($gcc_atomic_type) 0, 0, __ATOMIC_RELAXED, __ATOMIC_RELAXED); res = __sync_fetch_and_or(&var, &val, ($gcc_atomic_type) 0, 0, __ATOMIC_ACQUIRE, __ATOMIC_ACQUIRE);"
- ;;
- *)
- { { echo "$as_me:$LINENO: error: Internal error: missing implementation for __sync_fetch_and_or" >&5
-echo "$as_me: error: Internal error: missing implementation for __sync_fetch_and_or" >&2;}
- { (exit 1); exit 1; }; }
- ;;
- esac
- eval atomic${atomic_bit_size}_call=\"$atomic_call\"
- done
-
- echo "$as_me:$LINENO: checking for 32-bit __sync_fetch_and_or()" >&5
-echo $ECHO_N "checking for 32-bit __sync_fetch_and_or()... $ECHO_C" >&6
-if test "${ethr_cv_32bit___sync_fetch_and_or+set}" = set; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-
- ethr_cv_32bit___sync_fetch_and_or=no
- cat >conftest.$ac_ext <<_ACEOF
+ ac_lo=0 ac_mid=0
+ while :; do
+ cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
+ #include
+ #include "atomic_ops.h"
+
+
int
main ()
{
-$atomic32_call
+static int test_array [1 - 2 * !(((long) (sizeof (AO_t))) <= $ac_mid)];
+test_array [0] = 0
+
;
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
- (eval $ac_link) 2>conftest.er1
+rm -f conftest.$ac_objext
+if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
+ (eval $ac_compile) 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
@@ -15891,49 +14774,54 @@
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; } &&
- { ac_try='test -s conftest$ac_exeext'
+ { ac_try='test -s conftest.$ac_objext'
{ (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; }; then
- ethr_cv_32bit___sync_fetch_and_or=yes
+ ac_hi=$ac_mid; break
else
echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
+ac_lo=`expr $ac_mid + 1`
+ if test $ac_lo -le $ac_mid; then
+ ac_lo= ac_hi=
+ break
+ fi
+ ac_mid=`expr 2 '*' $ac_mid + 1`
fi
-rm -f conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-
-fi
-echo "$as_me:$LINENO: result: $ethr_cv_32bit___sync_fetch_and_or" >&5
-echo "${ECHO_T}$ethr_cv_32bit___sync_fetch_and_or" >&6
- echo "$as_me:$LINENO: checking for 64-bit __sync_fetch_and_or()" >&5
-echo $ECHO_N "checking for 64-bit __sync_fetch_and_or()... $ECHO_C" >&6
-if test "${ethr_cv_64bit___sync_fetch_and_or+set}" = set; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
+rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
+ done
else
+ echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
- ethr_cv_64bit___sync_fetch_and_or=no
- cat >conftest.$ac_ext <<_ACEOF
+cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
+ #include
+ #include "atomic_ops.h"
+
+
int
main ()
{
-$atomic64_call
+static int test_array [1 - 2 * !(((long) (sizeof (AO_t))) < 0)];
+test_array [0] = 0
+
;
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
- (eval $ac_link) 2>conftest.er1
+rm -f conftest.$ac_objext
+if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
+ (eval $ac_compile) 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
@@ -15947,49 +14835,38 @@
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; } &&
- { ac_try='test -s conftest$ac_exeext'
+ { ac_try='test -s conftest.$ac_objext'
{ (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; }; then
- ethr_cv_64bit___sync_fetch_and_or=yes
-else
- echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-fi
-rm -f conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-
-fi
-echo "$as_me:$LINENO: result: $ethr_cv_64bit___sync_fetch_and_or" >&5
-echo "${ECHO_T}$ethr_cv_64bit___sync_fetch_and_or" >&6
- echo "$as_me:$LINENO: checking for 128-bit __sync_fetch_and_or()" >&5
-echo $ECHO_N "checking for 128-bit __sync_fetch_and_or()... $ECHO_C" >&6
-if test "${ethr_cv_128bit___sync_fetch_and_or+set}" = set; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-
- ethr_cv_128bit___sync_fetch_and_or=no
- cat >conftest.$ac_ext <<_ACEOF
+ ac_hi=-1 ac_mid=-1
+ while :; do
+ cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
+ #include
+ #include "atomic_ops.h"
+
+
int
main ()
{
-$atomic128_call
+static int test_array [1 - 2 * !(((long) (sizeof (AO_t))) >= $ac_mid)];
+test_array [0] = 0
+
;
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
- (eval $ac_link) 2>conftest.er1
+rm -f conftest.$ac_objext
+if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
+ (eval $ac_compile) 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
@@ -16003,112 +14880,62 @@
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; } &&
- { ac_try='test -s conftest$ac_exeext'
+ { ac_try='test -s conftest.$ac_objext'
{ (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; }; then
- ethr_cv_128bit___sync_fetch_and_or=yes
+ ac_lo=$ac_mid; break
else
echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
+ac_hi=`expr '(' $ac_mid ')' - 1`
+ if test $ac_mid -le $ac_hi; then
+ ac_lo= ac_hi=
+ break
+ fi
+ ac_mid=`expr 2 '*' $ac_mid`
fi
-rm -f conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-
-fi
-echo "$as_me:$LINENO: result: $ethr_cv_128bit___sync_fetch_and_or" >&5
-echo "${ECHO_T}$ethr_cv_128bit___sync_fetch_and_or" >&6
-
- case $ethr_cv_128bit___sync_fetch_and_or-$ethr_cv_64bit___sync_fetch_and_or-$ethr_cv_32bit___sync_fetch_and_or in
- no-no-no)
- have_atomic_ops=0;;
- no-no-yes)
- have_atomic_ops=4;;
- no-yes-no)
- have_atomic_ops=8;;
- no-yes-yes)
- have_atomic_ops=12;;
- yes-no-no)
- have_atomic_ops=16;;
- yes-no-yes)
- have_atomic_ops=20;;
- yes-yes-no)
- have_atomic_ops=24;;
- yes-yes-yes)
- have_atomic_ops=28;;
- esac
-
-cat >>confdefs.h <<_ACEOF
-#define ETHR_HAVE___sync_fetch_and_or $have_atomic_ops
-_ACEOF
-
-
-
- # __sync_val_compare_and_swap - atomic_op
-
- for atomic_bit_size in 32 64 128; do
- case $atomic_bit_size in
- 32) gcc_atomic_type="$gcc_atomic_type32";;
- 64) gcc_atomic_type="$gcc_atomic_type64";;
- 128) gcc_atomic_type="$gcc_atomic_type128";;
- esac
- gcc_atomic_lockfree="int x[(2*__atomic_always_lock_free(sizeof($gcc_atomic_type), 0))-1]"
- case __sync_val_compare_and_swap in
- __sync_add_and_fetch | __sync_fetch_and_and | __sync_fetch_and_or)
- atomic_call="volatile $gcc_atomic_type var; $gcc_atomic_type res = __sync_val_compare_and_swap(&var, ($gcc_atomic_type) 0);"
- ;;
- __sync_val_compare_and_swap)
- atomic_call="volatile $gcc_atomic_type var; $gcc_atomic_type res = __sync_val_compare_and_swap(&var, ($gcc_atomic_type) 0, ($gcc_atomic_type) 0);"
- ;;
- __atomic_store_n)
- atomic_call="$gcc_atomic_lockfree; volatile $gcc_atomic_type var; __sync_val_compare_and_swap(&var, ($gcc_atomic_type) 0, __ATOMIC_RELAXED); __sync_val_compare_and_swap(&var, ($gcc_atomic_type) 0, __ATOMIC_RELEASE);"
- ;;
- __atomic_load_n)
- atomic_call="$gcc_atomic_lockfree; volatile $gcc_atomic_type var; $gcc_atomic_type res = __sync_val_compare_and_swap(&var, __ATOMIC_RELAXED); res = __sync_val_compare_and_swap(&var, __ATOMIC_ACQUIRE);"
- ;;
- __atomic_add_fetch| __atomic_fetch_and | __atomic_fetch_or)
- atomic_call="$gcc_atomic_lockfree; volatile $gcc_atomic_type var; $gcc_atomic_type res = __sync_val_compare_and_swap(&var, ($gcc_atomic_type) 0, __ATOMIC_RELAXED); res = __sync_val_compare_and_swap(&var, ($gcc_atomic_type) 0, __ATOMIC_ACQUIRE); res = __sync_val_compare_and_swap(&var, ($gcc_atomic_type) 0, __ATOMIC_RELEASE);"
- ;;
- __atomic_compare_exchange_n)
- atomic_call="$gcc_atomic_lockfree; volatile $gcc_atomic_type var; $gcc_atomic_type val; int res = __sync_val_compare_and_swap(&var, &val, ($gcc_atomic_type) 0, 0, __ATOMIC_RELAXED, __ATOMIC_RELAXED); res = __sync_val_compare_and_swap(&var, &val, ($gcc_atomic_type) 0, 0, __ATOMIC_ACQUIRE, __ATOMIC_ACQUIRE);"
- ;;
- *)
- { { echo "$as_me:$LINENO: error: Internal error: missing implementation for __sync_val_compare_and_swap" >&5
-echo "$as_me: error: Internal error: missing implementation for __sync_val_compare_and_swap" >&2;}
- { (exit 1); exit 1; }; }
- ;;
- esac
- eval atomic${atomic_bit_size}_call=\"$atomic_call\"
- done
-
- echo "$as_me:$LINENO: checking for 32-bit __sync_val_compare_and_swap()" >&5
-echo $ECHO_N "checking for 32-bit __sync_val_compare_and_swap()... $ECHO_C" >&6
-if test "${ethr_cv_32bit___sync_val_compare_and_swap+set}" = set; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
+rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
+ done
else
+ echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
- ethr_cv_32bit___sync_val_compare_and_swap=no
- cat >conftest.$ac_ext <<_ACEOF
+ac_lo= ac_hi=
+fi
+rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
+fi
+rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
+# Binary search between lo and hi bounds.
+while test "x$ac_lo" != "x$ac_hi"; do
+ ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
+ cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
+ #include
+ #include "atomic_ops.h"
+
+
int
main ()
{
-$atomic32_call
+static int test_array [1 - 2 * !(((long) (sizeof (AO_t))) <= $ac_mid)];
+test_array [0] = 0
+
;
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
- (eval $ac_link) 2>conftest.er1
+rm -f conftest.$ac_objext
+if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
+ (eval $ac_compile) 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
@@ -16122,105 +14949,246 @@
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; } &&
- { ac_try='test -s conftest$ac_exeext'
+ { ac_try='test -s conftest.$ac_objext'
{ (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; }; then
- ethr_cv_32bit___sync_val_compare_and_swap=yes
+ ac_hi=$ac_mid
else
echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
+ac_lo=`expr '(' $ac_mid ')' + 1`
fi
-rm -f conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-
-fi
-echo "$as_me:$LINENO: result: $ethr_cv_32bit___sync_val_compare_and_swap" >&5
-echo "${ECHO_T}$ethr_cv_32bit___sync_val_compare_and_swap" >&6
- echo "$as_me:$LINENO: checking for 64-bit __sync_val_compare_and_swap()" >&5
-echo $ECHO_N "checking for 64-bit __sync_val_compare_and_swap()... $ECHO_C" >&6
-if test "${ethr_cv_64bit___sync_val_compare_and_swap+set}" = set; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
+rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
+done
+case $ac_lo in
+?*) ac_cv_sizeof_AO_t=$ac_lo;;
+'') { { echo "$as_me:$LINENO: error: cannot compute sizeof (AO_t), 77
+See \`config.log' for more details." >&5
+echo "$as_me: error: cannot compute sizeof (AO_t), 77
+See \`config.log' for more details." >&2;}
+ { (exit 1); exit 1; }; } ;;
+esac
else
-
- ethr_cv_64bit___sync_val_compare_and_swap=no
- cat >conftest.$ac_ext <<_ACEOF
+ if test "$cross_compiling" = yes; then
+ { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling
+See \`config.log' for more details." >&5
+echo "$as_me: error: cannot run test program while cross compiling
+See \`config.log' for more details." >&2;}
+ { (exit 1); exit 1; }; }
+else
+ cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
+ #include
+ #include "atomic_ops.h"
+
+
+long longval () { return (long) (sizeof (AO_t)); }
+unsigned long ulongval () { return (long) (sizeof (AO_t)); }
+#include
+#include
int
main ()
{
-$atomic64_call
+
+ FILE *f = fopen ("conftest.val", "w");
+ if (! f)
+ exit (1);
+ if (((long) (sizeof (AO_t))) < 0)
+ {
+ long i = longval ();
+ if (i != ((long) (sizeof (AO_t))))
+ exit (1);
+ fprintf (f, "%ld\n", i);
+ }
+ else
+ {
+ unsigned long i = ulongval ();
+ if (i != ((long) (sizeof (AO_t))))
+ exit (1);
+ fprintf (f, "%lu\n", i);
+ }
+ exit (ferror (f) || fclose (f) != 0);
+
;
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
+rm -f conftest$ac_exeext
if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
- (eval $ac_link) 2>conftest.er1
- ac_status=$?
- grep -v '^ *+' conftest.er1 >conftest.err
- rm -f conftest.er1
- cat conftest.err >&5
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -z "$ac_c_werror_flag"
- || test ! -s conftest.err'
- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
+ (eval $ac_link) 2>&5
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); }; } &&
- { ac_try='test -s conftest$ac_exeext'
+ (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
{ (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; }; then
- ethr_cv_64bit___sync_val_compare_and_swap=yes
+ ac_cv_sizeof_AO_t=`cat conftest.val`
else
- echo "$as_me: failed program was:" >&5
+ echo "$as_me: program exited with status $ac_status" >&5
+echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
+( exit $ac_status )
+{ { echo "$as_me:$LINENO: error: cannot compute sizeof (AO_t), 77
+See \`config.log' for more details." >&5
+echo "$as_me: error: cannot compute sizeof (AO_t), 77
+See \`config.log' for more details." >&2;}
+ { (exit 1); exit 1; }; }
+fi
+rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
+fi
+fi
+rm -f conftest.val
+else
+ ac_cv_sizeof_AO_t=0
+fi
+fi
+echo "$as_me:$LINENO: result: $ac_cv_sizeof_AO_t" >&5
+echo "${ECHO_T}$ac_cv_sizeof_AO_t" >&6
+cat >>confdefs.h <<_ACEOF
+#define SIZEOF_AO_T $ac_cv_sizeof_AO_t
+_ACEOF
+
+
+
+cat >>confdefs.h <<_ACEOF
+#define ETHR_SIZEOF_AO_T $ac_cv_sizeof_AO_t
+_ACEOF
+
+
+
+cat >>confdefs.h <<\_ACEOF
+#define ETHR_HAVE_LIBATOMIC_OPS 1
+_ACEOF
+
+ if test "x$with_libatomic_ops" != "xno" && test "x$with_libatomic_ops" != "x"; then
+
+cat >>confdefs.h <<\_ACEOF
+#define ETHR_PREFER_LIBATOMIC_OPS_NATIVE_IMPLS 1
+_ACEOF
+
+ fi
+ ETHR_DEFS="$ETHR_DEFS $libatomic_ops_include"
+ elif test "x$with_libatomic_ops" != "xno" && test "x$with_libatomic_ops" != "x"; then
+ { { echo "$as_me:$LINENO: error: No usable libatomic_ops implementation found" >&5
+echo "$as_me: error: No usable libatomic_ops implementation found" >&2;}
+ { (exit 1); exit 1; }; }
+ fi
+
+ case "$host_cpu" in
+ sparc | sun4u | sparc64 | sun4v)
+ case "$with_sparc_memory_order" in
+ "TSO")
+
+cat >>confdefs.h <<\_ACEOF
+#define ETHR_SPARC_TSO 1
+_ACEOF
+;;
+ "PSO")
+
+cat >>confdefs.h <<\_ACEOF
+#define ETHR_SPARC_PSO 1
+_ACEOF
+;;
+ "RMO"|"")
+
+cat >>confdefs.h <<\_ACEOF
+#define ETHR_SPARC_RMO 1
+_ACEOF
+;;
+ *)
+ { { echo "$as_me:$LINENO: error: Unsupported Sparc memory order: $with_sparc_memory_order" >&5
+echo "$as_me: error: Unsupported Sparc memory order: $with_sparc_memory_order" >&2;}
+ { (exit 1); exit 1; }; };;
+ esac
+ ethr_have_native_atomics=yes;;
+ i86pc | i*86 | x86_64 | amd64)
+ if test "$enable_x86_out_of_order" = "yes"; then
+
+cat >>confdefs.h <<\_ACEOF
+#define ETHR_X86_OUT_OF_ORDER 1
+_ACEOF
+
+ fi
+ ethr_have_native_atomics=yes;;
+ macppc | ppc | powerpc | "Power Macintosh")
+ ethr_have_native_atomics=yes;;
+ tile)
+ ethr_have_native_atomics=yes;;
+ *)
+ ;;
+ esac
+
+ fi
+
+ test ethr_have_native_atomics = "yes" && ethr_have_native_spinlock=yes
+
+ LIBS=$saved_libs
+ CPPFLAGS=$saved_cppflags
+
+ ;;
+ *)
+ ;;
+esac
+
+echo "$as_me:$LINENO: checking whether default stack size should be modified" >&5
+echo $ECHO_N "checking whether default stack size should be modified... $ECHO_C" >&6
+if test "x$ethr_modified_default_stack_size" != "x"; then
+
+cat >>confdefs.h <<_ACEOF
+#define ETHR_MODIFIED_DEFAULT_STACK_SIZE $ethr_modified_default_stack_size
+_ACEOF
+
+ echo "$as_me:$LINENO: result: yes; to $ethr_modified_default_stack_size kilo words" >&5
+echo "${ECHO_T}yes; to $ethr_modified_default_stack_size kilo words" >&6
+else
+ echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6
fi
-rm -f conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
+if test "x$ETHR_THR_LIB_BASE" != "x"; then
+ ETHR_DEFS="-DUSE_THREADS $ETHR_DEFS"
+ ETHR_LIBS="-l$ethr_lib_name -lerts_internal_r $ETHR_X_LIBS"
+ ETHR_LIB_NAME=$ethr_lib_name
fi
-echo "$as_me:$LINENO: result: $ethr_cv_64bit___sync_val_compare_and_swap" >&5
-echo "${ECHO_T}$ethr_cv_64bit___sync_val_compare_and_swap" >&6
- echo "$as_me:$LINENO: checking for 128-bit __sync_val_compare_and_swap()" >&5
-echo $ECHO_N "checking for 128-bit __sync_val_compare_and_swap()... $ECHO_C" >&6
-if test "${ethr_cv_128bit___sync_val_compare_and_swap+set}" = set; then
+
+echo "$as_me:$LINENO: checking for void *" >&5
+echo $ECHO_N "checking for void *... $ECHO_C" >&6
+if test "${ac_cv_type_void_p+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
-
- ethr_cv_128bit___sync_val_compare_and_swap=no
- cat >conftest.$ac_ext <<_ACEOF
+ cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
-
+$ac_includes_default
int
main ()
{
-$atomic128_call
+if ((void * *) 0)
+ return 0;
+if (sizeof (void *))
+ return 0;
;
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
- (eval $ac_link) 2>conftest.er1
+rm -f conftest.$ac_objext
+if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
+ (eval $ac_compile) 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
@@ -16234,113 +15202,56 @@
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; } &&
- { ac_try='test -s conftest$ac_exeext'
+ { ac_try='test -s conftest.$ac_objext'
{ (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; }; then
- ethr_cv_128bit___sync_val_compare_and_swap=yes
+ ac_cv_type_void_p=yes
else
echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
+ac_cv_type_void_p=no
fi
-rm -f conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-
+rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
fi
-echo "$as_me:$LINENO: result: $ethr_cv_128bit___sync_val_compare_and_swap" >&5
-echo "${ECHO_T}$ethr_cv_128bit___sync_val_compare_and_swap" >&6
-
- case $ethr_cv_128bit___sync_val_compare_and_swap-$ethr_cv_64bit___sync_val_compare_and_swap-$ethr_cv_32bit___sync_val_compare_and_swap in
- no-no-no)
- have_atomic_ops=0;;
- no-no-yes)
- have_atomic_ops=4;;
- no-yes-no)
- have_atomic_ops=8;;
- no-yes-yes)
- have_atomic_ops=12;;
- yes-no-no)
- have_atomic_ops=16;;
- yes-no-yes)
- have_atomic_ops=20;;
- yes-yes-no)
- have_atomic_ops=24;;
- yes-yes-yes)
- have_atomic_ops=28;;
- esac
-
-cat >>confdefs.h <<_ACEOF
-#define ETHR_HAVE___sync_val_compare_and_swap $have_atomic_ops
-_ACEOF
-
-
-
-
- # __atomic_store_n - atomic_op
-
- for atomic_bit_size in 32 64 128; do
- case $atomic_bit_size in
- 32) gcc_atomic_type="$gcc_atomic_type32";;
- 64) gcc_atomic_type="$gcc_atomic_type64";;
- 128) gcc_atomic_type="$gcc_atomic_type128";;
- esac
- gcc_atomic_lockfree="int x[(2*__atomic_always_lock_free(sizeof($gcc_atomic_type), 0))-1]"
- case __atomic_store_n in
- __sync_add_and_fetch | __sync_fetch_and_and | __sync_fetch_and_or)
- atomic_call="volatile $gcc_atomic_type var; $gcc_atomic_type res = __atomic_store_n(&var, ($gcc_atomic_type) 0);"
- ;;
- __sync_val_compare_and_swap)
- atomic_call="volatile $gcc_atomic_type var; $gcc_atomic_type res = __atomic_store_n(&var, ($gcc_atomic_type) 0, ($gcc_atomic_type) 0);"
- ;;
- __atomic_store_n)
- atomic_call="$gcc_atomic_lockfree; volatile $gcc_atomic_type var; __atomic_store_n(&var, ($gcc_atomic_type) 0, __ATOMIC_RELAXED); __atomic_store_n(&var, ($gcc_atomic_type) 0, __ATOMIC_RELEASE);"
- ;;
- __atomic_load_n)
- atomic_call="$gcc_atomic_lockfree; volatile $gcc_atomic_type var; $gcc_atomic_type res = __atomic_store_n(&var, __ATOMIC_RELAXED); res = __atomic_store_n(&var, __ATOMIC_ACQUIRE);"
- ;;
- __atomic_add_fetch| __atomic_fetch_and | __atomic_fetch_or)
- atomic_call="$gcc_atomic_lockfree; volatile $gcc_atomic_type var; $gcc_atomic_type res = __atomic_store_n(&var, ($gcc_atomic_type) 0, __ATOMIC_RELAXED); res = __atomic_store_n(&var, ($gcc_atomic_type) 0, __ATOMIC_ACQUIRE); res = __atomic_store_n(&var, ($gcc_atomic_type) 0, __ATOMIC_RELEASE);"
- ;;
- __atomic_compare_exchange_n)
- atomic_call="$gcc_atomic_lockfree; volatile $gcc_atomic_type var; $gcc_atomic_type val; int res = __atomic_store_n(&var, &val, ($gcc_atomic_type) 0, 0, __ATOMIC_RELAXED, __ATOMIC_RELAXED); res = __atomic_store_n(&var, &val, ($gcc_atomic_type) 0, 0, __ATOMIC_ACQUIRE, __ATOMIC_ACQUIRE);"
- ;;
- *)
- { { echo "$as_me:$LINENO: error: Internal error: missing implementation for __atomic_store_n" >&5
-echo "$as_me: error: Internal error: missing implementation for __atomic_store_n" >&2;}
- { (exit 1); exit 1; }; }
- ;;
- esac
- eval atomic${atomic_bit_size}_call=\"$atomic_call\"
- done
+echo "$as_me:$LINENO: result: $ac_cv_type_void_p" >&5
+echo "${ECHO_T}$ac_cv_type_void_p" >&6
- echo "$as_me:$LINENO: checking for 32-bit __atomic_store_n()" >&5
-echo $ECHO_N "checking for 32-bit __atomic_store_n()... $ECHO_C" >&6
-if test "${ethr_cv_32bit___atomic_store_n+set}" = set; then
+echo "$as_me:$LINENO: checking size of void *" >&5
+echo $ECHO_N "checking size of void *... $ECHO_C" >&6
+if test "${ac_cv_sizeof_void_p+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
-
- ethr_cv_32bit___atomic_store_n=no
- cat >conftest.$ac_ext <<_ACEOF
+ if test "$ac_cv_type_void_p" = yes; then
+ # The cast to unsigned long works around a bug in the HP C Compiler
+ # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
+ # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
+ # This bug is HP SR number 8606223364.
+ if test "$cross_compiling" = yes; then
+ # Depending upon the size, compute the lo and hi bounds.
+cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
-
+$ac_includes_default
int
main ()
{
-$atomic32_call
+static int test_array [1 - 2 * !(((long) (sizeof (void *))) >= 0)];
+test_array [0] = 0
+
;
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
- (eval $ac_link) 2>conftest.er1
+rm -f conftest.$ac_objext
+if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
+ (eval $ac_compile) 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
@@ -16354,49 +15265,34 @@
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; } &&
- { ac_try='test -s conftest$ac_exeext'
+ { ac_try='test -s conftest.$ac_objext'
{ (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; }; then
- ethr_cv_32bit___atomic_store_n=yes
-else
- echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-fi
-rm -f conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-
-fi
-echo "$as_me:$LINENO: result: $ethr_cv_32bit___atomic_store_n" >&5
-echo "${ECHO_T}$ethr_cv_32bit___atomic_store_n" >&6
- echo "$as_me:$LINENO: checking for 64-bit __atomic_store_n()" >&5
-echo $ECHO_N "checking for 64-bit __atomic_store_n()... $ECHO_C" >&6
-if test "${ethr_cv_64bit___atomic_store_n+set}" = set; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-
- ethr_cv_64bit___atomic_store_n=no
- cat >conftest.$ac_ext <<_ACEOF
+ ac_lo=0 ac_mid=0
+ while :; do
+ cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
-
+$ac_includes_default
int
main ()
{
-$atomic64_call
+static int test_array [1 - 2 * !(((long) (sizeof (void *))) <= $ac_mid)];
+test_array [0] = 0
+
;
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
- (eval $ac_link) 2>conftest.er1
+rm -f conftest.$ac_objext
+if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
+ (eval $ac_compile) 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
@@ -16410,49 +15306,50 @@
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; } &&
- { ac_try='test -s conftest$ac_exeext'
+ { ac_try='test -s conftest.$ac_objext'
{ (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; }; then
- ethr_cv_64bit___atomic_store_n=yes
+ ac_hi=$ac_mid; break
else
echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
+ac_lo=`expr $ac_mid + 1`
+ if test $ac_lo -le $ac_mid; then
+ ac_lo= ac_hi=
+ break
+ fi
+ ac_mid=`expr 2 '*' $ac_mid + 1`
fi
-rm -f conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-
-fi
-echo "$as_me:$LINENO: result: $ethr_cv_64bit___atomic_store_n" >&5
-echo "${ECHO_T}$ethr_cv_64bit___atomic_store_n" >&6
- echo "$as_me:$LINENO: checking for 128-bit __atomic_store_n()" >&5
-echo $ECHO_N "checking for 128-bit __atomic_store_n()... $ECHO_C" >&6
-if test "${ethr_cv_128bit___atomic_store_n+set}" = set; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
+rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
+ done
else
+ echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
- ethr_cv_128bit___atomic_store_n=no
- cat >conftest.$ac_ext <<_ACEOF
+cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
-
+$ac_includes_default
int
main ()
{
-$atomic128_call
+static int test_array [1 - 2 * !(((long) (sizeof (void *))) < 0)];
+test_array [0] = 0
+
;
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
- (eval $ac_link) 2>conftest.er1
+rm -f conftest.$ac_objext
+if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
+ (eval $ac_compile) 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
@@ -16466,112 +15363,34 @@
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; } &&
- { ac_try='test -s conftest$ac_exeext'
+ { ac_try='test -s conftest.$ac_objext'
{ (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; }; then
- ethr_cv_128bit___atomic_store_n=yes
-else
- echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-fi
-rm -f conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-
-fi
-echo "$as_me:$LINENO: result: $ethr_cv_128bit___atomic_store_n" >&5
-echo "${ECHO_T}$ethr_cv_128bit___atomic_store_n" >&6
-
- case $ethr_cv_128bit___atomic_store_n-$ethr_cv_64bit___atomic_store_n-$ethr_cv_32bit___atomic_store_n in
- no-no-no)
- have_atomic_ops=0;;
- no-no-yes)
- have_atomic_ops=4;;
- no-yes-no)
- have_atomic_ops=8;;
- no-yes-yes)
- have_atomic_ops=12;;
- yes-no-no)
- have_atomic_ops=16;;
- yes-no-yes)
- have_atomic_ops=20;;
- yes-yes-no)
- have_atomic_ops=24;;
- yes-yes-yes)
- have_atomic_ops=28;;
- esac
-
-cat >>confdefs.h <<_ACEOF
-#define ETHR_HAVE___atomic_store_n $have_atomic_ops
-_ACEOF
-
-
-
- # __atomic_load_n - atomic_op
-
- for atomic_bit_size in 32 64 128; do
- case $atomic_bit_size in
- 32) gcc_atomic_type="$gcc_atomic_type32";;
- 64) gcc_atomic_type="$gcc_atomic_type64";;
- 128) gcc_atomic_type="$gcc_atomic_type128";;
- esac
- gcc_atomic_lockfree="int x[(2*__atomic_always_lock_free(sizeof($gcc_atomic_type), 0))-1]"
- case __atomic_load_n in
- __sync_add_and_fetch | __sync_fetch_and_and | __sync_fetch_and_or)
- atomic_call="volatile $gcc_atomic_type var; $gcc_atomic_type res = __atomic_load_n(&var, ($gcc_atomic_type) 0);"
- ;;
- __sync_val_compare_and_swap)
- atomic_call="volatile $gcc_atomic_type var; $gcc_atomic_type res = __atomic_load_n(&var, ($gcc_atomic_type) 0, ($gcc_atomic_type) 0);"
- ;;
- __atomic_store_n)
- atomic_call="$gcc_atomic_lockfree; volatile $gcc_atomic_type var; __atomic_load_n(&var, ($gcc_atomic_type) 0, __ATOMIC_RELAXED); __atomic_load_n(&var, ($gcc_atomic_type) 0, __ATOMIC_RELEASE);"
- ;;
- __atomic_load_n)
- atomic_call="$gcc_atomic_lockfree; volatile $gcc_atomic_type var; $gcc_atomic_type res = __atomic_load_n(&var, __ATOMIC_RELAXED); res = __atomic_load_n(&var, __ATOMIC_ACQUIRE);"
- ;;
- __atomic_add_fetch| __atomic_fetch_and | __atomic_fetch_or)
- atomic_call="$gcc_atomic_lockfree; volatile $gcc_atomic_type var; $gcc_atomic_type res = __atomic_load_n(&var, ($gcc_atomic_type) 0, __ATOMIC_RELAXED); res = __atomic_load_n(&var, ($gcc_atomic_type) 0, __ATOMIC_ACQUIRE); res = __atomic_load_n(&var, ($gcc_atomic_type) 0, __ATOMIC_RELEASE);"
- ;;
- __atomic_compare_exchange_n)
- atomic_call="$gcc_atomic_lockfree; volatile $gcc_atomic_type var; $gcc_atomic_type val; int res = __atomic_load_n(&var, &val, ($gcc_atomic_type) 0, 0, __ATOMIC_RELAXED, __ATOMIC_RELAXED); res = __atomic_load_n(&var, &val, ($gcc_atomic_type) 0, 0, __ATOMIC_ACQUIRE, __ATOMIC_ACQUIRE);"
- ;;
- *)
- { { echo "$as_me:$LINENO: error: Internal error: missing implementation for __atomic_load_n" >&5
-echo "$as_me: error: Internal error: missing implementation for __atomic_load_n" >&2;}
- { (exit 1); exit 1; }; }
- ;;
- esac
- eval atomic${atomic_bit_size}_call=\"$atomic_call\"
- done
-
- echo "$as_me:$LINENO: checking for 32-bit __atomic_load_n()" >&5
-echo $ECHO_N "checking for 32-bit __atomic_load_n()... $ECHO_C" >&6
-if test "${ethr_cv_32bit___atomic_load_n+set}" = set; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-
- ethr_cv_32bit___atomic_load_n=no
- cat >conftest.$ac_ext <<_ACEOF
+ ac_hi=-1 ac_mid=-1
+ while :; do
+ cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
-
+$ac_includes_default
int
main ()
{
-$atomic32_call
+static int test_array [1 - 2 * !(((long) (sizeof (void *))) >= $ac_mid)];
+test_array [0] = 0
+
;
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
- (eval $ac_link) 2>conftest.er1
+rm -f conftest.$ac_objext
+if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
+ (eval $ac_compile) 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
@@ -16585,49 +15404,58 @@
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; } &&
- { ac_try='test -s conftest$ac_exeext'
+ { ac_try='test -s conftest.$ac_objext'
{ (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; }; then
- ethr_cv_32bit___atomic_load_n=yes
+ ac_lo=$ac_mid; break
else
echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
+ac_hi=`expr '(' $ac_mid ')' - 1`
+ if test $ac_mid -le $ac_hi; then
+ ac_lo= ac_hi=
+ break
+ fi
+ ac_mid=`expr 2 '*' $ac_mid`
fi
-rm -f conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-
-fi
-echo "$as_me:$LINENO: result: $ethr_cv_32bit___atomic_load_n" >&5
-echo "${ECHO_T}$ethr_cv_32bit___atomic_load_n" >&6
- echo "$as_me:$LINENO: checking for 64-bit __atomic_load_n()" >&5
-echo $ECHO_N "checking for 64-bit __atomic_load_n()... $ECHO_C" >&6
-if test "${ethr_cv_64bit___atomic_load_n+set}" = set; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
+rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
+ done
else
+ echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
- ethr_cv_64bit___atomic_load_n=no
- cat >conftest.$ac_ext <<_ACEOF
+ac_lo= ac_hi=
+fi
+rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
+fi
+rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
+# Binary search between lo and hi bounds.
+while test "x$ac_lo" != "x$ac_hi"; do
+ ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
+ cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
-
+$ac_includes_default
int
main ()
{
-$atomic64_call
+static int test_array [1 - 2 * !(((long) (sizeof (void *))) <= $ac_mid)];
+test_array [0] = 0
+
;
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
- (eval $ac_link) 2>conftest.er1
+rm -f conftest.$ac_objext
+if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
+ (eval $ac_compile) 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
@@ -16641,168 +15469,146 @@
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; } &&
- { ac_try='test -s conftest$ac_exeext'
+ { ac_try='test -s conftest.$ac_objext'
{ (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; }; then
- ethr_cv_64bit___atomic_load_n=yes
+ ac_hi=$ac_mid
else
echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
+ac_lo=`expr '(' $ac_mid ')' + 1`
fi
-rm -f conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-
-fi
-echo "$as_me:$LINENO: result: $ethr_cv_64bit___atomic_load_n" >&5
-echo "${ECHO_T}$ethr_cv_64bit___atomic_load_n" >&6
- echo "$as_me:$LINENO: checking for 128-bit __atomic_load_n()" >&5
-echo $ECHO_N "checking for 128-bit __atomic_load_n()... $ECHO_C" >&6
-if test "${ethr_cv_128bit___atomic_load_n+set}" = set; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
+rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
+done
+case $ac_lo in
+?*) ac_cv_sizeof_void_p=$ac_lo;;
+'') { { echo "$as_me:$LINENO: error: cannot compute sizeof (void *), 77
+See \`config.log' for more details." >&5
+echo "$as_me: error: cannot compute sizeof (void *), 77
+See \`config.log' for more details." >&2;}
+ { (exit 1); exit 1; }; } ;;
+esac
else
-
- ethr_cv_128bit___atomic_load_n=no
- cat >conftest.$ac_ext <<_ACEOF
+ if test "$cross_compiling" = yes; then
+ { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling
+See \`config.log' for more details." >&5
+echo "$as_me: error: cannot run test program while cross compiling
+See \`config.log' for more details." >&2;}
+ { (exit 1); exit 1; }; }
+else
+ cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
-
+$ac_includes_default
+long longval () { return (long) (sizeof (void *)); }
+unsigned long ulongval () { return (long) (sizeof (void *)); }
+#include
+#include
int
main ()
{
-$atomic128_call
+
+ FILE *f = fopen ("conftest.val", "w");
+ if (! f)
+ exit (1);
+ if (((long) (sizeof (void *))) < 0)
+ {
+ long i = longval ();
+ if (i != ((long) (sizeof (void *))))
+ exit (1);
+ fprintf (f, "%ld\n", i);
+ }
+ else
+ {
+ unsigned long i = ulongval ();
+ if (i != ((long) (sizeof (void *))))
+ exit (1);
+ fprintf (f, "%lu\n", i);
+ }
+ exit (ferror (f) || fclose (f) != 0);
+
;
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
+rm -f conftest$ac_exeext
if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
- (eval $ac_link) 2>conftest.er1
- ac_status=$?
- grep -v '^ *+' conftest.er1 >conftest.err
- rm -f conftest.er1
- cat conftest.err >&5
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -z "$ac_c_werror_flag"
- || test ! -s conftest.err'
- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
+ (eval $ac_link) 2>&5
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); }; } &&
- { ac_try='test -s conftest$ac_exeext'
+ (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
{ (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; }; then
- ethr_cv_128bit___atomic_load_n=yes
+ ac_cv_sizeof_void_p=`cat conftest.val`
else
- echo "$as_me: failed program was:" >&5
+ echo "$as_me: program exited with status $ac_status" >&5
+echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
+( exit $ac_status )
+{ { echo "$as_me:$LINENO: error: cannot compute sizeof (void *), 77
+See \`config.log' for more details." >&5
+echo "$as_me: error: cannot compute sizeof (void *), 77
+See \`config.log' for more details." >&2;}
+ { (exit 1); exit 1; }; }
fi
-rm -f conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-
+rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
fi
-echo "$as_me:$LINENO: result: $ethr_cv_128bit___atomic_load_n" >&5
-echo "${ECHO_T}$ethr_cv_128bit___atomic_load_n" >&6
-
- case $ethr_cv_128bit___atomic_load_n-$ethr_cv_64bit___atomic_load_n-$ethr_cv_32bit___atomic_load_n in
- no-no-no)
- have_atomic_ops=0;;
- no-no-yes)
- have_atomic_ops=4;;
- no-yes-no)
- have_atomic_ops=8;;
- no-yes-yes)
- have_atomic_ops=12;;
- yes-no-no)
- have_atomic_ops=16;;
- yes-no-yes)
- have_atomic_ops=20;;
- yes-yes-no)
- have_atomic_ops=24;;
- yes-yes-yes)
- have_atomic_ops=28;;
- esac
-
+fi
+rm -f conftest.val
+else
+ ac_cv_sizeof_void_p=0
+fi
+fi
+echo "$as_me:$LINENO: result: $ac_cv_sizeof_void_p" >&5
+echo "${ECHO_T}$ac_cv_sizeof_void_p" >&6
cat >>confdefs.h <<_ACEOF
-#define ETHR_HAVE___atomic_load_n $have_atomic_ops
+#define SIZEOF_VOID_P $ac_cv_sizeof_void_p
_ACEOF
- # __atomic_add_fetch - atomic_op
+cat >>confdefs.h <<_ACEOF
+#define ETHR_SIZEOF_PTR $ac_cv_sizeof_void_p
+_ACEOF
- for atomic_bit_size in 32 64 128; do
- case $atomic_bit_size in
- 32) gcc_atomic_type="$gcc_atomic_type32";;
- 64) gcc_atomic_type="$gcc_atomic_type64";;
- 128) gcc_atomic_type="$gcc_atomic_type128";;
- esac
- gcc_atomic_lockfree="int x[(2*__atomic_always_lock_free(sizeof($gcc_atomic_type), 0))-1]"
- case __atomic_add_fetch in
- __sync_add_and_fetch | __sync_fetch_and_and | __sync_fetch_and_or)
- atomic_call="volatile $gcc_atomic_type var; $gcc_atomic_type res = __atomic_add_fetch(&var, ($gcc_atomic_type) 0);"
- ;;
- __sync_val_compare_and_swap)
- atomic_call="volatile $gcc_atomic_type var; $gcc_atomic_type res = __atomic_add_fetch(&var, ($gcc_atomic_type) 0, ($gcc_atomic_type) 0);"
- ;;
- __atomic_store_n)
- atomic_call="$gcc_atomic_lockfree; volatile $gcc_atomic_type var; __atomic_add_fetch(&var, ($gcc_atomic_type) 0, __ATOMIC_RELAXED); __atomic_add_fetch(&var, ($gcc_atomic_type) 0, __ATOMIC_RELEASE);"
- ;;
- __atomic_load_n)
- atomic_call="$gcc_atomic_lockfree; volatile $gcc_atomic_type var; $gcc_atomic_type res = __atomic_add_fetch(&var, __ATOMIC_RELAXED); res = __atomic_add_fetch(&var, __ATOMIC_ACQUIRE);"
- ;;
- __atomic_add_fetch| __atomic_fetch_and | __atomic_fetch_or)
- atomic_call="$gcc_atomic_lockfree; volatile $gcc_atomic_type var; $gcc_atomic_type res = __atomic_add_fetch(&var, ($gcc_atomic_type) 0, __ATOMIC_RELAXED); res = __atomic_add_fetch(&var, ($gcc_atomic_type) 0, __ATOMIC_ACQUIRE); res = __atomic_add_fetch(&var, ($gcc_atomic_type) 0, __ATOMIC_RELEASE);"
- ;;
- __atomic_compare_exchange_n)
- atomic_call="$gcc_atomic_lockfree; volatile $gcc_atomic_type var; $gcc_atomic_type val; int res = __atomic_add_fetch(&var, &val, ($gcc_atomic_type) 0, 0, __ATOMIC_RELAXED, __ATOMIC_RELAXED); res = __atomic_add_fetch(&var, &val, ($gcc_atomic_type) 0, 0, __ATOMIC_ACQUIRE, __ATOMIC_ACQUIRE);"
- ;;
- *)
- { { echo "$as_me:$LINENO: error: Internal error: missing implementation for __atomic_add_fetch" >&5
-echo "$as_me: error: Internal error: missing implementation for __atomic_add_fetch" >&2;}
- { (exit 1); exit 1; }; }
- ;;
- esac
- eval atomic${atomic_bit_size}_call=\"$atomic_call\"
- done
- echo "$as_me:$LINENO: checking for 32-bit __atomic_add_fetch()" >&5
-echo $ECHO_N "checking for 32-bit __atomic_add_fetch()... $ECHO_C" >&6
-if test "${ethr_cv_32bit___atomic_add_fetch+set}" = set; then
+echo "$as_me:$LINENO: checking for int" >&5
+echo $ECHO_N "checking for int... $ECHO_C" >&6
+if test "${ac_cv_type_int+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
-
- ethr_cv_32bit___atomic_add_fetch=no
- cat >conftest.$ac_ext <<_ACEOF
+ cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
-
+$ac_includes_default
int
main ()
{
-$atomic32_call
+if ((int *) 0)
+ return 0;
+if (sizeof (int))
+ return 0;
;
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
- (eval $ac_link) 2>conftest.er1
+rm -f conftest.$ac_objext
+if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
+ (eval $ac_compile) 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
@@ -16816,49 +15622,56 @@
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; } &&
- { ac_try='test -s conftest$ac_exeext'
+ { ac_try='test -s conftest.$ac_objext'
{ (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; }; then
- ethr_cv_32bit___atomic_add_fetch=yes
+ ac_cv_type_int=yes
else
echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
+ac_cv_type_int=no
fi
-rm -f conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-
+rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
fi
-echo "$as_me:$LINENO: result: $ethr_cv_32bit___atomic_add_fetch" >&5
-echo "${ECHO_T}$ethr_cv_32bit___atomic_add_fetch" >&6
- echo "$as_me:$LINENO: checking for 64-bit __atomic_add_fetch()" >&5
-echo $ECHO_N "checking for 64-bit __atomic_add_fetch()... $ECHO_C" >&6
-if test "${ethr_cv_64bit___atomic_add_fetch+set}" = set; then
+echo "$as_me:$LINENO: result: $ac_cv_type_int" >&5
+echo "${ECHO_T}$ac_cv_type_int" >&6
+
+echo "$as_me:$LINENO: checking size of int" >&5
+echo $ECHO_N "checking size of int... $ECHO_C" >&6
+if test "${ac_cv_sizeof_int+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
-
- ethr_cv_64bit___atomic_add_fetch=no
- cat >conftest.$ac_ext <<_ACEOF
+ if test "$ac_cv_type_int" = yes; then
+ # The cast to unsigned long works around a bug in the HP C Compiler
+ # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
+ # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
+ # This bug is HP SR number 8606223364.
+ if test "$cross_compiling" = yes; then
+ # Depending upon the size, compute the lo and hi bounds.
+cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
-
+$ac_includes_default
int
main ()
{
-$atomic64_call
+static int test_array [1 - 2 * !(((long) (sizeof (int))) >= 0)];
+test_array [0] = 0
+
;
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
- (eval $ac_link) 2>conftest.er1
+rm -f conftest.$ac_objext
+if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
+ (eval $ac_compile) 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
@@ -16872,49 +15685,34 @@
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; } &&
- { ac_try='test -s conftest$ac_exeext'
+ { ac_try='test -s conftest.$ac_objext'
{ (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; }; then
- ethr_cv_64bit___atomic_add_fetch=yes
-else
- echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-fi
-rm -f conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-
-fi
-echo "$as_me:$LINENO: result: $ethr_cv_64bit___atomic_add_fetch" >&5
-echo "${ECHO_T}$ethr_cv_64bit___atomic_add_fetch" >&6
- echo "$as_me:$LINENO: checking for 128-bit __atomic_add_fetch()" >&5
-echo $ECHO_N "checking for 128-bit __atomic_add_fetch()... $ECHO_C" >&6
-if test "${ethr_cv_128bit___atomic_add_fetch+set}" = set; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-
- ethr_cv_128bit___atomic_add_fetch=no
- cat >conftest.$ac_ext <<_ACEOF
+ ac_lo=0 ac_mid=0
+ while :; do
+ cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
-
+$ac_includes_default
int
main ()
{
-$atomic128_call
+static int test_array [1 - 2 * !(((long) (sizeof (int))) <= $ac_mid)];
+test_array [0] = 0
+
;
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
- (eval $ac_link) 2>conftest.er1
+rm -f conftest.$ac_objext
+if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
+ (eval $ac_compile) 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
@@ -16928,112 +15726,50 @@
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; } &&
- { ac_try='test -s conftest$ac_exeext'
+ { ac_try='test -s conftest.$ac_objext'
{ (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; }; then
- ethr_cv_128bit___atomic_add_fetch=yes
+ ac_hi=$ac_mid; break
else
echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
+ac_lo=`expr $ac_mid + 1`
+ if test $ac_lo -le $ac_mid; then
+ ac_lo= ac_hi=
+ break
+ fi
+ ac_mid=`expr 2 '*' $ac_mid + 1`
fi
-rm -f conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-
-fi
-echo "$as_me:$LINENO: result: $ethr_cv_128bit___atomic_add_fetch" >&5
-echo "${ECHO_T}$ethr_cv_128bit___atomic_add_fetch" >&6
-
- case $ethr_cv_128bit___atomic_add_fetch-$ethr_cv_64bit___atomic_add_fetch-$ethr_cv_32bit___atomic_add_fetch in
- no-no-no)
- have_atomic_ops=0;;
- no-no-yes)
- have_atomic_ops=4;;
- no-yes-no)
- have_atomic_ops=8;;
- no-yes-yes)
- have_atomic_ops=12;;
- yes-no-no)
- have_atomic_ops=16;;
- yes-no-yes)
- have_atomic_ops=20;;
- yes-yes-no)
- have_atomic_ops=24;;
- yes-yes-yes)
- have_atomic_ops=28;;
- esac
-
-cat >>confdefs.h <<_ACEOF
-#define ETHR_HAVE___atomic_add_fetch $have_atomic_ops
-_ACEOF
-
-
-
- # __atomic_fetch_and - atomic_op
-
- for atomic_bit_size in 32 64 128; do
- case $atomic_bit_size in
- 32) gcc_atomic_type="$gcc_atomic_type32";;
- 64) gcc_atomic_type="$gcc_atomic_type64";;
- 128) gcc_atomic_type="$gcc_atomic_type128";;
- esac
- gcc_atomic_lockfree="int x[(2*__atomic_always_lock_free(sizeof($gcc_atomic_type), 0))-1]"
- case __atomic_fetch_and in
- __sync_add_and_fetch | __sync_fetch_and_and | __sync_fetch_and_or)
- atomic_call="volatile $gcc_atomic_type var; $gcc_atomic_type res = __atomic_fetch_and(&var, ($gcc_atomic_type) 0);"
- ;;
- __sync_val_compare_and_swap)
- atomic_call="volatile $gcc_atomic_type var; $gcc_atomic_type res = __atomic_fetch_and(&var, ($gcc_atomic_type) 0, ($gcc_atomic_type) 0);"
- ;;
- __atomic_store_n)
- atomic_call="$gcc_atomic_lockfree; volatile $gcc_atomic_type var; __atomic_fetch_and(&var, ($gcc_atomic_type) 0, __ATOMIC_RELAXED); __atomic_fetch_and(&var, ($gcc_atomic_type) 0, __ATOMIC_RELEASE);"
- ;;
- __atomic_load_n)
- atomic_call="$gcc_atomic_lockfree; volatile $gcc_atomic_type var; $gcc_atomic_type res = __atomic_fetch_and(&var, __ATOMIC_RELAXED); res = __atomic_fetch_and(&var, __ATOMIC_ACQUIRE);"
- ;;
- __atomic_add_fetch| __atomic_fetch_and | __atomic_fetch_or)
- atomic_call="$gcc_atomic_lockfree; volatile $gcc_atomic_type var; $gcc_atomic_type res = __atomic_fetch_and(&var, ($gcc_atomic_type) 0, __ATOMIC_RELAXED); res = __atomic_fetch_and(&var, ($gcc_atomic_type) 0, __ATOMIC_ACQUIRE); res = __atomic_fetch_and(&var, ($gcc_atomic_type) 0, __ATOMIC_RELEASE);"
- ;;
- __atomic_compare_exchange_n)
- atomic_call="$gcc_atomic_lockfree; volatile $gcc_atomic_type var; $gcc_atomic_type val; int res = __atomic_fetch_and(&var, &val, ($gcc_atomic_type) 0, 0, __ATOMIC_RELAXED, __ATOMIC_RELAXED); res = __atomic_fetch_and(&var, &val, ($gcc_atomic_type) 0, 0, __ATOMIC_ACQUIRE, __ATOMIC_ACQUIRE);"
- ;;
- *)
- { { echo "$as_me:$LINENO: error: Internal error: missing implementation for __atomic_fetch_and" >&5
-echo "$as_me: error: Internal error: missing implementation for __atomic_fetch_and" >&2;}
- { (exit 1); exit 1; }; }
- ;;
- esac
- eval atomic${atomic_bit_size}_call=\"$atomic_call\"
- done
-
- echo "$as_me:$LINENO: checking for 32-bit __atomic_fetch_and()" >&5
-echo $ECHO_N "checking for 32-bit __atomic_fetch_and()... $ECHO_C" >&6
-if test "${ethr_cv_32bit___atomic_fetch_and+set}" = set; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
+rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
+ done
else
+ echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
- ethr_cv_32bit___atomic_fetch_and=no
- cat >conftest.$ac_ext <<_ACEOF
+cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
-
+$ac_includes_default
int
main ()
{
-$atomic32_call
+static int test_array [1 - 2 * !(((long) (sizeof (int))) < 0)];
+test_array [0] = 0
+
;
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
- (eval $ac_link) 2>conftest.er1
+rm -f conftest.$ac_objext
+if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
+ (eval $ac_compile) 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
@@ -17047,49 +15783,34 @@
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; } &&
- { ac_try='test -s conftest$ac_exeext'
+ { ac_try='test -s conftest.$ac_objext'
{ (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; }; then
- ethr_cv_32bit___atomic_fetch_and=yes
-else
- echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-fi
-rm -f conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-
-fi
-echo "$as_me:$LINENO: result: $ethr_cv_32bit___atomic_fetch_and" >&5
-echo "${ECHO_T}$ethr_cv_32bit___atomic_fetch_and" >&6
- echo "$as_me:$LINENO: checking for 64-bit __atomic_fetch_and()" >&5
-echo $ECHO_N "checking for 64-bit __atomic_fetch_and()... $ECHO_C" >&6
-if test "${ethr_cv_64bit___atomic_fetch_and+set}" = set; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-
- ethr_cv_64bit___atomic_fetch_and=no
- cat >conftest.$ac_ext <<_ACEOF
+ ac_hi=-1 ac_mid=-1
+ while :; do
+ cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
-
+$ac_includes_default
int
main ()
{
-$atomic64_call
+static int test_array [1 - 2 * !(((long) (sizeof (int))) >= $ac_mid)];
+test_array [0] = 0
+
;
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
- (eval $ac_link) 2>conftest.er1
+rm -f conftest.$ac_objext
+if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
+ (eval $ac_compile) 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
@@ -17103,49 +15824,58 @@
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; } &&
- { ac_try='test -s conftest$ac_exeext'
+ { ac_try='test -s conftest.$ac_objext'
{ (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; }; then
- ethr_cv_64bit___atomic_fetch_and=yes
+ ac_lo=$ac_mid; break
else
echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
+ac_hi=`expr '(' $ac_mid ')' - 1`
+ if test $ac_mid -le $ac_hi; then
+ ac_lo= ac_hi=
+ break
+ fi
+ ac_mid=`expr 2 '*' $ac_mid`
fi
-rm -f conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-
-fi
-echo "$as_me:$LINENO: result: $ethr_cv_64bit___atomic_fetch_and" >&5
-echo "${ECHO_T}$ethr_cv_64bit___atomic_fetch_and" >&6
- echo "$as_me:$LINENO: checking for 128-bit __atomic_fetch_and()" >&5
-echo $ECHO_N "checking for 128-bit __atomic_fetch_and()... $ECHO_C" >&6
-if test "${ethr_cv_128bit___atomic_fetch_and+set}" = set; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
+rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
+ done
else
+ echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
- ethr_cv_128bit___atomic_fetch_and=no
- cat >conftest.$ac_ext <<_ACEOF
+ac_lo= ac_hi=
+fi
+rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
+fi
+rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
+# Binary search between lo and hi bounds.
+while test "x$ac_lo" != "x$ac_hi"; do
+ ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
+ cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
-
+$ac_includes_default
int
main ()
{
-$atomic128_call
+static int test_array [1 - 2 * !(((long) (sizeof (int))) <= $ac_mid)];
+test_array [0] = 0
+
;
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
- (eval $ac_link) 2>conftest.er1
+rm -f conftest.$ac_objext
+if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
+ (eval $ac_compile) 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
@@ -17159,168 +15889,145 @@
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; } &&
- { ac_try='test -s conftest$ac_exeext'
+ { ac_try='test -s conftest.$ac_objext'
{ (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; }; then
- ethr_cv_128bit___atomic_fetch_and=yes
+ ac_hi=$ac_mid
else
echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
+ac_lo=`expr '(' $ac_mid ')' + 1`
fi
-rm -f conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-
-fi
-echo "$as_me:$LINENO: result: $ethr_cv_128bit___atomic_fetch_and" >&5
-echo "${ECHO_T}$ethr_cv_128bit___atomic_fetch_and" >&6
-
- case $ethr_cv_128bit___atomic_fetch_and-$ethr_cv_64bit___atomic_fetch_and-$ethr_cv_32bit___atomic_fetch_and in
- no-no-no)
- have_atomic_ops=0;;
- no-no-yes)
- have_atomic_ops=4;;
- no-yes-no)
- have_atomic_ops=8;;
- no-yes-yes)
- have_atomic_ops=12;;
- yes-no-no)
- have_atomic_ops=16;;
- yes-no-yes)
- have_atomic_ops=20;;
- yes-yes-no)
- have_atomic_ops=24;;
- yes-yes-yes)
- have_atomic_ops=28;;
- esac
-
-cat >>confdefs.h <<_ACEOF
-#define ETHR_HAVE___atomic_fetch_and $have_atomic_ops
-_ACEOF
-
-
-
- # __atomic_fetch_or - atomic_op
-
- for atomic_bit_size in 32 64 128; do
- case $atomic_bit_size in
- 32) gcc_atomic_type="$gcc_atomic_type32";;
- 64) gcc_atomic_type="$gcc_atomic_type64";;
- 128) gcc_atomic_type="$gcc_atomic_type128";;
- esac
- gcc_atomic_lockfree="int x[(2*__atomic_always_lock_free(sizeof($gcc_atomic_type), 0))-1]"
- case __atomic_fetch_or in
- __sync_add_and_fetch | __sync_fetch_and_and | __sync_fetch_and_or)
- atomic_call="volatile $gcc_atomic_type var; $gcc_atomic_type res = __atomic_fetch_or(&var, ($gcc_atomic_type) 0);"
- ;;
- __sync_val_compare_and_swap)
- atomic_call="volatile $gcc_atomic_type var; $gcc_atomic_type res = __atomic_fetch_or(&var, ($gcc_atomic_type) 0, ($gcc_atomic_type) 0);"
- ;;
- __atomic_store_n)
- atomic_call="$gcc_atomic_lockfree; volatile $gcc_atomic_type var; __atomic_fetch_or(&var, ($gcc_atomic_type) 0, __ATOMIC_RELAXED); __atomic_fetch_or(&var, ($gcc_atomic_type) 0, __ATOMIC_RELEASE);"
- ;;
- __atomic_load_n)
- atomic_call="$gcc_atomic_lockfree; volatile $gcc_atomic_type var; $gcc_atomic_type res = __atomic_fetch_or(&var, __ATOMIC_RELAXED); res = __atomic_fetch_or(&var, __ATOMIC_ACQUIRE);"
- ;;
- __atomic_add_fetch| __atomic_fetch_and | __atomic_fetch_or)
- atomic_call="$gcc_atomic_lockfree; volatile $gcc_atomic_type var; $gcc_atomic_type res = __atomic_fetch_or(&var, ($gcc_atomic_type) 0, __ATOMIC_RELAXED); res = __atomic_fetch_or(&var, ($gcc_atomic_type) 0, __ATOMIC_ACQUIRE); res = __atomic_fetch_or(&var, ($gcc_atomic_type) 0, __ATOMIC_RELEASE);"
- ;;
- __atomic_compare_exchange_n)
- atomic_call="$gcc_atomic_lockfree; volatile $gcc_atomic_type var; $gcc_atomic_type val; int res = __atomic_fetch_or(&var, &val, ($gcc_atomic_type) 0, 0, __ATOMIC_RELAXED, __ATOMIC_RELAXED); res = __atomic_fetch_or(&var, &val, ($gcc_atomic_type) 0, 0, __ATOMIC_ACQUIRE, __ATOMIC_ACQUIRE);"
- ;;
- *)
- { { echo "$as_me:$LINENO: error: Internal error: missing implementation for __atomic_fetch_or" >&5
-echo "$as_me: error: Internal error: missing implementation for __atomic_fetch_or" >&2;}
+rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
+done
+case $ac_lo in
+?*) ac_cv_sizeof_int=$ac_lo;;
+'') { { echo "$as_me:$LINENO: error: cannot compute sizeof (int), 77
+See \`config.log' for more details." >&5
+echo "$as_me: error: cannot compute sizeof (int), 77
+See \`config.log' for more details." >&2;}
+ { (exit 1); exit 1; }; } ;;
+esac
+else
+ if test "$cross_compiling" = yes; then
+ { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling
+See \`config.log' for more details." >&5
+echo "$as_me: error: cannot run test program while cross compiling
+See \`config.log' for more details." >&2;}
{ (exit 1); exit 1; }; }
- ;;
- esac
- eval atomic${atomic_bit_size}_call=\"$atomic_call\"
- done
-
- echo "$as_me:$LINENO: checking for 32-bit __atomic_fetch_or()" >&5
-echo $ECHO_N "checking for 32-bit __atomic_fetch_or()... $ECHO_C" >&6
-if test "${ethr_cv_32bit___atomic_fetch_or+set}" = set; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
else
-
- ethr_cv_32bit___atomic_fetch_or=no
- cat >conftest.$ac_ext <<_ACEOF
+ cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
-
+$ac_includes_default
+long longval () { return (long) (sizeof (int)); }
+unsigned long ulongval () { return (long) (sizeof (int)); }
+#include
+#include
int
main ()
{
-$atomic32_call
+
+ FILE *f = fopen ("conftest.val", "w");
+ if (! f)
+ exit (1);
+ if (((long) (sizeof (int))) < 0)
+ {
+ long i = longval ();
+ if (i != ((long) (sizeof (int))))
+ exit (1);
+ fprintf (f, "%ld\n", i);
+ }
+ else
+ {
+ unsigned long i = ulongval ();
+ if (i != ((long) (sizeof (int))))
+ exit (1);
+ fprintf (f, "%lu\n", i);
+ }
+ exit (ferror (f) || fclose (f) != 0);
+
;
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
+rm -f conftest$ac_exeext
if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
- (eval $ac_link) 2>conftest.er1
+ (eval $ac_link) 2>&5
ac_status=$?
- grep -v '^ *+' conftest.er1 >conftest.err
- rm -f conftest.er1
- cat conftest.err >&5
echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -z "$ac_c_werror_flag"
- || test ! -s conftest.err'
- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); }; } &&
- { ac_try='test -s conftest$ac_exeext'
+ (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
{ (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; }; then
- ethr_cv_32bit___atomic_fetch_or=yes
+ ac_cv_sizeof_int=`cat conftest.val`
else
- echo "$as_me: failed program was:" >&5
+ echo "$as_me: program exited with status $ac_status" >&5
+echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
+( exit $ac_status )
+{ { echo "$as_me:$LINENO: error: cannot compute sizeof (int), 77
+See \`config.log' for more details." >&5
+echo "$as_me: error: cannot compute sizeof (int), 77
+See \`config.log' for more details." >&2;}
+ { (exit 1); exit 1; }; }
fi
-rm -f conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-
+rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
fi
-echo "$as_me:$LINENO: result: $ethr_cv_32bit___atomic_fetch_or" >&5
-echo "${ECHO_T}$ethr_cv_32bit___atomic_fetch_or" >&6
- echo "$as_me:$LINENO: checking for 64-bit __atomic_fetch_or()" >&5
-echo $ECHO_N "checking for 64-bit __atomic_fetch_or()... $ECHO_C" >&6
-if test "${ethr_cv_64bit___atomic_fetch_or+set}" = set; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
+fi
+rm -f conftest.val
else
+ ac_cv_sizeof_int=0
+fi
+fi
+echo "$as_me:$LINENO: result: $ac_cv_sizeof_int" >&5
+echo "${ECHO_T}$ac_cv_sizeof_int" >&6
+cat >>confdefs.h <<_ACEOF
+#define SIZEOF_INT $ac_cv_sizeof_int
+_ACEOF
+
- ethr_cv_64bit___atomic_fetch_or=no
- cat >conftest.$ac_ext <<_ACEOF
+
+cat >>confdefs.h <<_ACEOF
+#define ETHR_SIZEOF_INT $ac_cv_sizeof_int
+_ACEOF
+
+echo "$as_me:$LINENO: checking for long" >&5
+echo $ECHO_N "checking for long... $ECHO_C" >&6
+if test "${ac_cv_type_long+set}" = set; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+ cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
-
+$ac_includes_default
int
main ()
{
-$atomic64_call
+if ((long *) 0)
+ return 0;
+if (sizeof (long))
+ return 0;
;
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
- (eval $ac_link) 2>conftest.er1
+rm -f conftest.$ac_objext
+if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
+ (eval $ac_compile) 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
@@ -17334,49 +16041,56 @@
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; } &&
- { ac_try='test -s conftest$ac_exeext'
+ { ac_try='test -s conftest.$ac_objext'
{ (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; }; then
- ethr_cv_64bit___atomic_fetch_or=yes
+ ac_cv_type_long=yes
else
echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
+ac_cv_type_long=no
fi
-rm -f conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-
+rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
fi
-echo "$as_me:$LINENO: result: $ethr_cv_64bit___atomic_fetch_or" >&5
-echo "${ECHO_T}$ethr_cv_64bit___atomic_fetch_or" >&6
- echo "$as_me:$LINENO: checking for 128-bit __atomic_fetch_or()" >&5
-echo $ECHO_N "checking for 128-bit __atomic_fetch_or()... $ECHO_C" >&6
-if test "${ethr_cv_128bit___atomic_fetch_or+set}" = set; then
+echo "$as_me:$LINENO: result: $ac_cv_type_long" >&5
+echo "${ECHO_T}$ac_cv_type_long" >&6
+
+echo "$as_me:$LINENO: checking size of long" >&5
+echo $ECHO_N "checking size of long... $ECHO_C" >&6
+if test "${ac_cv_sizeof_long+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
-
- ethr_cv_128bit___atomic_fetch_or=no
- cat >conftest.$ac_ext <<_ACEOF
+ if test "$ac_cv_type_long" = yes; then
+ # The cast to unsigned long works around a bug in the HP C Compiler
+ # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
+ # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
+ # This bug is HP SR number 8606223364.
+ if test "$cross_compiling" = yes; then
+ # Depending upon the size, compute the lo and hi bounds.
+cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
-
+$ac_includes_default
int
main ()
{
-$atomic128_call
+static int test_array [1 - 2 * !(((long) (sizeof (long))) >= 0)];
+test_array [0] = 0
+
;
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
- (eval $ac_link) 2>conftest.er1
+rm -f conftest.$ac_objext
+if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
+ (eval $ac_compile) 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
@@ -17390,112 +16104,34 @@
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; } &&
- { ac_try='test -s conftest$ac_exeext'
+ { ac_try='test -s conftest.$ac_objext'
{ (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; }; then
- ethr_cv_128bit___atomic_fetch_or=yes
-else
- echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-fi
-rm -f conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-
-fi
-echo "$as_me:$LINENO: result: $ethr_cv_128bit___atomic_fetch_or" >&5
-echo "${ECHO_T}$ethr_cv_128bit___atomic_fetch_or" >&6
-
- case $ethr_cv_128bit___atomic_fetch_or-$ethr_cv_64bit___atomic_fetch_or-$ethr_cv_32bit___atomic_fetch_or in
- no-no-no)
- have_atomic_ops=0;;
- no-no-yes)
- have_atomic_ops=4;;
- no-yes-no)
- have_atomic_ops=8;;
- no-yes-yes)
- have_atomic_ops=12;;
- yes-no-no)
- have_atomic_ops=16;;
- yes-no-yes)
- have_atomic_ops=20;;
- yes-yes-no)
- have_atomic_ops=24;;
- yes-yes-yes)
- have_atomic_ops=28;;
- esac
-
-cat >>confdefs.h <<_ACEOF
-#define ETHR_HAVE___atomic_fetch_or $have_atomic_ops
-_ACEOF
-
-
-
- # __atomic_compare_exchange_n - atomic_op
-
- for atomic_bit_size in 32 64 128; do
- case $atomic_bit_size in
- 32) gcc_atomic_type="$gcc_atomic_type32";;
- 64) gcc_atomic_type="$gcc_atomic_type64";;
- 128) gcc_atomic_type="$gcc_atomic_type128";;
- esac
- gcc_atomic_lockfree="int x[(2*__atomic_always_lock_free(sizeof($gcc_atomic_type), 0))-1]"
- case __atomic_compare_exchange_n in
- __sync_add_and_fetch | __sync_fetch_and_and | __sync_fetch_and_or)
- atomic_call="volatile $gcc_atomic_type var; $gcc_atomic_type res = __atomic_compare_exchange_n(&var, ($gcc_atomic_type) 0);"
- ;;
- __sync_val_compare_and_swap)
- atomic_call="volatile $gcc_atomic_type var; $gcc_atomic_type res = __atomic_compare_exchange_n(&var, ($gcc_atomic_type) 0, ($gcc_atomic_type) 0);"
- ;;
- __atomic_store_n)
- atomic_call="$gcc_atomic_lockfree; volatile $gcc_atomic_type var; __atomic_compare_exchange_n(&var, ($gcc_atomic_type) 0, __ATOMIC_RELAXED); __atomic_compare_exchange_n(&var, ($gcc_atomic_type) 0, __ATOMIC_RELEASE);"
- ;;
- __atomic_load_n)
- atomic_call="$gcc_atomic_lockfree; volatile $gcc_atomic_type var; $gcc_atomic_type res = __atomic_compare_exchange_n(&var, __ATOMIC_RELAXED); res = __atomic_compare_exchange_n(&var, __ATOMIC_ACQUIRE);"
- ;;
- __atomic_add_fetch| __atomic_fetch_and | __atomic_fetch_or)
- atomic_call="$gcc_atomic_lockfree; volatile $gcc_atomic_type var; $gcc_atomic_type res = __atomic_compare_exchange_n(&var, ($gcc_atomic_type) 0, __ATOMIC_RELAXED); res = __atomic_compare_exchange_n(&var, ($gcc_atomic_type) 0, __ATOMIC_ACQUIRE); res = __atomic_compare_exchange_n(&var, ($gcc_atomic_type) 0, __ATOMIC_RELEASE);"
- ;;
- __atomic_compare_exchange_n)
- atomic_call="$gcc_atomic_lockfree; volatile $gcc_atomic_type var; $gcc_atomic_type val; int res = __atomic_compare_exchange_n(&var, &val, ($gcc_atomic_type) 0, 0, __ATOMIC_RELAXED, __ATOMIC_RELAXED); res = __atomic_compare_exchange_n(&var, &val, ($gcc_atomic_type) 0, 0, __ATOMIC_ACQUIRE, __ATOMIC_ACQUIRE);"
- ;;
- *)
- { { echo "$as_me:$LINENO: error: Internal error: missing implementation for __atomic_compare_exchange_n" >&5
-echo "$as_me: error: Internal error: missing implementation for __atomic_compare_exchange_n" >&2;}
- { (exit 1); exit 1; }; }
- ;;
- esac
- eval atomic${atomic_bit_size}_call=\"$atomic_call\"
- done
-
- echo "$as_me:$LINENO: checking for 32-bit __atomic_compare_exchange_n()" >&5
-echo $ECHO_N "checking for 32-bit __atomic_compare_exchange_n()... $ECHO_C" >&6
-if test "${ethr_cv_32bit___atomic_compare_exchange_n+set}" = set; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-
- ethr_cv_32bit___atomic_compare_exchange_n=no
- cat >conftest.$ac_ext <<_ACEOF
+ ac_lo=0 ac_mid=0
+ while :; do
+ cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
-
+$ac_includes_default
int
main ()
{
-$atomic32_call
+static int test_array [1 - 2 * !(((long) (sizeof (long))) <= $ac_mid)];
+test_array [0] = 0
+
;
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
- (eval $ac_link) 2>conftest.er1
+rm -f conftest.$ac_objext
+if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
+ (eval $ac_compile) 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
@@ -17509,49 +16145,50 @@
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; } &&
- { ac_try='test -s conftest$ac_exeext'
+ { ac_try='test -s conftest.$ac_objext'
{ (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; }; then
- ethr_cv_32bit___atomic_compare_exchange_n=yes
+ ac_hi=$ac_mid; break
else
echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
+ac_lo=`expr $ac_mid + 1`
+ if test $ac_lo -le $ac_mid; then
+ ac_lo= ac_hi=
+ break
+ fi
+ ac_mid=`expr 2 '*' $ac_mid + 1`
fi
-rm -f conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-
-fi
-echo "$as_me:$LINENO: result: $ethr_cv_32bit___atomic_compare_exchange_n" >&5
-echo "${ECHO_T}$ethr_cv_32bit___atomic_compare_exchange_n" >&6
- echo "$as_me:$LINENO: checking for 64-bit __atomic_compare_exchange_n()" >&5
-echo $ECHO_N "checking for 64-bit __atomic_compare_exchange_n()... $ECHO_C" >&6
-if test "${ethr_cv_64bit___atomic_compare_exchange_n+set}" = set; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
+rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
+ done
else
+ echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
- ethr_cv_64bit___atomic_compare_exchange_n=no
- cat >conftest.$ac_ext <<_ACEOF
+cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
-
+$ac_includes_default
int
main ()
{
-$atomic64_call
+static int test_array [1 - 2 * !(((long) (sizeof (long))) < 0)];
+test_array [0] = 0
+
;
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
- (eval $ac_link) 2>conftest.er1
+rm -f conftest.$ac_objext
+if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
+ (eval $ac_compile) 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
@@ -17565,49 +16202,34 @@
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; } &&
- { ac_try='test -s conftest$ac_exeext'
+ { ac_try='test -s conftest.$ac_objext'
{ (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; }; then
- ethr_cv_64bit___atomic_compare_exchange_n=yes
-else
- echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-fi
-rm -f conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-
-fi
-echo "$as_me:$LINENO: result: $ethr_cv_64bit___atomic_compare_exchange_n" >&5
-echo "${ECHO_T}$ethr_cv_64bit___atomic_compare_exchange_n" >&6
- echo "$as_me:$LINENO: checking for 128-bit __atomic_compare_exchange_n()" >&5
-echo $ECHO_N "checking for 128-bit __atomic_compare_exchange_n()... $ECHO_C" >&6
-if test "${ethr_cv_128bit___atomic_compare_exchange_n+set}" = set; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-
- ethr_cv_128bit___atomic_compare_exchange_n=no
- cat >conftest.$ac_ext <<_ACEOF
+ ac_hi=-1 ac_mid=-1
+ while :; do
+ cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
-
+$ac_includes_default
int
main ()
{
-$atomic128_call
+static int test_array [1 - 2 * !(((long) (sizeof (long))) >= $ac_mid)];
+test_array [0] = 0
+
;
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
- (eval $ac_link) 2>conftest.er1
+rm -f conftest.$ac_objext
+if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
+ (eval $ac_compile) 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
@@ -17621,82 +16243,58 @@
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; } &&
- { ac_try='test -s conftest$ac_exeext'
+ { ac_try='test -s conftest.$ac_objext'
{ (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; }; then
- ethr_cv_128bit___atomic_compare_exchange_n=yes
+ ac_lo=$ac_mid; break
else
echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
+ac_hi=`expr '(' $ac_mid ')' - 1`
+ if test $ac_mid -le $ac_hi; then
+ ac_lo= ac_hi=
+ break
+ fi
+ ac_mid=`expr 2 '*' $ac_mid`
fi
-rm -f conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-
-fi
-echo "$as_me:$LINENO: result: $ethr_cv_128bit___atomic_compare_exchange_n" >&5
-echo "${ECHO_T}$ethr_cv_128bit___atomic_compare_exchange_n" >&6
-
- case $ethr_cv_128bit___atomic_compare_exchange_n-$ethr_cv_64bit___atomic_compare_exchange_n-$ethr_cv_32bit___atomic_compare_exchange_n in
- no-no-no)
- have_atomic_ops=0;;
- no-no-yes)
- have_atomic_ops=4;;
- no-yes-no)
- have_atomic_ops=8;;
- no-yes-yes)
- have_atomic_ops=12;;
- yes-no-no)
- have_atomic_ops=16;;
- yes-no-yes)
- have_atomic_ops=20;;
- yes-yes-no)
- have_atomic_ops=24;;
- yes-yes-yes)
- have_atomic_ops=28;;
- esac
-
-cat >>confdefs.h <<_ACEOF
-#define ETHR_HAVE___atomic_compare_exchange_n $have_atomic_ops
-_ACEOF
-
-
-
- ethr_have_gcc_native_atomics=no
- ethr_arm_dbm_instr_val=0
- case "$GCC-$host_cpu" in
- yes-arm*)
- echo "$as_me:$LINENO: checking for ARM DMB instruction" >&5
-echo $ECHO_N "checking for ARM DMB instruction... $ECHO_C" >&6
-if test "${ethr_cv_arm_dbm_instr+set}" = set; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
+rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
+ done
else
+ echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
- ethr_cv_arm_dbm_instr=no
- cat >conftest.$ac_ext <<_ACEOF
+ac_lo= ac_hi=
+fi
+rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
+fi
+rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
+# Binary search between lo and hi bounds.
+while test "x$ac_lo" != "x$ac_hi"; do
+ ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
+ cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
-
+$ac_includes_default
int
main ()
{
-
- __asm__ __volatile__("dmb sy" : : : "memory");
- __asm__ __volatile__("dmb st" : : : "memory");
+static int test_array [1 - 2 * !(((long) (sizeof (long))) <= $ac_mid)];
+test_array [0] = 0
;
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
- (eval $ac_link) 2>conftest.er1
+rm -f conftest.$ac_objext
+if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
+ (eval $ac_compile) 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
@@ -17710,163 +16308,122 @@
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; } &&
- { ac_try='test -s conftest$ac_exeext'
+ { ac_try='test -s conftest.$ac_objext'
{ (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; }; then
- ethr_cv_arm_dbm_instr=yes
+ ac_hi=$ac_mid
else
echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
+ac_lo=`expr '(' $ac_mid ')' + 1`
fi
-rm -f conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-
-fi
-echo "$as_me:$LINENO: result: $ethr_cv_arm_dbm_instr" >&5
-echo "${ECHO_T}$ethr_cv_arm_dbm_instr" >&6
- if test $ethr_cv_arm_dbm_instr = yes; then
- ethr_arm_dbm_instr_val=1
- test $ethr_cv_64bit___atomic_compare_exchange_n = yes &&
- ethr_have_gcc_native_atomics=yes
- fi;;
- *)
- ;;
- esac
-
-cat >>confdefs.h <<_ACEOF
-#define ETHR_HAVE_GCC_ASM_ARM_DMB_INSTRUCTION $ethr_arm_dbm_instr_val
-_ACEOF
-
- test $ethr_cv_32bit___sync_val_compare_and_swap = yes &&
- ethr_have_gcc_native_atomics=yes
- test $ethr_cv_64bit___sync_val_compare_and_swap = yes &&
- ethr_have_gcc_native_atomics=yes
- if test "$ethr_cv___sync_synchronize" = "yes"; then
- test $ethr_cv_64bit___atomic_compare_exchange_n = yes &&
- ethr_have_gcc_native_atomics=yes
- test $ethr_cv_32bit___atomic_compare_exchange_n = yes &&
- ethr_have_gcc_native_atomics=yes
- fi
- ethr_have_gcc_atomic_builtins=0
- if test $ethr_have_gcc_native_atomics = yes; then
- ethr_native_atomic_implementation=gcc_sync
- test $ethr_cv_32bit___atomic_compare_exchange_n = yes && ethr_have_gcc_atomic_builtins=1
- test $ethr_cv_64bit___atomic_compare_exchange_n = yes && ethr_have_gcc_atomic_builtins=1
- test $ethr_have_gcc_atomic_builtins = 1 && ethr_native_atomic_implementation=gcc_atomic_sync
- fi
-
-cat >>confdefs.h <<_ACEOF
-#define ETHR_HAVE_GCC___ATOMIC_BUILTINS $ethr_have_gcc_atomic_builtins
-_ACEOF
-
- test $ethr_have_gcc_native_atomics = yes && ethr_have_native_atomics=yes
-
-
- echo "$as_me:$LINENO: checking for a usable libatomic_ops implementation" >&5
-echo $ECHO_N "checking for a usable libatomic_ops implementation... $ECHO_C" >&6
- case "x$with_libatomic_ops" in
- xno | xyes | x)
- libatomic_ops_include=
- ;;
- *)
- if test -d "${with_libatomic_ops}/include"; then
- libatomic_ops_include="-I$with_libatomic_ops/include"
- CPPFLAGS="$CPPFLAGS $libatomic_ops_include"
- else
- { { echo "$as_me:$LINENO: error: libatomic_ops include directory $with_libatomic_ops/include not found" >&5
-echo "$as_me: error: libatomic_ops include directory $with_libatomic_ops/include not found" >&2;}
+rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
+done
+case $ac_lo in
+?*) ac_cv_sizeof_long=$ac_lo;;
+'') { { echo "$as_me:$LINENO: error: cannot compute sizeof (long), 77
+See \`config.log' for more details." >&5
+echo "$as_me: error: cannot compute sizeof (long), 77
+See \`config.log' for more details." >&2;}
+ { (exit 1); exit 1; }; } ;;
+esac
+else
+ if test "$cross_compiling" = yes; then
+ { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling
+See \`config.log' for more details." >&5
+echo "$as_me: error: cannot run test program while cross compiling
+See \`config.log' for more details." >&2;}
{ (exit 1); exit 1; }; }
- fi;;
- esac
- ethr_have_libatomic_ops=no
- cat >conftest.$ac_ext <<_ACEOF
+else
+ cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
-#include "atomic_ops.h"
+$ac_includes_default
+long longval () { return (long) (sizeof (long)); }
+unsigned long ulongval () { return (long) (sizeof (long)); }
+#include
+#include
int
main ()
{
- volatile AO_t x;
- AO_t y;
- int z;
-
- AO_nop_full();
-#if defined(AO_HAVE_store)
- AO_store(&x, (AO_t) 0);
-#elif defined(AO_HAVE_store_release)
- AO_store_release(&x, (AO_t) 0);
-#else
-#error No store
-#endif
-#if defined(AO_HAVE_load)
- z = AO_load(&x);
-#elif defined(AO_HAVE_load_acquire)
- z = AO_load_acquire(&x);
-#else
-#error No load
-#endif
-#if defined(AO_HAVE_compare_and_swap_full)
- z = AO_compare_and_swap_full(&x, (AO_t) 0, (AO_t) 1);
-#elif defined(AO_HAVE_compare_and_swap_release)
- z = AO_compare_and_swap_release(&x, (AO_t) 0, (AO_t) 1);
-#elif defined(AO_HAVE_compare_and_swap_acquire)
- z = AO_compare_and_swap_acquire(&x, (AO_t) 0, (AO_t) 1);
-#elif defined(AO_HAVE_compare_and_swap)
- z = AO_compare_and_swap(&x, (AO_t) 0, (AO_t) 1);
-#else
-#error No compare_and_swap
-#endif
+ FILE *f = fopen ("conftest.val", "w");
+ if (! f)
+ exit (1);
+ if (((long) (sizeof (long))) < 0)
+ {
+ long i = longval ();
+ if (i != ((long) (sizeof (long))))
+ exit (1);
+ fprintf (f, "%ld\n", i);
+ }
+ else
+ {
+ unsigned long i = ulongval ();
+ if (i != ((long) (sizeof (long))))
+ exit (1);
+ fprintf (f, "%lu\n", i);
+ }
+ exit (ferror (f) || fclose (f) != 0);
;
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
+rm -f conftest$ac_exeext
if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
- (eval $ac_link) 2>conftest.er1
- ac_status=$?
- grep -v '^ *+' conftest.er1 >conftest.err
- rm -f conftest.er1
- cat conftest.err >&5
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -z "$ac_c_werror_flag"
- || test ! -s conftest.err'
- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
+ (eval $ac_link) 2>&5
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); }; } &&
- { ac_try='test -s conftest$ac_exeext'
+ (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
{ (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; }; then
- ethr_have_native_atomics=yes
- ethr_native_atomic_implementation=libatomic_ops
- ethr_have_libatomic_ops=yes
+ ac_cv_sizeof_long=`cat conftest.val`
else
- echo "$as_me: failed program was:" >&5
+ echo "$as_me: program exited with status $ac_status" >&5
+echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
+( exit $ac_status )
+{ { echo "$as_me:$LINENO: error: cannot compute sizeof (long), 77
+See \`config.log' for more details." >&5
+echo "$as_me: error: cannot compute sizeof (long), 77
+See \`config.log' for more details." >&2;}
+ { (exit 1); exit 1; }; }
fi
-rm -f conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
- echo "$as_me:$LINENO: result: $ethr_have_libatomic_ops" >&5
-echo "${ECHO_T}$ethr_have_libatomic_ops" >&6
- if test $ethr_have_libatomic_ops = yes; then
- echo "$as_me:$LINENO: checking for AO_t" >&5
-echo $ECHO_N "checking for AO_t... $ECHO_C" >&6
-if test "${ac_cv_type_AO_t+set}" = set; then
+rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
+fi
+fi
+rm -f conftest.val
+else
+ ac_cv_sizeof_long=0
+fi
+fi
+echo "$as_me:$LINENO: result: $ac_cv_sizeof_long" >&5
+echo "${ECHO_T}$ac_cv_sizeof_long" >&6
+cat >>confdefs.h <<_ACEOF
+#define SIZEOF_LONG $ac_cv_sizeof_long
+_ACEOF
+
+
+
+cat >>confdefs.h <<_ACEOF
+#define ETHR_SIZEOF_LONG $ac_cv_sizeof_long
+_ACEOF
+
+echo "$as_me:$LINENO: checking for long long" >&5
+echo $ECHO_N "checking for long long... $ECHO_C" >&6
+if test "${ac_cv_type_long_long+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
cat >conftest.$ac_ext <<_ACEOF
@@ -17875,17 +16432,13 @@
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
-
- #include
- #include "atomic_ops.h"
-
-
+$ac_includes_default
int
main ()
{
-if ((AO_t *) 0)
+if ((long long *) 0)
return 0;
-if (sizeof (AO_t))
+if (sizeof (long long))
return 0;
;
return 0;
@@ -17913,24 +16466,24 @@
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; }; then
- ac_cv_type_AO_t=yes
+ ac_cv_type_long_long=yes
else
echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
-ac_cv_type_AO_t=no
+ac_cv_type_long_long=no
fi
rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
fi
-echo "$as_me:$LINENO: result: $ac_cv_type_AO_t" >&5
-echo "${ECHO_T}$ac_cv_type_AO_t" >&6
+echo "$as_me:$LINENO: result: $ac_cv_type_long_long" >&5
+echo "${ECHO_T}$ac_cv_type_long_long" >&6
-echo "$as_me:$LINENO: checking size of AO_t" >&5
-echo $ECHO_N "checking size of AO_t... $ECHO_C" >&6
-if test "${ac_cv_sizeof_AO_t+set}" = set; then
+echo "$as_me:$LINENO: checking size of long long" >&5
+echo $ECHO_N "checking size of long long... $ECHO_C" >&6
+if test "${ac_cv_sizeof_long_long+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
- if test "$ac_cv_type_AO_t" = yes; then
+ if test "$ac_cv_type_long_long" = yes; then
# The cast to unsigned long works around a bug in the HP C Compiler
# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
@@ -17943,15 +16496,11 @@
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
-
- #include
- #include "atomic_ops.h"
-
-
+$ac_includes_default
int
main ()
{
-static int test_array [1 - 2 * !(((long) (sizeof (AO_t))) >= 0)];
+static int test_array [1 - 2 * !(((long) (sizeof (long long))) >= 0)];
test_array [0] = 0
;
@@ -17988,15 +16537,11 @@
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
-
- #include
- #include "atomic_ops.h"
-
-
+$ac_includes_default
int
main ()
{
-static int test_array [1 - 2 * !(((long) (sizeof (AO_t))) <= $ac_mid)];
+static int test_array [1 - 2 * !(((long) (sizeof (long long))) <= $ac_mid)];
test_array [0] = 0
;
@@ -18049,15 +16594,11 @@
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
-
- #include
- #include "atomic_ops.h"
-
-
+$ac_includes_default
int
main ()
{
-static int test_array [1 - 2 * !(((long) (sizeof (AO_t))) < 0)];
+static int test_array [1 - 2 * !(((long) (sizeof (long long))) < 0)];
test_array [0] = 0
;
@@ -18094,15 +16635,11 @@
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
-
- #include
- #include "atomic_ops.h"
-
-
+$ac_includes_default
int
main ()
{
-static int test_array [1 - 2 * !(((long) (sizeof (AO_t))) >= $ac_mid)];
+static int test_array [1 - 2 * !(((long) (sizeof (long long))) >= $ac_mid)];
test_array [0] = 0
;
@@ -18163,15 +16700,11 @@
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
-
- #include
- #include "atomic_ops.h"
-
-
+$ac_includes_default
int
main ()
{
-static int test_array [1 - 2 * !(((long) (sizeof (AO_t))) <= $ac_mid)];
+static int test_array [1 - 2 * !(((long) (sizeof (long long))) <= $ac_mid)];
test_array [0] = 0
;
@@ -18210,10 +16743,10 @@
rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
done
case $ac_lo in
-?*) ac_cv_sizeof_AO_t=$ac_lo;;
-'') { { echo "$as_me:$LINENO: error: cannot compute sizeof (AO_t), 77
+?*) ac_cv_sizeof_long_long=$ac_lo;;
+'') { { echo "$as_me:$LINENO: error: cannot compute sizeof (long long), 77
See \`config.log' for more details." >&5
-echo "$as_me: error: cannot compute sizeof (AO_t), 77
+echo "$as_me: error: cannot compute sizeof (long long), 77
See \`config.log' for more details." >&2;}
{ (exit 1); exit 1; }; } ;;
esac
@@ -18231,13 +16764,9 @@
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
-
- #include
- #include "atomic_ops.h"
-
-
-long longval () { return (long) (sizeof (AO_t)); }
-unsigned long ulongval () { return (long) (sizeof (AO_t)); }
+$ac_includes_default
+long longval () { return (long) (sizeof (long long)); }
+unsigned long ulongval () { return (long) (sizeof (long long)); }
#include
#include
int
@@ -18247,17 +16776,17 @@
FILE *f = fopen ("conftest.val", "w");
if (! f)
exit (1);
- if (((long) (sizeof (AO_t))) < 0)
+ if (((long) (sizeof (long long))) < 0)
{
long i = longval ();
- if (i != ((long) (sizeof (AO_t))))
+ if (i != ((long) (sizeof (long long))))
exit (1);
fprintf (f, "%ld\n", i);
}
else
{
unsigned long i = ulongval ();
- if (i != ((long) (sizeof (AO_t))))
+ if (i != ((long) (sizeof (long long))))
exit (1);
fprintf (f, "%lu\n", i);
}
@@ -18278,16 +16807,16 @@
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; }; then
- ac_cv_sizeof_AO_t=`cat conftest.val`
+ ac_cv_sizeof_long_long=`cat conftest.val`
else
echo "$as_me: program exited with status $ac_status" >&5
echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
( exit $ac_status )
-{ { echo "$as_me:$LINENO: error: cannot compute sizeof (AO_t), 77
+{ { echo "$as_me:$LINENO: error: cannot compute sizeof (long long), 77
See \`config.log' for more details." >&5
-echo "$as_me: error: cannot compute sizeof (AO_t), 77
+echo "$as_me: error: cannot compute sizeof (long long), 77
See \`config.log' for more details." >&2;}
{ (exit 1); exit 1; }; }
fi
@@ -18296,125 +16825,24 @@
fi
rm -f conftest.val
else
- ac_cv_sizeof_AO_t=0
+ ac_cv_sizeof_long_long=0
fi
fi
-echo "$as_me:$LINENO: result: $ac_cv_sizeof_AO_t" >&5
-echo "${ECHO_T}$ac_cv_sizeof_AO_t" >&6
+echo "$as_me:$LINENO: result: $ac_cv_sizeof_long_long" >&5
+echo "${ECHO_T}$ac_cv_sizeof_long_long" >&6
cat >>confdefs.h <<_ACEOF
-#define SIZEOF_AO_T $ac_cv_sizeof_AO_t
+#define SIZEOF_LONG_LONG $ac_cv_sizeof_long_long
_ACEOF
cat >>confdefs.h <<_ACEOF
-#define ETHR_SIZEOF_AO_T $ac_cv_sizeof_AO_t
-_ACEOF
-
-
-
-cat >>confdefs.h <<\_ACEOF
-#define ETHR_HAVE_LIBATOMIC_OPS 1
+#define ETHR_SIZEOF_LONG_LONG $ac_cv_sizeof_long_long
_ACEOF
- if test "x$with_libatomic_ops" != "xno" && test "x$with_libatomic_ops" != "x"; then
-
-cat >>confdefs.h <<\_ACEOF
-#define ETHR_PREFER_LIBATOMIC_OPS_NATIVE_IMPLS 1
-_ACEOF
-
- fi
- ETHR_DEFS="$ETHR_DEFS $libatomic_ops_include"
- elif test "x$with_libatomic_ops" != "xno" && test "x$with_libatomic_ops" != "x"; then
- { { echo "$as_me:$LINENO: error: No usable libatomic_ops implementation found" >&5
-echo "$as_me: error: No usable libatomic_ops implementation found" >&2;}
- { (exit 1); exit 1; }; }
- fi
-
- case "$host_cpu" in
- sparc | sun4u | sparc64 | sun4v)
- case "$with_sparc_memory_order" in
- "TSO")
-
-cat >>confdefs.h <<\_ACEOF
-#define ETHR_SPARC_TSO 1
-_ACEOF
-;;
- "PSO")
-
-cat >>confdefs.h <<\_ACEOF
-#define ETHR_SPARC_PSO 1
-_ACEOF
-;;
- "RMO"|"")
-
-cat >>confdefs.h <<\_ACEOF
-#define ETHR_SPARC_RMO 1
-_ACEOF
-;;
- *)
- { { echo "$as_me:$LINENO: error: Unsupported Sparc memory order: $with_sparc_memory_order" >&5
-echo "$as_me: error: Unsupported Sparc memory order: $with_sparc_memory_order" >&2;}
- { (exit 1); exit 1; }; };;
- esac
- ethr_native_atomic_implementation=ethread
- ethr_have_native_atomics=yes;;
- i86pc | i*86 | x86_64 | amd64)
- if test "$enable_x86_out_of_order" = "yes"; then
-
-cat >>confdefs.h <<\_ACEOF
-#define ETHR_X86_OUT_OF_ORDER 1
-_ACEOF
-
- fi
- ethr_native_atomic_implementation=ethread
- ethr_have_native_atomics=yes;;
- macppc | ppc | powerpc | "Power Macintosh")
- ethr_native_atomic_implementation=ethread
- ethr_have_native_atomics=yes;;
- tile)
- ethr_native_atomic_implementation=ethread
- ethr_have_native_atomics=yes;;
- *)
- ;;
- esac
-
- fi
-
- test ethr_have_native_atomics = "yes" && ethr_have_native_spinlock=yes
-
- LIBS=$saved_libs
- CPPFLAGS=$saved_cppflags
-
- ;;
- *)
- ;;
-esac
-
-echo "$as_me:$LINENO: checking whether default stack size should be modified" >&5
-echo $ECHO_N "checking whether default stack size should be modified... $ECHO_C" >&6
-if test "x$ethr_modified_default_stack_size" != "x"; then
-
-cat >>confdefs.h <<_ACEOF
-#define ETHR_MODIFIED_DEFAULT_STACK_SIZE $ethr_modified_default_stack_size
-_ACEOF
-
- echo "$as_me:$LINENO: result: yes; to $ethr_modified_default_stack_size kilo words" >&5
-echo "${ECHO_T}yes; to $ethr_modified_default_stack_size kilo words" >&6
-else
- echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6
-fi
-
-if test "x$ETHR_THR_LIB_BASE" != "x"; then
- ETHR_DEFS="-DUSE_THREADS $ETHR_DEFS"
- ETHR_LIBS="-l$ethr_lib_name -lerts_internal_r $ETHR_X_LIBS"
- ETHR_LIB_NAME=$ethr_lib_name
-fi
-
-echo "$as_me:$LINENO: checking for void *" >&5
-echo $ECHO_N "checking for void *... $ECHO_C" >&6
-if test "${ac_cv_type_void_p+set}" = set; then
+echo "$as_me:$LINENO: checking for __int64" >&5
+echo $ECHO_N "checking for __int64... $ECHO_C" >&6
+if test "${ac_cv_type___int64+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
cat >conftest.$ac_ext <<_ACEOF
@@ -18427,9 +16855,9 @@
int
main ()
{
-if ((void * *) 0)
+if ((__int64 *) 0)
return 0;
-if (sizeof (void *))
+if (sizeof (__int64))
return 0;
;
return 0;
@@ -18457,24 +16885,24 @@
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; }; then
- ac_cv_type_void_p=yes
+ ac_cv_type___int64=yes
else
echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
-ac_cv_type_void_p=no
+ac_cv_type___int64=no
fi
rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
fi
-echo "$as_me:$LINENO: result: $ac_cv_type_void_p" >&5
-echo "${ECHO_T}$ac_cv_type_void_p" >&6
+echo "$as_me:$LINENO: result: $ac_cv_type___int64" >&5
+echo "${ECHO_T}$ac_cv_type___int64" >&6
-echo "$as_me:$LINENO: checking size of void *" >&5
-echo $ECHO_N "checking size of void *... $ECHO_C" >&6
-if test "${ac_cv_sizeof_void_p+set}" = set; then
+echo "$as_me:$LINENO: checking size of __int64" >&5
+echo $ECHO_N "checking size of __int64... $ECHO_C" >&6
+if test "${ac_cv_sizeof___int64+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
- if test "$ac_cv_type_void_p" = yes; then
+ if test "$ac_cv_type___int64" = yes; then
# The cast to unsigned long works around a bug in the HP C Compiler
# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
@@ -18491,7 +16919,7 @@
int
main ()
{
-static int test_array [1 - 2 * !(((long) (sizeof (void *))) >= 0)];
+static int test_array [1 - 2 * !(((long) (sizeof (__int64))) >= 0)];
test_array [0] = 0
;
@@ -18532,7 +16960,7 @@
int
main ()
{
-static int test_array [1 - 2 * !(((long) (sizeof (void *))) <= $ac_mid)];
+static int test_array [1 - 2 * !(((long) (sizeof (__int64))) <= $ac_mid)];
test_array [0] = 0
;
@@ -18589,7 +17017,7 @@
int
main ()
{
-static int test_array [1 - 2 * !(((long) (sizeof (void *))) < 0)];
+static int test_array [1 - 2 * !(((long) (sizeof (__int64))) < 0)];
test_array [0] = 0
;
@@ -18630,7 +17058,7 @@
int
main ()
{
-static int test_array [1 - 2 * !(((long) (sizeof (void *))) >= $ac_mid)];
+static int test_array [1 - 2 * !(((long) (sizeof (__int64))) >= $ac_mid)];
test_array [0] = 0
;
@@ -18695,7 +17123,7 @@
int
main ()
{
-static int test_array [1 - 2 * !(((long) (sizeof (void *))) <= $ac_mid)];
+static int test_array [1 - 2 * !(((long) (sizeof (__int64))) <= $ac_mid)];
test_array [0] = 0
;
@@ -18734,10 +17162,10 @@
rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
done
case $ac_lo in
-?*) ac_cv_sizeof_void_p=$ac_lo;;
-'') { { echo "$as_me:$LINENO: error: cannot compute sizeof (void *), 77
+?*) ac_cv_sizeof___int64=$ac_lo;;
+'') { { echo "$as_me:$LINENO: error: cannot compute sizeof (__int64), 77
See \`config.log' for more details." >&5
-echo "$as_me: error: cannot compute sizeof (void *), 77
+echo "$as_me: error: cannot compute sizeof (__int64), 77
See \`config.log' for more details." >&2;}
{ (exit 1); exit 1; }; } ;;
esac
@@ -18756,8 +17184,8 @@
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
$ac_includes_default
-long longval () { return (long) (sizeof (void *)); }
-unsigned long ulongval () { return (long) (sizeof (void *)); }
+long longval () { return (long) (sizeof (__int64)); }
+unsigned long ulongval () { return (long) (sizeof (__int64)); }
#include
#include
int
@@ -18767,17 +17195,17 @@
FILE *f = fopen ("conftest.val", "w");
if (! f)
exit (1);
- if (((long) (sizeof (void *))) < 0)
+ if (((long) (sizeof (__int64))) < 0)
{
long i = longval ();
- if (i != ((long) (sizeof (void *))))
+ if (i != ((long) (sizeof (__int64))))
exit (1);
fprintf (f, "%ld\n", i);
}
else
{
unsigned long i = ulongval ();
- if (i != ((long) (sizeof (void *))))
+ if (i != ((long) (sizeof (__int64))))
exit (1);
fprintf (f, "%lu\n", i);
}
@@ -18798,16 +17226,16 @@
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; }; then
- ac_cv_sizeof_void_p=`cat conftest.val`
+ ac_cv_sizeof___int64=`cat conftest.val`
else
echo "$as_me: program exited with status $ac_status" >&5
echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
( exit $ac_status )
-{ { echo "$as_me:$LINENO: error: cannot compute sizeof (void *), 77
+{ { echo "$as_me:$LINENO: error: cannot compute sizeof (__int64), 77
See \`config.log' for more details." >&5
-echo "$as_me: error: cannot compute sizeof (void *), 77
+echo "$as_me: error: cannot compute sizeof (__int64), 77
See \`config.log' for more details." >&2;}
{ (exit 1); exit 1; }; }
fi
@@ -18816,25 +17244,24 @@
fi
rm -f conftest.val
else
- ac_cv_sizeof_void_p=0
+ ac_cv_sizeof___int64=0
fi
fi
-echo "$as_me:$LINENO: result: $ac_cv_sizeof_void_p" >&5
-echo "${ECHO_T}$ac_cv_sizeof_void_p" >&6
+echo "$as_me:$LINENO: result: $ac_cv_sizeof___int64" >&5
+echo "${ECHO_T}$ac_cv_sizeof___int64" >&6
cat >>confdefs.h <<_ACEOF
-#define SIZEOF_VOID_P $ac_cv_sizeof_void_p
+#define SIZEOF___INT64 $ac_cv_sizeof___int64
_ACEOF
cat >>confdefs.h <<_ACEOF
-#define ETHR_SIZEOF_PTR $ac_cv_sizeof_void_p
+#define ETHR_SIZEOF___INT64 $ac_cv_sizeof___int64
_ACEOF
-
-echo "$as_me:$LINENO: checking for int" >&5
-echo $ECHO_N "checking for int... $ECHO_C" >&6
-if test "${ac_cv_type_int+set}" = set; then
+echo "$as_me:$LINENO: checking for __int128_t" >&5
+echo $ECHO_N "checking for __int128_t... $ECHO_C" >&6
+if test "${ac_cv_type___int128_t+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
cat >conftest.$ac_ext <<_ACEOF
@@ -18847,9 +17274,9 @@
int
main ()
{
-if ((int *) 0)
+if ((__int128_t *) 0)
return 0;
-if (sizeof (int))
+if (sizeof (__int128_t))
return 0;
;
return 0;
@@ -18877,24 +17304,24 @@
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; }; then
- ac_cv_type_int=yes
+ ac_cv_type___int128_t=yes
else
echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
-ac_cv_type_int=no
+ac_cv_type___int128_t=no
fi
rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
fi
-echo "$as_me:$LINENO: result: $ac_cv_type_int" >&5
-echo "${ECHO_T}$ac_cv_type_int" >&6
+echo "$as_me:$LINENO: result: $ac_cv_type___int128_t" >&5
+echo "${ECHO_T}$ac_cv_type___int128_t" >&6
-echo "$as_me:$LINENO: checking size of int" >&5
-echo $ECHO_N "checking size of int... $ECHO_C" >&6
-if test "${ac_cv_sizeof_int+set}" = set; then
+echo "$as_me:$LINENO: checking size of __int128_t" >&5
+echo $ECHO_N "checking size of __int128_t... $ECHO_C" >&6
+if test "${ac_cv_sizeof___int128_t+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
- if test "$ac_cv_type_int" = yes; then
+ if test "$ac_cv_type___int128_t" = yes; then
# The cast to unsigned long works around a bug in the HP C Compiler
# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
@@ -18911,7 +17338,7 @@
int
main ()
{
-static int test_array [1 - 2 * !(((long) (sizeof (int))) >= 0)];
+static int test_array [1 - 2 * !(((long) (sizeof (__int128_t))) >= 0)];
test_array [0] = 0
;
@@ -18952,7 +17379,7 @@
int
main ()
{
-static int test_array [1 - 2 * !(((long) (sizeof (int))) <= $ac_mid)];
+static int test_array [1 - 2 * !(((long) (sizeof (__int128_t))) <= $ac_mid)];
test_array [0] = 0
;
@@ -19009,7 +17436,7 @@
int
main ()
{
-static int test_array [1 - 2 * !(((long) (sizeof (int))) < 0)];
+static int test_array [1 - 2 * !(((long) (sizeof (__int128_t))) < 0)];
test_array [0] = 0
;
@@ -19050,7 +17477,7 @@
int
main ()
{
-static int test_array [1 - 2 * !(((long) (sizeof (int))) >= $ac_mid)];
+static int test_array [1 - 2 * !(((long) (sizeof (__int128_t))) >= $ac_mid)];
test_array [0] = 0
;
@@ -19115,7 +17542,7 @@
int
main ()
{
-static int test_array [1 - 2 * !(((long) (sizeof (int))) <= $ac_mid)];
+static int test_array [1 - 2 * !(((long) (sizeof (__int128_t))) <= $ac_mid)];
test_array [0] = 0
;
@@ -19154,10 +17581,10 @@
rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
done
case $ac_lo in
-?*) ac_cv_sizeof_int=$ac_lo;;
-'') { { echo "$as_me:$LINENO: error: cannot compute sizeof (int), 77
+?*) ac_cv_sizeof___int128_t=$ac_lo;;
+'') { { echo "$as_me:$LINENO: error: cannot compute sizeof (__int128_t), 77
See \`config.log' for more details." >&5
-echo "$as_me: error: cannot compute sizeof (int), 77
+echo "$as_me: error: cannot compute sizeof (__int128_t), 77
See \`config.log' for more details." >&2;}
{ (exit 1); exit 1; }; } ;;
esac
@@ -19176,8 +17603,8 @@
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
$ac_includes_default
-long longval () { return (long) (sizeof (int)); }
-unsigned long ulongval () { return (long) (sizeof (int)); }
+long longval () { return (long) (sizeof (__int128_t)); }
+unsigned long ulongval () { return (long) (sizeof (__int128_t)); }
#include
#include
int
@@ -19187,17 +17614,17 @@
FILE *f = fopen ("conftest.val", "w");
if (! f)
exit (1);
- if (((long) (sizeof (int))) < 0)
+ if (((long) (sizeof (__int128_t))) < 0)
{
long i = longval ();
- if (i != ((long) (sizeof (int))))
+ if (i != ((long) (sizeof (__int128_t))))
exit (1);
fprintf (f, "%ld\n", i);
}
else
{
unsigned long i = ulongval ();
- if (i != ((long) (sizeof (int))))
+ if (i != ((long) (sizeof (__int128_t))))
exit (1);
fprintf (f, "%lu\n", i);
}
@@ -19218,16 +17645,16 @@
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; }; then
- ac_cv_sizeof_int=`cat conftest.val`
+ ac_cv_sizeof___int128_t=`cat conftest.val`
else
echo "$as_me: program exited with status $ac_status" >&5
echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
( exit $ac_status )
-{ { echo "$as_me:$LINENO: error: cannot compute sizeof (int), 77
+{ { echo "$as_me:$LINENO: error: cannot compute sizeof (__int128_t), 77
See \`config.log' for more details." >&5
-echo "$as_me: error: cannot compute sizeof (int), 77
+echo "$as_me: error: cannot compute sizeof (__int128_t), 77
See \`config.log' for more details." >&2;}
{ (exit 1); exit 1; }; }
fi
@@ -19236,102 +17663,52 @@
fi
rm -f conftest.val
else
- ac_cv_sizeof_int=0
+ ac_cv_sizeof___int128_t=0
fi
fi
-echo "$as_me:$LINENO: result: $ac_cv_sizeof_int" >&5
-echo "${ECHO_T}$ac_cv_sizeof_int" >&6
+echo "$as_me:$LINENO: result: $ac_cv_sizeof___int128_t" >&5
+echo "${ECHO_T}$ac_cv_sizeof___int128_t" >&6
cat >>confdefs.h <<_ACEOF
-#define SIZEOF_INT $ac_cv_sizeof_int
+#define SIZEOF___INT128_T $ac_cv_sizeof___int128_t
_ACEOF
cat >>confdefs.h <<_ACEOF
-#define ETHR_SIZEOF_INT $ac_cv_sizeof_int
+#define ETHR_SIZEOF___INT128_T $ac_cv_sizeof___int128_t
_ACEOF
-echo "$as_me:$LINENO: checking for long" >&5
-echo $ECHO_N "checking for long... $ECHO_C" >&6
-if test "${ac_cv_type_long+set}" = set; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
-else
- cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h. */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h. */
-$ac_includes_default
-int
-main ()
-{
-if ((long *) 0)
- return 0;
-if (sizeof (long))
- return 0;
- ;
- return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
- (eval $ac_compile) 2>conftest.er1
- ac_status=$?
- grep -v '^ *+' conftest.er1 >conftest.err
- rm -f conftest.er1
- cat conftest.err >&5
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -z "$ac_c_werror_flag"
- || test ! -s conftest.err'
- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); }; } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
- ac_cv_type_long=yes
-else
- echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-ac_cv_type_long=no
-fi
-rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-echo "$as_me:$LINENO: result: $ac_cv_type_long" >&5
-echo "${ECHO_T}$ac_cv_type_long" >&6
-echo "$as_me:$LINENO: checking size of long" >&5
-echo $ECHO_N "checking size of long... $ECHO_C" >&6
-if test "${ac_cv_sizeof_long+set}" = set; then
+case X$erl_xcomp_bigendian in
+ X) ;;
+ Xyes|Xno) ac_cv_c_bigendian=$erl_xcomp_bigendian;;
+ *) { { echo "$as_me:$LINENO: error: Bad erl_xcomp_bigendian value: $erl_xcomp_bigendian" >&5
+echo "$as_me: error: Bad erl_xcomp_bigendian value: $erl_xcomp_bigendian" >&2;}
+ { (exit 1); exit 1; }; };;
+esac
+
+echo "$as_me:$LINENO: checking whether byte ordering is bigendian" >&5
+echo $ECHO_N "checking whether byte ordering is bigendian... $ECHO_C" >&6
+if test "${ac_cv_c_bigendian+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
- if test "$ac_cv_type_long" = yes; then
- # The cast to unsigned long works around a bug in the HP C Compiler
- # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
- # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
- # This bug is HP SR number 8606223364.
- if test "$cross_compiling" = yes; then
- # Depending upon the size, compute the lo and hi bounds.
+ # See if sys/param.h defines the BYTE_ORDER macro.
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
-$ac_includes_default
+#include
+#include
+
int
main ()
{
-static int test_array [1 - 2 * !(((long) (sizeof (long))) >= 0)];
-test_array [0] = 0
+#if !BYTE_ORDER || !BIG_ENDIAN || !LITTLE_ENDIAN
+ bogus endian macros
+#endif
;
return 0;
@@ -19359,20 +17736,22 @@
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; }; then
- ac_lo=0 ac_mid=0
- while :; do
- cat >conftest.$ac_ext <<_ACEOF
+ # It does; now see whether it defined to BIG_ENDIAN or not.
+cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
-$ac_includes_default
+#include
+#include
+
int
main ()
{
-static int test_array [1 - 2 * !(((long) (sizeof (long))) <= $ac_mid)];
-test_array [0] = 0
+#if BYTE_ORDER != BIG_ENDIAN
+ not big endian
+#endif
;
return 0;
@@ -19400,78 +17779,38 @@
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; }; then
- ac_hi=$ac_mid; break
+ ac_cv_c_bigendian=yes
else
echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
-ac_lo=`expr $ac_mid + 1`
- if test $ac_lo -le $ac_mid; then
- ac_lo= ac_hi=
- break
- fi
- ac_mid=`expr 2 '*' $ac_mid + 1`
+ac_cv_c_bigendian=no
fi
rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
- done
else
echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
-cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h. */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h. */
-$ac_includes_default
-int
-main ()
-{
-static int test_array [1 - 2 * !(((long) (sizeof (long))) < 0)];
-test_array [0] = 0
-
- ;
- return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
- (eval $ac_compile) 2>conftest.er1
- ac_status=$?
- grep -v '^ *+' conftest.er1 >conftest.err
- rm -f conftest.er1
- cat conftest.err >&5
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -z "$ac_c_werror_flag"
- || test ! -s conftest.err'
- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); }; } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
- ac_hi=-1 ac_mid=-1
- while :; do
- cat >conftest.$ac_ext <<_ACEOF
+# It does not; compile a test program.
+if test "$cross_compiling" = yes; then
+ # try to guess the endianness by grepping values into an object file
+ ac_cv_c_bigendian=unknown
+ cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
-$ac_includes_default
+short ascii_mm[] = { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 };
+short ascii_ii[] = { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 };
+void _ascii () { char *s = (char *) ascii_mm; s = (char *) ascii_ii; }
+short ebcdic_ii[] = { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 };
+short ebcdic_mm[] = { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 };
+void _ebcdic () { char *s = (char *) ebcdic_mm; s = (char *) ebcdic_ii; }
int
main ()
{
-static int test_array [1 - 2 * !(((long) (sizeof (long))) >= $ac_mid)];
-test_array [0] = 0
-
+ _ascii (); _ebcdic ();
;
return 0;
}
@@ -19498,133 +17837,184 @@
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; }; then
- ac_lo=$ac_mid; break
-else
- echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-ac_hi=`expr '(' $ac_mid ')' - 1`
- if test $ac_mid -le $ac_hi; then
- ac_lo= ac_hi=
- break
- fi
- ac_mid=`expr 2 '*' $ac_mid`
+ if grep BIGenDianSyS conftest.$ac_objext >/dev/null ; then
+ ac_cv_c_bigendian=yes
+fi
+if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then
+ if test "$ac_cv_c_bigendian" = unknown; then
+ ac_cv_c_bigendian=no
+ else
+ # finding both strings is unlikely to happen, but who knows?
+ ac_cv_c_bigendian=unknown
+ fi
fi
-rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
- done
else
echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
-ac_lo= ac_hi=
-fi
-rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
fi
rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
-# Binary search between lo and hi bounds.
-while test "x$ac_lo" != "x$ac_hi"; do
- ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
+else
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
-$ac_includes_default
int
main ()
{
-static int test_array [1 - 2 * !(((long) (sizeof (long))) <= $ac_mid)];
-test_array [0] = 0
-
- ;
- return 0;
+ /* Are we little or big endian? From Harbison&Steele. */
+ union
+ {
+ long l;
+ char c[sizeof (long)];
+ } u;
+ u.l = 1;
+ exit (u.c[sizeof (long) - 1] == 1);
}
_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
- (eval $ac_compile) 2>conftest.er1
- ac_status=$?
- grep -v '^ *+' conftest.er1 >conftest.err
- rm -f conftest.er1
- cat conftest.err >&5
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -z "$ac_c_werror_flag"
- || test ! -s conftest.err'
- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
+rm -f conftest$ac_exeext
+if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
+ (eval $ac_link) 2>&5
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); }; } &&
- { ac_try='test -s conftest.$ac_objext'
+ (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
{ (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; }; then
- ac_hi=$ac_mid
+ ac_cv_c_bigendian=no
else
- echo "$as_me: failed program was:" >&5
+ echo "$as_me: program exited with status $ac_status" >&5
+echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
-ac_lo=`expr '(' $ac_mid ')' + 1`
+( exit $ac_status )
+ac_cv_c_bigendian=yes
+fi
+rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
+fi
fi
rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
-done
-case $ac_lo in
-?*) ac_cv_sizeof_long=$ac_lo;;
-'') { { echo "$as_me:$LINENO: error: cannot compute sizeof (long), 77
-See \`config.log' for more details." >&5
-echo "$as_me: error: cannot compute sizeof (long), 77
-See \`config.log' for more details." >&2;}
+fi
+echo "$as_me:$LINENO: result: $ac_cv_c_bigendian" >&5
+echo "${ECHO_T}$ac_cv_c_bigendian" >&6
+case $ac_cv_c_bigendian in
+ yes)
+
+cat >>confdefs.h <<\_ACEOF
+#define WORDS_BIGENDIAN 1
+_ACEOF
+ ;;
+ no)
+ ;;
+ *)
+ { { echo "$as_me:$LINENO: error: unknown endianness
+presetting ac_cv_c_bigendian=no (or yes) will help" >&5
+echo "$as_me: error: unknown endianness
+presetting ac_cv_c_bigendian=no (or yes) will help" >&2;}
{ (exit 1); exit 1; }; } ;;
esac
-else
- if test "$cross_compiling" = yes; then
- { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling
-See \`config.log' for more details." >&5
-echo "$as_me: error: cannot run test program while cross compiling
-See \`config.log' for more details." >&2;}
- { (exit 1); exit 1; }; }
-else
- cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h. */
+
+
+if test "$ac_cv_c_bigendian" = "yes"; then
+
+cat >>confdefs.h <<\_ACEOF
+#define ETHR_BIGENDIAN 1
_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h. */
-$ac_includes_default
-long longval () { return (long) (sizeof (long)); }
-unsigned long ulongval () { return (long) (sizeof (long)); }
-#include
+
+fi
+
+case X$erl_xcomp_double_middle_endian in
+ X) ;;
+ Xyes|Xno|Xunknown) ac_cv_c_double_middle_endian=$erl_xcomp_double_middle_endian;;
+ *) { { echo "$as_me:$LINENO: error: Bad erl_xcomp_double_middle_endian value: $erl_xcomp_double_middle_endian" >&5
+echo "$as_me: error: Bad erl_xcomp_double_middle_endian value: $erl_xcomp_double_middle_endian" >&2;}
+ { (exit 1); exit 1; }; };;
+esac
+
+echo "$as_me:$LINENO: checking whether double word ordering is middle-endian" >&5
+echo $ECHO_N "checking whether double word ordering is middle-endian... $ECHO_C" >&6
+if test "${ac_cv_c_double_middle_endian+set}" = set; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+ # It does not; compile a test program.
+if test "$cross_compiling" = yes; then
+ ac_cv_c_double_middle=unknown
+else
+ cat >conftest.$ac_ext <<_ACEOF
+/* confdefs.h. */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h. */
#include
+
int
-main ()
+main(void)
{
+ int i = 0;
+ int zero = 0;
+ int bigendian;
+ int zero_index = 0;
- FILE *f = fopen ("conftest.val", "w");
- if (! f)
- exit (1);
- if (((long) (sizeof (long))) < 0)
+ union
+ {
+ long int l;
+ char c[sizeof (long int)];
+ } u;
+
+ /* we'll use the one with 32-bit words */
+ union
+ {
+ double d;
+ unsigned int c[2];
+ } vint;
+
+ union
+ {
+ double d;
+ unsigned long c[2];
+ } vlong;
+
+ union
+ {
+ double d;
+ unsigned short c[2];
+ } vshort;
+
+
+ /* Are we little or big endian? From Harbison&Steele. */
+ u.l = 1;
+ bigendian = (u.c[sizeof (long int) - 1] == 1);
+
+ zero_index = bigendian ? 1 : 0;
+
+ vint.d = 1.0;
+ vlong.d = 1.0;
+ vshort.d = 1.0;
+
+ if (sizeof(unsigned int) == 4)
{
- long i = longval ();
- if (i != ((long) (sizeof (long))))
- exit (1);
- fprintf (f, "%ld\n", i);
+ if (vint.c[zero_index] != 0)
+ zero = 1;
}
- else
+ else if (sizeof(unsigned long) == 4)
{
- unsigned long i = ulongval ();
- if (i != ((long) (sizeof (long))))
- exit (1);
- fprintf (f, "%lu\n", i);
+ if (vlong.c[zero_index] != 0)
+ zero = 1;
+ }
+ else if (sizeof(unsigned short) == 4)
+ {
+ if (vshort.c[zero_index] != 0)
+ zero = 1;
}
- exit (ferror (f) || fclose (f) != 0);
- ;
- return 0;
+ exit (zero);
}
+
_ACEOF
rm -f conftest$ac_exeext
if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
@@ -19637,58 +18027,59 @@
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; }; then
- ac_cv_sizeof_long=`cat conftest.val`
+ ac_cv_c_double_middle_endian=no
else
echo "$as_me: program exited with status $ac_status" >&5
echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
( exit $ac_status )
-{ { echo "$as_me:$LINENO: error: cannot compute sizeof (long), 77
-See \`config.log' for more details." >&5
-echo "$as_me: error: cannot compute sizeof (long), 77
-See \`config.log' for more details." >&2;}
- { (exit 1); exit 1; }; }
+ac_cv_c_double_middle_endian=yes
fi
rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
fi
fi
-rm -f conftest.val
-else
- ac_cv_sizeof_long=0
-fi
-fi
-echo "$as_me:$LINENO: result: $ac_cv_sizeof_long" >&5
-echo "${ECHO_T}$ac_cv_sizeof_long" >&6
-cat >>confdefs.h <<_ACEOF
-#define SIZEOF_LONG $ac_cv_sizeof_long
-_ACEOF
-
-
+echo "$as_me:$LINENO: result: $ac_cv_c_double_middle_endian" >&5
+echo "${ECHO_T}$ac_cv_c_double_middle_endian" >&6
+case $ac_cv_c_double_middle_endian in
+ yes)
-cat >>confdefs.h <<_ACEOF
-#define ETHR_SIZEOF_LONG $ac_cv_sizeof_long
+cat >>confdefs.h <<\_ACEOF
+#define DOUBLE_MIDDLE_ENDIAN 1
_ACEOF
+ ;;
+ no)
+ ;;
+ *)
+ { echo "$as_me:$LINENO: WARNING: unknown double endianness
+presetting ac_cv_c_double_middle_endian=no (or yes) will help" >&5
+echo "$as_me: WARNING: unknown double endianness
+presetting ac_cv_c_double_middle_endian=no (or yes) will help" >&2;} ;;
+esac
-echo "$as_me:$LINENO: checking for long long" >&5
-echo $ECHO_N "checking for long long... $ECHO_C" >&6
-if test "${ac_cv_type_long_long+set}" = set; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
-else
- cat >conftest.$ac_ext <<_ACEOF
+
+ETHR_X86_SSE2_ASM=no
+case "$GCC-$ac_cv_sizeof_void_p-$host_cpu" in
+ yes-4-i86pc | yes-4-i*86 | yes-4-x86_64 | yes-4-amd64)
+ echo "$as_me:$LINENO: checking for gcc sse2 asm support" >&5
+echo $ECHO_N "checking for gcc sse2 asm support... $ECHO_C" >&6
+ save_CFLAGS="$CFLAGS"
+ CFLAGS="$CFLAGS -msse2"
+ gcc_sse2_asm=no
+ cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
-$ac_includes_default
+
int
main ()
{
-if ((long long *) 0)
- return 0;
-if (sizeof (long long))
- return 0;
+
+ long long x, *y;
+ __asm__ __volatile__("movq %1, %0\n\t" : "=x"(x) : "m"(*y) : "memory");
+
;
return 0;
}
@@ -19715,83 +18106,70 @@
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; }; then
- ac_cv_type_long_long=yes
+ gcc_sse2_asm=yes
else
echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
-ac_cv_type_long_long=no
fi
rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-echo "$as_me:$LINENO: result: $ac_cv_type_long_long" >&5
-echo "${ECHO_T}$ac_cv_type_long_long" >&6
+ CFLAGS="$save_CFLAGS"
+ echo "$as_me:$LINENO: result: $gcc_sse2_asm" >&5
+echo "${ECHO_T}$gcc_sse2_asm" >&6
+ if test "$gcc_sse2_asm" = "yes"; then
-echo "$as_me:$LINENO: checking size of long long" >&5
-echo $ECHO_N "checking size of long long... $ECHO_C" >&6
-if test "${ac_cv_sizeof_long_long+set}" = set; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
-else
- if test "$ac_cv_type_long_long" = yes; then
- # The cast to unsigned long works around a bug in the HP C Compiler
- # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
- # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
- # This bug is HP SR number 8606223364.
- if test "$cross_compiling" = yes; then
- # Depending upon the size, compute the lo and hi bounds.
-cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h. */
+cat >>confdefs.h <<\_ACEOF
+#define ETHR_GCC_HAVE_SSE2_ASM_SUPPORT 1
_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h. */
-$ac_includes_default
-int
-main ()
-{
-static int test_array [1 - 2 * !(((long) (sizeof (long long))) >= 0)];
-test_array [0] = 0
- ;
- return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
- (eval $ac_compile) 2>conftest.er1
- ac_status=$?
- grep -v '^ *+' conftest.er1 >conftest.err
- rm -f conftest.er1
- cat conftest.err >&5
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -z "$ac_c_werror_flag"
- || test ! -s conftest.err'
- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); }; } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
- ac_lo=0 ac_mid=0
- while :; do
+ ETHR_X86_SSE2_ASM=yes
+ fi
+ ;;
+ *)
+ ;;
+esac
+
+case "$GCC-$host_cpu" in
+ yes-i86pc | yes-i*86 | yes-x86_64 | yes-amd64)
+ gcc_dw_cmpxchg_asm=no
+ echo "$as_me:$LINENO: checking for gcc double word cmpxchg asm support" >&5
+echo $ECHO_N "checking for gcc double word cmpxchg asm support... $ECHO_C" >&6
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
-$ac_includes_default
+
int
main ()
{
-static int test_array [1 - 2 * !(((long) (sizeof (long long))) <= $ac_mid)];
-test_array [0] = 0
+
+ char xchgd;
+ long new[2], xchg[2], *p;
+ __asm__ __volatile__(
+#if ETHR_SIZEOF_PTR == 4 && defined(__PIC__) && __PIC__
+ "pushl %%ebx\n\t"
+ "movl %8, %%ebx\n\t"
+#endif
+#if ETHR_SIZEOF_PTR == 4
+ "lock; cmpxchg8b %0\n\t"
+#else
+ "lock; cmpxchg16b %0\n\t"
+#endif
+ "setz %3\n\t"
+#if ETHR_SIZEOF_PTR == 4 && defined(__PIC__) && __PIC__
+ "popl %%ebx\n\t"
+#endif
+ : "=m"(*p), "=d"(xchg[1]), "=a"(xchg[0]), "=c"(xchgd)
+ : "m"(*p), "1"(xchg[1]), "2"(xchg[0]), "3"(new[1]),
+#if ETHR_SIZEOF_PTR == 4 && defined(__PIC__) && __PIC__
+ "r"(new[0])
+#else
+ "b"(new[0])
+#endif
+ : "cc", "memory");
+
;
return 0;
@@ -19819,77 +18197,41 @@
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; }; then
- ac_hi=$ac_mid; break
+ gcc_dw_cmpxchg_asm=yes
else
echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
-ac_lo=`expr $ac_mid + 1`
- if test $ac_lo -le $ac_mid; then
- ac_lo= ac_hi=
- break
- fi
- ac_mid=`expr 2 '*' $ac_mid + 1`
fi
rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
- done
-else
- echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-cat >conftest.$ac_ext <<_ACEOF
+ if test $gcc_dw_cmpxchg_asm = no && test $ac_cv_sizeof_void_p = 4; then
+ cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
-$ac_includes_default
-int
-main ()
-{
-static int test_array [1 - 2 * !(((long) (sizeof (long long))) < 0)];
-test_array [0] = 0
- ;
- return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
- (eval $ac_compile) 2>conftest.er1
- ac_status=$?
- grep -v '^ *+' conftest.er1 >conftest.err
- rm -f conftest.er1
- cat conftest.err >&5
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -z "$ac_c_werror_flag"
- || test ! -s conftest.err'
- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); }; } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
- ac_hi=-1 ac_mid=-1
- while :; do
- cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h. */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h. */
-$ac_includes_default
int
main ()
{
-static int test_array [1 - 2 * !(((long) (sizeof (long long))) >= $ac_mid)];
-test_array [0] = 0
+
+ char xchgd;
+ long new[2], xchg[2], *p;
+#if !defined(__PIC__) || !__PIC__
+# error nope
+#endif
+ __asm__ __volatile__(
+ "pushl %%ebx\n\t"
+ "movl (%7), %%ebx\n\t"
+ "movl 4(%7), %%ecx\n\t"
+ "lock; cmpxchg8b %0\n\t"
+ "setz %3\n\t"
+ "popl %%ebx\n\t"
+ : "=m"(*p), "=d"(xchg[1]), "=a"(xchg[0]), "=c"(xchgd)
+ : "m"(*p), "1"(xchg[1]), "2"(xchg[0]), "3"(new)
+ : "cc", "memory");
+
;
return 0;
@@ -19917,44 +18259,86 @@
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; }; then
- ac_lo=$ac_mid; break
+ gcc_dw_cmpxchg_asm=yes
else
echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
-ac_hi=`expr '(' $ac_mid ')' - 1`
- if test $ac_mid -le $ac_hi; then
- ac_lo= ac_hi=
- break
- fi
- ac_mid=`expr 2 '*' $ac_mid`
fi
rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
- done
-else
- echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
+ if test "$gcc_dw_cmpxchg_asm" = "yes"; then
-ac_lo= ac_hi=
-fi
-rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
+cat >>confdefs.h <<\_ACEOF
+#define ETHR_CMPXCHG8B_REGISTER_SHORTAGE 1
+_ACEOF
+
+ fi
+ fi
+ echo "$as_me:$LINENO: result: $gcc_dw_cmpxchg_asm" >&5
+echo "${ECHO_T}$gcc_dw_cmpxchg_asm" >&6
+ if test "$gcc_dw_cmpxchg_asm" = "yes"; then
+
+cat >>confdefs.h <<\_ACEOF
+#define ETHR_GCC_HAVE_DW_CMPXCHG_ASM_SUPPORT 1
+_ACEOF
+
+ fi;;
+ *)
+ ;;
+esac
+
+
+cat >>confdefs.h <<\_ACEOF
+#define ETHR_HAVE_ETHREAD_DEFINES 1
+_ACEOF
+
+
+
+
+
+
+
+
+
+
+
+
+if test "X$ETHR_LIB_NAME" = "X"; then
+ found_threads=no
+else
+ found_threads=yes
fi
-rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
-# Binary search between lo and hi bounds.
-while test "x$ac_lo" != "x$ac_hi"; do
- ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
- cat >conftest.$ac_ext <<_ACEOF
+
+
+ERTS_BUILD_SMP_EMU=$enable_smp_support
+echo "$as_me:$LINENO: checking whether an emulator with smp support should be built" >&5
+echo $ECHO_N "checking whether an emulator with smp support should be built... $ECHO_C" >&6
+case $ERTS_BUILD_SMP_EMU in
+ yes)
+ echo "$as_me:$LINENO: result: yes; enabled by user" >&5
+echo "${ECHO_T}yes; enabled by user" >&6
+ ;;
+ no)
+ echo "$as_me:$LINENO: result: no; disabled by user" >&5
+echo "${ECHO_T}no; disabled by user" >&6
+ ;;
+ unknown)
+ cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
-$ac_includes_default
+
int
main ()
{
-static int test_array [1 - 2 * !(((long) (sizeof (long long))) <= $ac_mid)];
-test_array [0] = 0
+
+ #if __GNUC__ >= 3 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 95)
+ ;
+ #else
+ #error old or no gcc
+ #endif
;
return 0;
@@ -19982,116 +18366,126 @@
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; }; then
- ac_hi=$ac_mid
+ gcc_smp=okgcc
else
echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
-ac_lo=`expr '(' $ac_mid ')' + 1`
+gcc_smp=oldornogcc
fi
rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
-done
-case $ac_lo in
-?*) ac_cv_sizeof_long_long=$ac_lo;;
-'') { { echo "$as_me:$LINENO: error: cannot compute sizeof (long long), 77
-See \`config.log' for more details." >&5
-echo "$as_me: error: cannot compute sizeof (long long), 77
-See \`config.log' for more details." >&2;}
- { (exit 1); exit 1; }; } ;;
+ ERTS_BUILD_SMP_EMU=yes
+ case "$enable_threads-$gcc_smp-$found_threads-$host_os" in
+
+ no-*)
+ echo "$as_me:$LINENO: result: no; threads disabled by user" >&5
+echo "${ECHO_T}no; threads disabled by user" >&6
+ ERTS_BUILD_SMP_EMU=no
+ ;;
+
+ *-okgcc-yes-*)
+ echo "$as_me:$LINENO: result: yes" >&5
+echo "${ECHO_T}yes" >&6
+ ERTS_BUILD_SMP_EMU=yes
+ ;;
+
+ *-win32)
+ echo "$as_me:$LINENO: result: yes" >&5
+echo "${ECHO_T}yes" >&6
+ ERTS_BUILD_SMP_EMU=yes
+ ;;
+
+ *-oldornogcc-*)
+ echo "$as_me:$LINENO: result: no; old gcc or no gcc found" >&5
+echo "${ECHO_T}no; old gcc or no gcc found" >&6
+ ERTS_BUILD_SMP_EMU=no
+ ;;
+
+ *)
+ echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6
+ ERTS_BUILD_SMP_EMU=no
+ ;;
+ esac
+ ;;
esac
-else
- if test "$cross_compiling" = yes; then
- { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling
-See \`config.log' for more details." >&5
-echo "$as_me: error: cannot run test program while cross compiling
-See \`config.log' for more details." >&2;}
+
+if test $ERTS_BUILD_SMP_EMU = yes; then
+
+ if test $found_threads = no; then
+ { { echo "$as_me:$LINENO: error: cannot build smp enabled emulator since no thread library was found" >&5
+echo "$as_me: error: cannot build smp enabled emulator since no thread library was found" >&2;}
{ (exit 1); exit 1; }; }
-else
- cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h. */
+ fi
+
+
+cat >>confdefs.h <<\_ACEOF
+#define ERTS_HAVE_SMP_EMU 1
_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h. */
-$ac_includes_default
-long longval () { return (long) (sizeof (long long)); }
-unsigned long ulongval () { return (long) (sizeof (long long)); }
-#include
-#include
-int
-main ()
-{
- FILE *f = fopen ("conftest.val", "w");
- if (! f)
- exit (1);
- if (((long) (sizeof (long long))) < 0)
- {
- long i = longval ();
- if (i != ((long) (sizeof (long long))))
- exit (1);
- fprintf (f, "%ld\n", i);
- }
- else
- {
- unsigned long i = ulongval ();
- if (i != ((long) (sizeof (long long))))
- exit (1);
- fprintf (f, "%lu\n", i);
- }
- exit (ferror (f) || fclose (f) != 0);
- ;
- return 0;
-}
+ test "X$smp_require_native_atomics" = "Xyes" &&
+
+cat >>confdefs.h <<\_ACEOF
+#define ETHR_SMP_REQUIRE_NATIVE_IMPLS 1
_ACEOF
-rm -f conftest$ac_exeext
-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
- (eval $ac_link) 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
- ac_cv_sizeof_long_long=`cat conftest.val`
-else
- echo "$as_me: program exited with status $ac_status" >&5
-echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-( exit $ac_status )
-{ { echo "$as_me:$LINENO: error: cannot compute sizeof (long long), 77
-See \`config.log' for more details." >&5
-echo "$as_me: error: cannot compute sizeof (long long), 77
-See \`config.log' for more details." >&2;}
+
+ case "$ethr_have_native_atomics-$smp_require_native_atomics-$ethr_have_native_spinlock" in
+ yes-*)
+ ;;
+
+ no-yes-*)
+ { { echo "$as_me:$LINENO: error: No native atomic implementation found. See Configuring section in INSTALL.md for more information." >&5
+echo "$as_me: error: No native atomic implementation found. See Configuring section in INSTALL.md for more information." >&2;}
{ (exit 1); exit 1; }; }
+ ;;
+
+ no-no-yes)
+
+ test -f "$ERL_TOP/erts/CONF_INFO" ||
+ echo "" > "$ERL_TOP/erts/CONF_INFO"
+ cat >> $ERL_TOP/erts/CONF_INFO < "$ERL_TOP/erts/CONF_INFO"
+ cat >> "$ERL_TOP/erts/CONF_INFO" <&5
-echo "${ECHO_T}$ac_cv_sizeof_long_long" >&6
-cat >>confdefs.h <<_ACEOF
-#define SIZEOF_LONG_LONG $ac_cv_sizeof_long_long
-_ACEOF
-cat >>confdefs.h <<_ACEOF
-#define ETHR_SIZEOF_LONG_LONG $ac_cv_sizeof_long_long
-_ACEOF
-echo "$as_me:$LINENO: checking for __int64" >&5
-echo $ECHO_N "checking for __int64... $ECHO_C" >&6
-if test "${ac_cv_type___int64+set}" = set; then
+
+for ac_func in posix_fadvise closefrom
+do
+as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
+echo "$as_me:$LINENO: checking for $ac_func" >&5
+echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
+if eval "test \"\${$as_ac_var+set}\" = set"; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
cat >conftest.$ac_ext <<_ACEOF
@@ -20100,21 +18494,54 @@
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
-$ac_includes_default
+/* Define $ac_func to an innocuous variant, in case declares $ac_func.
+ For example, HP-UX 11i declares gettimeofday. */
+#define $ac_func innocuous_$ac_func
+
+/* System header to define __stub macros and hopefully few prototypes,
+ which can conflict with char $ac_func (); below.
+ Prefer to if __STDC__ is defined, since
+ exists even on freestanding compilers. */
+
+#ifdef __STDC__
+# include
+#else
+# include
+#endif
+
+#undef $ac_func
+
+/* Override any gcc2 internal prototype to avoid an error. */
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+/* We use char because int might match the return type of a gcc2
+ builtin and then its argument prototype would still apply. */
+char $ac_func ();
+/* The GNU C library defines this for functions which it implements
+ to always fail with ENOSYS. Some functions are actually named
+ something starting with __ and the normal name is an alias. */
+#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
+choke me
+#else
+char (*f) () = $ac_func;
+#endif
+#ifdef __cplusplus
+}
+#endif
+
int
main ()
{
-if ((__int64 *) 0)
- return 0;
-if (sizeof (__int64))
- return 0;
+return f != $ac_func;
;
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
- (eval $ac_compile) 2>conftest.er1
+rm -f conftest.$ac_objext conftest$ac_exeext
+if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
+ (eval $ac_link) 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
@@ -20128,36 +18555,48 @@
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; } &&
- { ac_try='test -s conftest.$ac_objext'
+ { ac_try='test -s conftest$ac_exeext'
{ (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; }; then
- ac_cv_type___int64=yes
+ eval "$as_ac_var=yes"
else
echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
-ac_cv_type___int64=no
+eval "$as_ac_var=no"
fi
-rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
+rm -f conftest.err conftest.$ac_objext \
+ conftest$ac_exeext conftest.$ac_ext
fi
-echo "$as_me:$LINENO: result: $ac_cv_type___int64" >&5
-echo "${ECHO_T}$ac_cv_type___int64" >&6
+echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
+echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
+if test `eval echo '${'$as_ac_var'}'` = yes; then
+ cat >>confdefs.h <<_ACEOF
+#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
+_ACEOF
-echo "$as_me:$LINENO: checking size of __int64" >&5
-echo $ECHO_N "checking size of __int64... $ECHO_C" >&6
-if test "${ac_cv_sizeof___int64+set}" = set; then
+fi
+done
+
+
+for ac_header in linux/falloc.h
+do
+as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
+if eval "test \"\${$as_ac_Header+set}\" = set"; then
+ echo "$as_me:$LINENO: checking for $ac_header" >&5
+echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
+if eval "test \"\${$as_ac_Header+set}\" = set"; then
echo $ECHO_N "(cached) $ECHO_C" >&6
+fi
+echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
+echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
else
- if test "$ac_cv_type___int64" = yes; then
- # The cast to unsigned long works around a bug in the HP C Compiler
- # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
- # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
- # This bug is HP SR number 8606223364.
- if test "$cross_compiling" = yes; then
- # Depending upon the size, compute the lo and hi bounds.
+ # Is the header compilable?
+echo "$as_me:$LINENO: checking $ac_header usability" >&5
+echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
_ACEOF
@@ -20165,15 +18604,7 @@
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
$ac_includes_default
-int
-main ()
-{
-static int test_array [1 - 2 * !(((long) (sizeof (__int64))) >= 0)];
-test_array [0] = 0
-
- ;
- return 0;
-}
+#include <$ac_header>
_ACEOF
rm -f conftest.$ac_objext
if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
@@ -20197,126 +18628,143 @@
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; }; then
- ac_lo=0 ac_mid=0
- while :; do
- cat >conftest.$ac_ext <<_ACEOF
+ ac_header_compiler=yes
+else
+ echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+ac_header_compiler=no
+fi
+rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
+echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
+echo "${ECHO_T}$ac_header_compiler" >&6
+
+# Is the header present?
+echo "$as_me:$LINENO: checking $ac_header presence" >&5
+echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
+cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
-$ac_includes_default
-int
-main ()
-{
-static int test_array [1 - 2 * !(((long) (sizeof (__int64))) <= $ac_mid)];
-test_array [0] = 0
-
- ;
- return 0;
-}
+#include <$ac_header>
_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
- (eval $ac_compile) 2>conftest.er1
+if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
+ (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
cat conftest.err >&5
echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -z "$ac_c_werror_flag"
- || test ! -s conftest.err'
- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); }; } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
- ac_hi=$ac_mid; break
+ (exit $ac_status); } >/dev/null; then
+ if test -s conftest.err; then
+ ac_cpp_err=$ac_c_preproc_warn_flag
+ ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
+ else
+ ac_cpp_err=
+ fi
+else
+ ac_cpp_err=yes
+fi
+if test -z "$ac_cpp_err"; then
+ ac_header_preproc=yes
else
echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
-ac_lo=`expr $ac_mid + 1`
- if test $ac_lo -le $ac_mid; then
- ac_lo= ac_hi=
- break
- fi
- ac_mid=`expr 2 '*' $ac_mid + 1`
+ ac_header_preproc=no
fi
-rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
- done
+rm -f conftest.err conftest.$ac_ext
+echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
+echo "${ECHO_T}$ac_header_preproc" >&6
+
+# So? What about this header?
+case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
+ yes:no: )
+ { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
+echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
+ { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
+echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
+ ac_header_preproc=yes
+ ;;
+ no:yes:* )
+ { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
+echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
+ { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
+echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
+ { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
+echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
+ { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5
+echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;}
+ { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
+echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
+ { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
+echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
+ (
+ cat <<\_ASBOX
+## ------------------------------------------ ##
+## Report this to the AC_PACKAGE_NAME lists. ##
+## ------------------------------------------ ##
+_ASBOX
+ ) |
+ sed "s/^/$as_me: WARNING: /" >&2
+ ;;
+esac
+echo "$as_me:$LINENO: checking for $ac_header" >&5
+echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
+if eval "test \"\${$as_ac_Header+set}\" = set"; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
else
- echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
+ eval "$as_ac_Header=\$ac_header_preproc"
+fi
+echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
+echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
-cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h. */
+fi
+if test `eval echo '${'$as_ac_Header'}'` = yes; then
+ cat >>confdefs.h <<_ACEOF
+#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h. */
-$ac_includes_default
-int
-main ()
-{
-static int test_array [1 - 2 * !(((long) (sizeof (__int64))) < 0)];
-test_array [0] = 0
- ;
- return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
- (eval $ac_compile) 2>conftest.er1
- ac_status=$?
- grep -v '^ *+' conftest.er1 >conftest.err
- rm -f conftest.er1
- cat conftest.err >&5
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -z "$ac_c_werror_flag"
- || test ! -s conftest.err'
- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); }; } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
- ac_hi=-1 ac_mid=-1
- while :; do
+fi
+
+done
+
+echo "$as_me:$LINENO: checking whether fallocate() works" >&5
+echo $ECHO_N "checking whether fallocate() works... $ECHO_C" >&6
+if test "${i_cv_fallocate_works+set}" = set; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
-$ac_includes_default
+
+ #include
+ #include
+ #include
+ #include
+ #include
+ #include
+
int
main ()
{
-static int test_array [1 - 2 * !(((long) (sizeof (__int64))) >= $ac_mid)];
-test_array [0] = 0
+
+ int fd = creat("conftest.temp", 0600);
+ fallocate(fd, FALLOC_FL_KEEP_SIZE,(off_t) 1024,(off_t) 1024);
;
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
- (eval $ac_compile) 2>conftest.er1
+rm -f conftest.$ac_objext conftest$ac_exeext
+if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
+ (eval $ac_link) 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
@@ -20330,210 +18778,391 @@
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; } &&
- { ac_try='test -s conftest.$ac_objext'
+ { ac_try='test -s conftest$ac_exeext'
{ (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; }; then
- ac_lo=$ac_mid; break
+ i_cv_fallocate_works=yes
else
echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
-ac_hi=`expr '(' $ac_mid ')' - 1`
- if test $ac_mid -le $ac_hi; then
- ac_lo= ac_hi=
- break
- fi
- ac_mid=`expr 2 '*' $ac_mid`
+i_cv_fallocate_works=no
fi
-rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
- done
-else
- echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
+rm -f conftest.err conftest.$ac_objext \
+ conftest$ac_exeext conftest.$ac_ext
-ac_lo= ac_hi=
fi
-rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
+echo "$as_me:$LINENO: result: $i_cv_fallocate_works" >&5
+echo "${ECHO_T}$i_cv_fallocate_works" >&6
+if test $i_cv_fallocate_works = yes; then
+
+cat >>confdefs.h <<\_ACEOF
+#define HAVE_FALLOCATE 1
+_ACEOF
+
fi
-rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
-# Binary search between lo and hi bounds.
-while test "x$ac_lo" != "x$ac_hi"; do
- ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
+
+echo "$as_me:$LINENO: checking whether posix_fallocate() works" >&5
+echo $ECHO_N "checking whether posix_fallocate() works... $ECHO_C" >&6
+if test "${i_cv_posix_fallocate_works+set}" = set; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+
+ if test "$cross_compiling" = yes; then
+
+ i_cv_posix_fallocate_works=no
+
+else
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
-$ac_includes_default
-int
-main ()
-{
-static int test_array [1 - 2 * !(((long) (sizeof (__int64))) <= $ac_mid)];
-test_array [0] = 0
- ;
- return 0;
-}
+ #if !defined(__sun) && !defined(__sun__)
+ #define _XOPEN_SOURCE 600
+ #endif
+ #include
+ #include
+ #include
+ #include
+ #if defined(__GLIBC__) && (__GLIBC__ < 2 || (__GLIBC__ == 2 && __GLIBC_MINOR__ < 7))
+ possibly broken posix_fallocate
+ #endif
+ int main() {
+ int fd = creat("conftest.temp", 0600);
+ int ret;
+ if (-1 == fd) {
+ perror("creat()");
+ return 2;
+ }
+ ret = posix_fallocate(fd, 1024, 1024) < 0 ? 1 : 0;
+ unlink("conftest.temp");
+ return ret;
+ }
+
_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
- (eval $ac_compile) 2>conftest.er1
- ac_status=$?
- grep -v '^ *+' conftest.er1 >conftest.err
- rm -f conftest.er1
- cat conftest.err >&5
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -z "$ac_c_werror_flag"
- || test ! -s conftest.err'
- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
+rm -f conftest$ac_exeext
+if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
+ (eval $ac_link) 2>&5
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); }; } &&
- { ac_try='test -s conftest.$ac_objext'
+ (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
{ (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; }; then
- ac_hi=$ac_mid
+
+ i_cv_posix_fallocate_works=yes
+
else
- echo "$as_me: failed program was:" >&5
+ echo "$as_me: program exited with status $ac_status" >&5
+echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
-ac_lo=`expr '(' $ac_mid ')' + 1`
+( exit $ac_status )
+
+ i_cv_posix_fallocate_works=no
+
fi
-rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
-done
-case $ac_lo in
-?*) ac_cv_sizeof___int64=$ac_lo;;
-'') { { echo "$as_me:$LINENO: error: cannot compute sizeof (__int64), 77
-See \`config.log' for more details." >&5
-echo "$as_me: error: cannot compute sizeof (__int64), 77
-See \`config.log' for more details." >&2;}
+rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
+fi
+
+fi
+echo "$as_me:$LINENO: result: $i_cv_posix_fallocate_works" >&5
+echo "${ECHO_T}$i_cv_posix_fallocate_works" >&6
+if test $i_cv_posix_fallocate_works = yes; then
+
+cat >>confdefs.h <<\_ACEOF
+#define HAVE_POSIX_FALLOCATE
+_ACEOF
+
+fi
+
+#
+# Figure out if the emulator should use threads. The default is set above
+# in the enable_threads variable. It can have the following values:
+#
+# no single-threaded emulator requested
+# yes multi-threaded emulator requested
+# force multi-threaded emulator required
+#
+# EMU_THR_LIB_NAME, EMU_THR_LIBS, EMU_THR_X_LIBS, and EMU_THR_DEFS is
+# used by the emulator, and can (but should not) be used by applications
+# that only require thread support when the emulator has thread support.
+# Other applications should use ETHR_LIB_NAME, ETHR_LIBS, ETHR_X_LIBS,
+# and ETHR_DEFS.
+#
+echo "$as_me:$LINENO: checking whether the emulator should use threads" >&5
+echo $ECHO_N "checking whether the emulator should use threads... $ECHO_C" >&6
+
+EMU_THR_LIB_NAME=
+EMU_THR_X_LIBS=
+EMU_THR_LIBS=
+EMU_THR_DEFS=
+emu_threads=no
+
+case "$enable_threads"-"$host_os" in
+ *-win32)
+ # The windows erlang emulator can never run without threads.
+ # It has to be enabled or the emulator will crash. Until that
+ # is fixed we force threads on win32.
+ enable_threads=force ;;
+ yes-osf*)
+ # The emulator hang when threads are enabled on osf
+ { { echo "$as_me:$LINENO: error: unresolved problems exist with threads on this platform" >&5
+echo "$as_me: error: unresolved problems exist with threads on this platform" >&2;}
{ (exit 1); exit 1; }; } ;;
+ *) ;;
esac
-else
- if test "$cross_compiling" = yes; then
- { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling
-See \`config.log' for more details." >&5
-echo "$as_me: error: cannot run test program while cross compiling
-See \`config.log' for more details." >&2;}
- { (exit 1); exit 1; }; }
-else
- cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h. */
+
+case "$enable_threads"-"$found_threads" in
+ force-yes)
+ emu_threads=yes
+ echo "$as_me:$LINENO: result: yes; thread support required and therefore forced" >&5
+echo "${ECHO_T}yes; thread support required and therefore forced" >&6 ;;
+ yes-yes)
+ emu_threads=yes
+ echo "$as_me:$LINENO: result: yes; enabled by user" >&5
+echo "${ECHO_T}yes; enabled by user" >&6 ;;
+ unknown-yes)
+ case $host_os in
+ solaris*|linux*|darwin*|win32|ose)
+ emu_threads=yes
+ echo "$as_me:$LINENO: result: yes; default on this platform" >&5
+echo "${ECHO_T}yes; default on this platform" >&6
+ ;;
+ *)
+ echo "$as_me:$LINENO: result: no; default on this platform" >&5
+echo "${ECHO_T}no; default on this platform" >&6
+ ;;
+ esac
+ ;;
+ no-yes)
+ echo "$as_me:$LINENO: result: no; thread support found but disabled by user" >&5
+echo "${ECHO_T}no; thread support found but disabled by user" >&6 ;;
+ unknown-no|no-no)
+ echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6 ;;
+ force-no)
+ { { echo "$as_me:$LINENO: error: thread support required but not found" >&5
+echo "$as_me: error: thread support required but not found" >&2;}
+ { (exit 1); exit 1; }; } ;;
+ yes-no)
+ { { echo "$as_me:$LINENO: error: thread support enabled by user but not found" >&5
+echo "$as_me: error: thread support enabled by user but not found" >&2;}
+ { (exit 1); exit 1; }; } ;;
+ *)
+ { { echo "$as_me:$LINENO: error: internal error" >&5
+echo "$as_me: error: internal error" >&2;}
+ { (exit 1); exit 1; }; } ;;
+esac
+
+if test $emu_threads != yes; then
+ enable_lock_check=no
+ enable_lock_count=no
+ echo "$as_me:$LINENO: checking whether dirty schedulers should be enabled" >&5
+echo $ECHO_N "checking whether dirty schedulers should be enabled... $ECHO_C" >&6
+ if test "x$enable_dirty_schedulers" != "xno"; then
+
+cat >>confdefs.h <<\_ACEOF
+#define ERL_NIF_DIRTY_SCHEDULER_SUPPORT 1
_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h. */
-$ac_includes_default
-long longval () { return (long) (sizeof (__int64)); }
-unsigned long ulongval () { return (long) (sizeof (__int64)); }
-#include
-#include
-int
-main ()
-{
- FILE *f = fopen ("conftest.val", "w");
- if (! f)
- exit (1);
- if (((long) (sizeof (__int64))) < 0)
- {
- long i = longval ();
- if (i != ((long) (sizeof (__int64))))
- exit (1);
- fprintf (f, "%ld\n", i);
- }
- else
- {
- unsigned long i = ulongval ();
- if (i != ((long) (sizeof (__int64))))
- exit (1);
- fprintf (f, "%lu\n", i);
- }
- exit (ferror (f) || fclose (f) != 0);
- ;
- return 0;
-}
+cat >>confdefs.h <<\_ACEOF
+#define ERL_DRV_DIRTY_SCHEDULER_SUPPORT 1
_ACEOF
-rm -f conftest$ac_exeext
-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
- (eval $ac_link) 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
- ac_cv_sizeof___int64=`cat conftest.val`
+
+ echo "$as_me:$LINENO: result: yes" >&5
+echo "${ECHO_T}yes" >&6
+ else
+ echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6
+ fi
else
- echo "$as_me: program exited with status $ac_status" >&5
-echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
+ # Threads enabled for emulator
+ EMU_THR_LIB_NAME=$ETHR_LIB_NAME
+ EMU_THR_X_LIBS=$ETHR_X_LIBS
+ EMU_THR_LIBS=$ETHR_LIBS
+ EMU_THR_DEFS=$ETHR_DEFS
+ ENABLE_ALLOC_TYPE_VARS="$ENABLE_ALLOC_TYPE_VARS threads"
+ echo "$as_me:$LINENO: checking whether lock checking should be enabled" >&5
+echo $ECHO_N "checking whether lock checking should be enabled... $ECHO_C" >&6
+ echo "$as_me:$LINENO: result: $enable_lock_check" >&5
+echo "${ECHO_T}$enable_lock_check" >&6
+ if test "x$enable_lock_check" != "xno"; then
+ EMU_THR_DEFS="$EMU_THR_DEFS -DERTS_ENABLE_LOCK_CHECK"
+ fi
-( exit $ac_status )
-{ { echo "$as_me:$LINENO: error: cannot compute sizeof (__int64), 77
-See \`config.log' for more details." >&5
-echo "$as_me: error: cannot compute sizeof (__int64), 77
-See \`config.log' for more details." >&2;}
- { (exit 1); exit 1; }; }
-fi
-rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
-fi
+ echo "$as_me:$LINENO: checking whether lock counters should be enabled" >&5
+echo $ECHO_N "checking whether lock counters should be enabled... $ECHO_C" >&6
+ echo "$as_me:$LINENO: result: $enable_lock_count" >&5
+echo "${ECHO_T}$enable_lock_count" >&6
+ if test "x$enable_lock_count" != "xno"; then
+ EMU_THR_DEFS="$EMU_THR_DEFS -DERTS_ENABLE_LOCK_COUNT"
+ fi
+
+ echo "$as_me:$LINENO: checking whether dirty schedulers should be enabled" >&5
+echo $ECHO_N "checking whether dirty schedulers should be enabled... $ECHO_C" >&6
+ if test "x$enable_dirty_schedulers" != "xno"; then
+ EMU_THR_DEFS="$EMU_THR_DEFS -DERTS_DIRTY_SCHEDULERS"
+
+cat >>confdefs.h <<\_ACEOF
+#define ERTS_DIRTY_SCHEDULERS 1
+_ACEOF
+
+
+cat >>confdefs.h <<\_ACEOF
+#define ERL_NIF_DIRTY_SCHEDULER_SUPPORT 1
+_ACEOF
+
+
+cat >>confdefs.h <<\_ACEOF
+#define ERL_DRV_DIRTY_SCHEDULER_SUPPORT 1
+_ACEOF
+
+ echo "$as_me:$LINENO: result: yes" >&5
+echo "${ECHO_T}yes" >&6
+ else
+ echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6
+ fi
+
+ disable_child_waiter_thread=no
+ case $host_os in
+ solaris*)
+ enable_child_waiter_thread=yes
+ ;;
+ linux*)
+ echo "$as_me:$LINENO: checking whether dlopen() needs to be called before first call to dlerror()" >&5
+echo $ECHO_N "checking whether dlopen() needs to be called before first call to dlerror()... $ECHO_C" >&6
+ if test "x$ETHR_THR_LIB_BASE_TYPE" != "xposix_nptl"; then
+
+cat >>confdefs.h <<\_ACEOF
+#define ERTS_NEED_DLOPEN_BEFORE_DLERROR 1
+_ACEOF
+
+ echo "$as_me:$LINENO: result: yes" >&5
+echo "${ECHO_T}yes" >&6
+ else
+ echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6
+ fi
+ if test "x$ETHR_THR_LIB_BASE_TYPE" != "xposix_nptl"; then
+ # Child waiter thread cannot be enabled
+ disable_child_waiter_thread=yes
+ enable_child_waiter_thread=no
+ fi
+ ;;
+ win32|ose)
+ # Child waiter thread cannot be enabled
+ disable_child_waiter_thread=yes
+ enable_child_waiter_thread=no
+ ;;
+ *)
+ ;;
+ esac
+
+ # Remove -D_WIN32_WINNT*, -DWINVER* and -D_GNU_SOURCE from EMU_THR_DEFS
+ # (defined in CFLAGS). Note that we want to keep these flags
+ # in ETHR_DEFS, but not in EMU_THR_DEFS.
+ new_emu_thr_defs=
+ for thr_def in $EMU_THR_DEFS; do
+ case $thr_def in
+ -D_GNU_SOURCE*|-D_WIN32_WINNT*|-DWINVER*)
+ ;;
+ *)
+ new_emu_thr_defs="$new_emu_thr_defs $thr_def"
+ ;;
+ esac
+ done
+ EMU_THR_DEFS=$new_emu_thr_defs
+
+ echo "$as_me:$LINENO: checking whether the child waiter thread should be enabled" >&5
+echo $ECHO_N "checking whether the child waiter thread should be enabled... $ECHO_C" >&6
+ if test $enable_child_waiter_thread = yes; then
+
+cat >>confdefs.h <<\_ACEOF
+#define ENABLE_CHILD_WAITER_THREAD 1
+_ACEOF
+
+ echo "$as_me:$LINENO: result: yes" >&5
+echo "${ECHO_T}yes" >&6
+ else
+ case $ERTS_BUILD_SMP_EMU-$disable_child_waiter_thread in
+ yes-no)
+ echo "$as_me:$LINENO: result: yes on SMP build, but not on non-SMP build" >&5
+echo "${ECHO_T}yes on SMP build, but not on non-SMP build" >&6;;
+ *-yes)
+
+cat >>confdefs.h <<\_ACEOF
+#define DISABLE_CHILD_WAITER_THREAD 1
+_ACEOF
+
+ echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6;;
+ *)
+ echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6;;
+ esac
+ fi
fi
-rm -f conftest.val
+
+
+
+
+
+
+if test "x$enable_lock_check" = "xno"; then
+ EMU_LOCK_CHECKING=no
else
- ac_cv_sizeof___int64=0
-fi
+ EMU_LOCK_CHECKING=yes
fi
-echo "$as_me:$LINENO: result: $ac_cv_sizeof___int64" >&5
-echo "${ECHO_T}$ac_cv_sizeof___int64" >&6
-cat >>confdefs.h <<_ACEOF
-#define SIZEOF___INT64 $ac_cv_sizeof___int64
-_ACEOF
-cat >>confdefs.h <<_ACEOF
-#define ETHR_SIZEOF___INT64 $ac_cv_sizeof___int64
-_ACEOF
-echo "$as_me:$LINENO: checking for __int128_t" >&5
-echo $ECHO_N "checking for __int128_t... $ECHO_C" >&6
-if test "${ac_cv_type___int128_t+set}" = set; then
+
+ERTS_INTERNAL_X_LIBS=
+
+echo "$as_me:$LINENO: checking for kstat_open in -lkstat" >&5
+echo $ECHO_N "checking for kstat_open in -lkstat... $ECHO_C" >&6
+if test "${ac_cv_lib_kstat_kstat_open+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
- cat >conftest.$ac_ext <<_ACEOF
+ ac_check_lib_save_LIBS=$LIBS
+LIBS="-lkstat $LIBS"
+cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
-$ac_includes_default
+
+/* Override any gcc2 internal prototype to avoid an error. */
+#ifdef __cplusplus
+extern "C"
+#endif
+/* We use char because int might match the return type of a gcc2
+ builtin and then its argument prototype would still apply. */
+char kstat_open ();
int
main ()
{
-if ((__int128_t *) 0)
- return 0;
-if (sizeof (__int128_t))
- return 0;
+kstat_open ();
;
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
- (eval $ac_compile) 2>conftest.er1
+rm -f conftest.$ac_objext conftest$ac_exeext
+if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
+ (eval $ac_link) 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
@@ -20547,56 +19176,87 @@
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; } &&
- { ac_try='test -s conftest.$ac_objext'
+ { ac_try='test -s conftest$ac_exeext'
{ (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; }; then
- ac_cv_type___int128_t=yes
+ ac_cv_lib_kstat_kstat_open=yes
else
echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
-ac_cv_type___int128_t=no
+ac_cv_lib_kstat_kstat_open=no
fi
-rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
+rm -f conftest.err conftest.$ac_objext \
+ conftest$ac_exeext conftest.$ac_ext
+LIBS=$ac_check_lib_save_LIBS
fi
-echo "$as_me:$LINENO: result: $ac_cv_type___int128_t" >&5
-echo "${ECHO_T}$ac_cv_type___int128_t" >&6
+echo "$as_me:$LINENO: result: $ac_cv_lib_kstat_kstat_open" >&5
+echo "${ECHO_T}$ac_cv_lib_kstat_kstat_open" >&6
+if test $ac_cv_lib_kstat_kstat_open = yes; then
-echo "$as_me:$LINENO: checking size of __int128_t" >&5
-echo $ECHO_N "checking size of __int128_t... $ECHO_C" >&6
-if test "${ac_cv_sizeof___int128_t+set}" = set; then
+cat >>confdefs.h <<\_ACEOF
+#define HAVE_KSTAT 1
+_ACEOF
+
+ERTS_INTERNAL_X_LIBS="$ERTS_INTERNAL_X_LIBS -lkstat"
+fi
+
+
+
+
+
+
+THR_LIBS=$ETHR_X_LIBS
+THR_DEFS=$ETHR_DEFS
+
+
+
+
+
+TERMCAP_LIB=
+
+if test "x$with_termcap" != "xno" &&
+ test "X$host" != "Xwin32"; then
+ # try these libs
+ termcap_libs="tinfo ncurses curses termcap termlib"
+
+ for termcap_lib in $termcap_libs; do
+ as_ac_Lib=`echo "ac_cv_lib_$termcap_lib''_tgetent" | $as_tr_sh`
+echo "$as_me:$LINENO: checking for tgetent in -l$termcap_lib" >&5
+echo $ECHO_N "checking for tgetent in -l$termcap_lib... $ECHO_C" >&6
+if eval "test \"\${$as_ac_Lib+set}\" = set"; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
- if test "$ac_cv_type___int128_t" = yes; then
- # The cast to unsigned long works around a bug in the HP C Compiler
- # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
- # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
- # This bug is HP SR number 8606223364.
- if test "$cross_compiling" = yes; then
- # Depending upon the size, compute the lo and hi bounds.
+ ac_check_lib_save_LIBS=$LIBS
+LIBS="-l$termcap_lib $LIBS"
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
-$ac_includes_default
+
+/* Override any gcc2 internal prototype to avoid an error. */
+#ifdef __cplusplus
+extern "C"
+#endif
+/* We use char because int might match the return type of a gcc2
+ builtin and then its argument prototype would still apply. */
+char tgetent ();
int
main ()
{
-static int test_array [1 - 2 * !(((long) (sizeof (__int128_t))) >= 0)];
-test_array [0] = 0
-
+tgetent ();
;
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
- (eval $ac_compile) 2>conftest.er1
+rm -f conftest.$ac_objext conftest$ac_exeext
+if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
+ (eval $ac_link) 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
@@ -20610,34 +19270,73 @@
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; } &&
- { ac_try='test -s conftest.$ac_objext'
+ { ac_try='test -s conftest$ac_exeext'
{ (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; }; then
- ac_lo=0 ac_mid=0
- while :; do
+ eval "$as_ac_Lib=yes"
+else
+ echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+eval "$as_ac_Lib=no"
+fi
+rm -f conftest.err conftest.$ac_objext \
+ conftest$ac_exeext conftest.$ac_ext
+LIBS=$ac_check_lib_save_LIBS
+fi
+echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Lib'}'`" >&5
+echo "${ECHO_T}`eval echo '${'$as_ac_Lib'}'`" >&6
+if test `eval echo '${'$as_ac_Lib'}'` = yes; then
+ TERMCAP_LIB="-l$termcap_lib"
+fi
+
+ if test "x$TERMCAP_LIB" != "x"; then
+ break
+ fi
+ done
+
+ if test "x$TERMCAP_LIB" = "x"; then
+ { { echo "$as_me:$LINENO: error: No curses library functions found" >&5
+echo "$as_me: error: No curses library functions found" >&2;}
+ { (exit 1); exit 1; }; }
+ fi
+fi
+
+
+
+if test "x$TERMCAP_LIB" != "x"; then
+
+
+cat >>confdefs.h <<\_ACEOF
+#define HAVE_TERMCAP 1
+_ACEOF
+
+fi
+
+if test "X$host" != "Xwin32"; then
+ echo "$as_me:$LINENO: checking for wcwidth" >&5
+echo $ECHO_N "checking for wcwidth... $ECHO_C" >&6
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
-$ac_includes_default
+#include
int
main ()
{
-static int test_array [1 - 2 * !(((long) (sizeof (__int128_t))) <= $ac_mid)];
-test_array [0] = 0
-
+wcwidth(0);
;
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
- (eval $ac_compile) 2>conftest.er1
+rm -f conftest.$ac_objext conftest$ac_exeext
+if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
+ (eval $ac_link) 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
@@ -20651,50 +19350,83 @@
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; } &&
- { ac_try='test -s conftest.$ac_objext'
+ { ac_try='test -s conftest$ac_exeext'
{ (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; }; then
- ac_hi=$ac_mid; break
+ have_wcwidth=yes
else
echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
-ac_lo=`expr $ac_mid + 1`
- if test $ac_lo -le $ac_mid; then
- ac_lo= ac_hi=
- break
- fi
- ac_mid=`expr 2 '*' $ac_mid + 1`
+have_wcwidth=no
fi
-rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
- done
-else
- echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
+rm -f conftest.err conftest.$ac_objext \
+ conftest$ac_exeext conftest.$ac_ext
+ if test $have_wcwidth = yes; then
+ echo "$as_me:$LINENO: result: yes" >&5
+echo "${ECHO_T}yes" >&6
+cat >>confdefs.h <<\_ACEOF
+#define HAVE_WCWIDTH 1
+_ACEOF
+
+ fi
+fi
+
+
+# Check whether --enable-builtin-zlib or --disable-builtin-zlib was given.
+if test "${enable_builtin_zlib+set}" = set; then
+ enableval="$enable_builtin_zlib"
+ case "$enableval" in
+ no) enable_builtin_zlib=no ;;
+ *) enable_builtin_zlib=yes ;;
+ esac
+else
+ enable_builtin_zlib=no
+fi;
+
+Z_LIB=
+
+if test "x$enable_builtin_zlib" = "xyes"; then
+ { echo "$as_me:$LINENO: Using our own built-in zlib source" >&5
+echo "$as_me: Using our own built-in zlib source" >&6;}
+else
+echo "$as_me:$LINENO: checking for zlib 1.2.5 or higher" >&5
+echo $ECHO_N "checking for zlib 1.2.5 or higher... $ECHO_C" >&6
+zlib_save_LIBS=$LIBS
+LIBS="-lz $LIBS"
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
-$ac_includes_default
+
+#include "zlib.h"
+
int
main ()
{
-static int test_array [1 - 2 * !(((long) (sizeof (__int128_t))) < 0)];
-test_array [0] = 0
+
+#if ZLIB_VERNUM >= 0x1250
+ Bytef s[1];
+ s[0] = 0;
+ (void) adler32((uLong)0, s, 1);
+#else
+#error "No zlib 1.2.5 or higher found"
+error
+#endif
;
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
- (eval $ac_compile) 2>conftest.er1
+rm -f conftest.$ac_objext conftest$ac_exeext
+if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
+ (eval $ac_link) 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
@@ -20708,34 +19440,115 @@
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; } &&
- { ac_try='test -s conftest.$ac_objext'
+ { ac_try='test -s conftest$ac_exeext'
{ (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; }; then
- ac_hi=-1 ac_mid=-1
- while :; do
- cat >conftest.$ac_ext <<_ACEOF
+
+ Z_LIB="-lz"
+
+cat >>confdefs.h <<\_ACEOF
+#define HAVE_LIBZ 1
+_ACEOF
+
+ echo "$as_me:$LINENO: result: yes" >&5
+echo "${ECHO_T}yes" >&6
+
+else
+ echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+
+ echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6
+
+fi
+rm -f conftest.err conftest.$ac_objext \
+ conftest$ac_exeext conftest.$ac_ext
+LIBS=$zlib_save_LIBS
+fi
+
+
+#--------------------------------------------------------------------
+# Check for the existence of the -lsocket and -lnsl libraries.
+# The order here is important, so that they end up in the right
+# order in the command line generated by make. Here are some
+# special considerations:
+# 1. Use "connect" and "accept" to check for -lsocket, and
+# "gethostbyname" to check for -lnsl.
+# 2. Use each function name only once: can't redo a check because
+# autoconf caches the results of the last check and won't redo it.
+# 3. Use -lnsl and -lsocket only if they supply procedures that
+# aren't already present in the normal libraries. This is because
+# IRIX 5.2 has libraries, but they aren't needed and they're
+# bogus: they goof up name resolution if used.
+# 4. On some SVR4 systems, can't use -lsocket without -lnsl too.
+# To get around this problem, check for both libraries together
+# if -lsocket doesn't work by itself.
+#--------------------------------------------------------------------
+
+erl_checkBoth=0
+echo "$as_me:$LINENO: checking for connect" >&5
+echo $ECHO_N "checking for connect... $ECHO_C" >&6
+if test "${ac_cv_func_connect+set}" = set; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+ cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
-$ac_includes_default
+/* Define connect to an innocuous variant, in case declares connect.
+ For example, HP-UX 11i declares gettimeofday. */
+#define connect innocuous_connect
+
+/* System header to define __stub macros and hopefully few prototypes,
+ which can conflict with char connect (); below.
+ Prefer to if __STDC__ is defined, since
+ exists even on freestanding compilers. */
+
+#ifdef __STDC__
+# include
+#else
+# include
+#endif
+
+#undef connect
+
+/* Override any gcc2 internal prototype to avoid an error. */
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+/* We use char because int might match the return type of a gcc2
+ builtin and then its argument prototype would still apply. */
+char connect ();
+/* The GNU C library defines this for functions which it implements
+ to always fail with ENOSYS. Some functions are actually named
+ something starting with __ and the normal name is an alias. */
+#if defined (__stub_connect) || defined (__stub___connect)
+choke me
+#else
+char (*f) () = connect;
+#endif
+#ifdef __cplusplus
+}
+#endif
+
int
main ()
{
-static int test_array [1 - 2 * !(((long) (sizeof (__int128_t))) >= $ac_mid)];
-test_array [0] = 0
-
+return f != connect;
;
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
- (eval $ac_compile) 2>conftest.er1
+rm -f conftest.$ac_objext conftest$ac_exeext
+if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
+ (eval $ac_link) 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
@@ -20749,58 +19562,57 @@
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; } &&
- { ac_try='test -s conftest.$ac_objext'
+ { ac_try='test -s conftest$ac_exeext'
{ (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; }; then
- ac_lo=$ac_mid; break
+ ac_cv_func_connect=yes
else
echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
-ac_hi=`expr '(' $ac_mid ')' - 1`
- if test $ac_mid -le $ac_hi; then
- ac_lo= ac_hi=
- break
- fi
- ac_mid=`expr 2 '*' $ac_mid`
+ac_cv_func_connect=no
fi
-rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
- done
-else
- echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-ac_lo= ac_hi=
+rm -f conftest.err conftest.$ac_objext \
+ conftest$ac_exeext conftest.$ac_ext
fi
-rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
+echo "$as_me:$LINENO: result: $ac_cv_func_connect" >&5
+echo "${ECHO_T}$ac_cv_func_connect" >&6
+if test $ac_cv_func_connect = yes; then
+ erl_checkSocket=0
+else
+ erl_checkSocket=1
fi
-rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
-# Binary search between lo and hi bounds.
-while test "x$ac_lo" != "x$ac_hi"; do
- ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
- cat >conftest.$ac_ext <<_ACEOF
+
+if test "$erl_checkSocket" = 1; then
+ echo "$as_me:$LINENO: checking for main in -lsocket" >&5
+echo $ECHO_N "checking for main in -lsocket... $ECHO_C" >&6
+if test "${ac_cv_lib_socket_main+set}" = set; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+ ac_check_lib_save_LIBS=$LIBS
+LIBS="-lsocket $LIBS"
+cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
-$ac_includes_default
+
+
int
main ()
{
-static int test_array [1 - 2 * !(((long) (sizeof (__int128_t))) <= $ac_mid)];
-test_array [0] = 0
-
+main ();
;
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
- (eval $ac_compile) 2>conftest.er1
+rm -f conftest.$ac_objext conftest$ac_exeext
+if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
+ (eval $ac_link) 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
@@ -20814,36 +19626,39 @@
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; } &&
- { ac_try='test -s conftest.$ac_objext'
+ { ac_try='test -s conftest$ac_exeext'
{ (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; }; then
- ac_hi=$ac_mid
+ ac_cv_lib_socket_main=yes
else
echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
-ac_lo=`expr '(' $ac_mid ')' + 1`
+ac_cv_lib_socket_main=no
fi
-rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
-done
-case $ac_lo in
-?*) ac_cv_sizeof___int128_t=$ac_lo;;
-'') { { echo "$as_me:$LINENO: error: cannot compute sizeof (__int128_t), 77
-See \`config.log' for more details." >&5
-echo "$as_me: error: cannot compute sizeof (__int128_t), 77
-See \`config.log' for more details." >&2;}
- { (exit 1); exit 1; }; } ;;
-esac
+rm -f conftest.err conftest.$ac_objext \
+ conftest$ac_exeext conftest.$ac_ext
+LIBS=$ac_check_lib_save_LIBS
+fi
+echo "$as_me:$LINENO: result: $ac_cv_lib_socket_main" >&5
+echo "${ECHO_T}$ac_cv_lib_socket_main" >&6
+if test $ac_cv_lib_socket_main = yes; then
+ LIBS="$LIBS -lsocket"
else
- if test "$cross_compiling" = yes; then
- { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling
-See \`config.log' for more details." >&5
-echo "$as_me: error: cannot run test program while cross compiling
-See \`config.log' for more details." >&2;}
- { (exit 1); exit 1; }; }
+ erl_checkBoth=1
+fi
+
+fi
+if test "$erl_checkBoth" = 1; then
+ tk_oldLibs=$LIBS
+ LIBS="$LIBS -lsocket -lnsl"
+ echo "$as_me:$LINENO: checking for accept" >&5
+echo $ECHO_N "checking for accept... $ECHO_C" >&6
+if test "${ac_cv_func_accept+set}" = set; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
else
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
@@ -20851,121 +19666,151 @@
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
-$ac_includes_default
-long longval () { return (long) (sizeof (__int128_t)); }
-unsigned long ulongval () { return (long) (sizeof (__int128_t)); }
-#include
-#include
+/* Define accept to an innocuous variant, in case declares accept.
+ For example, HP-UX 11i declares gettimeofday. */
+#define accept innocuous_accept
+
+/* System header to define __stub macros and hopefully few prototypes,
+ which can conflict with char accept (); below.
+ Prefer to if __STDC__ is defined, since
+ exists even on freestanding compilers. */
+
+#ifdef __STDC__
+# include
+#else
+# include
+#endif
+
+#undef accept
+
+/* Override any gcc2 internal prototype to avoid an error. */
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+/* We use char because int might match the return type of a gcc2
+ builtin and then its argument prototype would still apply. */
+char accept ();
+/* The GNU C library defines this for functions which it implements
+ to always fail with ENOSYS. Some functions are actually named
+ something starting with __ and the normal name is an alias. */
+#if defined (__stub_accept) || defined (__stub___accept)
+choke me
+#else
+char (*f) () = accept;
+#endif
+#ifdef __cplusplus
+}
+#endif
+
int
main ()
{
-
- FILE *f = fopen ("conftest.val", "w");
- if (! f)
- exit (1);
- if (((long) (sizeof (__int128_t))) < 0)
- {
- long i = longval ();
- if (i != ((long) (sizeof (__int128_t))))
- exit (1);
- fprintf (f, "%ld\n", i);
- }
- else
- {
- unsigned long i = ulongval ();
- if (i != ((long) (sizeof (__int128_t))))
- exit (1);
- fprintf (f, "%lu\n", i);
- }
- exit (ferror (f) || fclose (f) != 0);
-
+return f != accept;
;
return 0;
}
_ACEOF
-rm -f conftest$ac_exeext
+rm -f conftest.$ac_objext conftest$ac_exeext
if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
- (eval $ac_link) 2>&5
+ (eval $ac_link) 2>conftest.er1
ac_status=$?
+ grep -v '^ *+' conftest.er1 >conftest.err
+ rm -f conftest.er1
+ cat conftest.err >&5
echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
+ (exit $ac_status); } &&
+ { ac_try='test -z "$ac_c_werror_flag"
+ || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); }; } &&
+ { ac_try='test -s conftest$ac_exeext'
{ (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; }; then
- ac_cv_sizeof___int128_t=`cat conftest.val`
+ ac_cv_func_accept=yes
else
- echo "$as_me: program exited with status $ac_status" >&5
-echo "$as_me: failed program was:" >&5
+ echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
-( exit $ac_status )
-{ { echo "$as_me:$LINENO: error: cannot compute sizeof (__int128_t), 77
-See \`config.log' for more details." >&5
-echo "$as_me: error: cannot compute sizeof (__int128_t), 77
-See \`config.log' for more details." >&2;}
- { (exit 1); exit 1; }; }
-fi
-rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
+ac_cv_func_accept=no
fi
+rm -f conftest.err conftest.$ac_objext \
+ conftest$ac_exeext conftest.$ac_ext
fi
-rm -f conftest.val
+echo "$as_me:$LINENO: result: $ac_cv_func_accept" >&5
+echo "${ECHO_T}$ac_cv_func_accept" >&6
+if test $ac_cv_func_accept = yes; then
+ erl_checkNsl=0
else
- ac_cv_sizeof___int128_t=0
-fi
+ LIBS=$tk_oldLibs
fi
-echo "$as_me:$LINENO: result: $ac_cv_sizeof___int128_t" >&5
-echo "${ECHO_T}$ac_cv_sizeof___int128_t" >&6
-cat >>confdefs.h <<_ACEOF
-#define SIZEOF___INT128_T $ac_cv_sizeof___int128_t
-_ACEOF
-
-
-
-cat >>confdefs.h <<_ACEOF
-#define ETHR_SIZEOF___INT128_T $ac_cv_sizeof___int128_t
-_ACEOF
-
-
-
-case X$erl_xcomp_bigendian in
- X) ;;
- Xyes|Xno) ac_cv_c_bigendian=$erl_xcomp_bigendian;;
- *) { { echo "$as_me:$LINENO: error: Bad erl_xcomp_bigendian value: $erl_xcomp_bigendian" >&5
-echo "$as_me: error: Bad erl_xcomp_bigendian value: $erl_xcomp_bigendian" >&2;}
- { (exit 1); exit 1; }; };;
-esac
-echo "$as_me:$LINENO: checking whether byte ordering is bigendian" >&5
-echo $ECHO_N "checking whether byte ordering is bigendian... $ECHO_C" >&6
-if test "${ac_cv_c_bigendian+set}" = set; then
+fi
+echo "$as_me:$LINENO: checking for gethostbyname" >&5
+echo $ECHO_N "checking for gethostbyname... $ECHO_C" >&6
+if test "${ac_cv_func_gethostbyname+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
- # See if sys/param.h defines the BYTE_ORDER macro.
-cat >conftest.$ac_ext <<_ACEOF
+ cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
-#include
-#include
+/* Define gethostbyname to an innocuous variant, in case declares gethostbyname.
+ For example, HP-UX 11i declares gettimeofday. */
+#define gethostbyname innocuous_gethostbyname
-int
-main ()
+/* System header to define __stub macros and hopefully few prototypes,
+ which can conflict with char gethostbyname (); below.
+ Prefer to if __STDC__ is defined, since
+ exists even on freestanding compilers. */
+
+#ifdef __STDC__
+# include
+#else
+# include
+#endif
+
+#undef gethostbyname
+
+/* Override any gcc2 internal prototype to avoid an error. */
+#ifdef __cplusplus
+extern "C"
{
-#if !BYTE_ORDER || !BIG_ENDIAN || !LITTLE_ENDIAN
- bogus endian macros
+#endif
+/* We use char because int might match the return type of a gcc2
+ builtin and then its argument prototype would still apply. */
+char gethostbyname ();
+/* The GNU C library defines this for functions which it implements
+ to always fail with ENOSYS. Some functions are actually named
+ something starting with __ and the normal name is an alias. */
+#if defined (__stub_gethostbyname) || defined (__stub___gethostbyname)
+choke me
+#else
+char (*f) () = gethostbyname;
+#endif
+#ifdef __cplusplus
+}
#endif
+int
+main ()
+{
+return f != gethostbyname;
;
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
- (eval $ac_compile) 2>conftest.er1
+rm -f conftest.$ac_objext conftest$ac_exeext
+if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
+ (eval $ac_link) 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
@@ -20979,36 +19824,53 @@
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; } &&
- { ac_try='test -s conftest.$ac_objext'
+ { ac_try='test -s conftest$ac_exeext'
{ (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; }; then
- # It does; now see whether it defined to BIG_ENDIAN or not.
+ ac_cv_func_gethostbyname=yes
+else
+ echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+ac_cv_func_gethostbyname=no
+fi
+rm -f conftest.err conftest.$ac_objext \
+ conftest$ac_exeext conftest.$ac_ext
+fi
+echo "$as_me:$LINENO: result: $ac_cv_func_gethostbyname" >&5
+echo "${ECHO_T}$ac_cv_func_gethostbyname" >&6
+if test $ac_cv_func_gethostbyname = yes; then
+ :
+else
+ echo "$as_me:$LINENO: checking for main in -lnsl" >&5
+echo $ECHO_N "checking for main in -lnsl... $ECHO_C" >&6
+if test "${ac_cv_lib_nsl_main+set}" = set; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+ ac_check_lib_save_LIBS=$LIBS
+LIBS="-lnsl $LIBS"
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
-#include
-#include
+
int
main ()
{
-#if BYTE_ORDER != BIG_ENDIAN
- not big endian
-#endif
-
+main ();
;
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
- (eval $ac_compile) 2>conftest.er1
+rm -f conftest.$ac_objext conftest$ac_exeext
+if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
+ (eval $ac_link) 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
@@ -21022,51 +19884,90 @@
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; } &&
- { ac_try='test -s conftest.$ac_objext'
+ { ac_try='test -s conftest$ac_exeext'
{ (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; }; then
- ac_cv_c_bigendian=yes
+ ac_cv_lib_nsl_main=yes
else
echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
-ac_cv_c_bigendian=no
+ac_cv_lib_nsl_main=no
+fi
+rm -f conftest.err conftest.$ac_objext \
+ conftest$ac_exeext conftest.$ac_ext
+LIBS=$ac_check_lib_save_LIBS
+fi
+echo "$as_me:$LINENO: result: $ac_cv_lib_nsl_main" >&5
+echo "${ECHO_T}$ac_cv_lib_nsl_main" >&6
+if test $ac_cv_lib_nsl_main = yes; then
+ LIBS="$LIBS -lnsl"
fi
-rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
-else
- echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-# It does not; compile a test program.
-if test "$cross_compiling" = yes; then
- # try to guess the endianness by grepping values into an object file
- ac_cv_c_bigendian=unknown
+fi
+
+echo "$as_me:$LINENO: checking for gethostbyname_r" >&5
+echo $ECHO_N "checking for gethostbyname_r... $ECHO_C" >&6
+if test "${ac_cv_func_gethostbyname_r+set}" = set; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
+else
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
-short ascii_mm[] = { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 };
-short ascii_ii[] = { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 };
-void _ascii () { char *s = (char *) ascii_mm; s = (char *) ascii_ii; }
-short ebcdic_ii[] = { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 };
-short ebcdic_mm[] = { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 };
-void _ebcdic () { char *s = (char *) ebcdic_mm; s = (char *) ebcdic_ii; }
-int
-main ()
-{
- _ascii (); _ebcdic ();
+/* Define gethostbyname_r to an innocuous variant, in case declares gethostbyname_r.
+ For example, HP-UX 11i declares gettimeofday. */
+#define gethostbyname_r innocuous_gethostbyname_r
+
+/* System header to define __stub macros and hopefully few prototypes,
+ which can conflict with char gethostbyname_r (); below.
+ Prefer to if __STDC__ is defined, since
+ exists even on freestanding compilers. */
+
+#ifdef __STDC__
+# include
+#else
+# include
+#endif
+
+#undef gethostbyname_r
+
+/* Override any gcc2 internal prototype to avoid an error. */
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+/* We use char because int might match the return type of a gcc2
+ builtin and then its argument prototype would still apply. */
+char gethostbyname_r ();
+/* The GNU C library defines this for functions which it implements
+ to always fail with ENOSYS. Some functions are actually named
+ something starting with __ and the normal name is an alias. */
+#if defined (__stub_gethostbyname_r) || defined (__stub___gethostbyname_r)
+choke me
+#else
+char (*f) () = gethostbyname_r;
+#endif
+#ifdef __cplusplus
+}
+#endif
+
+int
+main ()
+{
+return f != gethostbyname_r;
;
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
- (eval $ac_compile) 2>conftest.er1
+rm -f conftest.$ac_objext conftest$ac_exeext
+if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
+ (eval $ac_link) 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
@@ -21080,255 +19981,215 @@
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; } &&
- { ac_try='test -s conftest.$ac_objext'
+ { ac_try='test -s conftest$ac_exeext'
{ (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; }; then
- if grep BIGenDianSyS conftest.$ac_objext >/dev/null ; then
- ac_cv_c_bigendian=yes
-fi
-if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then
- if test "$ac_cv_c_bigendian" = unknown; then
- ac_cv_c_bigendian=no
- else
- # finding both strings is unlikely to happen, but who knows?
- ac_cv_c_bigendian=unknown
- fi
-fi
+ ac_cv_func_gethostbyname_r=yes
else
echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
+ac_cv_func_gethostbyname_r=no
fi
-rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
-else
- cat >conftest.$ac_ext <<_ACEOF
+rm -f conftest.err conftest.$ac_objext \
+ conftest$ac_exeext conftest.$ac_ext
+fi
+echo "$as_me:$LINENO: result: $ac_cv_func_gethostbyname_r" >&5
+echo "${ECHO_T}$ac_cv_func_gethostbyname_r" >&6
+if test $ac_cv_func_gethostbyname_r = yes; then
+ have_gethostbyname_r=yes
+fi
+
+
+
+if test "$have_gethostbyname_r" = yes; then
+ # OK, so we have gethostbyname_r() - but do we know how to call it...?
+ # (if not, HAVE_GETHOSTBYNAME_R will not be defined at all)
+ case $host_os in
+ solaris2*)
+
+cat >>confdefs.h <<\_ACEOF
+#define HAVE_GETHOSTBYNAME_R GHBN_R_SOLARIS
+_ACEOF
+
+ ;;
+ aix4*)
+ # AIX version also needs "struct hostent_data" defn
+ cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
+#include
int
main ()
{
- /* Are we little or big endian? From Harbison&Steele. */
- union
- {
- long l;
- char c[sizeof (long)];
- } u;
- u.l = 1;
- exit (u.c[sizeof (long) - 1] == 1);
+struct hostent_data hd;
+ ;
+ return 0;
}
_ACEOF
-rm -f conftest$ac_exeext
-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
- (eval $ac_link) 2>&5
+rm -f conftest.$ac_objext
+if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
+ (eval $ac_compile) 2>conftest.er1
ac_status=$?
+ grep -v '^ *+' conftest.er1 >conftest.err
+ rm -f conftest.er1
+ cat conftest.err >&5
echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
+ (exit $ac_status); } &&
+ { ac_try='test -z "$ac_c_werror_flag"
+ || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); }; } &&
+ { ac_try='test -s conftest.$ac_objext'
{ (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; }; then
- ac_cv_c_bigendian=no
+
+cat >>confdefs.h <<\_ACEOF
+#define HAVE_GETHOSTBYNAME_R GHBN_R_AIX
+_ACEOF
+
else
- echo "$as_me: program exited with status $ac_status" >&5
-echo "$as_me: failed program was:" >&5
+ echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
-( exit $ac_status )
-ac_cv_c_bigendian=yes
-fi
-rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
-fi
fi
rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-echo "$as_me:$LINENO: result: $ac_cv_c_bigendian" >&5
-echo "${ECHO_T}$ac_cv_c_bigendian" >&6
-case $ac_cv_c_bigendian in
- yes)
-
-cat >>confdefs.h <<\_ACEOF
-#define WORDS_BIGENDIAN 1
+ ;;
+ *)
+ cat >conftest.$ac_ext <<_ACEOF
+/* confdefs.h. */
_ACEOF
- ;;
- no)
- ;;
- *)
- { { echo "$as_me:$LINENO: error: unknown endianness
-presetting ac_cv_c_bigendian=no (or yes) will help" >&5
-echo "$as_me: error: unknown endianness
-presetting ac_cv_c_bigendian=no (or yes) will help" >&2;}
- { (exit 1); exit 1; }; } ;;
-esac
-
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h. */
+#include
+ #ifdef __GLIBC__
+ yes
+ #endif
-if test "$ac_cv_c_bigendian" = "yes"; then
+_ACEOF
+if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
+ $EGREP "yes" >/dev/null 2>&1; then
cat >>confdefs.h <<\_ACEOF
-#define ETHR_BIGENDIAN 1
+#define HAVE_GETHOSTBYNAME_R GHBN_R_GLIBC
_ACEOF
fi
+rm -f conftest*
-case X$erl_xcomp_double_middle_endian in
- X) ;;
- Xyes|Xno|Xunknown) ac_cv_c_double_middle_endian=$erl_xcomp_double_middle_endian;;
- *) { { echo "$as_me:$LINENO: error: Bad erl_xcomp_double_middle_endian value: $erl_xcomp_double_middle_endian" >&5
-echo "$as_me: error: Bad erl_xcomp_double_middle_endian value: $erl_xcomp_double_middle_endian" >&2;}
- { (exit 1); exit 1; }; };;
-esac
+ ;;
+ esac
+fi
-echo "$as_me:$LINENO: checking whether double word ordering is middle-endian" >&5
-echo $ECHO_N "checking whether double word ordering is middle-endian... $ECHO_C" >&6
-if test "${ac_cv_c_double_middle_endian+set}" = set; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
-else
- # It does not; compile a test program.
-if test "$cross_compiling" = yes; then
- ac_cv_c_double_middle=unknown
-else
- cat >conftest.$ac_ext <<_ACEOF
+echo "$as_me:$LINENO: checking for working posix_openpt implementation" >&5
+echo $ECHO_N "checking for working posix_openpt implementation... $ECHO_C" >&6
+cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
+
+#define _XOPEN_SOURCE 600
#include
+#include
int
-main(void)
+main ()
{
- int i = 0;
- int zero = 0;
- int bigendian;
- int zero_index = 0;
-
- union
- {
- long int l;
- char c[sizeof (long int)];
- } u;
-
- /* we'll use the one with 32-bit words */
- union
- {
- double d;
- unsigned int c[2];
- } vint;
-
- union
- {
- double d;
- unsigned long c[2];
- } vlong;
-
- union
- {
- double d;
- unsigned short c[2];
- } vshort;
-
-
- /* Are we little or big endian? From Harbison&Steele. */
- u.l = 1;
- bigendian = (u.c[sizeof (long int) - 1] == 1);
-
- zero_index = bigendian ? 1 : 0;
- vint.d = 1.0;
- vlong.d = 1.0;
- vshort.d = 1.0;
-
- if (sizeof(unsigned int) == 4)
- {
- if (vint.c[zero_index] != 0)
- zero = 1;
- }
- else if (sizeof(unsigned long) == 4)
- {
- if (vlong.c[zero_index] != 0)
- zero = 1;
- }
- else if (sizeof(unsigned short) == 4)
- {
- if (vshort.c[zero_index] != 0)
- zero = 1;
- }
+ int mfd = posix_openpt(O_RDWR);
+ ptsname(mfd);
+ grantpt(mfd);
+ unlockpt(mfd);
+ return mfd;
- exit (zero);
+ ;
+ return 0;
}
-
_ACEOF
-rm -f conftest$ac_exeext
+rm -f conftest.$ac_objext conftest$ac_exeext
if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
- (eval $ac_link) 2>&5
+ (eval $ac_link) 2>conftest.er1
ac_status=$?
+ grep -v '^ *+' conftest.er1 >conftest.err
+ rm -f conftest.er1
+ cat conftest.err >&5
echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
+ (exit $ac_status); } &&
+ { ac_try='test -z "$ac_c_werror_flag"
+ || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); }; } &&
+ { ac_try='test -s conftest$ac_exeext'
{ (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; }; then
- ac_cv_c_double_middle_endian=no
+ working_posix_openpt=yes
else
- echo "$as_me: program exited with status $ac_status" >&5
-echo "$as_me: failed program was:" >&5
+ echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
-( exit $ac_status )
-ac_cv_c_double_middle_endian=yes
-fi
-rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
-fi
+working_posix_openpt=no
fi
-echo "$as_me:$LINENO: result: $ac_cv_c_double_middle_endian" >&5
-echo "${ECHO_T}$ac_cv_c_double_middle_endian" >&6
-case $ac_cv_c_double_middle_endian in
- yes)
+rm -f conftest.err conftest.$ac_objext \
+ conftest$ac_exeext conftest.$ac_ext
+
+if test "X$working_posix_openpt" = "Xyes"; then
cat >>confdefs.h <<\_ACEOF
-#define DOUBLE_MIDDLE_ENDIAN 1
+#define HAVE_WORKING_POSIX_OPENPT 1
_ACEOF
- ;;
- no)
- ;;
- *)
- { echo "$as_me:$LINENO: WARNING: unknown double endianness
-presetting ac_cv_c_double_middle_endian=no (or yes) will help" >&5
-echo "$as_me: WARNING: unknown double endianness
-presetting ac_cv_c_double_middle_endian=no (or yes) will help" >&2;} ;;
-esac
+ echo "$as_me:$LINENO: result: yes" >&5
+echo "${ECHO_T}yes" >&6
+else
+ echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6
+fi
-ETHR_X86_SSE2_ASM=no
-case "$GCC-$ac_cv_sizeof_void_p-$host_cpu" in
- yes-4-i86pc | yes-4-i*86 | yes-4-x86_64 | yes-4-amd64)
- echo "$as_me:$LINENO: checking for gcc sse2 asm support" >&5
-echo $ECHO_N "checking for gcc sse2 asm support... $ECHO_C" >&6
- save_CFLAGS="$CFLAGS"
- CFLAGS="$CFLAGS -msse2"
- gcc_sse2_asm=no
- cat >conftest.$ac_ext <<_ACEOF
+echo "$as_me:$LINENO: checking if netdb.h requires netinet/in.h to be previously included" >&5
+echo $ECHO_N "checking if netdb.h requires netinet/in.h to be previously included... $ECHO_C" >&6
+cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
-
+#include
+_ACEOF
+if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
+ $EGREP "sockaddr_in" >/dev/null 2>&1; then
+ cat >conftest.$ac_ext <<_ACEOF
+/* confdefs.h. */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h. */
+#include
+ #include
int
main ()
{
-
- long long x, *y;
- __asm__ __volatile__("movq %1, %0\n\t" : "=x"(x) : "m"(*y) : "memory");
-
+return 0;
;
return 0;
}
@@ -21355,71 +20216,46 @@
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; }; then
- gcc_sse2_asm=yes
+ need_in_h=yes
else
echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
+need_in_h=no
fi
rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
- CFLAGS="$save_CFLAGS"
- echo "$as_me:$LINENO: result: $gcc_sse2_asm" >&5
-echo "${ECHO_T}$gcc_sse2_asm" >&6
- if test "$gcc_sse2_asm" = "yes"; then
+else
+ need_in_h=no
+fi
+rm -f conftest*
+
+
+if test $need_in_h = yes; then
cat >>confdefs.h <<\_ACEOF
-#define ETHR_GCC_HAVE_SSE2_ASM_SUPPORT 1
+#define NETDB_H_NEEDS_IN_H 1
_ACEOF
- ETHR_X86_SSE2_ASM=yes
- fi
- ;;
- *)
- ;;
-esac
+ echo "$as_me:$LINENO: result: yes" >&5
+echo "${ECHO_T}yes" >&6
+else
+ echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6
+fi
-case "$GCC-$host_cpu" in
- yes-i86pc | yes-i*86 | yes-x86_64 | yes-amd64)
- gcc_dw_cmpxchg_asm=no
- echo "$as_me:$LINENO: checking for gcc double word cmpxchg asm support" >&5
-echo $ECHO_N "checking for gcc double word cmpxchg asm support... $ECHO_C" >&6
- cat >conftest.$ac_ext <<_ACEOF
+echo "$as_me:$LINENO: checking for socklen_t" >&5
+echo $ECHO_N "checking for socklen_t... $ECHO_C" >&6
+cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
-
+#include
int
main ()
{
-
- char xchgd;
- long new[2], xchg[2], *p;
- __asm__ __volatile__(
-#if ETHR_SIZEOF_PTR == 4 && defined(__PIC__) && __PIC__
- "pushl %%ebx\n\t"
- "movl %8, %%ebx\n\t"
-#endif
-#if ETHR_SIZEOF_PTR == 4
- "lock; cmpxchg8b %0\n\t"
-#else
- "lock; cmpxchg16b %0\n\t"
-#endif
- "setz %3\n\t"
-#if ETHR_SIZEOF_PTR == 4 && defined(__PIC__) && __PIC__
- "popl %%ebx\n\t"
-#endif
- : "=m"(*p), "=d"(xchg[1]), "=a"(xchg[0]), "=c"(xchgd)
- : "m"(*p), "1"(xchg[1]), "2"(xchg[0]), "3"(new[1]),
-#if ETHR_SIZEOF_PTR == 4 && defined(__PIC__) && __PIC__
- "r"(new[0])
-#else
- "b"(new[0])
-#endif
- : "cc", "memory");
-
-
+socklen_t test;
;
return 0;
}
@@ -21446,42 +20282,45 @@
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; }; then
- gcc_dw_cmpxchg_asm=yes
+ have_socklen_t=yes
else
echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
+have_socklen_t=no
fi
-rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
- if test $gcc_dw_cmpxchg_asm = no && test $ac_cv_sizeof_void_p = 4; then
- cat >conftest.$ac_ext <<_ACEOF
+rm -f conftest.err conftest.$ac_objext conftest.$ac_ext,
+
+if test $have_socklen_t = yes; then
+
+cat >>confdefs.h <<\_ACEOF
+#define HAVE_SOCKLEN_T 1
+_ACEOF
+
+ echo "$as_me:$LINENO: result: yes" >&5
+echo "${ECHO_T}yes" >&6
+else
+ echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6
+fi
+
+
+echo "$as_me:$LINENO: checking for h_errno declaration in netdb.h" >&5
+echo $ECHO_N "checking for h_errno declaration in netdb.h... $ECHO_C" >&6
+if test "${ac_cv_decl_h_errno+set}" = set; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+ cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
-
+#include
int
main ()
{
-
- char xchgd;
- long new[2], xchg[2], *p;
-#if !defined(__PIC__) || !__PIC__
-# error nope
-#endif
- __asm__ __volatile__(
- "pushl %%ebx\n\t"
- "movl (%7), %%ebx\n\t"
- "movl 4(%7), %%ecx\n\t"
- "lock; cmpxchg8b %0\n\t"
- "setz %3\n\t"
- "popl %%ebx\n\t"
- : "=m"(*p), "=d"(xchg[1]), "=a"(xchg[0]), "=c"(xchgd)
- : "m"(*p), "1"(xchg[1]), "2"(xchg[0]), "3"(new)
- : "cc", "memory");
-
-
+int err = h_errno;
;
return 0;
}
@@ -21508,87 +20347,57 @@
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; }; then
- gcc_dw_cmpxchg_asm=yes
+ ac_cv_decl_h_errno=yes
else
echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
+ac_cv_decl_h_errno=no
fi
rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
- if test "$gcc_dw_cmpxchg_asm" = "yes"; then
-
-cat >>confdefs.h <<\_ACEOF
-#define ETHR_CMPXCHG8B_REGISTER_SHORTAGE 1
-_ACEOF
-
- fi
- fi
- echo "$as_me:$LINENO: result: $gcc_dw_cmpxchg_asm" >&5
-echo "${ECHO_T}$gcc_dw_cmpxchg_asm" >&6
- if test "$gcc_dw_cmpxchg_asm" = "yes"; then
-
-cat >>confdefs.h <<\_ACEOF
-#define ETHR_GCC_HAVE_DW_CMPXCHG_ASM_SUPPORT 1
-_ACEOF
-
- fi;;
- *)
- ;;
-esac
-
+fi
+echo "$as_me:$LINENO: result: $ac_cv_decl_h_errno" >&5
+echo "${ECHO_T}$ac_cv_decl_h_errno" >&6
+if test $ac_cv_decl_h_errno = yes; then
cat >>confdefs.h <<\_ACEOF
-#define ETHR_HAVE_ETHREAD_DEFINES 1
+#define H_ERRNO_DECLARED 1
_ACEOF
+fi
+saved_cppflags=$CPPFLAGS
+CPPFLAGS="$CPPFLAGS $EMU_THR_DEFS"
-
-
-if test "X$ETHR_LIB_NAME" = "X"; then
- found_threads=no
+ac_header_dirent=no
+for ac_hdr in dirent.h sys/ndir.h sys/dir.h ndir.h; do
+ as_ac_Header=`echo "ac_cv_header_dirent_$ac_hdr" | $as_tr_sh`
+echo "$as_me:$LINENO: checking for $ac_hdr that defines DIR" >&5
+echo $ECHO_N "checking for $ac_hdr that defines DIR... $ECHO_C" >&6
+if eval "test \"\${$as_ac_Header+set}\" = set"; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
else
- found_threads=yes
-fi
-
-
-ERTS_BUILD_SMP_EMU=$enable_smp_support
-echo "$as_me:$LINENO: checking whether an emulator with smp support should be built" >&5
-echo $ECHO_N "checking whether an emulator with smp support should be built... $ECHO_C" >&6
-case $ERTS_BUILD_SMP_EMU in
- yes)
- echo "$as_me:$LINENO: result: yes; enabled by user" >&5
-echo "${ECHO_T}yes; enabled by user" >&6
- ;;
- no)
- echo "$as_me:$LINENO: result: no; disabled by user" >&5
-echo "${ECHO_T}no; disabled by user" >&6
- ;;
- unknown)
- cat >conftest.$ac_ext <<_ACEOF
+ cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
+#include
+#include <$ac_hdr>
int
main ()
{
-
- #if __GNUC__ >= 3 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 95)
- ;
- #else
- #error old or no gcc
- #endif
-
+if ((DIR *) 0)
+return 0;
;
return 0;
}
@@ -21615,196 +20424,53 @@
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; }; then
- gcc_smp=okgcc
+ eval "$as_ac_Header=yes"
else
echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
-gcc_smp=oldornogcc
+eval "$as_ac_Header=no"
fi
rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
- ERTS_BUILD_SMP_EMU=yes
- case "$enable_threads-$gcc_smp-$found_threads-$host_os" in
-
- no-*)
- echo "$as_me:$LINENO: result: no; threads disabled by user" >&5
-echo "${ECHO_T}no; threads disabled by user" >&6
- ERTS_BUILD_SMP_EMU=no
- ;;
-
- *-okgcc-yes-*)
- echo "$as_me:$LINENO: result: yes" >&5
-echo "${ECHO_T}yes" >&6
- ERTS_BUILD_SMP_EMU=yes
- ;;
-
- *-win32)
- echo "$as_me:$LINENO: result: yes" >&5
-echo "${ECHO_T}yes" >&6
- ERTS_BUILD_SMP_EMU=yes
- ;;
-
- *-oldornogcc-*)
- echo "$as_me:$LINENO: result: no; old gcc or no gcc found" >&5
-echo "${ECHO_T}no; old gcc or no gcc found" >&6
- ERTS_BUILD_SMP_EMU=no
- ;;
-
- *)
- echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6
- ERTS_BUILD_SMP_EMU=no
- ;;
- esac
- ;;
-esac
-
-if test $ERTS_BUILD_SMP_EMU = yes; then
-
- if test $found_threads = no; then
- { { echo "$as_me:$LINENO: error: cannot build smp enabled emulator since no thread library was found" >&5
-echo "$as_me: error: cannot build smp enabled emulator since no thread library was found" >&2;}
- { (exit 1); exit 1; }; }
- fi
-
-
-cat >>confdefs.h <<\_ACEOF
-#define ERTS_HAVE_SMP_EMU 1
-_ACEOF
-
-
- test "X$smp_require_native_atomics" = "Xyes" &&
-
-cat >>confdefs.h <<\_ACEOF
-#define ETHR_SMP_REQUIRE_NATIVE_IMPLS 1
+fi
+echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
+echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
+if test `eval echo '${'$as_ac_Header'}'` = yes; then
+ cat >>confdefs.h <<_ACEOF
+#define `echo "HAVE_$ac_hdr" | $as_tr_cpp` 1
_ACEOF
-
- case "$ethr_have_native_atomics-$smp_require_native_atomics-$ethr_have_native_spinlock" in
- yes-*)
- if test "$ethr_native_atomic_implementation" = "gcc_sync"; then
- test -f "$ERL_TOP/erts/CONF_INFO" ||
- echo "" > "$ERL_TOP/erts/CONF_INFO"
- cat >> $ERL_TOP/erts/CONF_INFO <&5
-echo "$as_me: error: No native atomic implementation found. See the \\"Atomic Memory Operations and the VM\\" chapter of \$ERL_TOP/HOWTO/INSTALL.md for more information." >&2;}
- { (exit 1); exit 1; }; }
- ;;
-
- no-no-yes)
-
- test -f "$ERL_TOP/erts/CONF_INFO" ||
- echo "" > "$ERL_TOP/erts/CONF_INFO"
- cat >> $ERL_TOP/erts/CONF_INFO < "$ERL_TOP/erts/CONF_INFO"
- cat >> "$ERL_TOP/erts/CONF_INFO" <&5
-echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
-if eval "test \"\${$as_ac_var+set}\" = set"; then
+done
+# Two versions of opendir et al. are in -ldir and -lx on SCO Xenix.
+if test $ac_header_dirent = dirent.h; then
+ echo "$as_me:$LINENO: checking for library containing opendir" >&5
+echo $ECHO_N "checking for library containing opendir... $ECHO_C" >&6
+if test "${ac_cv_search_opendir+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
- cat >conftest.$ac_ext <<_ACEOF
+ ac_func_search_save_LIBS=$LIBS
+ac_cv_search_opendir=no
+cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
-/* Define $ac_func to an innocuous variant, in case declares $ac_func.
- For example, HP-UX 11i declares gettimeofday. */
-#define $ac_func innocuous_$ac_func
-
-/* System header to define __stub macros and hopefully few prototypes,
- which can conflict with char $ac_func (); below.
- Prefer to if __STDC__ is defined, since
- exists even on freestanding compilers. */
-
-#ifdef __STDC__
-# include
-#else
-# include
-#endif
-
-#undef $ac_func
/* Override any gcc2 internal prototype to avoid an error. */
#ifdef __cplusplus
extern "C"
-{
#endif
/* We use char because int might match the return type of a gcc2
builtin and then its argument prototype would still apply. */
-char $ac_func ();
-/* The GNU C library defines this for functions which it implements
- to always fail with ENOSYS. Some functions are actually named
- something starting with __ and the normal name is an alias. */
-#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
-choke me
-#else
-char (*f) () = $ac_func;
-#endif
-#ifdef __cplusplus
-}
-#endif
-
+char opendir ();
int
main ()
{
-return f != $ac_func;
+opendir ();
;
return 0;
}
@@ -21831,54 +20497,42 @@
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; }; then
- eval "$as_ac_var=yes"
+ ac_cv_search_opendir="none required"
else
echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
-eval "$as_ac_var=no"
fi
rm -f conftest.err conftest.$ac_objext \
conftest$ac_exeext conftest.$ac_ext
-fi
-echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
-echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
-if test `eval echo '${'$as_ac_var'}'` = yes; then
- cat >>confdefs.h <<_ACEOF
-#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
-_ACEOF
-
-fi
-done
-
-
-for ac_header in linux/falloc.h
-do
-as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
-if eval "test \"\${$as_ac_Header+set}\" = set"; then
- echo "$as_me:$LINENO: checking for $ac_header" >&5
-echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
-if eval "test \"\${$as_ac_Header+set}\" = set"; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
-fi
-echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
-echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
-else
- # Is the header compilable?
-echo "$as_me:$LINENO: checking $ac_header usability" >&5
-echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
-cat >conftest.$ac_ext <<_ACEOF
+if test "$ac_cv_search_opendir" = no; then
+ for ac_lib in dir; do
+ LIBS="-l$ac_lib $ac_func_search_save_LIBS"
+ cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
-$ac_includes_default
-#include <$ac_header>
+
+/* Override any gcc2 internal prototype to avoid an error. */
+#ifdef __cplusplus
+extern "C"
+#endif
+/* We use char because int might match the return type of a gcc2
+ builtin and then its argument prototype would still apply. */
+char opendir ();
+int
+main ()
+{
+opendir ();
+ ;
+ return 0;
+}
_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
- (eval $ac_compile) 2>conftest.er1
+rm -f conftest.$ac_objext conftest$ac_exeext
+if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
+ (eval $ac_link) 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
@@ -21892,121 +20546,95 @@
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; } &&
- { ac_try='test -s conftest.$ac_objext'
+ { ac_try='test -s conftest$ac_exeext'
{ (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; }; then
- ac_header_compiler=yes
+ ac_cv_search_opendir="-l$ac_lib"
+break
else
echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
-ac_header_compiler=no
fi
-rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
-echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
-echo "${ECHO_T}$ac_header_compiler" >&6
+rm -f conftest.err conftest.$ac_objext \
+ conftest$ac_exeext conftest.$ac_ext
+ done
+fi
+LIBS=$ac_func_search_save_LIBS
+fi
+echo "$as_me:$LINENO: result: $ac_cv_search_opendir" >&5
+echo "${ECHO_T}$ac_cv_search_opendir" >&6
+if test "$ac_cv_search_opendir" != no; then
+ test "$ac_cv_search_opendir" = "none required" || LIBS="$ac_cv_search_opendir $LIBS"
-# Is the header present?
-echo "$as_me:$LINENO: checking $ac_header presence" >&5
-echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
+fi
+
+else
+ echo "$as_me:$LINENO: checking for library containing opendir" >&5
+echo $ECHO_N "checking for library containing opendir... $ECHO_C" >&6
+if test "${ac_cv_search_opendir+set}" = set; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+ ac_func_search_save_LIBS=$LIBS
+ac_cv_search_opendir=no
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
-#include <$ac_header>
+
+/* Override any gcc2 internal prototype to avoid an error. */
+#ifdef __cplusplus
+extern "C"
+#endif
+/* We use char because int might match the return type of a gcc2
+ builtin and then its argument prototype would still apply. */
+char opendir ();
+int
+main ()
+{
+opendir ();
+ ;
+ return 0;
+}
_ACEOF
-if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
- (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
+rm -f conftest.$ac_objext conftest$ac_exeext
+if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
+ (eval $ac_link) 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
cat conftest.err >&5
echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); } >/dev/null; then
- if test -s conftest.err; then
- ac_cpp_err=$ac_c_preproc_warn_flag
- ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
- else
- ac_cpp_err=
- fi
-else
- ac_cpp_err=yes
-fi
-if test -z "$ac_cpp_err"; then
- ac_header_preproc=yes
+ (exit $ac_status); } &&
+ { ac_try='test -z "$ac_c_werror_flag"
+ || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); }; } &&
+ { ac_try='test -s conftest$ac_exeext'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); }; }; then
+ ac_cv_search_opendir="none required"
else
echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
- ac_header_preproc=no
-fi
-rm -f conftest.err conftest.$ac_ext
-echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
-echo "${ECHO_T}$ac_header_preproc" >&6
-
-# So? What about this header?
-case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
- yes:no: )
- { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
-echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
- { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
-echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
- ac_header_preproc=yes
- ;;
- no:yes:* )
- { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
-echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
- { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
-echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
- { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
-echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
- { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5
-echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;}
- { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
-echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
- { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
-echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
- (
- cat <<\_ASBOX
-## ------------------------------------------ ##
-## Report this to the AC_PACKAGE_NAME lists. ##
-## ------------------------------------------ ##
-_ASBOX
- ) |
- sed "s/^/$as_me: WARNING: /" >&2
- ;;
-esac
-echo "$as_me:$LINENO: checking for $ac_header" >&5
-echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
-if eval "test \"\${$as_ac_Header+set}\" = set"; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
-else
- eval "$as_ac_Header=\$ac_header_preproc"
-fi
-echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
-echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
-
-fi
-if test `eval echo '${'$as_ac_Header'}'` = yes; then
- cat >>confdefs.h <<_ACEOF
-#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
-_ACEOF
-
fi
-
-done
-
-echo "$as_me:$LINENO: checking whether fallocate() works" >&5
-echo $ECHO_N "checking whether fallocate() works... $ECHO_C" >&6
-if test "${i_cv_fallocate_works+set}" = set; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-
+rm -f conftest.err conftest.$ac_objext \
+ conftest$ac_exeext conftest.$ac_ext
+if test "$ac_cv_search_opendir" = no; then
+ for ac_lib in x; do
+ LIBS="-l$ac_lib $ac_func_search_save_LIBS"
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
_ACEOF
@@ -22014,20 +20642,17 @@
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
- #include
- #include
- #include
- #include
- #include
- #include
-
+/* Override any gcc2 internal prototype to avoid an error. */
+#ifdef __cplusplus
+extern "C"
+#endif
+/* We use char because int might match the return type of a gcc2
+ builtin and then its argument prototype would still apply. */
+char opendir ();
int
main ()
{
-
- int fd = creat("conftest.temp", 0600);
- fallocate(fd, FALLOC_FL_KEEP_SIZE,(off_t) 1024,(off_t) 1024);
-
+opendir ();
;
return 0;
}
@@ -22054,479 +20679,227 @@
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; }; then
- i_cv_fallocate_works=yes
+ ac_cv_search_opendir="-l$ac_lib"
+break
else
echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
-i_cv_fallocate_works=no
fi
rm -f conftest.err conftest.$ac_objext \
conftest$ac_exeext conftest.$ac_ext
-
+ done
fi
-echo "$as_me:$LINENO: result: $i_cv_fallocate_works" >&5
-echo "${ECHO_T}$i_cv_fallocate_works" >&6
-if test $i_cv_fallocate_works = yes; then
+LIBS=$ac_func_search_save_LIBS
+fi
+echo "$as_me:$LINENO: result: $ac_cv_search_opendir" >&5
+echo "${ECHO_T}$ac_cv_search_opendir" >&6
+if test "$ac_cv_search_opendir" != no; then
+ test "$ac_cv_search_opendir" = "none required" || LIBS="$ac_cv_search_opendir $LIBS"
-cat >>confdefs.h <<\_ACEOF
-#define HAVE_FALLOCATE 1
-_ACEOF
+fi
fi
-echo "$as_me:$LINENO: checking whether posix_fallocate() works" >&5
-echo $ECHO_N "checking whether posix_fallocate() works... $ECHO_C" >&6
-if test "${i_cv_posix_fallocate_works+set}" = set; then
+echo "$as_me:$LINENO: checking for ANSI C header files" >&5
+echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6
+if test "${ac_cv_header_stdc+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
-
- if test "$cross_compiling" = yes; then
-
- i_cv_posix_fallocate_works=no
-
-else
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
+#include
+#include
+#include
+#include
- #if !defined(__sun) && !defined(__sun__)
- #define _XOPEN_SOURCE 600
- #endif
- #include
- #include
- #include
- #include
- #if defined(__GLIBC__) && (__GLIBC__ < 2 || (__GLIBC__ == 2 && __GLIBC_MINOR__ < 7))
- possibly broken posix_fallocate
- #endif
- int main() {
- int fd = creat("conftest.temp", 0600);
- int ret;
- if (-1 == fd) {
- perror("creat()");
- return 2;
- }
- ret = posix_fallocate(fd, 1024, 1024) < 0 ? 1 : 0;
- unlink("conftest.temp");
- return ret;
- }
+int
+main ()
+{
+ ;
+ return 0;
+}
_ACEOF
-rm -f conftest$ac_exeext
-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
- (eval $ac_link) 2>&5
+rm -f conftest.$ac_objext
+if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
+ (eval $ac_compile) 2>conftest.er1
+ ac_status=$?
+ grep -v '^ *+' conftest.er1 >conftest.err
+ rm -f conftest.er1
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+ { ac_try='test -z "$ac_c_werror_flag"
+ || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
+ (exit $ac_status); }; } &&
+ { ac_try='test -s conftest.$ac_objext'
{ (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; }; then
-
- i_cv_posix_fallocate_works=yes
-
+ ac_cv_header_stdc=yes
else
- echo "$as_me: program exited with status $ac_status" >&5
-echo "$as_me: failed program was:" >&5
+ echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
-( exit $ac_status )
-
- i_cv_posix_fallocate_works=no
-
-fi
-rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
-fi
-
+ac_cv_header_stdc=no
fi
-echo "$as_me:$LINENO: result: $i_cv_posix_fallocate_works" >&5
-echo "${ECHO_T}$i_cv_posix_fallocate_works" >&6
-if test $i_cv_posix_fallocate_works = yes; then
+rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
-cat >>confdefs.h <<\_ACEOF
-#define HAVE_POSIX_FALLOCATE
-_ACEOF
-
-fi
-
-#
-# Figure out if the emulator should use threads. The default is set above
-# in the enable_threads variable. It can have the following values:
-#
-# no single-threaded emulator requested
-# yes multi-threaded emulator requested
-# force multi-threaded emulator required
-#
-# EMU_THR_LIB_NAME, EMU_THR_LIBS, EMU_THR_X_LIBS, and EMU_THR_DEFS is
-# used by the emulator, and can (but should not) be used by applications
-# that only require thread support when the emulator has thread support.
-# Other applications should use ETHR_LIB_NAME, ETHR_LIBS, ETHR_X_LIBS,
-# and ETHR_DEFS.
-#
-echo "$as_me:$LINENO: checking whether the emulator should use threads" >&5
-echo $ECHO_N "checking whether the emulator should use threads... $ECHO_C" >&6
-
-EMU_THR_LIB_NAME=
-EMU_THR_X_LIBS=
-EMU_THR_LIBS=
-EMU_THR_DEFS=
-emu_threads=no
-
-case "$enable_threads"-"$host_os" in
- *-win32)
- # The windows erlang emulator can never run without threads.
- # It has to be enabled or the emulator will crash. Until that
- # is fixed we force threads on win32.
- enable_threads=force ;;
- yes-osf*)
- # The emulator hang when threads are enabled on osf
- { { echo "$as_me:$LINENO: error: unresolved problems exist with threads on this platform" >&5
-echo "$as_me: error: unresolved problems exist with threads on this platform" >&2;}
- { (exit 1); exit 1; }; } ;;
- *) ;;
-esac
-
-case "$enable_threads"-"$found_threads" in
- force-yes)
- emu_threads=yes
- echo "$as_me:$LINENO: result: yes; thread support required and therefore forced" >&5
-echo "${ECHO_T}yes; thread support required and therefore forced" >&6 ;;
- yes-yes)
- emu_threads=yes
- echo "$as_me:$LINENO: result: yes; enabled by user" >&5
-echo "${ECHO_T}yes; enabled by user" >&6 ;;
- unknown-yes)
- case $host_os in
- solaris*|linux*|darwin*|win32|ose)
- emu_threads=yes
- echo "$as_me:$LINENO: result: yes; default on this platform" >&5
-echo "${ECHO_T}yes; default on this platform" >&6
- ;;
- *)
- echo "$as_me:$LINENO: result: no; default on this platform" >&5
-echo "${ECHO_T}no; default on this platform" >&6
- ;;
- esac
- ;;
- no-yes)
- echo "$as_me:$LINENO: result: no; thread support found but disabled by user" >&5
-echo "${ECHO_T}no; thread support found but disabled by user" >&6 ;;
- unknown-no|no-no)
- echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6 ;;
- force-no)
- { { echo "$as_me:$LINENO: error: thread support required but not found" >&5
-echo "$as_me: error: thread support required but not found" >&2;}
- { (exit 1); exit 1; }; } ;;
- yes-no)
- { { echo "$as_me:$LINENO: error: thread support enabled by user but not found" >&5
-echo "$as_me: error: thread support enabled by user but not found" >&2;}
- { (exit 1); exit 1; }; } ;;
- *)
- { { echo "$as_me:$LINENO: error: internal error" >&5
-echo "$as_me: error: internal error" >&2;}
- { (exit 1); exit 1; }; } ;;
-esac
-
-if test $emu_threads != yes; then
- enable_lock_check=no
- enable_lock_count=no
- echo "$as_me:$LINENO: checking whether dirty schedulers should be enabled" >&5
-echo $ECHO_N "checking whether dirty schedulers should be enabled... $ECHO_C" >&6
- if test "x$enable_dirty_schedulers" != "xno"; then
-
-cat >>confdefs.h <<\_ACEOF
-#define ERL_NIF_DIRTY_SCHEDULER_SUPPORT 1
+if test $ac_cv_header_stdc = yes; then
+ # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
+ cat >conftest.$ac_ext <<_ACEOF
+/* confdefs.h. */
_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h. */
+#include
-
-cat >>confdefs.h <<\_ACEOF
-#define ERL_DRV_DIRTY_SCHEDULER_SUPPORT 1
_ACEOF
-
- echo "$as_me:$LINENO: result: yes" >&5
-echo "${ECHO_T}yes" >&6
- else
- echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6
- fi
+if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
+ $EGREP "memchr" >/dev/null 2>&1; then
+ :
else
- # Threads enabled for emulator
- EMU_THR_LIB_NAME=$ETHR_LIB_NAME
- EMU_THR_X_LIBS=$ETHR_X_LIBS
- EMU_THR_LIBS=$ETHR_LIBS
- EMU_THR_DEFS=$ETHR_DEFS
- ENABLE_ALLOC_TYPE_VARS="$ENABLE_ALLOC_TYPE_VARS threads"
- echo "$as_me:$LINENO: checking whether lock checking should be enabled" >&5
-echo $ECHO_N "checking whether lock checking should be enabled... $ECHO_C" >&6
- echo "$as_me:$LINENO: result: $enable_lock_check" >&5
-echo "${ECHO_T}$enable_lock_check" >&6
- if test "x$enable_lock_check" != "xno"; then
- EMU_THR_DEFS="$EMU_THR_DEFS -DERTS_ENABLE_LOCK_CHECK"
- fi
-
- echo "$as_me:$LINENO: checking whether lock counters should be enabled" >&5
-echo $ECHO_N "checking whether lock counters should be enabled... $ECHO_C" >&6
- echo "$as_me:$LINENO: result: $enable_lock_count" >&5
-echo "${ECHO_T}$enable_lock_count" >&6
- if test "x$enable_lock_count" != "xno"; then
- EMU_THR_DEFS="$EMU_THR_DEFS -DERTS_ENABLE_LOCK_COUNT"
- fi
-
- echo "$as_me:$LINENO: checking whether dirty schedulers should be enabled" >&5
-echo $ECHO_N "checking whether dirty schedulers should be enabled... $ECHO_C" >&6
- if test "x$enable_dirty_schedulers" != "xno"; then
- EMU_THR_DEFS="$EMU_THR_DEFS -DERTS_DIRTY_SCHEDULERS"
-
-cat >>confdefs.h <<\_ACEOF
-#define ERTS_DIRTY_SCHEDULERS 1
-_ACEOF
-
-
-cat >>confdefs.h <<\_ACEOF
-#define ERL_NIF_DIRTY_SCHEDULER_SUPPORT 1
-_ACEOF
-
-
-cat >>confdefs.h <<\_ACEOF
-#define ERL_DRV_DIRTY_SCHEDULER_SUPPORT 1
-_ACEOF
-
- echo "$as_me:$LINENO: result: yes" >&5
-echo "${ECHO_T}yes" >&6
- else
- echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6
- fi
-
- disable_child_waiter_thread=no
- case $host_os in
- solaris*)
- enable_child_waiter_thread=yes
- ;;
- linux*)
- echo "$as_me:$LINENO: checking whether dlopen() needs to be called before first call to dlerror()" >&5
-echo $ECHO_N "checking whether dlopen() needs to be called before first call to dlerror()... $ECHO_C" >&6
- if test "x$ETHR_THR_LIB_BASE_TYPE" != "xposix_nptl"; then
-
-cat >>confdefs.h <<\_ACEOF
-#define ERTS_NEED_DLOPEN_BEFORE_DLERROR 1
-_ACEOF
-
- echo "$as_me:$LINENO: result: yes" >&5
-echo "${ECHO_T}yes" >&6
- else
- echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6
- fi
- if test "x$ETHR_THR_LIB_BASE_TYPE" != "xposix_nptl"; then
- # Child waiter thread cannot be enabled
- disable_child_waiter_thread=yes
- enable_child_waiter_thread=no
- fi
- ;;
- win32|ose)
- # Child waiter thread cannot be enabled
- disable_child_waiter_thread=yes
- enable_child_waiter_thread=no
- ;;
- *)
- ;;
- esac
-
- # Remove -D_WIN32_WINNT*, -DWINVER* and -D_GNU_SOURCE from EMU_THR_DEFS
- # (defined in CFLAGS). Note that we want to keep these flags
- # in ETHR_DEFS, but not in EMU_THR_DEFS.
- new_emu_thr_defs=
- for thr_def in $EMU_THR_DEFS; do
- case $thr_def in
- -D_GNU_SOURCE*|-D_WIN32_WINNT*|-DWINVER*)
- ;;
- *)
- new_emu_thr_defs="$new_emu_thr_defs $thr_def"
- ;;
- esac
- done
- EMU_THR_DEFS=$new_emu_thr_defs
+ ac_cv_header_stdc=no
+fi
+rm -f conftest*
- echo "$as_me:$LINENO: checking whether the child waiter thread should be enabled" >&5
-echo $ECHO_N "checking whether the child waiter thread should be enabled... $ECHO_C" >&6
- if test $enable_child_waiter_thread = yes; then
+fi
-cat >>confdefs.h <<\_ACEOF
-#define ENABLE_CHILD_WAITER_THREAD 1
+if test $ac_cv_header_stdc = yes; then
+ # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
+ cat >conftest.$ac_ext <<_ACEOF
+/* confdefs.h. */
_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h. */
+#include
- echo "$as_me:$LINENO: result: yes" >&5
-echo "${ECHO_T}yes" >&6
- else
- case $ERTS_BUILD_SMP_EMU-$disable_child_waiter_thread in
- yes-no)
- echo "$as_me:$LINENO: result: yes on SMP build, but not on non-SMP build" >&5
-echo "${ECHO_T}yes on SMP build, but not on non-SMP build" >&6;;
- *-yes)
-
-cat >>confdefs.h <<\_ACEOF
-#define DISABLE_CHILD_WAITER_THREAD 1
_ACEOF
-
- echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6;;
- *)
- echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6;;
- esac
- fi
-fi
-
-
-
-
-
-
-if test "x$enable_lock_check" = "xno"; then
- EMU_LOCK_CHECKING=no
+if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
+ $EGREP "free" >/dev/null 2>&1; then
+ :
else
- EMU_LOCK_CHECKING=yes
+ ac_cv_header_stdc=no
fi
+rm -f conftest*
+fi
-
-
-
-ERTS_INTERNAL_X_LIBS=
-
-echo "$as_me:$LINENO: checking for kstat_open in -lkstat" >&5
-echo $ECHO_N "checking for kstat_open in -lkstat... $ECHO_C" >&6
-if test "${ac_cv_lib_kstat_kstat_open+set}" = set; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
+if test $ac_cv_header_stdc = yes; then
+ # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
+ if test "$cross_compiling" = yes; then
+ :
else
- ac_check_lib_save_LIBS=$LIBS
-LIBS="-lkstat $LIBS"
-cat >conftest.$ac_ext <<_ACEOF
+ cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
-
-/* Override any gcc2 internal prototype to avoid an error. */
-#ifdef __cplusplus
-extern "C"
+#include
+#if ((' ' & 0x0FF) == 0x020)
+# define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
+# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
+#else
+# define ISLOWER(c) \
+ (('a' <= (c) && (c) <= 'i') \
+ || ('j' <= (c) && (c) <= 'r') \
+ || ('s' <= (c) && (c) <= 'z'))
+# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
#endif
-/* We use char because int might match the return type of a gcc2
- builtin and then its argument prototype would still apply. */
-char kstat_open ();
+
+#define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
int
main ()
{
-kstat_open ();
- ;
- return 0;
+ int i;
+ for (i = 0; i < 256; i++)
+ if (XOR (islower (i), ISLOWER (i))
+ || toupper (i) != TOUPPER (i))
+ exit(2);
+ exit (0);
}
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
+rm -f conftest$ac_exeext
if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
- (eval $ac_link) 2>conftest.er1
- ac_status=$?
- grep -v '^ *+' conftest.er1 >conftest.err
- rm -f conftest.er1
- cat conftest.err >&5
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -z "$ac_c_werror_flag"
- || test ! -s conftest.err'
- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
+ (eval $ac_link) 2>&5
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); }; } &&
- { ac_try='test -s conftest$ac_exeext'
+ (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
{ (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; }; then
- ac_cv_lib_kstat_kstat_open=yes
+ :
else
- echo "$as_me: failed program was:" >&5
+ echo "$as_me: program exited with status $ac_status" >&5
+echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
-ac_cv_lib_kstat_kstat_open=no
+( exit $ac_status )
+ac_cv_header_stdc=no
fi
-rm -f conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
+rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
fi
-echo "$as_me:$LINENO: result: $ac_cv_lib_kstat_kstat_open" >&5
-echo "${ECHO_T}$ac_cv_lib_kstat_kstat_open" >&6
-if test $ac_cv_lib_kstat_kstat_open = yes; then
+fi
+fi
+echo "$as_me:$LINENO: result: $ac_cv_header_stdc" >&5
+echo "${ECHO_T}$ac_cv_header_stdc" >&6
+if test $ac_cv_header_stdc = yes; then
cat >>confdefs.h <<\_ACEOF
-#define HAVE_KSTAT 1
+#define STDC_HEADERS 1
_ACEOF
-ERTS_INTERNAL_X_LIBS="$ERTS_INTERNAL_X_LIBS -lkstat"
fi
-
-
-
-
-
-THR_LIBS=$ETHR_X_LIBS
-THR_DEFS=$ETHR_DEFS
-
-
-
-
-
-TERMCAP_LIB=
-
-if test "x$with_termcap" != "xno" &&
- test "X$host" != "Xwin32"; then
- # try these libs
- termcap_libs="tinfo ncurses curses termcap termlib"
-
- for termcap_lib in $termcap_libs; do
- as_ac_Lib=`echo "ac_cv_lib_$termcap_lib''_tgetent" | $as_tr_sh`
-echo "$as_me:$LINENO: checking for tgetent in -l$termcap_lib" >&5
-echo $ECHO_N "checking for tgetent in -l$termcap_lib... $ECHO_C" >&6
-if eval "test \"\${$as_ac_Lib+set}\" = set"; then
+echo "$as_me:$LINENO: checking for sys/wait.h that is POSIX.1 compatible" >&5
+echo $ECHO_N "checking for sys/wait.h that is POSIX.1 compatible... $ECHO_C" >&6
+if test "${ac_cv_header_sys_wait_h+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
- ac_check_lib_save_LIBS=$LIBS
-LIBS="-l$termcap_lib $LIBS"
-cat >conftest.$ac_ext <<_ACEOF
+ cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
-
-/* Override any gcc2 internal prototype to avoid an error. */
-#ifdef __cplusplus
-extern "C"
+#include
+#include
+#ifndef WEXITSTATUS
+# define WEXITSTATUS(stat_val) ((unsigned)(stat_val) >> 8)
#endif
-/* We use char because int might match the return type of a gcc2
- builtin and then its argument prototype would still apply. */
-char tgetent ();
+#ifndef WIFEXITED
+# define WIFEXITED(stat_val) (((stat_val) & 255) == 0)
+#endif
+
int
main ()
{
-tgetent ();
+ int s;
+ wait (&s);
+ s = WIFEXITED (s) ? WEXITSTATUS (s) : 1;
;
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
- (eval $ac_link) 2>conftest.er1
+rm -f conftest.$ac_objext
+if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
+ (eval $ac_compile) 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
@@ -22540,73 +20913,58 @@
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; } &&
- { ac_try='test -s conftest$ac_exeext'
+ { ac_try='test -s conftest.$ac_objext'
{ (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; }; then
- eval "$as_ac_Lib=yes"
+ ac_cv_header_sys_wait_h=yes
else
echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
-eval "$as_ac_Lib=no"
-fi
-rm -f conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
-fi
-echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Lib'}'`" >&5
-echo "${ECHO_T}`eval echo '${'$as_ac_Lib'}'`" >&6
-if test `eval echo '${'$as_ac_Lib'}'` = yes; then
- TERMCAP_LIB="-l$termcap_lib"
+ac_cv_header_sys_wait_h=no
fi
-
- if test "x$TERMCAP_LIB" != "x"; then
- break
- fi
- done
-
- if test "x$TERMCAP_LIB" = "x"; then
- { { echo "$as_me:$LINENO: error: No curses library functions found" >&5
-echo "$as_me: error: No curses library functions found" >&2;}
- { (exit 1); exit 1; }; }
- fi
+rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
fi
-
-
-
-if test "x$TERMCAP_LIB" != "x"; then
-
+echo "$as_me:$LINENO: result: $ac_cv_header_sys_wait_h" >&5
+echo "${ECHO_T}$ac_cv_header_sys_wait_h" >&6
+if test $ac_cv_header_sys_wait_h = yes; then
cat >>confdefs.h <<\_ACEOF
-#define HAVE_TERMCAP 1
+#define HAVE_SYS_WAIT_H 1
_ACEOF
fi
-if test "X$host" != "Xwin32"; then
- echo "$as_me:$LINENO: checking for wcwidth" >&5
-echo $ECHO_N "checking for wcwidth... $ECHO_C" >&6
- cat >conftest.$ac_ext <<_ACEOF
+echo "$as_me:$LINENO: checking whether time.h and sys/time.h may both be included" >&5
+echo $ECHO_N "checking whether time.h and sys/time.h may both be included... $ECHO_C" >&6
+if test "${ac_cv_header_time+set}" = set; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+ cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
-#include
+#include
+#include
+#include
+
int
main ()
{
-wcwidth(0);
+if ((struct tm *) 0)
+return 0;
;
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
- (eval $ac_link) 2>conftest.er1
+rm -f conftest.$ac_objext
+if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
+ (eval $ac_compile) 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
@@ -22620,83 +20978,89 @@
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; } &&
- { ac_try='test -s conftest$ac_exeext'
+ { ac_try='test -s conftest.$ac_objext'
{ (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; }; then
- have_wcwidth=yes
+ ac_cv_header_time=yes
else
echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
-have_wcwidth=no
+ac_cv_header_time=no
fi
-rm -f conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
- if test $have_wcwidth = yes; then
- echo "$as_me:$LINENO: result: yes" >&5
-echo "${ECHO_T}yes" >&6
+rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
+fi
+echo "$as_me:$LINENO: result: $ac_cv_header_time" >&5
+echo "${ECHO_T}$ac_cv_header_time" >&6
+if test $ac_cv_header_time = yes; then
cat >>confdefs.h <<\_ACEOF
-#define HAVE_WCWIDTH 1
+#define TIME_WITH_SYS_TIME 1
_ACEOF
- fi
fi
-# Check whether --enable-builtin-zlib or --disable-builtin-zlib was given.
-if test "${enable_builtin_zlib+set}" = set; then
- enableval="$enable_builtin_zlib"
- case "$enableval" in
- no) enable_builtin_zlib=no ;;
- *) enable_builtin_zlib=yes ;;
- esac
-else
- enable_builtin_zlib=no
-fi;
-Z_LIB=
-if test "x$enable_builtin_zlib" = "xyes"; then
- { echo "$as_me:$LINENO: Using our own built-in zlib source" >&5
-echo "$as_me: Using our own built-in zlib source" >&6;}
-else
-echo "$as_me:$LINENO: checking for zlib 1.2.5 or higher" >&5
-echo $ECHO_N "checking for zlib 1.2.5 or higher... $ECHO_C" >&6
-zlib_save_LIBS=$LIBS
-LIBS="-lz $LIBS"
-cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h. */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h. */
-#include "zlib.h"
-int
-main ()
-{
-#if ZLIB_VERNUM >= 0x1250
- Bytef s[1];
- s[0] = 0;
- (void) adler32((uLong)0, s, 1);
-#else
-#error "No zlib 1.2.5 or higher found"
-error
-#endif
- ;
- return 0;
-}
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+for ac_header in fcntl.h limits.h unistd.h syslog.h dlfcn.h ieeefp.h \
+ sys/types.h sys/stropts.h sys/sysctl.h \
+ sys/ioctl.h sys/time.h sys/uio.h \
+ sys/socket.h sys/sockio.h sys/socketio.h \
+ net/errno.h malloc.h arpa/nameser.h libdlpi.h \
+ pty.h util.h utmp.h langinfo.h poll.h sdkddkver.h
+do
+as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
+if eval "test \"\${$as_ac_Header+set}\" = set"; then
+ echo "$as_me:$LINENO: checking for $ac_header" >&5
+echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
+if eval "test \"\${$as_ac_Header+set}\" = set"; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
+fi
+echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
+echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
+else
+ # Is the header compilable?
+echo "$as_me:$LINENO: checking $ac_header usability" >&5
+echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
+cat >conftest.$ac_ext <<_ACEOF
+/* confdefs.h. */
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
- (eval $ac_link) 2>conftest.er1
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h. */
+$ac_includes_default
+#include <$ac_header>
+_ACEOF
+rm -f conftest.$ac_objext
+if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
+ (eval $ac_compile) 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
@@ -22710,59 +21074,119 @@
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; } &&
- { ac_try='test -s conftest$ac_exeext'
+ { ac_try='test -s conftest.$ac_objext'
{ (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; }; then
+ ac_header_compiler=yes
+else
+ echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
- Z_LIB="-lz"
+ac_header_compiler=no
+fi
+rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
+echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
+echo "${ECHO_T}$ac_header_compiler" >&6
-cat >>confdefs.h <<\_ACEOF
-#define HAVE_LIBZ 1
+# Is the header present?
+echo "$as_me:$LINENO: checking $ac_header presence" >&5
+echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
+cat >conftest.$ac_ext <<_ACEOF
+/* confdefs.h. */
_ACEOF
-
- echo "$as_me:$LINENO: result: yes" >&5
-echo "${ECHO_T}yes" >&6
-
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h. */
+#include <$ac_header>
+_ACEOF
+if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
+ (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
+ ac_status=$?
+ grep -v '^ *+' conftest.er1 >conftest.err
+ rm -f conftest.er1
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } >/dev/null; then
+ if test -s conftest.err; then
+ ac_cpp_err=$ac_c_preproc_warn_flag
+ ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
+ else
+ ac_cpp_err=
+ fi
+else
+ ac_cpp_err=yes
+fi
+if test -z "$ac_cpp_err"; then
+ ac_header_preproc=yes
else
echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
+ ac_header_preproc=no
+fi
+rm -f conftest.err conftest.$ac_ext
+echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
+echo "${ECHO_T}$ac_header_preproc" >&6
- echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6
+# So? What about this header?
+case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
+ yes:no: )
+ { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
+echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
+ { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
+echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
+ ac_header_preproc=yes
+ ;;
+ no:yes:* )
+ { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
+echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
+ { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
+echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
+ { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
+echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
+ { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5
+echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;}
+ { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
+echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
+ { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
+echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
+ (
+ cat <<\_ASBOX
+## ------------------------------------------ ##
+## Report this to the AC_PACKAGE_NAME lists. ##
+## ------------------------------------------ ##
+_ASBOX
+ ) |
+ sed "s/^/$as_me: WARNING: /" >&2
+ ;;
+esac
+echo "$as_me:$LINENO: checking for $ac_header" >&5
+echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
+if eval "test \"\${$as_ac_Header+set}\" = set"; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+ eval "$as_ac_Header=\$ac_header_preproc"
+fi
+echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
+echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
fi
-rm -f conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-LIBS=$zlib_save_LIBS
+if test `eval echo '${'$as_ac_Header'}'` = yes; then
+ cat >>confdefs.h <<_ACEOF
+#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
+_ACEOF
+
fi
+done
-#--------------------------------------------------------------------
-# Check for the existence of the -lsocket and -lnsl libraries.
-# The order here is important, so that they end up in the right
-# order in the command line generated by make. Here are some
-# special considerations:
-# 1. Use "connect" and "accept" to check for -lsocket, and
-# "gethostbyname" to check for -lnsl.
-# 2. Use each function name only once: can't redo a check because
-# autoconf caches the results of the last check and won't redo it.
-# 3. Use -lnsl and -lsocket only if they supply procedures that
-# aren't already present in the normal libraries. This is because
-# IRIX 5.2 has libraries, but they aren't needed and they're
-# bogus: they goof up name resolution if used.
-# 4. On some SVR4 systems, can't use -lsocket without -lnsl too.
-# To get around this problem, check for both libraries together
-# if -lsocket doesn't work by itself.
-#--------------------------------------------------------------------
-erl_checkBoth=0
-echo "$as_me:$LINENO: checking for connect" >&5
-echo $ECHO_N "checking for connect... $ECHO_C" >&6
-if test "${ac_cv_func_connect+set}" = set; then
+echo "$as_me:$LINENO: checking for struct ifreq.ifr_hwaddr" >&5
+echo $ECHO_N "checking for struct ifreq.ifr_hwaddr... $ECHO_C" >&6
+if test "${ac_cv_member_struct_ifreq_ifr_hwaddr+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
cat >conftest.$ac_ext <<_ACEOF
@@ -22771,54 +21195,28 @@
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
-/* Define connect to an innocuous variant, in case declares connect.
- For example, HP-UX 11i declares gettimeofday. */
-#define connect innocuous_connect
-
-/* System header to define __stub macros and hopefully few prototypes,
- which can conflict with char connect (); below.
- Prefer to if __STDC__ is defined, since
- exists even on freestanding compilers. */
-
-#ifdef __STDC__
-# include
-#else
-# include
-#endif
-
-#undef connect
+#ifdef __WIN32__
+ #else
+ #ifdef VXWORKS
+ #else
+ #include
+ #endif
+ #endif
-/* Override any gcc2 internal prototype to avoid an error. */
-#ifdef __cplusplus
-extern "C"
-{
-#endif
-/* We use char because int might match the return type of a gcc2
- builtin and then its argument prototype would still apply. */
-char connect ();
-/* The GNU C library defines this for functions which it implements
- to always fail with ENOSYS. Some functions are actually named
- something starting with __ and the normal name is an alias. */
-#if defined (__stub_connect) || defined (__stub___connect)
-choke me
-#else
-char (*f) () = connect;
-#endif
-#ifdef __cplusplus
-}
-#endif
int
main ()
{
-return f != connect;
+static struct ifreq ac_aggr;
+if (ac_aggr.ifr_hwaddr)
+return 0;
;
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
- (eval $ac_link) 2>conftest.er1
+rm -f conftest.$ac_objext
+if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
+ (eval $ac_compile) 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
@@ -22832,57 +21230,45 @@
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; } &&
- { ac_try='test -s conftest$ac_exeext'
+ { ac_try='test -s conftest.$ac_objext'
{ (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; }; then
- ac_cv_func_connect=yes
+ ac_cv_member_struct_ifreq_ifr_hwaddr=yes
else
echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
-ac_cv_func_connect=no
-fi
-rm -f conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-fi
-echo "$as_me:$LINENO: result: $ac_cv_func_connect" >&5
-echo "${ECHO_T}$ac_cv_func_connect" >&6
-if test $ac_cv_func_connect = yes; then
- erl_checkSocket=0
-else
- erl_checkSocket=1
-fi
-
-if test "$erl_checkSocket" = 1; then
- echo "$as_me:$LINENO: checking for main in -lsocket" >&5
-echo $ECHO_N "checking for main in -lsocket... $ECHO_C" >&6
-if test "${ac_cv_lib_socket_main+set}" = set; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
-else
- ac_check_lib_save_LIBS=$LIBS
-LIBS="-lsocket $LIBS"
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
+#ifdef __WIN32__
+ #else
+ #ifdef VXWORKS
+ #else
+ #include
+ #endif
+ #endif
int
main ()
{
-main ();
+static struct ifreq ac_aggr;
+if (sizeof ac_aggr.ifr_hwaddr)
+return 0;
;
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
- (eval $ac_link) 2>conftest.er1
+rm -f conftest.$ac_objext
+if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
+ (eval $ac_compile) 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
@@ -22896,38 +21282,38 @@
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; } &&
- { ac_try='test -s conftest$ac_exeext'
+ { ac_try='test -s conftest.$ac_objext'
{ (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; }; then
- ac_cv_lib_socket_main=yes
+ ac_cv_member_struct_ifreq_ifr_hwaddr=yes
else
echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
-ac_cv_lib_socket_main=no
+ac_cv_member_struct_ifreq_ifr_hwaddr=no
fi
-rm -f conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
+rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
fi
-echo "$as_me:$LINENO: result: $ac_cv_lib_socket_main" >&5
-echo "${ECHO_T}$ac_cv_lib_socket_main" >&6
-if test $ac_cv_lib_socket_main = yes; then
- LIBS="$LIBS -lsocket"
-else
- erl_checkBoth=1
+rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
fi
+echo "$as_me:$LINENO: result: $ac_cv_member_struct_ifreq_ifr_hwaddr" >&5
+echo "${ECHO_T}$ac_cv_member_struct_ifreq_ifr_hwaddr" >&6
+if test $ac_cv_member_struct_ifreq_ifr_hwaddr = yes; then
+
+cat >>confdefs.h <<_ACEOF
+#define HAVE_STRUCT_IFREQ_IFR_HWADDR 1
+_ACEOF
+
fi
-if test "$erl_checkBoth" = 1; then
- tk_oldLibs=$LIBS
- LIBS="$LIBS -lsocket -lnsl"
- echo "$as_me:$LINENO: checking for accept" >&5
-echo $ECHO_N "checking for accept... $ECHO_C" >&6
-if test "${ac_cv_func_accept+set}" = set; then
+
+
+echo "$as_me:$LINENO: checking for struct ifreq.ifr_enaddr" >&5
+echo $ECHO_N "checking for struct ifreq.ifr_enaddr... $ECHO_C" >&6
+if test "${ac_cv_member_struct_ifreq_ifr_enaddr+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
cat >conftest.$ac_ext <<_ACEOF
@@ -22936,54 +21322,28 @@
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
-/* Define accept to an innocuous variant, in case declares accept.
- For example, HP-UX 11i declares gettimeofday. */
-#define accept innocuous_accept
-
-/* System header to define __stub macros and hopefully few prototypes,
- which can conflict with char accept (); below.
- Prefer to if __STDC__ is defined, since
- exists even on freestanding compilers. */
-
-#ifdef __STDC__
-# include
-#else
-# include
-#endif
-
-#undef accept
+#ifdef __WIN32__
+ #else
+ #ifdef VXWORKS
+ #else
+ #include
+ #endif
+ #endif
-/* Override any gcc2 internal prototype to avoid an error. */
-#ifdef __cplusplus
-extern "C"
-{
-#endif
-/* We use char because int might match the return type of a gcc2
- builtin and then its argument prototype would still apply. */
-char accept ();
-/* The GNU C library defines this for functions which it implements
- to always fail with ENOSYS. Some functions are actually named
- something starting with __ and the normal name is an alias. */
-#if defined (__stub_accept) || defined (__stub___accept)
-choke me
-#else
-char (*f) () = accept;
-#endif
-#ifdef __cplusplus
-}
-#endif
int
main ()
{
-return f != accept;
+static struct ifreq ac_aggr;
+if (ac_aggr.ifr_enaddr)
+return 0;
;
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
- (eval $ac_link) 2>conftest.er1
+rm -f conftest.$ac_objext
+if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
+ (eval $ac_compile) 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
@@ -22997,90 +21357,45 @@
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; } &&
- { ac_try='test -s conftest$ac_exeext'
+ { ac_try='test -s conftest.$ac_objext'
{ (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; }; then
- ac_cv_func_accept=yes
+ ac_cv_member_struct_ifreq_ifr_enaddr=yes
else
echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
-ac_cv_func_accept=no
-fi
-rm -f conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-fi
-echo "$as_me:$LINENO: result: $ac_cv_func_accept" >&5
-echo "${ECHO_T}$ac_cv_func_accept" >&6
-if test $ac_cv_func_accept = yes; then
- erl_checkNsl=0
-else
- LIBS=$tk_oldLibs
-fi
-
-fi
-echo "$as_me:$LINENO: checking for gethostbyname" >&5
-echo $ECHO_N "checking for gethostbyname... $ECHO_C" >&6
-if test "${ac_cv_func_gethostbyname+set}" = set; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
-else
- cat >conftest.$ac_ext <<_ACEOF
+cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
-/* Define gethostbyname to an innocuous variant, in case declares gethostbyname.
- For example, HP-UX 11i declares gettimeofday. */
-#define gethostbyname innocuous_gethostbyname
-
-/* System header to define __stub macros and hopefully few prototypes,
- which can conflict with char gethostbyname (); below.
- Prefer to if __STDC__ is defined, since
- exists even on freestanding compilers. */
-
-#ifdef __STDC__
-# include
-#else
-# include
-#endif
-
-#undef gethostbyname
+#ifdef __WIN32__
+ #else
+ #ifdef VXWORKS
+ #else
+ #include
+ #endif
+ #endif
-/* Override any gcc2 internal prototype to avoid an error. */
-#ifdef __cplusplus
-extern "C"
-{
-#endif
-/* We use char because int might match the return type of a gcc2
- builtin and then its argument prototype would still apply. */
-char gethostbyname ();
-/* The GNU C library defines this for functions which it implements
- to always fail with ENOSYS. Some functions are actually named
- something starting with __ and the normal name is an alias. */
-#if defined (__stub_gethostbyname) || defined (__stub___gethostbyname)
-choke me
-#else
-char (*f) () = gethostbyname;
-#endif
-#ifdef __cplusplus
-}
-#endif
int
main ()
{
-return f != gethostbyname;
+static struct ifreq ac_aggr;
+if (sizeof ac_aggr.ifr_enaddr)
+return 0;
;
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
- (eval $ac_link) 2>conftest.er1
+rm -f conftest.$ac_objext
+if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
+ (eval $ac_compile) 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
@@ -23094,34 +21409,46 @@
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; } &&
- { ac_try='test -s conftest$ac_exeext'
+ { ac_try='test -s conftest.$ac_objext'
{ (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; }; then
- ac_cv_func_gethostbyname=yes
+ ac_cv_member_struct_ifreq_ifr_enaddr=yes
else
echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
-ac_cv_func_gethostbyname=no
+ac_cv_member_struct_ifreq_ifr_enaddr=no
fi
-rm -f conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
+rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
fi
-echo "$as_me:$LINENO: result: $ac_cv_func_gethostbyname" >&5
-echo "${ECHO_T}$ac_cv_func_gethostbyname" >&6
-if test $ac_cv_func_gethostbyname = yes; then
- :
-else
- echo "$as_me:$LINENO: checking for main in -lnsl" >&5
-echo $ECHO_N "checking for main in -lnsl... $ECHO_C" >&6
-if test "${ac_cv_lib_nsl_main+set}" = set; then
+rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
+fi
+echo "$as_me:$LINENO: result: $ac_cv_member_struct_ifreq_ifr_enaddr" >&5
+echo "${ECHO_T}$ac_cv_member_struct_ifreq_ifr_enaddr" >&6
+if test $ac_cv_member_struct_ifreq_ifr_enaddr = yes; then
+
+cat >>confdefs.h <<_ACEOF
+#define HAVE_STRUCT_IFREQ_IFR_ENADDR 1
+_ACEOF
+
+
+fi
+
+
+if test x"$enable_systemd" != x"no"; then
+
+systemd_daemon_save_LIBS=$LIBS
+LIBS=
+echo "$as_me:$LINENO: checking for library containing sd_listen_fds" >&5
+echo $ECHO_N "checking for library containing sd_listen_fds... $ECHO_C" >&6
+if test "${ac_cv_search_sd_listen_fds+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
- ac_check_lib_save_LIBS=$LIBS
-LIBS="-lnsl $LIBS"
+ ac_func_search_save_LIBS=$LIBS
+ac_cv_search_sd_listen_fds=no
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
_ACEOF
@@ -23129,11 +21456,17 @@
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
-
+/* Override any gcc2 internal prototype to avoid an error. */
+#ifdef __cplusplus
+extern "C"
+#endif
+/* We use char because int might match the return type of a gcc2
+ builtin and then its argument prototype would still apply. */
+char sd_listen_fds ();
int
main ()
{
-main ();
+sd_listen_fds ();
;
return 0;
}
@@ -23160,77 +21493,35 @@
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; }; then
- ac_cv_lib_nsl_main=yes
+ ac_cv_search_sd_listen_fds="none required"
else
echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
-ac_cv_lib_nsl_main=no
fi
rm -f conftest.err conftest.$ac_objext \
conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
-fi
-echo "$as_me:$LINENO: result: $ac_cv_lib_nsl_main" >&5
-echo "${ECHO_T}$ac_cv_lib_nsl_main" >&6
-if test $ac_cv_lib_nsl_main = yes; then
- LIBS="$LIBS -lnsl"
-fi
-
-fi
-
-echo "$as_me:$LINENO: checking for gethostbyname_r" >&5
-echo $ECHO_N "checking for gethostbyname_r... $ECHO_C" >&6
-if test "${ac_cv_func_gethostbyname_r+set}" = set; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
-else
- cat >conftest.$ac_ext <<_ACEOF
+if test "$ac_cv_search_sd_listen_fds" = no; then
+ for ac_lib in systemd systemd-daemon; do
+ LIBS="-l$ac_lib $systemd_daemon_save_LIBS $ac_func_search_save_LIBS"
+ cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
-/* Define gethostbyname_r to an innocuous variant, in case declares gethostbyname_r.
- For example, HP-UX 11i declares gettimeofday. */
-#define gethostbyname_r innocuous_gethostbyname_r
-
-/* System header to define __stub macros and hopefully few prototypes,
- which can conflict with char gethostbyname_r (); below.
- Prefer to if __STDC__ is defined, since
- exists even on freestanding compilers. */
-
-#ifdef __STDC__
-# include
-#else
-# include
-#endif
-
-#undef gethostbyname_r
/* Override any gcc2 internal prototype to avoid an error. */
#ifdef __cplusplus
extern "C"
-{
#endif
/* We use char because int might match the return type of a gcc2
builtin and then its argument prototype would still apply. */
-char gethostbyname_r ();
-/* The GNU C library defines this for functions which it implements
- to always fail with ENOSYS. Some functions are actually named
- something starting with __ and the normal name is an alias. */
-#if defined (__stub_gethostbyname_r) || defined (__stub___gethostbyname_r)
-choke me
-#else
-char (*f) () = gethostbyname_r;
-#endif
-#ifdef __cplusplus
-}
-#endif
-
+char sd_listen_fds ();
int
main ()
{
-return f != gethostbyname_r;
+sd_listen_fds ();
;
return 0;
}
@@ -23257,51 +21548,52 @@
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; }; then
- ac_cv_func_gethostbyname_r=yes
+ ac_cv_search_sd_listen_fds="-l$ac_lib"
+break
else
echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
-ac_cv_func_gethostbyname_r=no
fi
rm -f conftest.err conftest.$ac_objext \
conftest$ac_exeext conftest.$ac_ext
+ done
fi
-echo "$as_me:$LINENO: result: $ac_cv_func_gethostbyname_r" >&5
-echo "${ECHO_T}$ac_cv_func_gethostbyname_r" >&6
-if test $ac_cv_func_gethostbyname_r = yes; then
- have_gethostbyname_r=yes
+LIBS=$ac_func_search_save_LIBS
+fi
+echo "$as_me:$LINENO: result: $ac_cv_search_sd_listen_fds" >&5
+echo "${ECHO_T}$ac_cv_search_sd_listen_fds" >&6
+if test "$ac_cv_search_sd_listen_fds" != no; then
+ test "$ac_cv_search_sd_listen_fds" = "none required" || LIBS="$ac_cv_search_sd_listen_fds $LIBS"
+ have_sd_listen_fds=yes
+else
+ have_sd_listen_fds=no
fi
-
-if test "$have_gethostbyname_r" = yes; then
- # OK, so we have gethostbyname_r() - but do we know how to call it...?
- # (if not, HAVE_GETHOSTBYNAME_R will not be defined at all)
- case $host_os in
- solaris2*)
-
-cat >>confdefs.h <<\_ACEOF
-#define HAVE_GETHOSTBYNAME_R GHBN_R_SOLARIS
-_ACEOF
-
- ;;
- aix4*)
- # AIX version also needs "struct hostent_data" defn
- cat >conftest.$ac_ext <<_ACEOF
+for ac_header in systemd/sd-daemon.h
+do
+as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
+if eval "test \"\${$as_ac_Header+set}\" = set"; then
+ echo "$as_me:$LINENO: checking for $ac_header" >&5
+echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
+if eval "test \"\${$as_ac_Header+set}\" = set"; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
+fi
+echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
+echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
+else
+ # Is the header compilable?
+echo "$as_me:$LINENO: checking $ac_header usability" >&5
+echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
+cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
-#include
-int
-main ()
-{
-struct hostent_data hd;
- ;
- return 0;
-}
+$ac_includes_default
+#include <$ac_header>
_ACEOF
rm -f conftest.$ac_objext
if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
@@ -23325,48 +21617,140 @@
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; }; then
-
-cat >>confdefs.h <<\_ACEOF
-#define HAVE_GETHOSTBYNAME_R GHBN_R_AIX
-_ACEOF
-
+ ac_header_compiler=yes
else
echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
+ac_header_compiler=no
fi
rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
- ;;
- *)
- cat >conftest.$ac_ext <<_ACEOF
+echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
+echo "${ECHO_T}$ac_header_compiler" >&6
+
+# Is the header present?
+echo "$as_me:$LINENO: checking $ac_header presence" >&5
+echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
+cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
+#include <$ac_header>
+_ACEOF
+if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
+ (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
+ ac_status=$?
+ grep -v '^ *+' conftest.er1 >conftest.err
+ rm -f conftest.er1
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } >/dev/null; then
+ if test -s conftest.err; then
+ ac_cpp_err=$ac_c_preproc_warn_flag
+ ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
+ else
+ ac_cpp_err=
+ fi
+else
+ ac_cpp_err=yes
+fi
+if test -z "$ac_cpp_err"; then
+ ac_header_preproc=yes
+else
+ echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
-#include
-#ifdef __GLIBC__
-yes
-#endif
+ ac_header_preproc=no
+fi
+rm -f conftest.err conftest.$ac_ext
+echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
+echo "${ECHO_T}$ac_header_preproc" >&6
+
+# So? What about this header?
+case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
+ yes:no: )
+ { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
+echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
+ { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
+echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
+ ac_header_preproc=yes
+ ;;
+ no:yes:* )
+ { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
+echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
+ { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
+echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
+ { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
+echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
+ { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5
+echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;}
+ { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
+echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
+ { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
+echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
+ (
+ cat <<\_ASBOX
+## ------------------------------------------ ##
+## Report this to the AC_PACKAGE_NAME lists. ##
+## ------------------------------------------ ##
+_ASBOX
+ ) |
+ sed "s/^/$as_me: WARNING: /" >&2
+ ;;
+esac
+echo "$as_me:$LINENO: checking for $ac_header" >&5
+echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
+if eval "test \"\${$as_ac_Header+set}\" = set"; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+ eval "$as_ac_Header=\$ac_header_preproc"
+fi
+echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
+echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
+fi
+if test `eval echo '${'$as_ac_Header'}'` = yes; then
+ cat >>confdefs.h <<_ACEOF
+#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
_ACEOF
-if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
- $EGREP "^yes$" >/dev/null 2>&1; then
+ have_systemd_sd_daemon_h=yes
+else
+ have_systemd_sd_daemon_h=no
+fi
+
+done
+
+
+if test x"$have_sd_listen_fds" = x"yes" && \
+ test x"$have_systemd_sd_daemon_h" = x"yes"; then
cat >>confdefs.h <<\_ACEOF
-#define HAVE_GETHOSTBYNAME_R GHBN_R_GLIBC
+#define HAVE_SYSTEMD_DAEMON 1
_ACEOF
+ SYSTEMD_DAEMON_LIBS=$LIBS
+elif test x"$enable_systemd" = x"yes"; then
+ { { echo "$as_me:$LINENO: error: --enable-systemd was given, but test for systemd failed
+See \`config.log' for more details." >&5
+echo "$as_me: error: --enable-systemd was given, but test for systemd failed
+See \`config.log' for more details." >&2;}
+ { (exit 1); exit 1; }; }
fi
-rm -f conftest*
-
- ;;
- esac
+LIBS=$systemd_daemon_save_LIBS
fi
-echo "$as_me:$LINENO: checking for working posix_openpt implementation" >&5
-echo $ECHO_N "checking for working posix_openpt implementation... $ECHO_C" >&6
+
+
+
+echo "$as_me:$LINENO: checking for dlpi_open in -ldlpi" >&5
+echo $ECHO_N "checking for dlpi_open in -ldlpi... $ECHO_C" >&6
+if test "${ac_cv_lib_dlpi_dlpi_open+set}" = set; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+ ac_check_lib_save_LIBS=$LIBS
+LIBS="-ldlpi $LIBS"
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
_ACEOF
@@ -23374,20 +21758,17 @@
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
-#define _XOPEN_SOURCE 600
-#include
-#include