[Qgis-developer] Building QGIS in Mac OS X (Mountain Lion i.e. 10.8) with QtSQL support

Noli Sicad nsicad at gmail.com
Sat Aug 4 21:45:43 PDT 2012


Hi Larry,

Now, this is the tricky part using my qmake for PyQt and QtSDK.

I need help in this part.

#######

Based on the instruction (1)


python2.7 configure.py -d /Library/Python/2.7/site-packages -b /usr/local/bin


Nolis-MacBook-Pro:PyQt-mac-gpl-4.9.4 nsicad$ python2.7 configure.py -d
/Library/Python/2.7/site-packages -b /usr/local/bin
Determining the layout of your Qt installation...
Error: Qt has been built as static libraries so either the -g or -k argument
should be used.

#################

Now using the path:

python2.7 configure.py --qmake=/Users/nsicad/QtSDK/Desktop/Qt/474/gcc/bin/qmake


Nolis-MacBook-Pro:PyQt-mac-gpl-4.9.4 nsicad$ python2.7 configure.py
--qmake=/Users/nsicad/QtSDK/Desktop/Qt/474/gcc/bin/qmake -d
/Library/Python/2.7/site-packages -b /usr/local/bin
Determining the layout of your Qt installation...
Error: Qt has been built as static libraries so either the -g or -k argument
should be used.
Nolis-MacBook-Pro:PyQt-mac-gpl-4.9.4 nsicad$

########

Any ideas how to set this up properly (i.e. install PyQT with qmake)?


Noli


On 8/5/12, Noli Sicad <nsicad at gmail.com> wrote:
> Hi Larry,
>
> On 8/5/12, Larry Shaffer <larrys at dakotacarto.com> wrote:
>> Hi,
>>
>> Sorry to top post, but... I have not had any significant problems
>> following INSTALL to build master branch on Mt. Lion today. I have
>> just updated the Mac notes with some optional info on installing
>> ccache, and some cmake options for the external libspatialindex [0]. I
>> did not add any specific info about compiling on Mt. Lion to the
>> notes.
>
> Thanks for updating the documentation on Building QGIS for Mac OS X.
>
> More tweaks and a bit more details documentation the better.
>
> Now, here is proper logs for building SIP in accordance to the QGIS
> Mac OS X needs. I am overdriving my homebrew install of SIP.
>
> I am using the tarball of SIP (i.e. sip-4.13.3) after I fixed the c++
> problem.
>
> #########
> Last login: Sun Aug  5 12:51:29 on ttys010
> Nolis-MacBook-Pro:sip-4.13.3 nsicad$ python2.7 configure.py -d
> /Library/Python/2.7/site-packages -b /usr/local/bin -e
> /usr/local/include -v /usr/local/share/sip
> This is SIP 4.13.3 for Python 2.7.2 on darwin.
> The SIP code generator will be installed in /usr/local/bin.
> The sip module will be installed in /Library/Python/2.7/site-packages.
> The sip.h header file will be installed in /usr/local/include.
> The default directory to install .sip files in is /usr/local/share/sip.
> The platform/compiler configuration is macx-g++.
> Creating siplib/sip.h...
> Creating siplib/siplib.c...
> Creating siplib/siplib.sbf...
> Creating sipconfig.py...
> Creating top level Makefile...
> Creating sip code generator Makefile...
> Creating sip module Makefile...
> Nolis-MacBook-Pro:sip-4.13.3 nsicad$ make
> c++ -headerpad_max_install_names -o sip main.o transform.o gencode.o
> extracts.o export.o heap.o parser.o lexer.o
> cc -c -pipe -fPIC -Os -w -DNDEBUG -I.
> -I/System/Library/Frameworks/Python.framework/Versions/2.7/include/python2.7
> -o siplib.o siplib.c
> cc -c -pipe -fPIC -Os -w -DNDEBUG -I.
> -I/System/Library/Frameworks/Python.framework/Versions/2.7/include/python2.7
> -o apiversions.o apiversions.c
> cc -c -pipe -fPIC -Os -w -DNDEBUG -I.
> -I/System/Library/Frameworks/Python.framework/Versions/2.7/include/python2.7
> -o descriptors.o descriptors.c
> cc -c -pipe -fPIC -Os -w -DNDEBUG -I.
> -I/System/Library/Frameworks/Python.framework/Versions/2.7/include/python2.7
> -o qtlib.o qtlib.c
> cc -c -pipe -fPIC -Os -w -DNDEBUG -I.
> -I/System/Library/Frameworks/Python.framework/Versions/2.7/include/python2.7
> -o threads.o threads.c
> cc -c -pipe -fPIC -Os -w -DNDEBUG -I.
> -I/System/Library/Frameworks/Python.framework/Versions/2.7/include/python2.7
> -o objmap.o objmap.c
> cc -c -pipe -fPIC -Os -w -DNDEBUG -I.
> -I/System/Library/Frameworks/Python.framework/Versions/2.7/include/python2.7
> -o voidptr.o voidptr.c
> c++ -c -pipe -fPIC -Os -w -DNDEBUG -I.
> -I/System/Library/Frameworks/Python.framework/Versions/2.7/include/python2.7
> -o bool.o bool.cpp
> c++ -headerpad_max_install_names -bundle -undefined dynamic_lookup -o
> sip.so siplib.o apiversions.o descriptors.o qtlib.o threads.o objmap.o
> voidptr.o bool.o
> Nolis-MacBook-Pro:sip-4.13.3 nsicad$ sudo make install
> dyld: DYLD_ environment variables being ignored because main
> executable (/usr/bin/sudo) is setuid or setgid
> Password:
> Sorry, try again.
> Password:
> cp -f sip /usr/local/bin/sip
> cp -f sip.so /Library/Python/2.7/site-packages/sip.so
> cp -f /Users/nsicad/Downloads/sip-4.13.3/siplib/sip.h
> /usr/local/include/sip.h
> cp -f sipconfig.py /Library/Python/2.7/site-packages/sipconfig.py
> cp -f /Users/nsicad/Downloads/sip-4.13.3/sipdistutils.py
> /Library/Python/2.7/site-packages/sipdistutils.py
> Nolis-MacBook-Pro:sip-4.13.3 nsicad$
>
> ##########
>
> As we can see the SIP installed properly for PyQt to use for QGIS.
>
> I just like to document this in the list so other Mac OS X (i.e.
> Mountain Lion) users can use in the future including me :-).
>
> Regards,
>
> Noli
>


More information about the Qgis-developer mailing list