2 dnl This file contains details for non-native builds.
5 AC_DEFUN([GLIBCXX_CROSSCONFIG],[
6 # Base decisions on target environment.
9 # This is a freestanding configuration; there is nothing to do here.
13 # These definitions are for the SDE C library rather than newlib.
14 SECTION_FLAGS='-ffunction-sections -fdata-sections'
15 AC_SUBST(SECTION_FLAGS)
16 GLIBCXX_CHECK_COMPILER_FEATURES
17 GLIBCXX_CHECK_LINKER_FEATURES
18 GLIBCXX_CHECK_MATH_SUPPORT
19 GLIBCXX_CHECK_STDLIB_SUPPORT
21 AC_DEFINE(HAVE_FINITE)
26 AC_DEFINE(HAVE_LDEXPF)
32 # Darwin versions vary, but the linker should work in a cross environment,
33 # so we just check for all the features here.
34 # Check for available headers.
36 # Don't call GLIBCXX_CHECK_LINKER_FEATURES, Darwin doesn't have a GNU ld
37 GLIBCXX_CHECK_MATH_SUPPORT
38 GLIBCXX_CHECK_STDLIB_SUPPORT
42 # GLIBCXX_CHECK_MATH_SUPPORT
45 AC_DEFINE(HAVE_FINITE)
46 AC_DEFINE(HAVE_SINCOS)
51 SECTION_FLAGS='-ffunction-sections -fdata-sections'
52 AC_SUBST(SECTION_FLAGS)
53 GLIBCXX_CHECK_LINKER_FEATURES
54 AC_DEFINE(HAVE_SETENV)
55 AC_DEFINE(HAVE_FINITEF)
56 AC_DEFINE(HAVE_FINITE)
57 AC_DEFINE(HAVE_FREXPF)
59 AC_DEFINE(HAVE_HYPOTF)
62 AC_DEFINE(HAVE_ISNANF)
66 AC_DEFINE(HAVE_ATAN2F)
73 AC_DEFINE(HAVE_FLOORF)
75 AC_DEFINE(HAVE_FREXPF)
76 AC_DEFINE(HAVE_LDEXPF)
77 AC_DEFINE(HAVE_LOG10F)
86 if test x"long_double_math_on_this_cpu" = x"yes"; then
87 AC_DEFINE(HAVE_FINITEL)
88 AC_DEFINE(HAVE_ISINFL)
89 AC_DEFINE(HAVE_ISNANL)
93 SECTION_FLAGS='-ffunction-sections -fdata-sections'
94 AC_SUBST(SECTION_FLAGS)
95 GLIBCXX_CHECK_LINKER_FEATURES
97 # GLIBCXX_CHECK_MATH_SUPPORT
100 AC_DEFINE(HAVE_ACOSF)
101 AC_DEFINE(HAVE_ASINF)
102 AC_DEFINE(HAVE_ATANF)
104 AC_DEFINE(HAVE_COSHF)
106 AC_DEFINE(HAVE_SINHF)
108 AC_DEFINE(HAVE_TANHF)
110 AC_DEFINE(HAVE_ATAN2F)
111 AC_DEFINE(HAVE_FABSF)
112 AC_DEFINE(HAVE_FMODF)
113 AC_DEFINE(HAVE_FREXPF)
115 AC_DEFINE(HAVE_LOG10F)
118 AC_DEFINE(HAVE_SQRTF)
120 # GLIBCXX_CHECK_STDLIB_SUPPORT
121 AC_DEFINE(HAVE_STRTOLD)
126 AC_DEFINE(HAVE_ISINF)
127 AC_DEFINE(HAVE_ISINFF)
128 AC_DEFINE(HAVE_ISNANF)
129 AC_DEFINE(HAVE_FINITE)
130 AC_DEFINE(HAVE_FINITEF)
134 *-linux* | *-uclinux* | *-gnu* | *-kfreebsd*-gnu | *-knetbsd*-gnu)
135 GLIBCXX_CHECK_COMPILER_FEATURES
136 GLIBCXX_CHECK_LINKER_FEATURES
137 GLIBCXX_CHECK_MATH_SUPPORT
138 GLIBCXX_CHECK_STDLIB_SUPPORT
139 AC_DEFINE(_GLIBCXX_USE_RANDOM_TR1)
144 GLIBCXX_CHECK_LINKER_FEATURES
145 GLIBCXX_CHECK_MATH_SUPPORT
146 GLIBCXX_CHECK_STDLIB_SUPPORT
149 SECTION_FLAGS='-ffunction-sections -fdata-sections'
150 AC_SUBST(SECTION_FLAGS)
151 GLIBCXX_CHECK_LINKER_FEATURES
152 AC_DEFINE(HAVE_FINITEF)
153 AC_DEFINE(HAVE_FINITE)
154 AC_DEFINE(HAVE_FREXPF)
155 AC_DEFINE(HAVE_HYPOTF)
156 AC_DEFINE(HAVE_ISINF)
157 AC_DEFINE(HAVE_ISINFF)
158 AC_DEFINE(HAVE_ISNAN)
159 AC_DEFINE(HAVE_ISNANF)
160 if test x"long_double_math_on_this_cpu" = x"yes"; then
161 AC_DEFINE(HAVE_FINITEL)
162 AC_DEFINE(HAVE_ISINFL)
163 AC_DEFINE(HAVE_ISNANL)
167 SECTION_FLAGS='-ffunction-sections -fdata-sections'
168 AC_SUBST(SECTION_FLAGS)
169 GLIBCXX_CHECK_LINKER_FEATURES
170 AC_DEFINE(HAVE_HYPOT)
171 AC_DEFINE(HAVE_ISINF)
172 AC_DEFINE(HAVE_ISNAN)
174 *-qnx6.1* | *-qnx6.2*)
175 SECTION_FLAGS='-ffunction-sections -fdata-sections'
176 AC_SUBST(SECTION_FLAGS)
177 GLIBCXX_CHECK_LINKER_FEATURES
180 AC_DEFINE(HAVE_COSHF)
181 AC_DEFINE(HAVE_COSHL)
184 AC_DEFINE(HAVE_LOG10F)
185 AC_DEFINE(HAVE_LOG10L)
188 AC_DEFINE(HAVE_SINHF)
189 AC_DEFINE(HAVE_SINHL)
193 *-solaris2.7 | *-solaris2.8 | *-solaris2.9 | *-solaris2.10)
194 GLIBCXX_CHECK_LINKER_FEATURES
195 AC_DEFINE(HAVE_MBSTATE_T)
196 AC_DEFINE(HAVE_FINITE)
197 AC_DEFINE(HAVE_FPCLASS)
198 # All of the dependencies for wide character support are here, so
200 AC_DEFINE(_GLIBCXX_USE_WCHAR_T)
205 # These two C99 functions are present only in Solaris >= 10
206 AC_DEFINE(HAVE_STRTOF)
207 AC_DEFINE(HAVE_STRTOLD)
210 AC_DEFINE(HAVE_ISNAN)
211 AC_DEFINE(HAVE_ISNANF)
212 AC_DEFINE(HAVE_MODFF)
213 AC_DEFINE(HAVE_HYPOT)
216 SECTION_FLAGS='-ffunction-sections -fdata-sections'
217 AC_SUBST(SECTION_FLAGS)
218 GLIBCXX_CHECK_LINKER_FEATURES
219 AC_DEFINE(HAVE_FINITE)
220 AC_DEFINE(HAVE_FINITEF)
221 AC_DEFINE(HAVE_FREXPF)
222 AC_DEFINE(HAVE_HYPOTF)
223 AC_DEFINE(HAVE_ISINF)
224 AC_DEFINE(HAVE_ISINFF)
225 AC_DEFINE(HAVE_ISNAN)
226 AC_DEFINE(HAVE_ISNANF)
227 AC_DEFINE(HAVE_SINCOS)
228 AC_DEFINE(HAVE_SINCOSF)
229 if test x"long_double_math_on_this_cpu" = x"yes"; then
230 AC_DEFINE(HAVE_FINITEL)
231 AC_DEFINE(HAVE_HYPOTL)
232 AC_DEFINE(HAVE_ISINFL)
233 AC_DEFINE(HAVE_ISNANL)
237 AC_DEFINE(HAVE_ACOSF)
238 AC_DEFINE(HAVE_ASINF)
239 AC_DEFINE(HAVE_ATAN2F)
240 AC_DEFINE(HAVE_ATANF)
241 AC_DEFINE(HAVE_CEILF)
243 AC_DEFINE(HAVE_COSHF)
245 AC_DEFINE(HAVE_FABSF)
246 AC_DEFINE(HAVE_FLOORF)
247 AC_DEFINE(HAVE_FMODF)
248 AC_DEFINE(HAVE_HYPOT)
249 AC_DEFINE(HAVE_LOG10F)
253 AC_DEFINE(HAVE_SINHF)
254 AC_DEFINE(HAVE_SQRTF)
256 AC_DEFINE(HAVE_TANHF)
259 AC_MSG_ERROR([No support for this host/target combination.])