1 # This file is generated from configure.ac by Autoconf. DO NOT EDIT!
2 # Local preconfigure fragment for sysdeps/csky
6 abi=`$CC $CFLAGS $CPPFLAGS -E -dM -xc /dev/null |
7 sed -n 's/^#define __CSKYABI__ \(.*\)/\1/p'`
8 soft_float=`$CC $CFLAGS $CPPFLAGS -E -dM -xc /dev/null |
9 sed -n 's/^#define __CSKY_SOFT_FLOAT__ \(.*\)/\1/p'`
10 hard_float_abi=`$CC $CFLAGS $CPPFLAGS -E -dM -xc /dev/null |
11 sed -n 's/^#define __CSKY_HARD_FLOAT_ABI__ \(.*\)/\1/p'`
15 as_fn_error 1 "glibc does not support abiv1 yet" "$LINENO" 5
21 as_fn_error 1 "Unknown abi" "$LINENO" 5
25 # This check is for compatibility with GCC versions earlier than 11.
26 # The older versions of C-SKY GCC do not support the '-mfloat-abi=softfp' option
27 # and never define the '__CSKY_HARD_FLOAT_ABI__'.
28 # Therefore, if a check for '-mfloat-abi=softfp' is added as the expression
29 # 'defined(__CSKY_HARD_FLOAT__) && !defined(__CSKY_HARD_FLOAT_ABI__)'
30 # which is correct for newer versions of GCC will not work for those older versions.
31 # Since no expression compatible with all versions of GCC exists,
32 # a check for the '-mfloat-abi=softfp' option is added.
33 if { ac_try='${CC-cc} -S -mfloat-abi=softfp /dev/null 1>&5'
34 { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_try\""; } >&5
37 printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
38 test $ac_status = 0; }; }; then
39 soft_float_abi_support=1
41 soft_float_abi_support=0
44 if test -n "$soft_float"; then
49 if test -n "$soft_float_abi_support"; then
50 if test -n "$hard_float_abi"; then
63 printf "%s\n" "#define CSKYABI $abi" >>confdefs.h
65 printf "%s\n" "#define CSKY_HARD_FLOAT $with_fp_cond" >>confdefs.h
67 printf "%s\n" "#define CSKY_HARD_FLOAT_ABI $with_hard_float_abi" >>confdefs.h