diff options
author | Ian Lance Taylor <ian@airs.com> | 1997-08-01 00:04:48 +0000 |
---|---|---|
committer | Ian Lance Taylor <ian@airs.com> | 1997-08-01 00:04:48 +0000 |
commit | c0734708814c3871992a7d74a4f168a47dc05922 (patch) | |
tree | ea059ba31c250a6f11f93746e2c344aa14fa041a /bfd/acinclude.m4 | |
parent | bc6b39f5f5186513c2ed28da36c14746b145d26d (diff) | |
download | gdb-c0734708814c3871992a7d74a4f168a47dc05922.zip gdb-c0734708814c3871992a7d74a4f168a47dc05922.tar.gz gdb-c0734708814c3871992a7d74a4f168a47dc05922.tar.bz2 |
* Makefile.am: New file, based on old Makefile.in.
* acinclude.m4: New file, copied from old aclocal.m4.
* configure.in: Define and call AM_PROG_LIBTOOL and friends.
Remove shared library handling; now handled by libtool. Replace
AC_CONFIG_HEADER with AM_CONFIG_HEADER. Call AM_MAINTAINER_MODE,
AM_CYGWIN32, and AM_EXEEXT. Change all .o files to .lo. Remove
stamp-h handling in AC_OUTPUT.
* acconfig.h: Mention PACKAGE and VERSION.
* stamp-h.in: New file.
* dep-in.sed: Change .o to .lo.
* Makefile.in: Now built with automake.
* aclocal.m4: Now built with aclocal.
* config.in, configure: Rebuild.
Diffstat (limited to 'bfd/acinclude.m4')
-rw-r--r-- | bfd/acinclude.m4 | 49 |
1 files changed, 49 insertions, 0 deletions
diff --git a/bfd/acinclude.m4 b/bfd/acinclude.m4 new file mode 100644 index 0000000..ecb4c79 --- /dev/null +++ b/bfd/acinclude.m4 @@ -0,0 +1,49 @@ +dnl See whether we need to use fopen-bin.h rather than fopen-same.h. +AC_DEFUN(BFD_BINARY_FOPEN, +[AC_REQUIRE([AC_CANONICAL_SYSTEM]) +case "${host}" in +changequote(,)dnl +i[345]86-*-msdos* | i[345]86-*-go32* | *-*-cygwin32 | *-*-windows) +changequote([,])dnl + AC_DEFINE(USE_BINARY_FOPEN) ;; +esac])dnl + +dnl Get a default for CC_FOR_BUILD to put into Makefile. +AC_DEFUN(BFD_CC_FOR_BUILD, +[# Put a plausible default for CC_FOR_BUILD in Makefile. +if test -z "$CC_FOR_BUILD"; then + if test "x$cross_compiling" = "xno"; then + CC_FOR_BUILD='$(CC)' + else + CC_FOR_BUILD=gcc + fi +fi +AC_SUBST(CC_FOR_BUILD)])dnl + +dnl See whether we need a declaration for a function. +AC_DEFUN(BFD_NEED_DECLARATION, +[AC_MSG_CHECKING([whether $1 must be declared]) +AC_CACHE_VAL(bfd_cv_decl_needed_$1, +[AC_TRY_COMPILE([ +#include <stdio.h> +#ifdef HAVE_STRING_H +#include <string.h> +#else +#ifdef HAVE_STRINGS_H +#include <strings.h> +#endif +#endif +#ifdef HAVE_STDLIB_H +#include <stdlib.h> +#endif +#ifdef HAVE_UNISTD_H +#include <unistd.h> +#endif], +[char *(*pfn) = (char *(*)) $1], +bfd_cv_decl_needed_$1=no, bfd_cv_decl_needed_$1=yes)]) +AC_MSG_RESULT($bfd_cv_decl_needed_$1) +if test $bfd_cv_decl_needed_$1 = yes; then + bfd_tr_decl=NEED_DECLARATION_`echo $1 | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` + AC_DEFINE_UNQUOTED($bfd_tr_decl) +fi +])dnl |