pkgsrc-Bugs archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

pkg/28373: several problems compiling lang/python23 on IRIX 5.3



>Number:         28373
>Category:       pkg
>Synopsis:       several problems compiling lang/python23 on IRIX 5.3
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    pkg-manager
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Sun Nov 21 02:37:00 +0000 2004
>Originator:     Georg Schwarz
>Release:        current pkgsrc
>Organization:
>Environment:
IRIX lorenz 5.3 08031225 IP20 mips
>Description:
There are several issues with compiling on23 on IRIX 5.3:

- Python 2.3.4 bug ID #1070140: endianness not detected correctly (seems to be 
fixed with python2.4)
- corresponding issue to pkg/26507
- On IRIX 5.3 /usr/include/sys/types.h contains:

#if ( !defined(_XOPEN_SOURCE) && !defined(_POSIX_SOURCE) ) ||
defined(_BSD_TYPES) || defined(_BSD_COMPAT)
/*
 * Nested include for BSD/sockets source compatibility.
 * (The select macros used to be defined here).
 */
#include <sys/bsd_types.h>
#endif

sys/bsd_types.h however defines u_int.
If _XOPEN_SOURCE is defined (in pyconfig.h) this results in u_int not
being known and the compilation to fail.  

>How-To-Repeat:

>Fix:
The first two issues are fixed by the following patch:

--- Makefile.common.orig        Sat Nov 20 21:00:28 2004
+++ Makefile.common     Sat Nov 20 21:32:28 2004
@@ -29,8 +29,10 @@
 .endif
 PLIST_SRC+=    ${.CURDIR}/../../lang/python23/PLIST.common_end
 
-.if ${OPSYS} == "Darwin" || ${OPSYS} == "Interix" || ${OPSYS} == "IRIX"
+.if ${OPSYS} == "Darwin" || ${OPSYS} == "Interix"
 PY_PLATNAME=   ${LOWER_OPSYS}
+.elif ${OPSYS} == "IRIX"
+PY_PLATNAME=   ${LOWER_OPSYS:C/\..*//}
 .elif ${OPSYS} == "SunOS"
 PY_PLATNAME=   sunos${OS_VERSION:C/\..*//}
 .else
@@ -37,6 +39,11 @@
 PY_PLATNAME=   ${LOWER_OPSYS}${OS_VERSION:C/\..*//}
 .endif
 PLIST_SUBST+=  PY_PLATNAME=${PY_PLATNAME}
+
+# work around missing sys/endian.h support for IRIX 5.3
+.if ${MACHINE_ARCH} == "mipseb"
+CONFIGURE_ENV+=        ac_cv_c_bigendian="yes"
+.endif
 
 # the dl module isn't built for 64 bit archs and Darwin
 .if ${MACHINE_ARCH} == "alpha" || ${MACHINE_ARCH} == "amd64" \


The third issue is solved by patching configure as follows:

--- configure.orig      2004-08-08 00:18:33.000000000 +0200
+++ configure   2004-08-08 00:18:59.000000000 +0200
@@ -1466,6 +1466,8 @@
   # has another value. By not (re)defining it, the defaults come in
place.
   AIX/4)
     define_xopen_source=no;;
+  IRIX/5.*)
+    define_xopen_source=no;;
 esac
 
 if test $define_xopen_source = yes




Home | Main Index | Thread Index | Old Index