summaryrefslogtreecommitdiff
path: root/libiberty/configure.ac
diff options
context:
space:
mode:
authordj <dj@138bc75d-0d04-0410-961f-82ee72b054a4>2006-08-30 13:46:50 +0000
committerdj <dj@138bc75d-0d04-0410-961f-82ee72b054a4>2006-08-30 13:46:50 +0000
commit88f0e572472e2713fc6b6aa0fc501cd994fcd5a1 (patch)
tree3425722a99f19ea11bb6682556c590b6ecef0d47 /libiberty/configure.ac
parentcce6f47744e4e55530911c7762307af9c7905247 (diff)
downloadgcc-88f0e572472e2713fc6b6aa0fc501cd994fcd5a1.tar.gz
2006-08-30 Corinna Vinschen <corinna@vinschen.de>
* configure.ac: Add case for Mingw as host. * configure: Regenerate. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@116586 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'libiberty/configure.ac')
-rw-r--r--libiberty/configure.ac49
1 files changed, 49 insertions, 0 deletions
diff --git a/libiberty/configure.ac b/libiberty/configure.ac
index 76cf3d5333f..f9713c22e26 100644
--- a/libiberty/configure.ac
+++ b/libiberty/configure.ac
@@ -419,6 +419,55 @@ if test -n "${with_target_subdir}"; then
fi
+ # If we are being configured for Mingw, we know which functions
+ # Mingw provides and which ones we will be expected to provide.
+
+ case "${host}" in
+ *-*-mingw*)
+ AC_LIBOBJ([asprintf])
+ AC_LIBOBJ([basename])
+ AC_LIBOBJ([bcmp])
+ AC_LIBOBJ([bcopy])
+ AC_LIBOBJ([bzero])
+ AC_LIBOBJ([clock])
+ AC_LIBOBJ([ffs])
+ AC_LIBOBJ([getpagesize])
+ AC_LIBOBJ([index])
+ AC_LIBOBJ([insque])
+ AC_LIBOBJ([mempcpy])
+ AC_LIBOBJ([mkstemps])
+ AC_LIBOBJ([random])
+ AC_LIBOBJ([rindex])
+ AC_LIBOBJ([sigsetmask])
+ AC_LIBOBJ([stpcpy])
+ AC_LIBOBJ([stpncpy])
+ AC_LIBOBJ([strndup])
+ AC_LIBOBJ([strverscmp])
+ AC_LIBOBJ([vasprintf])
+ AC_LIBOBJ([waitpid])
+
+ for f in $funcs; do
+ case "$f" in
+ asprintf | basename | bcmp | bcopy | bzero | clock | ffs | getpagesize | index | insque | mempcpy | mkstemps | random | rindex | sigsetmask | stpcpy | stpncpy | strdup | strndup | strverscmp | vasprintf | waitpid)
+ ;;
+ *)
+ n=HAVE_`echo $f | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
+ AC_DEFINE_UNQUOTED($n)
+ ;;
+ esac
+ done
+
+ # Mingw doesnt provide any of the variables in $vars, so we
+ # dont have to check them here.
+
+ # Of the functions in $checkfuncs, Mingw only has strerror.
+ AC_DEFINE(HAVE_STRERROR)
+
+ setobjs=yes
+ ;;
+
+ esac
+
# We may wish to install the target headers somewhere.
AC_ARG_ENABLE(install-libiberty,
[ --enable-install-libiberty Install headers for end users],