[PyQt] build sip and pyqt on osx (unix way, no python framework)

Massimo Di Stefano massimodisasha at gmail.com
Tue Jun 1 10:25:29 BST 2010


Hi Phil,

thanks for your help, i succesfull build sip
commenting out this line in the file sipconfig.py :


            #if "Python.framework" not in dl:
            #    error("SIP requires Python to be built as a framework")


after build Sip, i'm tring to install PyQt

i used this configure :

python configure.py -d /usr/local/gislib/unix/lib/python2.6/site-packages -b /usr/local/gislib/unix/bin --use-arch=x86_64


but the make ends with an error :

MacBook-Pro-15-di-Massimo-Di-Stefano:PyQt-mac-gpl-4.7.3 sasha$ make
make[2]: Nothing to be done for `first'.
make[2]: Nothing to be done for `first'.
make[2]: Nothing to be done for `first'.
make[1]: Nothing to be done for `all'.
make[1]: Nothing to be done for `all'.
..
...
make[1]: Nothing to be done for `all'.
make[1]: Nothing to be done for `all'.
make[1]: Nothing to be done for `all'.
rm -f libpythonplugin.dylib
g++ -headerpad_max_install_names -arch x86_64 -Xarch_x86_64 -mmacosx-version-min=10.5 -single_module -dynamiclib -o libpythonplugin.dylib pluginloader.o moc_pluginloader.o  -F/Library/Frameworks -L/Library/Frameworks -framework Python -framework QtDesigner -framework QtScript -framework QtXml -framework QtGui -framework QtCore  
Undefined symbols:
  "__Py_RefTotal", referenced from:
      PyCustomWidgets::getModuleAttr(char const*, char const*)in pluginloader.o
      PyCustomWidgets::PyCustomWidgets(QObject*)in pluginloader.o
      PyCustomWidgets::PyCustomWidgets(QObject*)in pluginloader.o
      PyCustomWidgets::PyCustomWidgets(QObject*)in pluginloader.o
      PyCustomWidgets::PyCustomWidgets(QObject*)in pluginloader.o
  "__Py_Dealloc", referenced from:
      PyCustomWidgets::getModuleAttr(char const*, char const*)in pluginloader.o
      PyCustomWidgets::PyCustomWidgets(QObject*)in pluginloader.o
      PyCustomWidgets::PyCustomWidgets(QObject*)in pluginloader.o
      PyCustomWidgets::PyCustomWidgets(QObject*)in pluginloader.o
      PyCustomWidgets::PyCustomWidgets(QObject*)in pluginloader.o
  "__Py_NegativeRefcount", referenced from:
      PyCustomWidgets::getModuleAttr(char const*, char const*)in pluginloader.o
      PyCustomWidgets::PyCustomWidgets(QObject*)in pluginloader.o
      PyCustomWidgets::PyCustomWidgets(QObject*)in pluginloader.o
      PyCustomWidgets::PyCustomWidgets(QObject*)in pluginloader.o
      PyCustomWidgets::PyCustomWidgets(QObject*)in pluginloader.o
ld: symbol(s) not found
collect2: ld returned 1 exit status
make[1]: *** [libpythonplugin.dylib] Error 1
make: *** [all] Error 2

maybe i have to export a lib path
from :
/usr/local/gislib/unix/lib     

( "/usr/local/gislib/unix/" is where i'm installing source build libs) ?


Il giorno 01/giu/2010, alle ore 10.39, Phil Thompson ha scritto:

> On Tue, 1 Jun 2010 10:21:44 +0200, Massimo Di Stefano
> <massimodisasha at gmail.com> wrote:
>> Hi,
>> 
>> I'm tring to build sip on mac osx using python compiled from source
>> in a standard unix fashon, without framework.
>> 
>> i used this line to configure sip :
>> 
>> python configure.py -d /usr/local/gislib/unix/lib/python2.6/site-packages
>> -b /usr/local/gislib/unix/bin -e /usr/local/gislib/unix/include -v
>> /usr/local/gislib/unix/share --arch=x86_64
>> This is SIP 4.10.2 for Python 2.6.5 on darwin.
>> The SIP code generator will be installed in /usr/local/gislib/unix/bin.
>> The SIP module will be installed in
>> /usr/local/gislib/unix/lib/python2.6/site-packages.
>> The SIP header file will be installed in /usr/local/gislib/unix/include.
>> The default directory to install .sip files in is
>> /usr/local/gislib/unix/share.
>> The platform/compiler configuration is macx-g++.
>> MacOS/X binaries will be created for x86_64.
>> Creating sipconfig.py...
>> Creating top level Makefile...
>> Creating sip code generator Makefile...
>> Creating sip module Makefile...
>> Error: SIP requires Python to be built as a framework
>> [18007 refs]
>> 
>> 
>> how can i build sip without a python framework ?
> 
> You will have to hack at configure.py.
> 
> Phil
> _______________________________________________
> PyQt mailing list    PyQt at riverbankcomputing.com
> http://www.riverbankcomputing.com/mailman/listinfo/pyqt



More information about the PyQt mailing list