Rev 11996: Remove some more cruft. in file:///home/jelmer/bzr.samba/python/

Jelmer Vernooij jelmer at samba.org
Mon Apr 23 22:48:55 GMT 2007


At file:///home/jelmer/bzr.samba/python/

------------------------------------------------------------
revno: 11996
revision-id: jelmer at samba.org-20070423224827-r2ol1o27vwplxbj1
parent: jelmer at samba.org-20070423204721-oazsviba59vu2tpu
committer: Jelmer Vernooij <jelmer at samba.org>
branch nick: python
timestamp: Tue 2007-04-24 00:48:27 +0200
message:
  Remove some more cruft.
modified:
  source/lib/python/config.m4    configure.in-20070423105804-3mrp9flhlt8pjj8v-11
  source/lib/python/config.mk    makefile.pre.in-20070423105804-3mrp9flhlt8pjj8v-5
=== modified file 'source/lib/python/config.m4'
--- a/source/lib/python/config.m4	2007-04-23 20:38:05 +0000
+++ b/source/lib/python/config.m4	2007-04-23 22:48:27 +0000
@@ -31,464 +31,6 @@
 # them.
 AC_DEFINE(__BSD_VISIBLE, 1, [Define on FreeBSD to activate all library features])
 
-# The later defininition of _XOPEN_SOURCE and _POSIX_C_SOURCE disables
-# u_int on Irix 5.3. Defining _BSD_TYPES brings it back.
-AC_DEFINE(_BSD_TYPES, 1, [Define on Irix to enable u_int])
-
-define_xopen_source=yes
-
-# Some systems cannot stand _XOPEN_SOURCE being defined at all; they
-# disable features if it is defined, without any means to access these
-# features as extensions. For these systems, we skip the definition of
-# _XOPEN_SOURCE. Before adding a system to the list to gain access to
-# some feature, make sure there is no alternative way to access this
-# feature. Also, when using wildcards, make sure you have verified the
-# need for not defining _XOPEN_SOURCE on all systems matching the
-# wildcard, and that the wildcard does not include future systems
-# (which may remove their limitations).
-dnl quadrigraphs "@<:@" and "@:>@" produce "[" and "]" in the output
-case $ac_sys_system/$ac_sys_release in
-  # On OpenBSD, select(2) is not available if _XOPEN_SOURCE is defined,
-  # even though select is a POSIX function. Reported by J. Ribbens.
-  # Reconfirmed for OpenBSD 3.3 by Zachary Hamm, for 3.4 by Jason Ish.
-  OpenBSD/2.* | OpenBSD/3.@<:@0123456789@:>@ | OpenBSD/4.@<:@0@:>@) 
-    define_xopen_source=no;;
-  # Defining _XOPEN_SOURCE on NetBSD version prior to the introduction of
-  # _NETBSD_SOURCE disables certain features (eg. setgroups). Reported by
-  # Marc Recht
-  NetBSD/1.5 | NetBSD/1.5.* | NetBSD/1.6 | NetBSD/1.6.* | NetBSD/1.6[A-S])
-    define_xopen_source=no;;
-  # On Solaris 2.6, sys/wait.h is inconsistent in the usage
-  # of union __?sigval. Reported by Stuart Bishop.
-  SunOS/5.6)
-    define_xopen_source=no;;
-  # On UnixWare 7, u_long is never defined with _XOPEN_SOURCE,
-  # but used in /usr/include/netinet/tcp.h. Reported by Tim Rice.
-  # Reconfirmed for 7.1.4 by Martin v. Loewis.
-  OpenUNIX/8.0.0| UnixWare/7.1.@<:@0-4@:>@)
-    define_xopen_source=no;;
-  # On OpenServer 5, u_short is never defined with _XOPEN_SOURCE,
-  # but used in struct sockaddr.sa_family. Reported by Tim Rice.
-  SCO_SV/3.2)
-    define_xopen_source=no;;
-  # On FreeBSD 4.8 and MacOS X 10.2, a bug in ncurses.h means that
-  # it craps out if _XOPEN_EXTENDED_SOURCE is defined. Apparently,
-  # this is fixed in 10.3, which identifies itself as Darwin/7.*
-  # This should hopefully be fixed in FreeBSD 4.9
-  FreeBSD/4.8* | Darwin/6* )
-    define_xopen_source=no;;
-  # On AIX 4 and 5.1, mbstate_t is defined only when _XOPEN_SOURCE == 500 but
-  # used in wcsnrtombs() and mbsnrtowcs() even if _XOPEN_SOURCE is not defined
-  # or has another value. By not (re)defining it, the defaults come in place.
-  AIX/4)
-    define_xopen_source=no;;
-  AIX/5)
-    if test `uname -r` -eq 1; then
-      define_xopen_source=no
-    fi
-    ;;
-  # On Mac OS X 10.4, defining _POSIX_C_SOURCE or _XOPEN_SOURCE
-  # disables platform specific features beyond repair.
-  # On Mac OS X 10.3, defining _POSIX_C_SOURCE or _XOPEN_SOURCE 
-  # has no effect, don't bother defining them
-  Darwin/@<:@789@:>@.*)
-    define_xopen_source=no
-    ;;
-
-esac
-
-if test $define_xopen_source = yes
-then
-  # On Solaris w/ g++ it appears that _XOPEN_SOURCE has to be
-  # defined precisely as g++ defines it
-  # Furthermore, on Solaris 10, XPG6 requires the use of a C99
-  # compiler
-  case $ac_sys_system/$ac_sys_release in
-    SunOS/5.8|SunOS/5.9|SunOS/5.10)
-      AC_DEFINE(_XOPEN_SOURCE, 500, 
-                Define to the level of X/Open that your system supports)
-      ;;
-    *)
-      AC_DEFINE(_XOPEN_SOURCE, 600, 
-                Define to the level of X/Open that your system supports)
-      ;;
-  esac
-
-  # On Tru64 Unix 4.0F, defining _XOPEN_SOURCE also requires
-  # definition of _XOPEN_SOURCE_EXTENDED and _POSIX_C_SOURCE, or else
-  # several APIs are not declared. Since this is also needed in some
-  # cases for HP-UX, we define it globally.
-  # except for Solaris 10, where it must not be defined, 
-  # as it implies XPG4.2
-  case $ac_sys_system/$ac_sys_release in
-    SunOS/5.10)
-      ;;
-    *)
-      AC_DEFINE(_XOPEN_SOURCE_EXTENDED, 1,
-      		Define to activate Unix95-and-earlier features)
-      ;;
-  esac
-
-  AC_DEFINE(_POSIX_C_SOURCE, 200112L, Define to activate features from IEEE Stds 1003.1-2001)
-  
-fi
-
-#
-# SGI compilers allow the specification of the both the ABI and the
-# ISA on the command line.  Depending on the values of these switches,
-# different and often incompatable code will be generated.
-#
-# The SGI_ABI variable can be used to modify the CC and LDFLAGS and
-# thus supply support for various ABI/ISA combinations.  The MACHDEP
-# variable is also adjusted.
-#
-AC_SUBST(SGI_ABI)
-if test ! -z "$SGI_ABI"
-then
-        CC="cc $SGI_ABI"
-        LDFLAGS="$SGI_ABI $LDFLAGS"
-        MACHDEP=`echo "${MACHDEP}${SGI_ABI}" | sed 's/ *//g'`
-fi
-AC_MSG_RESULT($MACHDEP)
-
-# And add extra plat-mac for darwin
-AC_SUBST(EXTRAPLATDIR)
-AC_SUBST(EXTRAMACHDEPPATH)
-AC_MSG_CHECKING(EXTRAPLATDIR)
-if test -z "$EXTRAPLATDIR"
-then
-	case $MACHDEP in
-	darwin)	
-		EXTRAPLATDIR="\$(PLATMACDIRS)"
-		EXTRAMACHDEPPATH="\$(PLATMACPATH)"
-		;;
-	*) 
-		EXTRAPLATDIR=""
-		EXTRAMACHDEPPATH=""
-		;;
-	esac
-fi
-AC_MSG_RESULT($EXTRAPLATDIR)
-
-# Record the configure-time value of MACOSX_DEPLOYMENT_TARGET,
-# it may influence the way we can build extensions, so distutils
-# needs to check it
-AC_SUBST(CONFIGURE_MACOSX_DEPLOYMENT_TARGET)
-AC_SUBST(EXPORT_MACOSX_DEPLOYMENT_TARGET)
-CONFIGURE_MACOSX_DEPLOYMENT_TARGET=
-EXPORT_MACOSX_DEPLOYMENT_TARGET='#'
-
-# Check for unsupported systems
-case $ac_sys_system/$ac_sys_release in
-Linux*/1*)
-   echo This system \($ac_sys_system/$ac_sys_release\) is no longer supported.
-   echo See README for details.
-   exit 1;;
-esac
-
-case $MACHDEP in
-bsdos*)
-    case $CC in
-    gcc) CC="$CC -D_HAVE_BSDI";;
-    esac;;
-esac
-
-case $ac_sys_system in
-hp*|HP*)
-    case $CC in
-    cc|*/cc) CC="$CC -Ae";;
-    esac;;
-Monterey*)
-    case $CC in
-    cc) CC="$CC -Wl,-Bexport";;
-    esac;;
-SunOS*)
-    # Some functions have a prototype only with that define, e.g. confstr
-    AC_DEFINE(__EXTENSIONS__, 1, [Defined on Solaris to see additional function prototypes.])
-    ;;
-esac
-
-
-# LDLIBRARY is the name of the library to link against (as opposed to the
-# name of the library into which to insert object files). BLDLIBRARY is also
-# the library to link against, usually. On Mac OS X frameworks, BLDLIBRARY
-# is blank as the main program is not linked directly against LDLIBRARY.
-# LDLIBRARYDIR is the path to LDLIBRARY, which is made in a subdirectory. On
-# systems without shared libraries, LDLIBRARY is the same as LIBRARY
-# (defined in the Makefiles). On Cygwin LDLIBRARY is the import library,
-# DLLLIBRARY is the shared (i.e., DLL) library.
-# 
-# RUNSHARED is used to run shared python without installed libraries
-#
-# INSTSONAME is the name of the shared library that will be use to install
-# on the system - some systems like version suffix, others don't
-AC_SUBST(LDLIBRARY)
-AC_SUBST(DLLLIBRARY)
-AC_SUBST(BLDLIBRARY)
-AC_SUBST(LDLIBRARYDIR)
-AC_SUBST(INSTSONAME)
-AC_SUBST(RUNSHARED)
-LDLIBRARY="$LIBRARY"
-BLDLIBRARY='$(LDLIBRARY)'
-INSTSONAME='$(LDLIBRARY)'
-DLLLIBRARY=''
-LDLIBRARYDIR=''
-RUNSHARED=''
-
-AC_MSG_CHECKING(LDLIBRARY)
-
-# Other platforms follow
-if test $enable_shared = "yes"; then
-  AC_DEFINE(Py_ENABLE_SHARED, 1, [Defined if Python is built as a shared library.])
-  case $ac_sys_system in
-    BeOS*)
-          LDLIBRARY='libpython$(VERSION).so'
-          ;;
-    CYGWIN*)
-          LDLIBRARY='libpython$(VERSION).dll.a'
-          DLLLIBRARY='libpython$(VERSION).dll'
-          ;;
-    SunOS*)
-	  LDLIBRARY='libpython$(VERSION).so'
-	  BLDLIBRARY='-Wl,-R,$(LIBDIR) -L. -lpython$(VERSION)'
-	  RUNSHARED=LD_LIBRARY_PATH=`pwd`:${LD_LIBRARY_PATH}
-	  INSTSONAME="$LDLIBRARY".$SOVERSION
-          ;;
-    Linux*|GNU*|NetBSD*|FreeBSD*|DragonFly*)
-	  LDLIBRARY='libpython$(VERSION).so'
-	  BLDLIBRARY='-L. -lpython$(VERSION)'
-	  RUNSHARED=LD_LIBRARY_PATH=`pwd`:${LD_LIBRARY_PATH}
-	  case $ac_sys_system in
-	      FreeBSD*)
-		SOVERSION=`echo $SOVERSION|cut -d "." -f 1`
-		;;
-	  esac
-	  INSTSONAME="$LDLIBRARY".$SOVERSION
-	  ;;
-    hp*|HP*)
-	  case `uname -m` in
-		ia64)
-			LDLIBRARY='libpython$(VERSION).so'
-			;;
-		*)
-			LDLIBRARY='libpython$(VERSION).sl'
-			;;
-	  esac
-	  BLDLIBRARY='-Wl,+b,$(LIBDIR) -L. -lpython$(VERSION)'
-	  RUNSHARED=SHLIB_PATH=`pwd`:${SHLIB_PATH}
-	  ;;
-    OSF*)
-	  LDLIBRARY='libpython$(VERSION).so'
-	  BLDLIBRARY='-rpath $(LIBDIR) -L. -lpython$(VERSION)'
-	  RUNSHARED=LD_LIBRARY_PATH=`pwd`:${LD_LIBRARY_PATH}
-	  ;;
-    atheos*)
-	  LDLIBRARY='libpython$(VERSION).so'
-	  BLDLIBRARY='-L. -lpython$(VERSION)'
-	  RUNSHARED=DLL_PATH=`pwd`:${DLL_PATH:-/atheos/sys/libs:/atheos/autolnk/lib}
-	  ;;
-  esac
-else # shared is disabled
-  case $ac_sys_system in
-    CYGWIN*)
-          BLDLIBRARY='$(LIBRARY)'
-          LDLIBRARY='libpython$(VERSION).dll.a'
-          ;;
-  esac
-fi
-
-AC_MSG_RESULT($LDLIBRARY)
-
-AC_PROG_RANLIB
-AC_SUBST(AR)
-AC_CHECK_PROGS(AR, ar aal, ar)
-
-case $MACHDEP in
-bsdos*|hp*|HP*)
-	# install -d does not work on BSDI or HP-UX
-	if test -z "$INSTALL"
-	then
-		INSTALL="${srcdir}/install-sh -c"
-	fi
-esac
-AC_PROG_INSTALL
-
-# Not every filesystem supports hard links
-AC_SUBST(LN)
-if test -z "$LN" ; then
-	case $ac_sys_system in
-		BeOS*) LN="ln -s";;
-		CYGWIN*) LN="ln -s";;
-		atheos*) LN="ln -s";;
-		*) LN=ln;;
-	esac
-fi
-
-# XXX Shouldn't the code above that fiddles with BASECFLAGS and OPT be
-# merged with this chunk of code?
-
-# Optimizer/debugger flags
-# ------------------------
-# (The following bit of code is complicated enough - please keep things
-# indented properly.  Just pretend you're editing Python code. ;-)
-
-# There are two parallel sets of case statements below, one that checks to
-# see if OPT was set and one that does BASECFLAGS setting based upon
-# compiler and platform.  BASECFLAGS tweaks need to be made even if the
-# user set OPT.
-
-# tweak OPT based on compiler and platform, only if the user didn't set
-# it on the command line
-AC_SUBST(OPT)
-if test -z "$OPT"
-then
-    case $GCC in
-    yes)
-        if test "$CC" != 'g++' ; then
-	    STRICT_PROTO="-Wstrict-prototypes"
-	fi
-	case $ac_cv_prog_cc_g in
-	yes)
-	    if test "$Py_DEBUG" = 'true' ; then
-		# Optimization messes up debuggers, so turn it off for
-		# debug builds.
-		OPT="-g -Wall $STRICT_PROTO"
-	    else
-		OPT="-g -O3 -Wall $STRICT_PROTO"
-	    fi
-	    ;;
-	*)
-	    OPT="-O3 -Wall $STRICT_PROTO"
-	    ;;
-	esac
-	case $ac_sys_system in
-	    SCO_SV*) OPT="$OPT -m486 -DSCO5"
-	    ;;
-        esac
-	;;
-
-    *)
-	OPT="-O"
-	;;
-    esac
-
-    # The current (beta) Monterey compiler dies with optimizations
-    # XXX what is Monterey? Does it still die w/ -O? Can we get rid of this?
-    case $ac_sys_system in
-	Monterey*)
-	    OPT=""
-	    ;;
-    esac
-
-fi
-
-AC_SUBST(BASECFLAGS)
-# tweak BASECFLAGS based on compiler and platform
-case $GCC in
-yes)
-    # Python violates C99 rules, by casting between incompatible
-    # pointer types. GCC may generate bad code as a result of that,
-    # so use -fno-strict-aliasing if supported.
-    AC_MSG_CHECKING(whether $CC accepts -fno-strict-aliasing)
-     ac_save_cc="$CC"
-     CC="$CC -fno-strict-aliasing"
-     AC_TRY_RUN([int main() { return 0; }],
-     ac_cv_no_strict_aliasing_ok=yes,
-     ac_cv_no_strict_aliasing_ok=no,
-     ac_cv_no_strict_aliasing_ok=no)
-     CC="$ac_save_cc"
-    AC_MSG_RESULT($ac_cv_no_strict_aliasing_ok)
-    if test $ac_cv_no_strict_aliasing_ok = yes
-    then
-      BASECFLAGS="$BASECFLAGS -fno-strict-aliasing"
-    fi
-    case $ac_sys_system in
-	SCO_SV*)
-	    BASECFLAGS="$BASECFLAGS -m486 -DSCO5"
-	    ;;
-	# is there any other compiler on Darwin besides gcc?
-	Darwin*)
-	    BASECFLAGS="$BASECFLAGS -Wno-long-double -no-cpp-precomp -mno-fused-madd"
-	    if test "${enable_universalsdk}"; then
-		BASECFLAGS="-arch ppc -arch i386 -isysroot ${UNIVERSALSDK} ${BASECFLAGS}"
-	    fi
-
-	    ;;
-	OSF*)
-	    BASECFLAGS="$BASECFLAGS -mieee"
-	    ;;
-    esac
-    ;;
-
-*)
-    case $ac_sys_system in
-    OpenUNIX*|UnixWare*)
-	BASECFLAGS="$BASECFLAGS -K pentium,host,inline,loop_unroll,alloca "
-	;;
-    OSF*)
-	BASECFLAGS="$BASECFLAGS -ieee -std"
-    	;;
-    SCO_SV*)
-	BASECFLAGS="$BASECFLAGS -belf -Ki486 -DSCO5"
-	;;
-    esac
-    ;;
-esac
-
-if test "$Py_DEBUG" = 'true'; then
-  :
-else
-  OPT="-DNDEBUG $OPT"
-fi
-
-if test "$ac_arch_flags"
-then
-	BASECFLAGS="$BASECFLAGS $ac_arch_flags"
-fi
-
-# disable check for icc since it seems to pass, but generates a warning
-if test "$CC" = icc
-then
-  ac_cv_opt_olimit_ok=no
-fi
-
-AC_MSG_CHECKING(whether $CC accepts -OPT:Olimit=0)
-AC_CACHE_VAL(ac_cv_opt_olimit_ok,
-[ac_save_cc="$CC"
-CC="$CC -OPT:Olimit=0"
-AC_TRY_RUN([int main() { return 0; }],
-  ac_cv_opt_olimit_ok=yes,
-  ac_cv_opt_olimit_ok=no,
-  ac_cv_opt_olimit_ok=no)
-CC="$ac_save_cc"])
-AC_MSG_RESULT($ac_cv_opt_olimit_ok)
-if test $ac_cv_opt_olimit_ok = yes; then
-    case $ac_sys_system in
-	# XXX is this branch needed? On MacOSX 10.2.2 the result of the
-	# olimit_ok test is "no".  Is it "yes" in some other Darwin-esque
-	# environment?
-        Darwin*)
-	    ;;
-        *)
-	    BASECFLAGS="$BASECFLAGS -OPT:Olimit=0"
-	    ;;
-    esac
-else
-  AC_MSG_CHECKING(whether $CC accepts -Olimit 1500)
-  AC_CACHE_VAL(ac_cv_olimit_ok,
-  [ac_save_cc="$CC"
-  CC="$CC -Olimit 1500"
-  AC_TRY_RUN([int main() { return 0; }],
-    ac_cv_olimit_ok=yes,
-    ac_cv_olimit_ok=no,
-    ac_cv_olimit_ok=no)
-  CC="$ac_save_cc"])
-  AC_MSG_RESULT($ac_cv_olimit_ok)
-  if test $ac_cv_olimit_ok = yes; then
-    BASECFLAGS="$BASECFLAGS -Olimit 1500"
-  fi
-fi
-
 # Check whether GCC supports PyArg_ParseTuple format
 if test "$GCC" = "yes"
 then
