1999-08-08 15:27:18 +02:00
|
|
|
dnl Process this with autoconf to create configure
|
2004-03-11 20:59:49 +01:00
|
|
|
|
|
|
|
|
2015-01-12 17:19:59 +01:00
|
|
|
AC_INIT([libffi], [3.99999], [http://github.com/atgreen/libffi/issues])
|
2004-03-11 20:59:49 +01:00
|
|
|
AC_CONFIG_HEADERS([fficonfig.h])
|
|
|
|
|
|
|
|
AM_ENABLE_MULTILIB(, ..)
|
2000-03-03 17:58:42 +01:00
|
|
|
|
2003-09-04 16:47:05 +02:00
|
|
|
AC_CANONICAL_SYSTEM
|
|
|
|
target_alias=${target_alias-$host_alias}
|
1999-08-08 15:27:18 +02:00
|
|
|
|
2014-04-24 23:17:32 +02:00
|
|
|
AM_INIT_AUTOMAKE([no-dist])
|
1999-08-08 15:27:18 +02:00
|
|
|
|
2012-12-29 17:25:27 +01:00
|
|
|
# See if makeinfo has been installed and is modern enough
|
|
|
|
# that we can use it.
|
|
|
|
ACX_CHECK_PROG_VER([MAKEINFO], [makeinfo], [--version],
|
|
|
|
[GNU texinfo.* \([0-9][0-9.]*\)],
|
|
|
|
[4.[4-9]*|4.[1-9][0-9]*|[5-9]*|[1-9][0-9]*])
|
|
|
|
AM_CONDITIONAL(BUILD_INFO, test $gcc_cv_prog_makeinfo_modern = "yes")
|
|
|
|
|
|
|
|
# We would like our source tree to be readonly. However when releases or
|
|
|
|
# pre-releases are generated, the flex/bison generated files as well as the
|
|
|
|
# various formats of manuals need to be included along with the rest of the
|
|
|
|
# sources. Therefore we have --enable-generated-files-in-srcdir to do
|
|
|
|
# just that.
|
|
|
|
AC_MSG_CHECKING(generated-files-in-srcdir)
|
|
|
|
AC_ARG_ENABLE(generated-files-in-srcdir,
|
|
|
|
AS_HELP_STRING([--enable-generated-files-in-srcdir],
|
|
|
|
[put copies of generated files in source dir intended for creating source tarballs for users without texinfo bison or flex]),
|
|
|
|
[case "$enableval" in
|
|
|
|
yes) enable_generated_files_in_srcdir=yes ;;
|
|
|
|
no) enable_generated_files_in_srcdir=no ;;
|
|
|
|
*) AC_MSG_ERROR([Unknown argument to enable/disable version-specific libs]);;
|
|
|
|
esac],
|
|
|
|
[enable_generated_files_in_srcdir=no])
|
|
|
|
AC_MSG_RESULT($enable_generated_files_in_srcdir)
|
|
|
|
AM_CONDITIONAL(GENINSRC, test "$enable_generated_files_in_srcdir" = yes)
|
|
|
|
|
2004-03-11 20:59:49 +01:00
|
|
|
# The same as in boehm-gc and libstdc++. Have to borrow it from there.
|
|
|
|
# We must force CC to /not/ be precious variables; otherwise
|
|
|
|
# the wrong, non-multilib-adjusted value will be used in multilibs.
|
|
|
|
# As a side effect, we have to subst CFLAGS ourselves.
|
2015-01-12 17:19:59 +01:00
|
|
|
# Also save and restore CFLAGS, since AC_PROG_CC will come up with
|
|
|
|
# defaults of its own if none are provided.
|
1999-08-08 15:27:18 +02:00
|
|
|
|
2004-03-11 20:59:49 +01:00
|
|
|
m4_rename([_AC_ARG_VAR_PRECIOUS],[real_PRECIOUS])
|
|
|
|
m4_define([_AC_ARG_VAR_PRECIOUS],[])
|
2015-01-12 17:19:59 +01:00
|
|
|
save_CFLAGS=$CFLAGS
|
1999-08-08 15:27:18 +02:00
|
|
|
AC_PROG_CC
|
2015-01-12 17:19:59 +01:00
|
|
|
AC_PROG_CXX
|
|
|
|
CFLAGS=$save_CFLAGS
|
|
|
|
m4_undefine([_AC_ARG_VAR_PRECIOUS])
|
2009-07-30 21:41:13 +02:00
|
|
|
m4_rename_force([real_PRECIOUS],[_AC_ARG_VAR_PRECIOUS])
|
2003-09-04 16:47:05 +02:00
|
|
|
|
2004-03-11 20:59:49 +01:00
|
|
|
AC_SUBST(CFLAGS)
|
|
|
|
|
|
|
|
AM_PROG_AS
|
|
|
|
AM_PROG_CC_C_O
|
1999-08-08 15:27:18 +02:00
|
|
|
AC_PROG_LIBTOOL
|
|
|
|
|
2015-01-12 17:19:59 +01:00
|
|
|
# Test for 64-bit build.
|
|
|
|
AC_CHECK_SIZEOF([size_t])
|
|
|
|
|
2004-03-11 20:59:49 +01:00
|
|
|
AM_MAINTAINER_MODE
|
|
|
|
|
2004-04-27 07:41:45 +02:00
|
|
|
AC_CHECK_HEADERS(sys/mman.h)
|
2015-01-12 17:19:59 +01:00
|
|
|
AC_CHECK_FUNCS([mmap mkostemp])
|
2003-11-21 12:24:10 +01:00
|
|
|
AC_FUNC_MMAP_BLACKLIST
|
|
|
|
|
2003-09-04 16:47:05 +02:00
|
|
|
dnl The -no-testsuite modules omit the test subdir.
|
|
|
|
AM_CONDITIONAL(TESTSUBDIR, test -d $srcdir/testsuite)
|
|
|
|
|
1999-08-08 15:27:18 +02:00
|
|
|
TARGETDIR="unknown"
|
2013-12-10 01:42:14 +01:00
|
|
|
HAVE_LONG_DOUBLE_VARIANT=0
|
1999-08-08 15:27:18 +02:00
|
|
|
|
2015-01-12 17:19:59 +01:00
|
|
|
. ${srcdir}/configure.host
|
2003-09-04 16:47:05 +02:00
|
|
|
|
2015-01-12 17:19:59 +01:00
|
|
|
if test -n "${UNSUPPORTED}"; then
|
2004-03-11 20:59:49 +01:00
|
|
|
AC_MSG_ERROR(["libffi has not been ported to $host."])
|
1999-08-08 15:27:18 +02:00
|
|
|
fi
|
|
|
|
|
2015-01-12 17:19:59 +01:00
|
|
|
AC_SUBST(AM_RUNTESTFLAGS)
|
|
|
|
AC_SUBST(AM_LTLDFLAGS)
|
1999-08-08 15:27:18 +02:00
|
|
|
|
|
|
|
AC_HEADER_STDC
|
|
|
|
AC_CHECK_FUNCS(memcpy)
|
|
|
|
AC_FUNC_ALLOCA
|
|
|
|
|
2005-05-18 03:49:43 +02:00
|
|
|
AC_CHECK_SIZEOF(double)
|
|
|
|
AC_CHECK_SIZEOF(long double)
|
2002-01-31 23:25:31 +01:00
|
|
|
|
[multiple changes]
2003-10-21 Andreas Tobler <a.tobler@schweiz.ch>
* configure.in: AC_LINK_FILES(ffitarget.h).
* configure: Regenerate.
* Makefile.in: Likewise.
* include/Makefile.in: Likewise.
* testsuite/Makefile.in: Likewise.
* fficonfig.h.in: Likewise.
2003-10-21 Paolo Bonzini <bonzini@gnu.org>
Richard Henderson <rth@redhat.com>
Avoid that ffi.h includes fficonfig.h.
* Makefile.am (EXTRA_DIST): Include ffitarget.h files
(TARGET_SRC_MIPS_GCC): Renamed to TARGET_SRC_MIPS_IRIX.
(TARGET_SRC_MIPS_SGI): Removed.
(MIPS_GCC): Renamed to TARGET_SRC_MIPS_IRIX.
(MIPS_SGI): Removed.
(CLEANFILES): Removed.
(mostlyclean-am, clean-am, mostlyclean-sub, clean-sub): New
targets.
* acconfig.h: Removed.
* configure.in: Compute sizeofs only for double and long double.
Use them to define and subst HAVE_LONG_DOUBLE. Include comments
into AC_DEFINE instead of using acconfig.h. Create
include/ffitarget.h instead of include/fficonfig.h. Rename
MIPS_GCC to MIPS_IRIX, drop MIPS_SGI since we are in gcc's tree.
AC_DEFINE EH_FRAME_FLAGS.
* include/Makefile.am (DISTCLEANFILES): New automake macro.
(hack_DATA): Add ffitarget.h.
* include/ffi.h.in: Remove all system specific definitions.
Declare raw API even if it is not installed, why bother?
Use limits.h instead of SIZEOF_* to define ffi_type_*. Do
not define EH_FRAME_FLAGS, it is in fficonfig.h now. Include
ffitarget.h instead of fficonfig.h. Remove ALIGN macro.
(UINT_ARG, INT_ARG): Removed, use ffi_arg and ffi_sarg instead.
* include/ffi_common.h (bool): Do not define.
(ffi_assert): Accept failed assertion.
(ffi_type_test): Return void and accept file/line.
(FFI_ASSERT): Pass stringized failed assertion.
(FFI_ASSERT_AT): New macro.
(FFI_ASSERT_VALID_TYPE): New macro.
(UINT8, SINT8, UINT16, SINT16, UINT32, SINT32,
UINT64, SINT64): Define here with gcc's __attribute__ macro
instead of in ffi.h
(FLOAT32, ALIGN): Define here instead of in ffi.h
* include/ffi-mips.h: Removed. Its content moved to
src/mips/ffitarget.h after separating assembly and C sections.
* src/alpha/ffi.c, src/alpha/ffi.c, src/java_raw_api.c
src/prep_cif.c, src/raw_api.c, src/ia64/ffi.c,
src/mips/ffi.c, src/mips/n32.S, src/mips/o32.S,
src/mips/ffitarget.h, src/sparc/ffi.c, src/x86/ffi64.c:
SIZEOF_ARG -> FFI_SIZEOF_ARG.
* src/ia64/ffi.c: Include stdbool.h (provided by GCC 2.95+).
* src/debug.c (ffi_assert): Accept stringized failed assertion.
(ffi_type_test): Rewritten.
* src/prep-cif.c (initialize_aggregate, ffi_prep_cif): Call
FFI_ASSERT_VALID_TYPE.
* src/alpha/ffitarget.h, src/arm/ffitarget.h,
src/ia64/ffitarget.h, src/m68k/ffitarget.h,
src/mips/ffitarget.h, src/powerpc/ffitarget.h,
src/s390/ffitarget.h, src/sh/ffitarget.h,
src/sh64/ffitarget.h, src/sparc/ffitarget.h,
src/x86/ffitarget.h: New files.
* src/alpha/osf.S, src/arm/sysv.S, src/ia64/unix.S,
src/m68k/sysv.S, src/mips/n32.S, src/mips/o32.S,
src/powerpc/aix.S, src/powerpc/darwin.S,
src/powerpc/ffi_darwin.c, src/powerpc/linux64.S,
src/powerpc/linux64_closure.S, src/powerpc/ppc_closure.S,
src/powerpc/sysv.S, src/s390/sysv.S, src/sh/sysv.S,
src/sh64/sysv.S, src/sparc/v8.S, src/sparc/v9.S,
src/x86/sysv.S, src/x86/unix64.S, src/x86/win32.S:
include fficonfig.h
From-SVN: r72766
2003-10-21 21:01:58 +02:00
|
|
|
# Also AC_SUBST this variable for ffi.h.
|
2007-04-06 18:24:16 +02:00
|
|
|
if test -z "$HAVE_LONG_DOUBLE"; then
|
|
|
|
HAVE_LONG_DOUBLE=0
|
2013-12-10 01:42:14 +01:00
|
|
|
if test $ac_cv_sizeof_long_double != 0; then
|
|
|
|
if test $HAVE_LONG_DOUBLE_VARIANT != 0; then
|
|
|
|
AC_DEFINE(HAVE_LONG_DOUBLE_VARIANT, 1, [Define if you support more than one size of the long double type])
|
2007-04-06 18:24:16 +02:00
|
|
|
HAVE_LONG_DOUBLE=1
|
2013-12-10 01:42:14 +01:00
|
|
|
else
|
|
|
|
if test $ac_cv_sizeof_double != $ac_cv_sizeof_long_double; then
|
|
|
|
HAVE_LONG_DOUBLE=1
|
|
|
|
AC_DEFINE(HAVE_LONG_DOUBLE, 1, [Define if you have the long double type and it is bigger than a double])
|
|
|
|
fi
|
2007-04-06 18:24:16 +02:00
|
|
|
fi
|
[multiple changes]
2003-10-21 Andreas Tobler <a.tobler@schweiz.ch>
* configure.in: AC_LINK_FILES(ffitarget.h).
* configure: Regenerate.
* Makefile.in: Likewise.
* include/Makefile.in: Likewise.
* testsuite/Makefile.in: Likewise.
* fficonfig.h.in: Likewise.
2003-10-21 Paolo Bonzini <bonzini@gnu.org>
Richard Henderson <rth@redhat.com>
Avoid that ffi.h includes fficonfig.h.
* Makefile.am (EXTRA_DIST): Include ffitarget.h files
(TARGET_SRC_MIPS_GCC): Renamed to TARGET_SRC_MIPS_IRIX.
(TARGET_SRC_MIPS_SGI): Removed.
(MIPS_GCC): Renamed to TARGET_SRC_MIPS_IRIX.
(MIPS_SGI): Removed.
(CLEANFILES): Removed.
(mostlyclean-am, clean-am, mostlyclean-sub, clean-sub): New
targets.
* acconfig.h: Removed.
* configure.in: Compute sizeofs only for double and long double.
Use them to define and subst HAVE_LONG_DOUBLE. Include comments
into AC_DEFINE instead of using acconfig.h. Create
include/ffitarget.h instead of include/fficonfig.h. Rename
MIPS_GCC to MIPS_IRIX, drop MIPS_SGI since we are in gcc's tree.
AC_DEFINE EH_FRAME_FLAGS.
* include/Makefile.am (DISTCLEANFILES): New automake macro.
(hack_DATA): Add ffitarget.h.
* include/ffi.h.in: Remove all system specific definitions.
Declare raw API even if it is not installed, why bother?
Use limits.h instead of SIZEOF_* to define ffi_type_*. Do
not define EH_FRAME_FLAGS, it is in fficonfig.h now. Include
ffitarget.h instead of fficonfig.h. Remove ALIGN macro.
(UINT_ARG, INT_ARG): Removed, use ffi_arg and ffi_sarg instead.
* include/ffi_common.h (bool): Do not define.
(ffi_assert): Accept failed assertion.
(ffi_type_test): Return void and accept file/line.
(FFI_ASSERT): Pass stringized failed assertion.
(FFI_ASSERT_AT): New macro.
(FFI_ASSERT_VALID_TYPE): New macro.
(UINT8, SINT8, UINT16, SINT16, UINT32, SINT32,
UINT64, SINT64): Define here with gcc's __attribute__ macro
instead of in ffi.h
(FLOAT32, ALIGN): Define here instead of in ffi.h
* include/ffi-mips.h: Removed. Its content moved to
src/mips/ffitarget.h after separating assembly and C sections.
* src/alpha/ffi.c, src/alpha/ffi.c, src/java_raw_api.c
src/prep_cif.c, src/raw_api.c, src/ia64/ffi.c,
src/mips/ffi.c, src/mips/n32.S, src/mips/o32.S,
src/mips/ffitarget.h, src/sparc/ffi.c, src/x86/ffi64.c:
SIZEOF_ARG -> FFI_SIZEOF_ARG.
* src/ia64/ffi.c: Include stdbool.h (provided by GCC 2.95+).
* src/debug.c (ffi_assert): Accept stringized failed assertion.
(ffi_type_test): Rewritten.
* src/prep-cif.c (initialize_aggregate, ffi_prep_cif): Call
FFI_ASSERT_VALID_TYPE.
* src/alpha/ffitarget.h, src/arm/ffitarget.h,
src/ia64/ffitarget.h, src/m68k/ffitarget.h,
src/mips/ffitarget.h, src/powerpc/ffitarget.h,
src/s390/ffitarget.h, src/sh/ffitarget.h,
src/sh64/ffitarget.h, src/sparc/ffitarget.h,
src/x86/ffitarget.h: New files.
* src/alpha/osf.S, src/arm/sysv.S, src/ia64/unix.S,
src/m68k/sysv.S, src/mips/n32.S, src/mips/o32.S,
src/powerpc/aix.S, src/powerpc/darwin.S,
src/powerpc/ffi_darwin.c, src/powerpc/linux64.S,
src/powerpc/linux64_closure.S, src/powerpc/ppc_closure.S,
src/powerpc/sysv.S, src/s390/sysv.S, src/sh/sysv.S,
src/sh64/sysv.S, src/sparc/v8.S, src/sparc/v9.S,
src/x86/sysv.S, src/x86/unix64.S, src/x86/win32.S:
include fficonfig.h
From-SVN: r72766
2003-10-21 21:01:58 +02:00
|
|
|
fi
|
|
|
|
fi
|
|
|
|
AC_SUBST(HAVE_LONG_DOUBLE)
|
2013-12-10 01:42:14 +01:00
|
|
|
AC_SUBST(HAVE_LONG_DOUBLE_VARIANT)
|
[multiple changes]
2003-10-21 Andreas Tobler <a.tobler@schweiz.ch>
* configure.in: AC_LINK_FILES(ffitarget.h).
* configure: Regenerate.
* Makefile.in: Likewise.
* include/Makefile.in: Likewise.
* testsuite/Makefile.in: Likewise.
* fficonfig.h.in: Likewise.
2003-10-21 Paolo Bonzini <bonzini@gnu.org>
Richard Henderson <rth@redhat.com>
Avoid that ffi.h includes fficonfig.h.
* Makefile.am (EXTRA_DIST): Include ffitarget.h files
(TARGET_SRC_MIPS_GCC): Renamed to TARGET_SRC_MIPS_IRIX.
(TARGET_SRC_MIPS_SGI): Removed.
(MIPS_GCC): Renamed to TARGET_SRC_MIPS_IRIX.
(MIPS_SGI): Removed.
(CLEANFILES): Removed.
(mostlyclean-am, clean-am, mostlyclean-sub, clean-sub): New
targets.
* acconfig.h: Removed.
* configure.in: Compute sizeofs only for double and long double.
Use them to define and subst HAVE_LONG_DOUBLE. Include comments
into AC_DEFINE instead of using acconfig.h. Create
include/ffitarget.h instead of include/fficonfig.h. Rename
MIPS_GCC to MIPS_IRIX, drop MIPS_SGI since we are in gcc's tree.
AC_DEFINE EH_FRAME_FLAGS.
* include/Makefile.am (DISTCLEANFILES): New automake macro.
(hack_DATA): Add ffitarget.h.
* include/ffi.h.in: Remove all system specific definitions.
Declare raw API even if it is not installed, why bother?
Use limits.h instead of SIZEOF_* to define ffi_type_*. Do
not define EH_FRAME_FLAGS, it is in fficonfig.h now. Include
ffitarget.h instead of fficonfig.h. Remove ALIGN macro.
(UINT_ARG, INT_ARG): Removed, use ffi_arg and ffi_sarg instead.
* include/ffi_common.h (bool): Do not define.
(ffi_assert): Accept failed assertion.
(ffi_type_test): Return void and accept file/line.
(FFI_ASSERT): Pass stringized failed assertion.
(FFI_ASSERT_AT): New macro.
(FFI_ASSERT_VALID_TYPE): New macro.
(UINT8, SINT8, UINT16, SINT16, UINT32, SINT32,
UINT64, SINT64): Define here with gcc's __attribute__ macro
instead of in ffi.h
(FLOAT32, ALIGN): Define here instead of in ffi.h
* include/ffi-mips.h: Removed. Its content moved to
src/mips/ffitarget.h after separating assembly and C sections.
* src/alpha/ffi.c, src/alpha/ffi.c, src/java_raw_api.c
src/prep_cif.c, src/raw_api.c, src/ia64/ffi.c,
src/mips/ffi.c, src/mips/n32.S, src/mips/o32.S,
src/mips/ffitarget.h, src/sparc/ffi.c, src/x86/ffi64.c:
SIZEOF_ARG -> FFI_SIZEOF_ARG.
* src/ia64/ffi.c: Include stdbool.h (provided by GCC 2.95+).
* src/debug.c (ffi_assert): Accept stringized failed assertion.
(ffi_type_test): Rewritten.
* src/prep-cif.c (initialize_aggregate, ffi_prep_cif): Call
FFI_ASSERT_VALID_TYPE.
* src/alpha/ffitarget.h, src/arm/ffitarget.h,
src/ia64/ffitarget.h, src/m68k/ffitarget.h,
src/mips/ffitarget.h, src/powerpc/ffitarget.h,
src/s390/ffitarget.h, src/sh/ffitarget.h,
src/sh64/ffitarget.h, src/sparc/ffitarget.h,
src/x86/ffitarget.h: New files.
* src/alpha/osf.S, src/arm/sysv.S, src/ia64/unix.S,
src/m68k/sysv.S, src/mips/n32.S, src/mips/o32.S,
src/powerpc/aix.S, src/powerpc/darwin.S,
src/powerpc/ffi_darwin.c, src/powerpc/linux64.S,
src/powerpc/linux64_closure.S, src/powerpc/ppc_closure.S,
src/powerpc/sysv.S, src/s390/sysv.S, src/sh/sysv.S,
src/sh64/sysv.S, src/sparc/v8.S, src/sparc/v9.S,
src/x86/sysv.S, src/x86/unix64.S, src/x86/win32.S:
include fficonfig.h
From-SVN: r72766
2003-10-21 21:01:58 +02:00
|
|
|
|
2005-05-18 03:49:43 +02:00
|
|
|
AC_C_BIGENDIAN
|
1999-08-08 15:27:18 +02:00
|
|
|
|
2011-11-10 20:34:57 +01:00
|
|
|
GCC_AS_CFI_PSEUDO_OP
|
2007-05-10 23:20:02 +02:00
|
|
|
|
2015-01-29 00:23:55 +01:00
|
|
|
case "$TARGET" in
|
|
|
|
SPARC)
|
2002-04-28 21:57:42 +02:00
|
|
|
AC_CACHE_CHECK([assembler and linker support unaligned pc related relocs],
|
|
|
|
libffi_cv_as_sparc_ua_pcrel, [
|
|
|
|
save_CFLAGS="$CFLAGS"
|
|
|
|
save_LDFLAGS="$LDFLAGS"
|
|
|
|
CFLAGS="$CFLAGS -fpic"
|
|
|
|
LDFLAGS="$LDFLAGS -shared"
|
|
|
|
AC_TRY_LINK([asm (".text; foo: nop; .data; .align 4; .byte 0; .uaword %r_disp32(foo); .text");],,
|
|
|
|
[libffi_cv_as_sparc_ua_pcrel=yes],
|
|
|
|
[libffi_cv_as_sparc_ua_pcrel=no])
|
|
|
|
CFLAGS="$save_CFLAGS"
|
|
|
|
LDFLAGS="$save_LDFLAGS"])
|
|
|
|
if test "x$libffi_cv_as_sparc_ua_pcrel" = xyes; then
|
|
|
|
AC_DEFINE(HAVE_AS_SPARC_UA_PCREL, 1,
|
|
|
|
[Define if your assembler and linker support unaligned PC relative relocs.])
|
|
|
|
fi
|
2003-05-08 22:41:24 +02:00
|
|
|
|
|
|
|
AC_CACHE_CHECK([assembler .register pseudo-op support],
|
|
|
|
libffi_cv_as_register_pseudo_op, [
|
|
|
|
libffi_cv_as_register_pseudo_op=unknown
|
|
|
|
# Check if we have .register
|
2015-01-12 17:19:59 +01:00
|
|
|
AC_TRY_COMPILE(,[asm (".register %g2, #scratch");],
|
2004-03-11 20:59:49 +01:00
|
|
|
[libffi_cv_as_register_pseudo_op=yes],
|
|
|
|
[libffi_cv_as_register_pseudo_op=no])
|
2003-05-08 22:41:24 +02:00
|
|
|
])
|
|
|
|
if test "x$libffi_cv_as_register_pseudo_op" = xyes; then
|
|
|
|
AC_DEFINE(HAVE_AS_REGISTER_PSEUDO_OP, 1,
|
2004-03-11 20:59:49 +01:00
|
|
|
[Define if your assembler supports .register.])
|
2003-05-08 22:41:24 +02:00
|
|
|
fi
|
2015-01-29 00:23:55 +01:00
|
|
|
;;
|
2002-04-28 21:57:42 +02:00
|
|
|
|
2015-01-29 00:23:55 +01:00
|
|
|
X86*)
|
2008-12-19 15:59:42 +01:00
|
|
|
AC_CACHE_CHECK([assembler supports pc related relocs],
|
|
|
|
libffi_cv_as_x86_pcrel, [
|
2015-01-12 17:19:59 +01:00
|
|
|
libffi_cv_as_x86_pcrel=no
|
2008-12-19 15:59:42 +01:00
|
|
|
echo '.text; foo: nop; .data; .long foo-.; .text' > conftest.s
|
2015-01-12 17:19:59 +01:00
|
|
|
if $CC $CFLAGS -c conftest.s > /dev/null 2>&1; then
|
|
|
|
libffi_cv_as_x86_pcrel=yes
|
2008-12-19 15:59:42 +01:00
|
|
|
fi
|
|
|
|
])
|
|
|
|
if test "x$libffi_cv_as_x86_pcrel" = xyes; then
|
|
|
|
AC_DEFINE(HAVE_AS_X86_PCREL, 1,
|
|
|
|
[Define if your assembler supports PC relative relocs.])
|
|
|
|
fi
|
2015-01-29 00:23:55 +01:00
|
|
|
;;
|
2010-05-19 17:31:36 +02:00
|
|
|
|
2015-01-29 00:23:55 +01:00
|
|
|
S390)
|
2015-01-12 17:19:59 +01:00
|
|
|
AC_CACHE_CHECK([compiler uses zarch features],
|
|
|
|
libffi_cv_as_s390_zarch, [
|
|
|
|
libffi_cv_as_s390_zarch=no
|
|
|
|
echo 'void foo(void) { bar(); bar(); }' > conftest.c
|
|
|
|
if $CC $CFLAGS -S conftest.c > /dev/null 2>&1; then
|
|
|
|
if grep -q brasl conftest.s; then
|
|
|
|
libffi_cv_as_s390_zarch=yes
|
|
|
|
fi
|
|
|
|
fi
|
|
|
|
])
|
|
|
|
if test "x$libffi_cv_as_s390_zarch" = xyes; then
|
|
|
|
AC_DEFINE(HAVE_AS_S390_ZARCH, 1,
|
|
|
|
[Define if the compiler uses zarch features.])
|
|
|
|
fi
|
2015-01-29 00:23:55 +01:00
|
|
|
;;
|
|
|
|
esac
|
2015-01-12 17:19:59 +01:00
|
|
|
|
2012-12-26 17:28:02 +01:00
|
|
|
# On PaX enable kernels that have MPROTECT enable we can't use PROT_EXEC.
|
|
|
|
AC_ARG_ENABLE(pax_emutramp,
|
|
|
|
[ --enable-pax_emutramp enable pax emulated trampolines, for we can't use PROT_EXEC],
|
|
|
|
if test "$enable_pax_emutramp" = "yes"; then
|
|
|
|
AC_DEFINE(FFI_MMAP_EXEC_EMUTRAMP_PAX, 1,
|
|
|
|
[Define this if you want to enable pax emulated trampolines])
|
|
|
|
fi)
|
|
|
|
|
|
|
|
FFI_EXEC_TRAMPOLINE_TABLE=0
|
2009-12-26 19:49:55 +01:00
|
|
|
case "$target" in
|
2015-01-29 00:23:55 +01:00
|
|
|
*arm*-apple-darwin* | aarch64-apple-darwin*)
|
2012-12-26 17:28:02 +01:00
|
|
|
FFI_EXEC_TRAMPOLINE_TABLE=1
|
|
|
|
AC_DEFINE(FFI_EXEC_TRAMPOLINE_TABLE, 1,
|
|
|
|
[Cannot use PROT_EXEC on this target, so, we revert to
|
|
|
|
alternative means])
|
|
|
|
;;
|
|
|
|
*-apple-darwin1* | *-*-freebsd* | *-*-kfreebsd* | *-*-openbsd* | *-pc-solaris*)
|
2009-12-26 19:49:55 +01:00
|
|
|
AC_DEFINE(FFI_MMAP_EXEC_WRIT, 1,
|
|
|
|
[Cannot use malloc on this target, so, we revert to
|
|
|
|
alternative means])
|
|
|
|
;;
|
|
|
|
esac
|
2012-12-26 17:28:02 +01:00
|
|
|
AM_CONDITIONAL(FFI_EXEC_TRAMPOLINE_TABLE, test x$FFI_EXEC_TRAMPOLINE_TABLE = x1)
|
|
|
|
AC_SUBST(FFI_EXEC_TRAMPOLINE_TABLE)
|
2009-12-26 19:49:55 +01:00
|
|
|
|
2010-03-15 20:36:26 +01:00
|
|
|
if test x$TARGET = xX86_64; then
|
2015-01-12 17:19:59 +01:00
|
|
|
AC_CACHE_CHECK([toolchain supports unwind section type],
|
2010-03-15 20:36:26 +01:00
|
|
|
libffi_cv_as_x86_64_unwind_section_type, [
|
2015-01-12 17:19:59 +01:00
|
|
|
cat > conftest1.s << EOF
|
|
|
|
.text
|
|
|
|
.globl foo
|
|
|
|
foo:
|
|
|
|
jmp bar
|
|
|
|
.section .eh_frame,"a",@unwind
|
|
|
|
bar:
|
|
|
|
EOF
|
|
|
|
|
|
|
|
cat > conftest2.c << EOF
|
|
|
|
extern void foo();
|
|
|
|
int main(){foo();}
|
|
|
|
EOF
|
|
|
|
|
|
|
|
libffi_cv_as_x86_64_unwind_section_type=no
|
|
|
|
# we ensure that we can compile _and_ link an assembly file containing an @unwind section
|
|
|
|
# since the compiler can support it and not the linker (ie old binutils)
|
|
|
|
if $CC -Wa,--fatal-warnings $CFLAGS -c conftest1.s > /dev/null 2>&1 && \
|
|
|
|
$CC conftest2.c conftest1.o > /dev/null 2>&1 ; then
|
|
|
|
libffi_cv_as_x86_64_unwind_section_type=yes
|
2010-03-15 20:36:26 +01:00
|
|
|
fi
|
|
|
|
])
|
|
|
|
if test "x$libffi_cv_as_x86_64_unwind_section_type" = xyes; then
|
|
|
|
AC_DEFINE(HAVE_AS_X86_64_UNWIND_SECTION_TYPE, 1,
|
|
|
|
[Define if your assembler supports unwind section type.])
|
|
|
|
fi
|
|
|
|
fi
|
|
|
|
|
2012-12-26 17:28:02 +01:00
|
|
|
if test "x$GCC" = "xyes"; then
|
|
|
|
AC_CACHE_CHECK([whether .eh_frame section should be read-only],
|
|
|
|
libffi_cv_ro_eh_frame, [
|
|
|
|
libffi_cv_ro_eh_frame=no
|
|
|
|
echo 'extern void foo (void); void bar (void) { foo (); foo (); }' > conftest.c
|
2015-01-12 17:19:59 +01:00
|
|
|
if $CC $CFLAGS -c -fpic -fexceptions -o conftest.o conftest.c > /dev/null 2>&1; then
|
|
|
|
objdump -h conftest.o > conftest.dump 2>&1
|
|
|
|
libffi_eh_frame_line=`grep -n eh_frame conftest.dump | cut -d: -f 1`
|
|
|
|
if test "x$libffi_eh_frame_line" != "x"; then
|
|
|
|
libffi_test_line=`expr $libffi_eh_frame_line + 1`p
|
|
|
|
sed -n $libffi_test_line conftest.dump > conftest.line
|
|
|
|
if grep READONLY conftest.line > /dev/null; then
|
|
|
|
libffi_cv_ro_eh_frame=yes
|
|
|
|
fi
|
|
|
|
fi
|
2012-12-26 17:28:02 +01:00
|
|
|
fi
|
|
|
|
rm -f conftest.*
|
|
|
|
])
|
|
|
|
if test "x$libffi_cv_ro_eh_frame" = xyes; then
|
|
|
|
AC_DEFINE(HAVE_RO_EH_FRAME, 1,
|
|
|
|
[Define if .eh_frame sections should be read-only.])
|
|
|
|
AC_DEFINE(EH_FRAME_FLAGS, "a",
|
|
|
|
[Define to the flags needed for the .section .eh_frame directive. ])
|
|
|
|
else
|
|
|
|
AC_DEFINE(EH_FRAME_FLAGS, "aw",
|
|
|
|
[Define to the flags needed for the .section .eh_frame directive. ])
|
|
|
|
fi
|
2003-05-17 00:09:22 +02:00
|
|
|
|
2012-12-26 17:28:02 +01:00
|
|
|
AC_CACHE_CHECK([for __attribute__((visibility("hidden")))],
|
|
|
|
libffi_cv_hidden_visibility_attribute, [
|
|
|
|
echo 'int __attribute__ ((visibility ("hidden"))) foo (void) { return 1 ; }' > conftest.c
|
|
|
|
libffi_cv_hidden_visibility_attribute=no
|
|
|
|
if AC_TRY_COMMAND(${CC-cc} -Werror -S conftest.c -o conftest.s 1>&AS_MESSAGE_LOG_FD); then
|
|
|
|
if grep '\.hidden.*foo' conftest.s >/dev/null; then
|
|
|
|
libffi_cv_hidden_visibility_attribute=yes
|
|
|
|
fi
|
|
|
|
fi
|
|
|
|
rm -f conftest.*
|
|
|
|
])
|
|
|
|
if test $libffi_cv_hidden_visibility_attribute = yes; then
|
|
|
|
AC_DEFINE(HAVE_HIDDEN_VISIBILITY_ATTRIBUTE, 1,
|
|
|
|
[Define if __attribute__((visibility("hidden"))) is supported.])
|
|
|
|
fi
|
2005-08-11 23:18:24 +02:00
|
|
|
fi
|
|
|
|
|
|
|
|
AH_BOTTOM([
|
|
|
|
#ifdef HAVE_HIDDEN_VISIBILITY_ATTRIBUTE
|
|
|
|
#ifdef LIBFFI_ASM
|
|
|
|
#define FFI_HIDDEN(name) .hidden name
|
|
|
|
#else
|
|
|
|
#define FFI_HIDDEN __attribute__ ((visibility ("hidden")))
|
|
|
|
#endif
|
|
|
|
#else
|
|
|
|
#ifdef LIBFFI_ASM
|
|
|
|
#define FFI_HIDDEN(name)
|
|
|
|
#else
|
|
|
|
#define FFI_HIDDEN
|
|
|
|
#endif
|
|
|
|
#endif
|
|
|
|
])
|
|
|
|
|
1999-08-08 15:27:18 +02:00
|
|
|
AC_SUBST(TARGET)
|
|
|
|
AC_SUBST(TARGETDIR)
|
|
|
|
|
2015-01-12 17:19:59 +01:00
|
|
|
changequote(<,>)
|
|
|
|
TARGET_OBJ=
|
|
|
|
for i in $SOURCES; do
|
|
|
|
TARGET_OBJ="${TARGET_OBJ} src/${TARGETDIR}/"`echo $i | sed 's/[cS]$/lo/'`
|
|
|
|
done
|
|
|
|
changequote([,])
|
|
|
|
AC_SUBST(TARGET_OBJ)
|
|
|
|
|
1999-08-08 15:27:18 +02:00
|
|
|
AC_SUBST(SHELL)
|
|
|
|
|
2001-06-01 06:09:21 +02:00
|
|
|
AC_ARG_ENABLE(debug,
|
|
|
|
[ --enable-debug debugging mode],
|
|
|
|
if test "$enable_debug" = "yes"; then
|
[multiple changes]
2003-10-21 Andreas Tobler <a.tobler@schweiz.ch>
* configure.in: AC_LINK_FILES(ffitarget.h).
* configure: Regenerate.
* Makefile.in: Likewise.
* include/Makefile.in: Likewise.
* testsuite/Makefile.in: Likewise.
* fficonfig.h.in: Likewise.
2003-10-21 Paolo Bonzini <bonzini@gnu.org>
Richard Henderson <rth@redhat.com>
Avoid that ffi.h includes fficonfig.h.
* Makefile.am (EXTRA_DIST): Include ffitarget.h files
(TARGET_SRC_MIPS_GCC): Renamed to TARGET_SRC_MIPS_IRIX.
(TARGET_SRC_MIPS_SGI): Removed.
(MIPS_GCC): Renamed to TARGET_SRC_MIPS_IRIX.
(MIPS_SGI): Removed.
(CLEANFILES): Removed.
(mostlyclean-am, clean-am, mostlyclean-sub, clean-sub): New
targets.
* acconfig.h: Removed.
* configure.in: Compute sizeofs only for double and long double.
Use them to define and subst HAVE_LONG_DOUBLE. Include comments
into AC_DEFINE instead of using acconfig.h. Create
include/ffitarget.h instead of include/fficonfig.h. Rename
MIPS_GCC to MIPS_IRIX, drop MIPS_SGI since we are in gcc's tree.
AC_DEFINE EH_FRAME_FLAGS.
* include/Makefile.am (DISTCLEANFILES): New automake macro.
(hack_DATA): Add ffitarget.h.
* include/ffi.h.in: Remove all system specific definitions.
Declare raw API even if it is not installed, why bother?
Use limits.h instead of SIZEOF_* to define ffi_type_*. Do
not define EH_FRAME_FLAGS, it is in fficonfig.h now. Include
ffitarget.h instead of fficonfig.h. Remove ALIGN macro.
(UINT_ARG, INT_ARG): Removed, use ffi_arg and ffi_sarg instead.
* include/ffi_common.h (bool): Do not define.
(ffi_assert): Accept failed assertion.
(ffi_type_test): Return void and accept file/line.
(FFI_ASSERT): Pass stringized failed assertion.
(FFI_ASSERT_AT): New macro.
(FFI_ASSERT_VALID_TYPE): New macro.
(UINT8, SINT8, UINT16, SINT16, UINT32, SINT32,
UINT64, SINT64): Define here with gcc's __attribute__ macro
instead of in ffi.h
(FLOAT32, ALIGN): Define here instead of in ffi.h
* include/ffi-mips.h: Removed. Its content moved to
src/mips/ffitarget.h after separating assembly and C sections.
* src/alpha/ffi.c, src/alpha/ffi.c, src/java_raw_api.c
src/prep_cif.c, src/raw_api.c, src/ia64/ffi.c,
src/mips/ffi.c, src/mips/n32.S, src/mips/o32.S,
src/mips/ffitarget.h, src/sparc/ffi.c, src/x86/ffi64.c:
SIZEOF_ARG -> FFI_SIZEOF_ARG.
* src/ia64/ffi.c: Include stdbool.h (provided by GCC 2.95+).
* src/debug.c (ffi_assert): Accept stringized failed assertion.
(ffi_type_test): Rewritten.
* src/prep-cif.c (initialize_aggregate, ffi_prep_cif): Call
FFI_ASSERT_VALID_TYPE.
* src/alpha/ffitarget.h, src/arm/ffitarget.h,
src/ia64/ffitarget.h, src/m68k/ffitarget.h,
src/mips/ffitarget.h, src/powerpc/ffitarget.h,
src/s390/ffitarget.h, src/sh/ffitarget.h,
src/sh64/ffitarget.h, src/sparc/ffitarget.h,
src/x86/ffitarget.h: New files.
* src/alpha/osf.S, src/arm/sysv.S, src/ia64/unix.S,
src/m68k/sysv.S, src/mips/n32.S, src/mips/o32.S,
src/powerpc/aix.S, src/powerpc/darwin.S,
src/powerpc/ffi_darwin.c, src/powerpc/linux64.S,
src/powerpc/linux64_closure.S, src/powerpc/ppc_closure.S,
src/powerpc/sysv.S, src/s390/sysv.S, src/sh/sysv.S,
src/sh64/sysv.S, src/sparc/v8.S, src/sparc/v9.S,
src/x86/sysv.S, src/x86/unix64.S, src/x86/win32.S:
include fficonfig.h
From-SVN: r72766
2003-10-21 21:01:58 +02:00
|
|
|
AC_DEFINE(FFI_DEBUG, 1, [Define this if you want extra debugging.])
|
2001-06-01 06:09:21 +02:00
|
|
|
fi)
|
2012-12-26 17:28:02 +01:00
|
|
|
AM_CONDITIONAL(FFI_DEBUG, test "$enable_debug" = "yes")
|
2001-06-01 06:09:21 +02:00
|
|
|
|
|
|
|
AC_ARG_ENABLE(structs,
|
|
|
|
[ --disable-structs omit code for struct support],
|
|
|
|
if test "$enable_structs" = "no"; then
|
2015-01-12 17:19:59 +01:00
|
|
|
AC_DEFINE(FFI_NO_STRUCTS, 1, [Define this if you do not want support for aggregate types.])
|
2001-06-01 06:09:21 +02:00
|
|
|
fi)
|
2015-01-12 17:19:59 +01:00
|
|
|
AM_CONDITIONAL(FFI_DEBUG, test "$enable_debug" = "yes")
|
2001-06-01 06:09:21 +02:00
|
|
|
|
|
|
|
AC_ARG_ENABLE(raw-api,
|
|
|
|
[ --disable-raw-api make the raw api unavailable],
|
|
|
|
if test "$enable_raw_api" = "no"; then
|
2015-01-12 17:19:59 +01:00
|
|
|
AC_DEFINE(FFI_NO_RAW_API, 1, [Define this if you do not want support for the raw API.])
|
2001-06-01 06:09:21 +02:00
|
|
|
fi)
|
1999-08-08 15:27:18 +02:00
|
|
|
|
|
|
|
AC_ARG_ENABLE(purify-safety,
|
2001-06-01 06:09:21 +02:00
|
|
|
[ --enable-purify-safety purify-safe mode],
|
|
|
|
if test "$enable_purify_safety" = "yes"; then
|
[multiple changes]
2003-10-21 Andreas Tobler <a.tobler@schweiz.ch>
* configure.in: AC_LINK_FILES(ffitarget.h).
* configure: Regenerate.
* Makefile.in: Likewise.
* include/Makefile.in: Likewise.
* testsuite/Makefile.in: Likewise.
* fficonfig.h.in: Likewise.
2003-10-21 Paolo Bonzini <bonzini@gnu.org>
Richard Henderson <rth@redhat.com>
Avoid that ffi.h includes fficonfig.h.
* Makefile.am (EXTRA_DIST): Include ffitarget.h files
(TARGET_SRC_MIPS_GCC): Renamed to TARGET_SRC_MIPS_IRIX.
(TARGET_SRC_MIPS_SGI): Removed.
(MIPS_GCC): Renamed to TARGET_SRC_MIPS_IRIX.
(MIPS_SGI): Removed.
(CLEANFILES): Removed.
(mostlyclean-am, clean-am, mostlyclean-sub, clean-sub): New
targets.
* acconfig.h: Removed.
* configure.in: Compute sizeofs only for double and long double.
Use them to define and subst HAVE_LONG_DOUBLE. Include comments
into AC_DEFINE instead of using acconfig.h. Create
include/ffitarget.h instead of include/fficonfig.h. Rename
MIPS_GCC to MIPS_IRIX, drop MIPS_SGI since we are in gcc's tree.
AC_DEFINE EH_FRAME_FLAGS.
* include/Makefile.am (DISTCLEANFILES): New automake macro.
(hack_DATA): Add ffitarget.h.
* include/ffi.h.in: Remove all system specific definitions.
Declare raw API even if it is not installed, why bother?
Use limits.h instead of SIZEOF_* to define ffi_type_*. Do
not define EH_FRAME_FLAGS, it is in fficonfig.h now. Include
ffitarget.h instead of fficonfig.h. Remove ALIGN macro.
(UINT_ARG, INT_ARG): Removed, use ffi_arg and ffi_sarg instead.
* include/ffi_common.h (bool): Do not define.
(ffi_assert): Accept failed assertion.
(ffi_type_test): Return void and accept file/line.
(FFI_ASSERT): Pass stringized failed assertion.
(FFI_ASSERT_AT): New macro.
(FFI_ASSERT_VALID_TYPE): New macro.
(UINT8, SINT8, UINT16, SINT16, UINT32, SINT32,
UINT64, SINT64): Define here with gcc's __attribute__ macro
instead of in ffi.h
(FLOAT32, ALIGN): Define here instead of in ffi.h
* include/ffi-mips.h: Removed. Its content moved to
src/mips/ffitarget.h after separating assembly and C sections.
* src/alpha/ffi.c, src/alpha/ffi.c, src/java_raw_api.c
src/prep_cif.c, src/raw_api.c, src/ia64/ffi.c,
src/mips/ffi.c, src/mips/n32.S, src/mips/o32.S,
src/mips/ffitarget.h, src/sparc/ffi.c, src/x86/ffi64.c:
SIZEOF_ARG -> FFI_SIZEOF_ARG.
* src/ia64/ffi.c: Include stdbool.h (provided by GCC 2.95+).
* src/debug.c (ffi_assert): Accept stringized failed assertion.
(ffi_type_test): Rewritten.
* src/prep-cif.c (initialize_aggregate, ffi_prep_cif): Call
FFI_ASSERT_VALID_TYPE.
* src/alpha/ffitarget.h, src/arm/ffitarget.h,
src/ia64/ffitarget.h, src/m68k/ffitarget.h,
src/mips/ffitarget.h, src/powerpc/ffitarget.h,
src/s390/ffitarget.h, src/sh/ffitarget.h,
src/sh64/ffitarget.h, src/sparc/ffitarget.h,
src/x86/ffitarget.h: New files.
* src/alpha/osf.S, src/arm/sysv.S, src/ia64/unix.S,
src/m68k/sysv.S, src/mips/n32.S, src/mips/o32.S,
src/powerpc/aix.S, src/powerpc/darwin.S,
src/powerpc/ffi_darwin.c, src/powerpc/linux64.S,
src/powerpc/linux64_closure.S, src/powerpc/ppc_closure.S,
src/powerpc/sysv.S, src/s390/sysv.S, src/sh/sysv.S,
src/sh64/sysv.S, src/sparc/v8.S, src/sparc/v9.S,
src/x86/sysv.S, src/x86/unix64.S, src/x86/win32.S:
include fficonfig.h
From-SVN: r72766
2003-10-21 21:01:58 +02:00
|
|
|
AC_DEFINE(USING_PURIFY, 1, [Define this if you are using Purify and want to suppress spurious messages.])
|
2001-06-01 06:09:21 +02:00
|
|
|
fi)
|
1999-08-10 07:29:27 +02:00
|
|
|
|
2020-01-24 12:24:25 +01:00
|
|
|
GCC_WITH_TOOLEXECLIBDIR
|
|
|
|
|
2003-01-28 02:48:33 +01:00
|
|
|
if test -n "$with_cross_host" &&
|
|
|
|
test x"$with_cross_host" != x"no"; then
|
|
|
|
toolexecdir='$(exec_prefix)/$(target_alias)'
|
2020-01-24 12:24:25 +01:00
|
|
|
case ${with_toolexeclibdir} in
|
|
|
|
no)
|
|
|
|
toolexeclibdir='$(toolexecdir)/lib'
|
|
|
|
;;
|
|
|
|
*)
|
|
|
|
toolexeclibdir=${with_toolexeclibdir}
|
|
|
|
;;
|
|
|
|
esac
|
2003-01-28 02:48:33 +01:00
|
|
|
else
|
|
|
|
toolexecdir='$(libdir)/gcc-lib/$(target_alias)'
|
|
|
|
toolexeclibdir='$(libdir)'
|
|
|
|
fi
|
2003-03-12 22:34:31 +01:00
|
|
|
multi_os_directory=`$CC -print-multi-os-directory`
|
|
|
|
case $multi_os_directory in
|
|
|
|
.) ;; # Avoid trailing /.
|
|
|
|
*) toolexeclibdir=$toolexeclibdir/$multi_os_directory ;;
|
|
|
|
esac
|
2003-01-28 02:48:33 +01:00
|
|
|
AC_SUBST(toolexecdir)
|
|
|
|
AC_SUBST(toolexeclibdir)
|
1999-08-08 15:27:18 +02:00
|
|
|
|
2000-03-03 17:58:42 +01:00
|
|
|
if test "${multilib}" = "yes"; then
|
|
|
|
multilib_arg="--enable-multilib"
|
|
|
|
else
|
|
|
|
multilib_arg=
|
|
|
|
fi
|
|
|
|
|
2016-03-03 00:28:11 +01:00
|
|
|
# Check linker support.
|
|
|
|
LIBAT_ENABLE_SYMVERS
|
|
|
|
|
2017-01-21 09:47:11 +01:00
|
|
|
# Determine what GCC version number to use in filesystem paths.
|
|
|
|
GCC_BASE_VER
|
|
|
|
|
2004-03-11 20:59:49 +01:00
|
|
|
AC_CONFIG_COMMANDS(include, [test -d include || mkdir include])
|
|
|
|
AC_CONFIG_COMMANDS(src, [
|
2001-03-29 02:03:27 +02:00
|
|
|
test -d src || mkdir src
|
2004-03-11 20:59:49 +01:00
|
|
|
test -d src/$TARGETDIR || mkdir src/$TARGETDIR
|
|
|
|
], [TARGETDIR="$TARGETDIR"])
|
|
|
|
|
|
|
|
AC_CONFIG_LINKS(include/ffitarget.h:src/$TARGETDIR/ffitarget.h)
|
|
|
|
|
2015-01-12 17:19:59 +01:00
|
|
|
AC_CONFIG_FILES(include/Makefile include/ffi.h Makefile testsuite/Makefile man/Makefile libffi.pc)
|
[multiple changes]
2003-10-21 Andreas Tobler <a.tobler@schweiz.ch>
* configure.in: AC_LINK_FILES(ffitarget.h).
* configure: Regenerate.
* Makefile.in: Likewise.
* include/Makefile.in: Likewise.
* testsuite/Makefile.in: Likewise.
* fficonfig.h.in: Likewise.
2003-10-21 Paolo Bonzini <bonzini@gnu.org>
Richard Henderson <rth@redhat.com>
Avoid that ffi.h includes fficonfig.h.
* Makefile.am (EXTRA_DIST): Include ffitarget.h files
(TARGET_SRC_MIPS_GCC): Renamed to TARGET_SRC_MIPS_IRIX.
(TARGET_SRC_MIPS_SGI): Removed.
(MIPS_GCC): Renamed to TARGET_SRC_MIPS_IRIX.
(MIPS_SGI): Removed.
(CLEANFILES): Removed.
(mostlyclean-am, clean-am, mostlyclean-sub, clean-sub): New
targets.
* acconfig.h: Removed.
* configure.in: Compute sizeofs only for double and long double.
Use them to define and subst HAVE_LONG_DOUBLE. Include comments
into AC_DEFINE instead of using acconfig.h. Create
include/ffitarget.h instead of include/fficonfig.h. Rename
MIPS_GCC to MIPS_IRIX, drop MIPS_SGI since we are in gcc's tree.
AC_DEFINE EH_FRAME_FLAGS.
* include/Makefile.am (DISTCLEANFILES): New automake macro.
(hack_DATA): Add ffitarget.h.
* include/ffi.h.in: Remove all system specific definitions.
Declare raw API even if it is not installed, why bother?
Use limits.h instead of SIZEOF_* to define ffi_type_*. Do
not define EH_FRAME_FLAGS, it is in fficonfig.h now. Include
ffitarget.h instead of fficonfig.h. Remove ALIGN macro.
(UINT_ARG, INT_ARG): Removed, use ffi_arg and ffi_sarg instead.
* include/ffi_common.h (bool): Do not define.
(ffi_assert): Accept failed assertion.
(ffi_type_test): Return void and accept file/line.
(FFI_ASSERT): Pass stringized failed assertion.
(FFI_ASSERT_AT): New macro.
(FFI_ASSERT_VALID_TYPE): New macro.
(UINT8, SINT8, UINT16, SINT16, UINT32, SINT32,
UINT64, SINT64): Define here with gcc's __attribute__ macro
instead of in ffi.h
(FLOAT32, ALIGN): Define here instead of in ffi.h
* include/ffi-mips.h: Removed. Its content moved to
src/mips/ffitarget.h after separating assembly and C sections.
* src/alpha/ffi.c, src/alpha/ffi.c, src/java_raw_api.c
src/prep_cif.c, src/raw_api.c, src/ia64/ffi.c,
src/mips/ffi.c, src/mips/n32.S, src/mips/o32.S,
src/mips/ffitarget.h, src/sparc/ffi.c, src/x86/ffi64.c:
SIZEOF_ARG -> FFI_SIZEOF_ARG.
* src/ia64/ffi.c: Include stdbool.h (provided by GCC 2.95+).
* src/debug.c (ffi_assert): Accept stringized failed assertion.
(ffi_type_test): Rewritten.
* src/prep-cif.c (initialize_aggregate, ffi_prep_cif): Call
FFI_ASSERT_VALID_TYPE.
* src/alpha/ffitarget.h, src/arm/ffitarget.h,
src/ia64/ffitarget.h, src/m68k/ffitarget.h,
src/mips/ffitarget.h, src/powerpc/ffitarget.h,
src/s390/ffitarget.h, src/sh/ffitarget.h,
src/sh64/ffitarget.h, src/sparc/ffitarget.h,
src/x86/ffitarget.h: New files.
* src/alpha/osf.S, src/arm/sysv.S, src/ia64/unix.S,
src/m68k/sysv.S, src/mips/n32.S, src/mips/o32.S,
src/powerpc/aix.S, src/powerpc/darwin.S,
src/powerpc/ffi_darwin.c, src/powerpc/linux64.S,
src/powerpc/linux64_closure.S, src/powerpc/ppc_closure.S,
src/powerpc/sysv.S, src/s390/sysv.S, src/sh/sysv.S,
src/sh64/sysv.S, src/sparc/v8.S, src/sparc/v9.S,
src/x86/sysv.S, src/x86/unix64.S, src/x86/win32.S:
include fficonfig.h
From-SVN: r72766
2003-10-21 21:01:58 +02:00
|
|
|
|
2004-03-11 20:59:49 +01:00
|
|
|
AC_OUTPUT
|