[Python-checkins] r45735 - in python/trunk: Misc/NEWS Modules/_ctypes/libffi/configure Modules/_ctypes/libffi/configure.ac Modules/_ctypes/libffi/fficonfig.py.in
hyeshik.chang
python-checkins at python.org
Wed Apr 26 21:20:27 CEST 2006
Author: hyeshik.chang
Date: Wed Apr 26 21:20:26 2006
New Revision: 45735
Modified:
python/trunk/Misc/NEWS
python/trunk/Modules/_ctypes/libffi/configure
python/trunk/Modules/_ctypes/libffi/configure.ac
python/trunk/Modules/_ctypes/libffi/fficonfig.py.in
Log:
Fix build on MIPS for libffi. I haven't tested this yet because I
don't have an access on MIPS machines. Will be tested by buildbot. :)
Modified: python/trunk/Misc/NEWS
==============================================================================
--- python/trunk/Misc/NEWS (original)
+++ python/trunk/Misc/NEWS Wed Apr 26 21:20:26 2006
@@ -156,6 +156,8 @@
- Patch #1429775: Link extension modules with the shared libpython.
+- Fixed a libffi build problem on MIPS systems.
+
C API
-----
Modified: python/trunk/Modules/_ctypes/libffi/configure
==============================================================================
--- python/trunk/Modules/_ctypes/libffi/configure (original)
+++ python/trunk/Modules/_ctypes/libffi/configure Wed Apr 26 21:20:26 2006
@@ -310,7 +310,7 @@
# include <unistd.h>
#endif"
-ac_subst_vars='SHELL PATH_SEPARATOR PACKAGE_NAME PACKAGE_TARNAME PACKAGE_VERSION PACKAGE_STRING PACKAGE_BUGREPORT exec_prefix prefix program_transform_name bindir sbindir libexecdir datadir sysconfdir sharedstatedir localstatedir libdir includedir oldincludedir infodir mandir build_alias host_alias target_alias DEFS ECHO_C ECHO_N ECHO_T LIBS build build_cpu build_vendor build_os host host_cpu host_vendor host_os target target_cpu target_vendor target_os CC ac_ct_CC EXEEXT OBJEXT CFLAGS CPP CPPFLAGS EGREP ALLOCA HAVE_LONG_DOUBLE TARGET TARGETDIR LIBOBJS LTLIBOBJS'
+ac_subst_vars='SHELL PATH_SEPARATOR PACKAGE_NAME PACKAGE_TARNAME PACKAGE_VERSION PACKAGE_STRING PACKAGE_BUGREPORT exec_prefix prefix program_transform_name bindir sbindir libexecdir datadir sysconfdir sharedstatedir localstatedir libdir includedir oldincludedir infodir mandir build_alias host_alias target_alias DEFS ECHO_C ECHO_N ECHO_T LIBS build build_cpu build_vendor build_os host host_cpu host_vendor host_os target target_cpu target_vendor target_os CC ac_ct_CC EXEEXT OBJEXT CFLAGS CPP CPPFLAGS EGREP ALLOCA HAVE_LONG_DOUBLE TARGET TARGETDIR MKTARGET LIBOBJS LTLIBOBJS'
ac_subst_files=''
# Initialize some variables set by options.
@@ -3534,6 +3534,8 @@
{ (exit 1); exit 1; }; }
fi
+MKTARGET=$TARGET
+
case x$TARGET in
xMIPS*) TARGET=MIPS ;;
*) ;;
@@ -5457,6 +5459,7 @@
+
cat >>confdefs.h <<\_ACEOF
#define FFI_NO_RAW_API 1
_ACEOF
@@ -6129,6 +6132,7 @@
s, at HAVE_LONG_DOUBLE@,$HAVE_LONG_DOUBLE,;t t
s, at TARGET@,$TARGET,;t t
s, at TARGETDIR@,$TARGETDIR,;t t
+s, at MKTARGET@,$MKTARGET,;t t
s, at LIBOBJS@,$LIBOBJS,;t t
s, at LTLIBOBJS@,$LTLIBOBJS,;t t
CEOF
Modified: python/trunk/Modules/_ctypes/libffi/configure.ac
==============================================================================
--- python/trunk/Modules/_ctypes/libffi/configure.ac (original)
+++ python/trunk/Modules/_ctypes/libffi/configure.ac Wed Apr 26 21:20:26 2006
@@ -70,6 +70,12 @@
AC_MSG_ERROR(["libffi has not been ported to $host."])
fi
+dnl libffi changes TARGET for MIPS to define a such macro in the header
+dnl while MIPS_IRIX or MIPS_LINUX is separatedly used to decide which
+dnl files will be compiled. So, we need to keep the original decision
+dnl of TARGET to use in fficonfig.py.in.
+MKTARGET=$TARGET
+
case x$TARGET in
xMIPS*) TARGET=MIPS ;;
*) ;;
@@ -183,6 +189,7 @@
AC_SUBST(TARGET)
AC_SUBST(TARGETDIR)
+AC_SUBST(MKTARGET)
AC_SUBST(SHELL)
Modified: python/trunk/Modules/_ctypes/libffi/fficonfig.py.in
==============================================================================
--- python/trunk/Modules/_ctypes/libffi/fficonfig.py.in (original)
+++ python/trunk/Modules/_ctypes/libffi/fficonfig.py.in Wed Apr 26 21:20:26 2006
@@ -27,7 +27,7 @@
}
ffi_srcdir = '@srcdir@'
-ffi_sources += ffi_platforms['@TARGET@']
+ffi_sources += ffi_platforms['@MKTARGET@']
ffi_sources = [os.path.join('@srcdir@', f) for f in ffi_sources]
ffi_cflags = '@CFLAGS@'
More information about the Python-checkins
mailing list