@@ -515,7 +57,6 @@
 dnl AC_MSG_RESULT($cpp_type)
 
 # checks for header files
-AC_HEADER_STDC
 AC_CHECK_HEADERS(asm/types.h conio.h curses.h direct.h dlfcn.h errno.h \
 fcntl.h grp.h \
 io.h langinfo.h libintl.h ncurses.h poll.h process.h \
@@ -743,20 +284,6 @@
     LIBTOOL_CRUFT=$LIBTOOL_CRUFT' -compatibility_version $(VERSION) -current_version $(VERSION)';;
 esac
 
-AC_MSG_CHECKING(for --enable-framework)
-if test "$enable_framework"
-then
-	BASECFLAGS="$BASECFLAGS -fno-common -dynamic"
-	# -F. is needed to allow linking to the framework while 
-	# in the build location.
-	AC_DEFINE(WITH_NEXT_FRAMEWORK, 1, 
-         [Define if you want to produce an OpenStep/Rhapsody framework
-         (shared library plus accessory files).])
-	AC_MSG_RESULT(yes)
-else
-	AC_MSG_RESULT(no)
-fi
-
 AC_MSG_CHECKING(for dyld)
 case $ac_sys_system/$ac_sys_release in
   Darwin/*)
@@ -805,118 +332,6 @@
 	sleep 10
 fi
 AC_MSG_RESULT($SO)
-AC_DEFINE_UNQUOTED(SHLIB_EXT, "$SO", [Define this to be extension of shared libraries (including the dot!).])
-# LDSHARED is the ld *command* used to create shared library
-# -- "cc -G" on SunOS 5.x, "ld -shared" on IRIX 5
-# (Shared libraries in this instance are shared modules to be loaded into
-# Python, as opposed to building Python itself as a shared library.)
-AC_MSG_CHECKING(LDSHARED)
-if test -z "$LDSHARED"
-then
-	case $ac_sys_system/$ac_sys_release in
-	AIX*)
-		BLDSHARED="\$(srcdir)/lib/python/Modules/ld_so_aix \$(CC) -bI:lib/python/Modules/python.exp"
-		LDSHARED="\$(BINLIBDEST)/config/ld_so_aix \$(CC) -bI:\$(BINLIBDEST)/config/python.exp"
-		;;
-	BeOS*)
-		BLDSHARED="\$(srcdir)/lib/python/Modules/ld_so_beos $LDLIBRARY"
-		LDSHARED="\$(BINLIBDEST)/config/ld_so_beos \$(LIBDIR)/$LDLIBRARY"
-		;;
-	IRIX/5*) LDSHARED="ld -shared";;
-	IRIX*/6*) LDSHARED="ld ${SGI_ABI} -shared -all";;
-	SunOS/5*) 
-		if test "$GCC" = "yes"
-		then LDSHARED='$(CC) -shared'
-		else LDSHARED='$(CC) -G';
-		fi ;;
-	hp*|HP*) LDSHARED="ld -b";;
-	OSF*) LDSHARED="ld -shared -expect_unresolved \"*\"";;
-	Darwin/1.3*)
-		LDSHARED='$(CC) $(LDFLAGS) -bundle'
-		if test "$enable_framework" ; then
-			# Link against the framework. All externals should be defined.
-			BLDSHARED="$LDSHARED "'$(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)'
-			LDSHARED="$LDSHARED "'$(PYTHONFRAMEWORKPREFIX)/$(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)'
-		else
-			# No framework. Ignore undefined symbols, assuming they come from Python
-			LDSHARED="$LDSHARED -undefined suppress"
-		fi ;;
-	Darwin/1.4*|Darwin/5.*|Darwin/6.*)
-		LDSHARED='$(CC) $(LDFLAGS) -bundle'
-		if test "$enable_framework" ; then
-			# Link against the framework. All externals should be defined.
-			BLDSHARED="$LDSHARED "'$(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)'
-			LDSHARED="$LDSHARED "'$(PYTHONFRAMEWORKPREFIX)/$(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)'
-		else
-			# No framework, use the Python app as bundle-loader
-			BLDSHARED="$LDSHARED "'-bundle_loader $(BUILDPYTHON)'
-			LDSHARED="$LDSHARED "'-bundle_loader $(BINDIR)/python$(VERSION)$(EXE)'
-		fi ;;
-	Darwin/*)
-		# Use -undefined dynamic_lookup whenever possible (10.3 and later).
-		# This allows an extension to be used in any Python
-		cur_target=`sw_vers -productVersion | sed 's/\(10\.[[0-9]]*\).*/\1/'`
-		if test ${cur_target} '>' 10.2; then
-			cur_target=10.3
-		fi
-		CONFIGURE_MACOSX_DEPLOYMENT_TARGET=${MACOSX_DEPLOYMENT_TARGET-${cur_target}}
-		EXPORT_MACOSX_DEPLOYMENT_TARGET=''
-		if test ${MACOSX_DEPLOYMENT_TARGET-${cur_target}} '>' 10.2
-		then
-			if test "${enable_universalsdk}"; then
-				LDFLAGS="-arch i386 -arch ppc -isysroot ${UNIVERSALSDK} ${LDFLAGS}"
-			fi
-			LDSHARED='$(CC) $(LDFLAGS) -bundle -undefined dynamic_lookup'
-			BLDSHARED="$LDSHARED"
-		else
-			LDSHARED='$(CC) $(LDFLAGS) -bundle'
-			if test "$enable_framework" ; then
-				# Link against the framework. All externals should be defined.
-				BLDSHARED="$LDSHARED "'$(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)'
-				LDSHARED="$LDSHARED "'$(PYTHONFRAMEWORKPREFIX)/$(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)'
-			else
-				# No framework, use the Python app as bundle-loader
-				BLDSHARED="$LDSHARED "'-bundle_loader $(BUILDPYTHON)'
-				LDSHARED="$LDSHARED "'-bundle_loader $(BINDIR)/python$(VERSION)$(EXE)'
-			fi
-		fi
-		;;
-	Linux*|GNU*) LDSHARED='$(CC) -shared';;
-	BSD/OS*/4*) LDSHARED="gcc -shared";;
-	FreeBSD*)
-		if [[ "`$CC -dM -E - </dev/null | grep __ELF__`" != "" ]]
-		then
-			LDSHARED="$CC -shared ${LDFLAGS}"
-		else
-			LDSHARED="ld -Bshareable ${LDFLAGS}"
-		fi;;
-	OpenBSD*)
-		if [[ "`$CC -dM -E - </dev/null | grep __ELF__`" != "" ]]
-		then
-				LDSHARED='$(CC) -shared $(CCSHARED) ${LDFLAGS}'
-		else
-				case `uname -r` in
-				[[01]].* | 2.[[0-7]] | 2.[[0-7]].*)
-				   LDSHARED="ld -Bshareable ${LDFLAGS}"
-				   ;;
-				*)
-				   LDSHARED='$(CC) -shared $(CCSHARED) ${LDFLAGS}'
-				   ;;
-				esac
-		fi;;
-	NetBSD*|DragonFly*) LDSHARED="cc -shared ${LDFLAGS}";;
-	OpenUNIX*|UnixWare*)
-		if test "$GCC" = "yes"
-		then LDSHARED='$(CC) -shared'
-		else LDSHARED='$(CC) -G'
-		fi;;
-	SCO_SV*) LDSHARED='$(CC) -Wl,-G,-Bexport';;
-	Monterey*) LDSHARED="cc -G -dy -Bdynamic -Bexport -L/usr/lib/ia64l64";;
-	CYGWIN*) LDSHARED="gcc -shared -Wl,--enable-auto-image-base";;
-	atheos*) LDSHARED="gcc -shared";;
-	*)	LDSHARED="ld";;
-	esac
-fi
 AC_MSG_RESULT($LDSHARED)
 BLDSHARED=${BLDSHARED-$LDSHARED}
 # CCSHARED are the C *flags* used to create objects to go into a shared
