aboutsummaryrefslogtreecommitdiff
path: root/sim/m4
diff options
context:
space:
mode:
authorMike Frysinger <vapier@gentoo.org>2021-04-18 23:44:36 -0400
committerMike Frysinger <vapier@gentoo.org>2021-04-18 23:53:01 -0400
commit2c2645d7a8b0498d7b581eae709e0f2ba51dcfe6 (patch)
treecb26bf3fc746efd5a11e313ef9e5285cb7388e52 /sim/m4
parent41e166b43b16db5980a5fe011c0165642ee1708a (diff)
downloadfsf-binutils-gdb-2c2645d7a8b0498d7b581eae709e0f2ba51dcfe6.zip
fsf-binutils-gdb-2c2645d7a8b0498d7b581eae709e0f2ba51dcfe6.tar.gz
fsf-binutils-gdb-2c2645d7a8b0498d7b581eae709e0f2ba51dcfe6.tar.bz2
sim: switch to AC_CHECK_HEADERS_ONCE
This avoids duplicate tests for headers between common m4, arches, and any other sources that would trigger header tests.
Diffstat (limited to 'sim/m4')
-rw-r--r--sim/m4/sim_ac_common.m415
1 files changed, 11 insertions, 4 deletions
diff --git a/sim/m4/sim_ac_common.m4 b/sim/m4/sim_ac_common.m4
index 7845142..3cc9e87 100644
--- a/sim/m4/sim_ac_common.m4
+++ b/sim/m4/sim_ac_common.m4
@@ -52,10 +52,17 @@ ZW_GNU_GETTEXT_SISTER_DIR(../../intl)
# Check for common headers.
# NB: You can assume C11 headers exist.
-AC_CHECK_HEADERS(unistd.h)
-AC_CHECK_HEADERS(sys/time.h sys/times.h sys/resource.h sys/mman.h)
-AC_CHECK_HEADERS(fcntl.h fpu_control.h)
-AC_CHECK_HEADERS(dlfcn.h sys/stat.h)
+AC_CHECK_HEADERS_ONCE(m4_flatten([
+ dlfcn.h
+ fcntl.h
+ fpu_control.h
+ unistd.h
+ sys/mman.h
+ sys/resource.h
+ sys/time.h
+ sys/times.h
+ sys/stat.h
+]))
AC_CHECK_FUNCS_ONCE(m4_flatten([
__setfpucw
ftruncate