Python dont find system-libffi, build with internal libffi, patch Pythons libffi to build with uClibc-master

This commit is contained in:
Stephan Raue 2009-08-03 00:12:35 +02:00
parent eafd8f7ebc
commit f07510bf00
2 changed files with 27 additions and 2 deletions

View File

@ -6,7 +6,7 @@ $SCRIPTS/build toolchain
$SCRIPTS/build sqlite
$SCRIPTS/build openssl
$SCRIPTS/build zlib
$SCRIPTS/build libffi
#$SCRIPTS/build libffi
PY_DISABLED_MODULES="readline _curses _curses_panel _tkinter nis gdbm bsddb _codecs_kr _codecs_jp _codecs_cn _codecs_tw _codecs_hk"
PY_BUILD_DIR=`ls -d $ROOT/$PKG_BUILD`
@ -59,7 +59,7 @@ OPT="$TARGET_CFLAGS -fno-strict-aliasing" \
--without-fpectl \
--without-wctype-functions \
--without-cxx-main \
--with-system-ffi \
# --with-system-ffi \
make CC=$TARGET_CC \
GNU_HOST=$TARGET_NAME \

View File

@ -0,0 +1,25 @@
diff -Naur Python-2.6.2/Modules/_ctypes/libffi/include/ffi.h.in Python-2.6.2.patch/Modules/_ctypes/libffi/include/ffi.h.in
--- Python-2.6.2/Modules/_ctypes/libffi/include/ffi.h.in 2008-04-04 18:01:54.000000000 +0200
+++ Python-2.6.2.patch/Modules/_ctypes/libffi/include/ffi.h.in 2009-08-01 23:31:01.102336818 +0200
@@ -70,19 +70,8 @@
#include <stddef.h>
#include <limits.h>
-/* LONG_LONG_MAX is not always defined (not if STRICT_ANSI, for example).
- But we can find it either under the correct ANSI name, or under GNU
- C's internal name. */
-#ifdef LONG_LONG_MAX
-# define FFI_LONG_LONG_MAX LONG_LONG_MAX
-#else
-# ifdef LLONG_MAX
-# define FFI_LONG_LONG_MAX LLONG_MAX
-# else
-# ifdef __GNUC__
-# define FFI_LONG_LONG_MAX __LONG_LONG_MAX__
-# endif
-# endif
+#if defined __USE_ISOC99 && defined __GNUC__
+# define FFI_LONG_LONG_MAX __LONG_LONG_MAX__
#endif
/* The closure code assumes that this works on pointers, i.e. a size_t */