@@ -1024,22 +439,6 @@
 fi
 AC_MSG_RESULT($CFLAGSFORSHARED)
 
-# SHLIBS are libraries (except -lc and -lm) to link to the python shared
-# library (with --enable-shared).
-# For platforms on which shared libraries are not allowed to have unresolved
-# symbols, this must be set to $(LIBS) (expanded by make). We do this even
-# if it is not required, since it creates a dependency of the shared library
-# to LIBS. This, in turn, means that applications linking the shared libpython
-# don't need to link LIBS explicitly. The default should be only changed
-# on systems where this approach causes problems.
-AC_SUBST(SHLIBS)
-AC_MSG_CHECKING(SHLIBS)
-case "$ac_sys_system" in
-	*)
-		SHLIBS='$(LIBS)';;
-esac
-AC_MSG_RESULT($SHLIBS)
-
 # check if we need libintl for locale functions
 AC_CHECK_LIB(intl, textdomain,
 	AC_DEFINE(WITH_LIBINTL, 1,
@@ -1613,17 +1012,6 @@
 ])
 AC_MSG_RESULT($works)
 
-# check for socketpair
-AC_MSG_CHECKING(for socketpair)
-AC_TRY_COMPILE([
-#include <sys/types.h>
-#include <sys/socket.h>
-], void *x=socketpair,
-  AC_DEFINE(HAVE_SOCKETPAIR, 1, Define if you have the 'socketpair' function.)
-  AC_MSG_RESULT(yes),
-  AC_MSG_RESULT(no)
-)
-
 # check if sockaddr has sa_len member
 AC_MSG_CHECKING(if sockaddr has sa_len member)
 AC_TRY_COMPILE([#include <sys/types.h>
@@ -1744,43 +1132,6 @@
 fi],
 [AC_MSG_RESULT(no)])
 
