From 3756dd06265d3aca3a9acc6cf9feedee87722f27 Mon Sep 17 00:00:00 2001 From: rpointel Date: Wed, 29 Jun 2011 11:58:31 +0000 Subject: [PATCH] Use devel/libffi and not libffi embedded in Python. ok landry@ jasper@. --- lang/python3/3.2/Makefile | 4 +--- .../patch-Modules__ctypes_libffi_configure | 12 ----------- ...atch-Modules__ctypes_libffi_src_mips_ffi_c | 16 --------------- ...odules__ctypes_libffi_src_mips_ffitarget_h | 20 ------------------- lang/python3/Makefile.inc | 11 ++++++---- 5 files changed, 8 insertions(+), 55 deletions(-) delete mode 100644 lang/python3/3.2/patches/patch-Modules__ctypes_libffi_configure delete mode 100644 lang/python3/3.2/patches/patch-Modules__ctypes_libffi_src_mips_ffi_c delete mode 100644 lang/python3/3.2/patches/patch-Modules__ctypes_libffi_src_mips_ffitarget_h diff --git a/lang/python3/3.2/Makefile b/lang/python3/3.2/Makefile index fdf607916c0..b4df3728102 100644 --- a/lang/python3/3.2/Makefile +++ b/lang/python3/3.2/Makefile @@ -1,11 +1,9 @@ -# $OpenBSD: Makefile,v 1.1.1.1 2011/06/27 18:44:13 rpointel Exp $ +# $OpenBSD: Makefile,v 1.2 2011/06/29 11:58:31 rpointel Exp $ VERSION = 3.2 #PATCHLEVEL = .1 SHARED_LIBS = python3.2m 1.0 AUTOCONF_VERSION = 2.68 -CONFIGURE_ARGS += --with-cxx_main \ - --with-system-expat .include diff --git a/lang/python3/3.2/patches/patch-Modules__ctypes_libffi_configure b/lang/python3/3.2/patches/patch-Modules__ctypes_libffi_configure deleted file mode 100644 index 0dbd3d42902..00000000000 --- a/lang/python3/3.2/patches/patch-Modules__ctypes_libffi_configure +++ /dev/null @@ -1,12 +0,0 @@ -$OpenBSD: patch-Modules__ctypes_libffi_configure,v 1.1.1.1 2011/06/27 18:44:13 rpointel Exp $ ---- Modules/_ctypes/libffi/configure.orig Wed Jun 22 14:24:16 2011 -+++ Modules/_ctypes/libffi/configure Wed Jun 22 14:24:29 2011 -@@ -11254,7 +11254,7 @@ case "$host" in - mips-sgi-irix5.* | mips-sgi-irix6.*) - TARGET=MIPS_IRIX; TARGETDIR=mips - ;; -- mips*-*-linux*) -+ mips*-*-linux* | mips*-*-openbsd*) - # Support 128-bit long double for NewABI. - HAVE_LONG_DOUBLE='defined(__mips64)' - TARGET=MIPS_IRIX; TARGETDIR=mips diff --git a/lang/python3/3.2/patches/patch-Modules__ctypes_libffi_src_mips_ffi_c b/lang/python3/3.2/patches/patch-Modules__ctypes_libffi_src_mips_ffi_c deleted file mode 100644 index f70c727f0e2..00000000000 --- a/lang/python3/3.2/patches/patch-Modules__ctypes_libffi_src_mips_ffi_c +++ /dev/null @@ -1,16 +0,0 @@ -$OpenBSD: patch-Modules__ctypes_libffi_src_mips_ffi_c,v 1.1.1.1 2011/06/27 18:44:13 rpointel Exp $ ---- Modules/_ctypes/libffi/src/mips/ffi.c.orig Wed Jun 22 14:24:39 2011 -+++ Modules/_ctypes/libffi/src/mips/ffi.c Wed Jun 22 14:24:58 2011 -@@ -37,7 +37,11 @@ - #endif - - #ifndef USE__BUILTIN___CLEAR_CACHE --#include -+#if defined(__OpenBSD__) -+# include -+#else -+# include -+#endif - #endif - - #ifdef FFI_DEBUG diff --git a/lang/python3/3.2/patches/patch-Modules__ctypes_libffi_src_mips_ffitarget_h b/lang/python3/3.2/patches/patch-Modules__ctypes_libffi_src_mips_ffitarget_h deleted file mode 100644 index 592fc7214cb..00000000000 --- a/lang/python3/3.2/patches/patch-Modules__ctypes_libffi_src_mips_ffitarget_h +++ /dev/null @@ -1,20 +0,0 @@ -$OpenBSD: patch-Modules__ctypes_libffi_src_mips_ffitarget_h,v 1.1.1.1 2011/06/27 18:44:13 rpointel Exp $ ---- Modules/_ctypes/libffi/src/mips/ffitarget.h.orig Wed Jun 22 14:25:11 2011 -+++ Modules/_ctypes/libffi/src/mips/ffitarget.h Wed Jun 22 14:25:27 2011 -@@ -27,10 +27,12 @@ - #ifndef LIBFFI_TARGET_H - #define LIBFFI_TARGET_H - --#ifdef linux --# include --#else --# include -+#if !defined(__OpenBSD__) -+# ifdef linux -+# include -+# else -+# include -+# endif - #endif - # ifndef _ABIN32 - # define _ABIN32 _MIPS_SIM_NABI32 diff --git a/lang/python3/Makefile.inc b/lang/python3/Makefile.inc index 59c394f78a0..1813a868e17 100644 --- a/lang/python3/Makefile.inc +++ b/lang/python3/Makefile.inc @@ -1,4 +1,4 @@ -# $OpenBSD: Makefile.inc,v 1.1.1.1 2011/06/27 18:44:13 rpointel Exp $ +# $OpenBSD: Makefile.inc,v 1.2 2011/06/29 11:58:31 rpointel Exp $ # IMPORTANT! If you make any changes to the Python ports, be sure # to also update files/CHANGES.OpenBSD for your change. This is a @@ -57,9 +57,10 @@ LIB_DEPENDS= LIB_DEPENDS-main = archivers/bzip2 RUN_DEPENDS-main = WANTLIB-main = ssl panelw m crypto c util z readline pthread \ - ncursesw stdc++ expat bz2 + ncursesw stdc++ expat bz2 ffi #.if ${VERSION} == "2.5" || ${VERSION} == "2.6" || ${VERSION} == "2.7" -LIB_DEPENDS-main += databases/sqlite3 +LIB_DEPENDS-main += databases/sqlite3 \ + devel/libffi WANTLIB-main += sqlite3 #.endif @@ -104,7 +105,8 @@ CONFIGURE_STYLE= autoconf CONFIGURE_ARGS+= ${CONFIGURE_SHARED} # --srcdir is needed for systrace to work correctly CONFIGURE_ARGS+= --with-fpectl --with-threads --srcdir=${WRKSRC} -CONFIGURE_ARGS+= --enable-ipv6 +CONFIGURE_ARGS+= --enable-ipv6 --with-cxx_main +CONFIGURE_ARGS+= --with-system-ffi --with-system-expat # THREAD_STACK_SIZE value might be changed by particular python release THREAD_STACK_SIZE?=0x20000 @@ -123,6 +125,7 @@ ALL_TARGET?= everything ./Lib/plat-openbsd4 post-extract: rm -r ${WRKDIST}/Modules/expat + rm -r ${WRKDIST}/Modules/_ctypes/libffi post-configure: @cd ${WRKSRC} && ${MAKE_PROGRAM} Makefile