Allow Python to build on loongson. Bring in some libffi fixes, inspired
by jasper@'s fixes to the libffi port. Mark mips64 (aka, sgi) as BROKEN, as the build fails. We'll look closer at this after unlock. OK jasper@ ports is unlocked for a while only for those who have been informed.
This commit is contained in:
parent
f43f8ed99e
commit
cd7d60e242
@ -1,10 +1,14 @@
|
||||
# $OpenBSD: Makefile,v 1.25 2010/02/09 12:23:59 jasper Exp $
|
||||
# $OpenBSD: Makefile,v 1.26 2010/02/25 11:02:39 phessler Exp $
|
||||
|
||||
VERSION= 2.4
|
||||
PATCHLEVEL= .6
|
||||
PKG_PATCHLEVEL= p2
|
||||
SHARED_LIBS= python2.4 1.0
|
||||
|
||||
.if ${MACHINE_ARCH} == "mips64"
|
||||
BROKEN = Floating point exception while generating pyc objects
|
||||
.endif
|
||||
|
||||
.if ${MACHINE_ARCH} == "alpha" || ${MACHINE_ARCH} == "amd64" || \
|
||||
${MACHINE_ARCH} == "sparc64" || ${MACHINE_ARCH:Mmips64*}
|
||||
PATCH_LIST= patch-* sup64-*
|
||||
|
@ -1,10 +1,14 @@
|
||||
# $OpenBSD: Makefile,v 1.34 2010/02/09 12:23:59 jasper Exp $
|
||||
# $OpenBSD: Makefile,v 1.35 2010/02/25 11:02:39 phessler Exp $
|
||||
|
||||
VERSION= 2.5
|
||||
PATCHLEVEL= .4
|
||||
PKG_PATCHLEVEL= p3
|
||||
SHARED_LIBS= python2.5 1.0
|
||||
|
||||
.if ${MACHINE_ARCH} == "mips64"
|
||||
BROKEN = Floating point exception while generating pyc objects
|
||||
.endif
|
||||
|
||||
.if ${MACHINE_ARCH} == "alpha" || ${MACHINE_ARCH} == "amd64" || \
|
||||
${MACHINE_ARCH} == "sparc64" || ${MACHINE_ARCH:Mmips64*}
|
||||
PATCH_LIST= patch-* sup64-*
|
||||
|
@ -1,4 +1,4 @@
|
||||
$OpenBSD: CHANGES.OpenBSD,v 1.3 2007/06/26 16:50:18 martynas Exp $
|
||||
$OpenBSD: CHANGES.OpenBSD,v 1.4 2010/02/25 11:02:39 phessler Exp $
|
||||
|
||||
As required by item 3 of the PSF license, here is a brief summary
|
||||
of changes made to this version of Python for the OpenBSD package.
|
||||
@ -18,5 +18,8 @@ of changes made to this version of Python for the OpenBSD package.
|
||||
|
||||
5. Regression tests have been taught about OpenBSD.
|
||||
|
||||
6. Support for MIPS64 and MIPS64EL systems has been enabled for the
|
||||
_ctypes Module.
|
||||
|
||||
These changes are available in the OpenBSD CVS repository
|
||||
<http://www.openbsd.org/anoncvs.html> in ports/lang/python.
|
||||
|
@ -1,6 +1,6 @@
|
||||
$OpenBSD: patch-Modules__ctypes_libffi_configure,v 1.1 2009/11/22 22:53:19 jasper Exp $
|
||||
--- Modules/_ctypes/libffi/configure.orig Sun Nov 22 17:36:15 2009
|
||||
+++ Modules/_ctypes/libffi/configure Sun Nov 22 17:36:44 2009
|
||||
$OpenBSD: patch-Modules__ctypes_libffi_configure,v 1.2 2010/02/25 11:02:39 phessler Exp $
|
||||
--- Modules/_ctypes/libffi/configure.orig Wed Sep 5 01:47:16 2007
|
||||
+++ Modules/_ctypes/libffi/configure Sat Feb 20 17:54:36 2010
|
||||
@@ -3471,7 +3471,7 @@ fi
|
||||
TARGETDIR="unknown"
|
||||
case "$host" in
|
||||
|
@ -0,0 +1,20 @@
|
||||
$OpenBSD: patch-Modules__ctypes_libffi_src_mips_ffi_c,v 1.1 2010/02/25 11:02:39 phessler Exp $
|
||||
|
||||
Allow building this on OpenBSD, where we don't provide the ICACHE related
|
||||
defines in cachectl.h, but in sysarch.h
|
||||
|
||||
--- Modules/_ctypes/libffi/src/mips/ffi.c.orig Sat Feb 20 16:32:04 2010
|
||||
+++ Modules/_ctypes/libffi/src/mips/ffi.c Sat Feb 20 16:33:13 2010
|
||||
@@ -27,7 +27,11 @@
|
||||
#include <ffi_common.h>
|
||||
|
||||
#include <stdlib.h>
|
||||
-#include <sys/cachectl.h>
|
||||
+#if defined(__OpenBSD__)
|
||||
+# include <mips64/sysarch.h>
|
||||
+#else
|
||||
+# include <sys/cachectl.h>
|
||||
+#endif
|
||||
|
||||
#if _MIPS_SIM == _ABIN32
|
||||
#define FIX_ARGP \
|
@ -0,0 +1,17 @@
|
||||
$OpenBSD: patch-Modules__ctypes_libffi_src_mips_ffitarget_h,v 1.1 2010/02/25 11:02:39 phessler Exp $
|
||||
|
||||
Allow _ctypes to build on mips64*
|
||||
|
||||
--- Modules/_ctypes/libffi/src/mips/ffitarget.h.orig Thu Mar 9 02:35:32 2006
|
||||
+++ Modules/_ctypes/libffi/src/mips/ffitarget.h Tue Feb 23 21:32:09 2010
|
||||
@@ -158,8 +158,8 @@ typedef enum ffi_abi {
|
||||
#define FFI_CLOSURES 1
|
||||
#define FFI_TRAMPOLINE_SIZE 20
|
||||
#else
|
||||
-/* N32/N64 not implemented yet. */
|
||||
-#define FFI_CLOSURES 0
|
||||
+#define FFI_CLOSURES 1
|
||||
+#define FFI_TRAMPOLINE_SIZE 52
|
||||
#endif /* FFI_MIPS_O32 */
|
||||
#define FFI_NATIVE_RAW_API 0
|
||||
|
@ -1,4 +1,4 @@
|
||||
# $OpenBSD: Makefile,v 1.12 2010/02/09 12:23:59 jasper Exp $
|
||||
# $OpenBSD: Makefile,v 1.13 2010/02/25 11:02:39 phessler Exp $
|
||||
|
||||
VERSION= 2.6
|
||||
PATCHLEVEL= .3
|
||||
@ -7,6 +7,10 @@ SHARED_LIBS= python2.6 1.0
|
||||
|
||||
# PSUBDIR= python/${VERSION}
|
||||
|
||||
.if ${MACHINE_ARCH} == "mips64"
|
||||
BROKEN = Floating point exception while generating pyc objects
|
||||
.endif
|
||||
|
||||
.if ${MACHINE_ARCH} == "alpha" || ${MACHINE_ARCH} == "amd64" || \
|
||||
${MACHINE_ARCH} == "sparc64" || ${MACHINE_ARCH:Mmips64*}
|
||||
PATCH_LIST= patch-* sup64-*
|
||||
|
@ -1,4 +1,4 @@
|
||||
$OpenBSD: CHANGES.OpenBSD,v 1.1 2008/10/18 12:03:56 djm Exp $
|
||||
$OpenBSD: CHANGES.OpenBSD,v 1.2 2010/02/25 11:02:39 phessler Exp $
|
||||
|
||||
As required by item 3 of the PSF license, here is a brief summary
|
||||
of changes made to this version of Python for the OpenBSD package.
|
||||
@ -14,5 +14,8 @@ of changes made to this version of Python for the OpenBSD package.
|
||||
|
||||
4. Regression tests have been taught about OpenBSD.
|
||||
|
||||
5. Support for MIPS64 and MIPS64EL systems has been enabled for the
|
||||
_ctypes Module.
|
||||
|
||||
These changes are available in the OpenBSD CVS repository
|
||||
<http://www.openbsd.org/anoncvs.html> in ports/lang/python.
|
||||
|
@ -0,0 +1,12 @@
|
||||
$OpenBSD: patch-Modules__ctypes_libffi_configure,v 1.1 2010/02/25 11:02:39 phessler Exp $
|
||||
--- Modules/_ctypes/libffi/configure.orig Tue Feb 23 20:11:01 2010
|
||||
+++ Modules/_ctypes/libffi/configure Tue Feb 23 20:12:15 2010
|
||||
@@ -20428,7 +20428,7 @@ case "$host" in
|
||||
mips-sgi-irix5.* | mips-sgi-irix6.*)
|
||||
TARGET=MIPS_IRIX; TARGETDIR=mips
|
||||
;;
|
||||
- mips*-*-linux*)
|
||||
+ mips*-*-linux* | mips*-*-openbsd*)
|
||||
TARGET=MIPS_LINUX; TARGETDIR=mips
|
||||
;;
|
||||
|
@ -0,0 +1,20 @@
|
||||
$OpenBSD: patch-Modules__ctypes_libffi_src_mips_ffi_c,v 1.1 2010/02/25 11:02:39 phessler Exp $
|
||||
|
||||
Allow building this on OpenBSD, where we don't provide the ICACHE related
|
||||
defines in cachectl.h, but in sysarch.h
|
||||
|
||||
--- Modules/_ctypes/libffi/src/mips/ffi.c.orig Tue Feb 23 20:12:37 2010
|
||||
+++ Modules/_ctypes/libffi/src/mips/ffi.c Tue Feb 23 20:13:38 2010
|
||||
@@ -37,7 +37,11 @@
|
||||
#endif
|
||||
|
||||
#ifndef USE__BUILTIN___CLEAR_CACHE
|
||||
-#include <sys/cachectl.h>
|
||||
+#if defined(__OpenBSD__)
|
||||
+# include <mips64/sysarch.h>
|
||||
+#else
|
||||
+# include <sys/cachectl.h>
|
||||
+#endif
|
||||
#endif
|
||||
|
||||
#ifdef FFI_DEBUG
|
@ -1,4 +1,4 @@
|
||||
# $OpenBSD: Makefile.inc,v 1.63 2010/02/09 12:23:59 jasper Exp $
|
||||
# $OpenBSD: Makefile.inc,v 1.64 2010/02/25 11:02:39 phessler 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
|
||||
@ -71,7 +71,7 @@ FULLPKGNAME-tests= python-tests-${VERSION}${PATCHLEVEL}${PKG_PATCHLEVEL}
|
||||
FULLPKGNAME-tkinter= python-tkinter-${VERSION}${PATCHLEVEL}${PKG_PATCHLEVEL}
|
||||
FULLPKGNAME-tools= python-tools-${VERSION}${PATCHLEVEL}${PKG_PATCHLEVEL}
|
||||
|
||||
.if ${MACHINE_ARCH} == "alpha" || ${MACHINE_ARCH} == "amd64" || ${MACHINE_ARCH} == "sparc64"
|
||||
.if ${MACHINE_ARCH} == "alpha" || ${MACHINE_ARCH} == "amd64" || ${MACHINE_ARCH} == "sparc64" || ${MACHINE_ARCH:Mmips64*}
|
||||
PKG_ARGS+= -Dmm=0
|
||||
.else
|
||||
PKG_ARGS+= -Dmm=1
|
||||
|
Loading…
Reference in New Issue
Block a user