-# check for --with-libm=...
-AC_SUBST(LIBM)
-case $ac_sys_system in
-Darwin) ;;
-BeOS) ;;
-*) LIBM=-lm
-esac
-AC_MSG_CHECKING(for --with-libm=STRING)
-AC_ARG_WITH(libm,
-            AC_HELP_STRING(--with-libm=STRING, math library),
-[
-if test "$withval" = no
-then LIBM=
-     AC_MSG_RESULT(force LIBM empty)
-elif test "$withval" != yes
-then LIBM=$withval
-     AC_MSG_RESULT(set LIBM="$withval")
-else AC_MSG_ERROR([proper usage is --with-libm=STRING])
-fi],
-[AC_MSG_RESULT(default LIBM="$LIBM")])
-
-# check for --with-libc=...
-AC_SUBST(LIBC)
-AC_MSG_CHECKING(for --with-libc=STRING)
-AC_ARG_WITH(libc,
-            AC_HELP_STRING(--with-libc=STRING, C library),
-[
-if test "$withval" = no
-then LIBC=
-     AC_MSG_RESULT(force LIBC empty)
-elif test "$withval" != yes
-then LIBC=$withval
-     AC_MSG_RESULT(set LIBC="$withval")
-else AC_MSG_ERROR([proper usage is --with-libc=STRING])
-fi],
-[AC_MSG_RESULT(default LIBC="$LIBC")])
-
 # check for hypot() in math library
 LIBS_SAVE=$LIBS
 LIBS="$LIBS $LIBM"
