Python 2.6 fails on compiling > Bug report

  • Thread starter googler.1.webmaster
  • Start date
G

googler.1.webmaster

Hi!

I compiled Python 2.6.1 on a Mac OSX 10.5.5 Intel machine with this
configure command and got this message


FAILS: ./configure --with-framework-name=Python --with-
universal-archs=all --enable-framework --enable-
universalsdk=@executable_path/my/path/to/app


WORKS: ./configure --with-framework-name=Python --with-
universal-archs=all --enable-framework --enable-universalsdk=/


[...]
configure: WARNING: dlfcn.h: present but cannot be compiled
configure: WARNING: dlfcn.h: check for missing prerequisite
headers?
configure: WARNING: dlfcn.h: see the Autoconf documentation
configure: WARNING: dlfcn.h: section "Present But Cannot Be
Compiled"
configure: WARNING: dlfcn.h: proceeding with the preprocessor's result
configure: WARNING: dlfcn.h: in the future, the compiler will take
precedence
configure: WARNING: ##
------------------------------------------------ ##
configure: WARNING: ## Report this to http://www.python.org/python-bugs
##
configure: WARNING: ##
------------------------------------------------ ##
checking for dlfcn.h... yes
[...] many of this error warnings occure.


/* its already noted in the bug reporter but there is no solution.
Does anyone know how to use my custom path?


Thanks.
 
G

googler.1.webmaster

Hi searched for "Library/Frameworks/" in the config file and edited it
to "@executable_path".

Well my configure and make command worked very fine. Just 'make
install' aborted after this error message.


test -d "/Applications/Python 2.6" || mkdir -p "/Applications/Python
2.6"
test -d "/Applications/Python 2.6/IDLE.app" && rm -r "/Applications/
Python 2.6/IDLE.app"
cp -PR IDLE.app "/Applications/Python 2.6"
touch "/Applications/Python 2.6/IDLE.app"
cp ./config-main.def "@executable_path/Python.framework/Versions/2.6/
lib/python2.6/idlelib/config-main.def"
cp: @executable_path/Python.framework/Versions/2.6/lib/python2.6/
idlelib/config-main.def: No such file or directory
make[2]: *** [install] Error 1
make[1]: *** [install_IDLE] Error 2
make: *** [frameworkinstallapps4way] Error 2


That is not cool.. really.. thats not cool. Thanks for your tipps.
 
N

Ned Deily

hm... any ideas?

Have you tried specifying one of the universal SDKs, i.e.
/Developer/SDKs/MacOSX10.n.sdk? That's what the "official" python.org
builds do. The build script for the batteries-included installer is in
the source tar ball at Mac/BuildScript/build-installer.py.

FWIW, I made a universal (4-way) batteries-included framework build for
2.6 on 10.5 with the following patch to that script:

--- build-installer.py.bak 2008-12-17 20:02:59.000000000 -0800
+++ build-installer.py 2008-12-17 23:18:57.000000000 -0800
@@ -1,12 +1,9 @@
-#!/usr/bin/python2.3
+#!/usr/bin/python2.5
"""
This script is used to build the "official unofficial" universal build
on
-Mac OS X. It requires Mac OS X 10.4, Xcode 2.2 and the 10.4u SDK to do
its
+Mac OS X. It requires Mac OS X 10.5, Xcode 3.0 and the 10.5u SDK to do
its
work.

-Please ensure that this script keeps working with Python 2.3, to avoid
-bootstrap issues (/usr/bin/python is Python 2.3 on OSX 10.4)
-
Usage: see USAGE variable in the script.
"""
import platform, os, sys, getopt, textwrap, shutil, urllib2, stat,
time, pwd
@@ -65,10 +62,10 @@
DEPSRC = os.path.expanduser('~/Universal/other-sources')

# Location of the preferred SDK
-SDKPATH = "/Developer/SDKs/MacOSX10.4u.sdk"
+SDKPATH = "/Developer/SDKs/MacOSX10.5.sdk"
#SDKPATH = "/"

-ARCHLIST = ('i386', 'ppc',)
+ARCHLIST = ('i386', 'ppc', 'x86_64', 'ppc64', )

# Source directory (asume we're in Mac/BuildScript)
SRCDIR = os.path.dirname(
@@ -630,7 +627,7 @@
version = getVersion()

print "Running configure..."
- runCommand("%s -C --enable-framework --enable-universalsdk=%s
LDFLAGS='-g -L%s/libraries/usr/local/lib' OPT='-g -O3
-I%s/libraries/usr/local/include' 2>&1"%(
+ runCommand("%s -C --enable-framework --enable-universalsdk=%s
--with-universal-archs=all LDFLAGS='-g -L%s/libraries/usr/local/lib'
OPT='-g -O3 -I%s/libraries/usr/local/include' 2>&1"%(
shellQuote(os.path.join(SRCDIR, 'configure')),
shellQuote(SDKPATH), shellQuote(WORKDIR)[1:-1],
shellQuote(WORKDIR)[1:-1]))
@@ -1017,7 +1014,7 @@
parseOptions()
checkEnvironment()

- os.environ['MACOSX_DEPLOYMENT_TARGET'] = '10.3'
+ os.environ['MACOSX_DEPLOYMENT_TARGET'] = '10.5'

if os.path.exists(WORKDIR):
shutil.rmtree(WORKDIR)
 
G

googler.1.webmaster

hi, thanks for your help.

May the diff file is wrong? on my system it doesn't work.
Well, set the -enable-universalsdk= path occurs that error.

Hmm. that is really a disaster, isn't it :( hm.
 
N

Ned Deily

May the diff file is wrong? on my system it doesn't work.
Well, set the -enable-universalsdk= path occurs that error.

Sorry, there were a few line wrap-arounds in the diff file due to long
lines but the changes for the four significant lines should be easy to
do manually.

Note that the build I made this way has not been tested on ppc64 and has
had minimal testing so far on x64_64.
 
G

googler.1.webmaster

Hi! :)
Sorry, there were a few line wrap-arounds in the diff file due to long
lines but the changes for the four significant lines should be easy to
do manually.


Hadn't done that before but I found a ressource how to read that
syntax.
x86_64 would be enough. i test that again. Thank you. :)
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,769
Messages
2,569,578
Members
45,052
Latest member
LucyCarper

Latest Threads

Top