@@ -2291,13 +1642,6 @@
 #endif
 ])
 
-AC_SUBST(THREADHEADERS)
-
-for h in `(cd $srcdir;echo Python/thread_*.h)`
-do
-  THREADHEADERS="$THREADHEADERS \$(srcdir)/$h"
-done
-
 # generate output files
 AC_CONFIG_FILES(lib/python/Modules/Setup.config)
 
@@ -2307,10 +1651,4 @@
 	cp $srcdir/lib/python/Modules/Setup.dist lib/python/Modules/Setup
 fi
 
-echo "creating lib/python/Modules/Setup.local"
-if test ! -f lib/python/Modules/Setup.local
-then
-	echo "# Edit this file for local setup changes" >lib/python/Modules/Setup.local
-fi
-
 AC_DEFINE_UNQUOTED(PLATFORM, $MACHDEP, [Platforms])

=== modified file 'source/lib/python/config.mk'
--- a/source/lib/python/config.mk	2007-04-23 20:38:05 +0000
+++ b/source/lib/python/config.mk	2007-04-23 22:48:27 +0000
@@ -1,38 +1,9 @@
-# Symbols used for using shared libraries
-SO=		@SO@
-LDSHARED=	@LDSHARED@
-BLDSHARED=	@BLDSHARED@
-DESTSHARED=	$(BINLIBDEST)/lib-dynload
-
-# Environment to run shared python without installed libraries
-RUNSHARED=       @RUNSHARED@
-
-# Modes for directories, executables and data files created by the
-# install process.  Default to user-only-writable for all file types.
-DIRMODE=	755
-EXEMODE=	755
-FILEMODE=	644
-
-LIBRARY=	@LIBRARY@
-LDLIBRARY=      @LDLIBRARY@
-BLDLIBRARY=     @BLDLIBRARY@
-DLLLIBRARY=	@DLLLIBRARY@
-LDLIBRARYDIR=   @LDLIBRARYDIR@
-INSTSONAME=	@INSTSONAME@
-
-
-# === Definitions added by makesetup ===
-
-
-
-
 ##########################################################################
 # Grammar
 GRAMMAR_H=	$(srcdir)/lib/python/Include/graminit.h
 GRAMMAR_C=	$(srcdir)/lib/python/Python/graminit.c
 GRAMMAR_INPUT=	$(srcdir)/lib/python/Grammar/Grammar
 
-
 ##########################################################################
 # Parser
 [SUBSYSTEM::PYTHON_PARSER_HOST]
@@ -66,7 +37,7 @@
 
 [LIBRARY::PYTHON]
 LDFLAGS = -lm -lutil
-CFLAGS = -DPy_BUILD_CORE -Ilib/python/Include -Ilib/python -DPYTHONPATH=":plat-linux2" -DVERSION="2.6"
+CFLAGS = -DPy_BUILD_CORE -Ilib/python/Include -Ilib/python -DPYTHONPATH=":plat-linux2" -DVERSION="2.6" -DPLATFORM="linux2"
 OBJ_FILES =	\
 		Python/getplatform.o \
 		Modules/_typesmodule.o \
@@ -181,31 +152,6 @@
 OBJ_FILES = \
 			Modules/python.o
 
-# Build the shared modules
-sharedmods: $(BUILDPYTHON)
-	@case $$MAKEFLAGS in \
-	*-s*) $(RUNSHARED) CC='$(CC)' LDSHARED='$(BLDSHARED)' OPT='$(OPT)' ./$(BUILDPYTHON) -E $(srcdir)/setup.py -q build;; \
-	*) $(RUNSHARED) CC='$(CC)' LDSHARED='$(BLDSHARED)' OPT='$(OPT)' ./$(BUILDPYTHON) -E $(srcdir)/setup.py build;; \
-	esac
-
-# Build static library
-# avoid long command lines, same as LIBRARY_OBJS
-$(LIBRARY): $(LIBRARY_OBJS)
-	-rm -f $@
-	$(AR) cr $@ Modules/getbuildinfo.o
-	$(AR) cr $@ Modules/_typesmodule.o
-	$(AR) cr $@ $(PARSER_OBJS)
-	$(AR) cr $@ $(OBJECT_OBJS)
-	$(AR) cr $@ $(PYTHON_OBJS)
-	$(AR) cr $@ $(MODULE_OBJS) $(SIGNAL_OBJS)
-	$(AR) cr $@ $(MODOBJS)
-	$(RANLIB) $@
-
-oldsharedmods: $(SHAREDMODS)
-
-############################################################################
-# Special rules for object files
-
 $(GRAMMAR_H) $(GRAMMAR_C): bin/pgen $(GRAMMAR_INPUT)
 		-bin/pgen $(GRAMMAR_INPUT) $(GRAMMAR_H) $(GRAMMAR_C)
 
@@ -238,102 +184,3 @@
 
 lib/python/Objects/unicodectype.o:	$(srcdir)/lib/python/Objects/unicodectype.c \
 				$(srcdir)/lib/python/Objects/unicodetype_db.h
-
-############################################################################
-# Header files
-
-PYTHON_HEADERS= \
-		Include/Python.h \
-		Include/Python-ast.h \
-		Include/asdl.h \
-		Include/abstract.h \
-		Include/boolobject.h \
-		Include/bufferobject.h \
-		Include/ceval.h \
-		Include/classobject.h \
-		Include/cobject.h \
-		Include/code.h \
-		Include/codecs.h \
-		Include/compile.h \
-		Include/complexobject.h \
-		Include/descrobject.h \
-		Include/dictobject.h \
-		Include/enumobject.h \
-		Include/genobject.h \
-		Include/fileobject.h \
-		Include/floatobject.h \
-		Include/funcobject.h \
-		Include/import.h \
-		Include/intobject.h \
-		Include/intrcheck.h \
-		Include/iterobject.h \
-		Include/listobject.h \
-		Include/longobject.h \
-		Include/methodobject.h \
-		Include/modsupport.h \
-		Include/moduleobject.h \
-		Include/object.h \
-		Include/objimpl.h \
-		Include/parsetok.h \
-		Include/patchlevel.h \
-		Include/pyarena.h \
-		Include/pydebug.h \
-		Include/pyerrors.h \
-		Include/pyfpe.h \
-		Include/pymem.h \
-		Include/pyport.h \
-		Include/pystate.h \
-		Include/pythonrun.h \
-		Include/rangeobject.h \
-        Include/setobject.h \
-		Include/sliceobject.h \
-		Include/stringobject.h \
-		Include/structseq.h \
-		Include/structmember.h \
-		Include/symtable.h \
-		Include/sysmodule.h \
-		Include/traceback.h \
-		Include/tupleobject.h \
-		Include/unicodeobject.h \
-		Include/weakrefobject.h \
-		pyconfig.h
-
-$(LIBRARY_OBJS) $(MODOBJS) Modules/python.o: $(PYTHON_HEADERS)
-
-# Install the library
-PLATDIR=	plat-$(MACHDEP)
-EXTRAPLATDIR= @EXTRAPLATDIR@
-EXTRAMACHDEPPATH=@EXTRAMACHDEPPATH@
-MACHDEPS=	$(PLATDIR) $(EXTRAPLATDIR)
-XMLLIBSUBDIRS=  xml xml/dom xml/etree xml/parsers xml/sax
-PLATMACDIRS= plat-mac plat-mac/Carbon plat-mac/lib-scriptpackages \
-	plat-mac/lib-scriptpackages/_builtinSuites \
-	plat-mac/lib-scriptpackages/CodeWarrior \
-	plat-mac/lib-scriptpackages/Explorer \
-	plat-mac/lib-scriptpackages/Finder \
-	plat-mac/lib-scriptpackages/Netscape \
-	plat-mac/lib-scriptpackages/StdSuites \
-	plat-mac/lib-scriptpackages/SystemEvents \
-	plat-mac/lib-scriptpackages/Terminal 
-PLATMACPATH=:plat-mac:plat-mac/lib-scriptpackages
-LIBSUBDIRS=	lib-tk site-packages test test/output test/data \
-		test/decimaltestdata \
-		encodings compiler hotshot \
-		email email/mime email/test email/test/data \
-		sqlite3 sqlite3/test \
-		logging bsddb bsddb/test csv wsgiref \
-		ctypes ctypes/test ctypes/macholib idlelib idlelib/Icons \
-		distutils distutils/command distutils/tests $(XMLLIBSUBDIRS) \
-		setuptools setuptools/command setuptools/tests setuptools.egg-info \
-		curses $(MACHDEPS)
-
-# Create the PLATDIR source directory, if one wasn't distributed..
-$(srcdir)/lib/python/Lib/$(PLATDIR):
-	mkdir $(srcdir)/lib/python/Lib/$(PLATDIR)
-	cp $(srcdir)/Lib/plat-generic/regen $(srcdir)/lib/python/Lib/$(PLATDIR)/regen
-	export PATH; PATH="`pwd`:$$PATH"; \
-	export PYTHONPATH; PYTHONPATH="`pwd`/Lib"; \
-	export DYLD_FRAMEWORK_PATH; DYLD_FRAMEWORK_PATH="`pwd`"; \
-	export EXE; EXE="$(BUILDEXE)"; \
-	cd $(srcdir)/Lib/lib/python/$(PLATDIR); ./regen
-



More information about the samba-cvs mailing list