PyQt5 on MacOS X Mavericks
をテンプレートにして作成
[
トップ
] [
新規
|
一覧
|
単語検索
|
最終更新
]
開始行:
[[Python]]~
[[OS X]]
#contents
MacOS X Mavericks で PyQt を動作させる手順です。~
**PyQt とは [#fdc0f383]
PyQt は、クロスプラットフォームの GUI ツールキットである ...
Python で GUI プログラミングをするときの選択肢の一つです。~
(PyQt の他には PySide、PyGTK、wxPython、Tkinter などの P...
PyQt はイギリス Riverbank Computing によって開発されてお...
PyQt はクロスプラットフォームなツールキットであり、Window...
http://www.riverbankcomputing.com/software/pyqt/intro~
**インストール環境 [#v42fa969]
インストールを行ったマシンは Mac mini (Late 2012) で、~
~
MacOS X Maverikcs は 2014/09/24 時点で最新の更新である 10...
$ sw_vers
ProductName: Mac OS X
ProductVersion: 10.9.5
BuildVersion: 13F34
Xcode は 2014/09/24 時点で最新の更新である 6.0.1
$ xcode-select -p
/Applications/Xcode.app/Contents/Developer
$ xcodebuild -version
Xcode 6.0.1
Build version 6A317
です。
**Qt のインストール[#me852862]
まず Qt をインストールします。~
version は 2014/09/24 時点で最新の 5.3.2 です。~
最初は Qt Project のダウンロードページ~
http://qt-project.org/downloads~
から ~
Qt Online Installer for MacOS (qt-opensource-mac-x64-1.6....
をダウンロードしてインストールしましたが、~
10.9.5 への対応がまだ出来てないようで同梱の QtCreater が...
ソースコードからビルドしてインストールします。~
~
同ページ上で Show Downloads をクリックし、表示されるソー...
http://download.qt-project.org/official_releases/qt/5.3/5...
をダウンロードします。~
~
展開し、configure を実行します。config の option は defau...
$ tar xvf qt-everywhere-opensource-src-5.3.2.tar.gz
$ cd qt-everywhere-opensource-src-5.3.2
$ ./configure
+ cd qtbase
+ /Users/otsuka/Downloads/Qt/qt-everywhere-opensource-sr...
Which edition of Qt do you want to use ?
Type 'c' if you want to use the Commercial Edition.
Type 'o' if you want to use the Open Source Edition.
o
This is the Qt Open Source Edition.
You are licensed to use this software under the terms of
the Lesser GNU General Public License (LGPL) versions 2.1.
You are also licensed to use this software under the ter...
the GNU General Public License (GPL) versions 3.
Type '3' to view the GNU General Public License version 3.
Type 'L' to view the Lesser GNU General Public License v...
Type 'yes' to accept this license offer.
Type 'no' to decline this license offer.
Do you accept the terms of either license? yes
Creating qmake...
........ 以下略
script の選択肢に入力で回答し実行することで以下のような c...
Running configuration tests...
Configure summary
Build type: macx-clang (x86_64, CPU features: cx16 mm...
Build options:
Configuration .......... absolute_library_soname acces...
corewlan cups debug d...
large-config largefil...
qt_framework reduce_e...
Build parts ............ libs tools examples
Mode ................... debug and release; default li...
Using C++11 ............ yes
Using PCH .............. yes
Target compiler supports:
SSE2/SSE3/SSSE3 ...... yes/yes/yes
SSE4.1/SSE4.2 ........ yes/yes
AVX/AVX2 ............. yes/yes
Qt modules and options:
Qt D-Bus ............... no
Qt Concurrent .......... yes
Qt GUI ................. yes
Qt Widgets ............. yes
Large File ............. yes
QML debugging .......... yes
Use system proxies ..... no
Support enabled for:
Accessibility .......... yes
ALSA ................... no
CUPS ................... yes
Evdev .................. no
FontConfig ............. no
FreeType ............... yes (bundled copy)
Glib ................... no
GTK theme .............. no
HarfBuzz ............... yes
Iconv .................. yes
ICU .................... no
Image formats:
GIF .................. yes (plugin, using bundled co...
JPEG ................. yes (plugin, using bundled co...
PNG .................. yes (in QtGui, using bundled ...
journald ............... no
mtdev .................. no
Networking:
CoreWlan ............. yes
getaddrinfo .......... yes
getifaddrs ........... yes
IPv6 ifname .......... yes
OpenSSL .............. yes (loading libraries at run...
NIS .................... yes
OpenGL / OpenVG:
EGL .................. no
OpenGL ............... desktop
OpenVG ............... no
PCRE ................... yes (bundled copy)
pkg-config ............. yes
PulseAudio ............. no
QPA backends:
DirectFB ............. no
EGLFS ................ no
KMS .................. no
LinuxFB .............. no
XCB .................. no
Session management ..... yes
SQL drivers:
DB2 .................. no
InterBase ............ no
MySQL ................ no
OCI .................. no
ODBC ................. no
PostgreSQL ........... no
SQLite 2 ............. no
SQLite ............... yes (plugin, using bundled co...
TDS .................. no
udev ................... no
xkbcommon .............. no
zlib ................... yes (system library)
Info: creating super cache file /Users/otsuka/Downloads/...
Info: creating stash file /Users/otsuka/Downloads/Qt/qt-...
Qt is now configured for building. Just run 'make'.
Once everything is built, you must run 'make install'.
Qt will be installed into /usr/local/Qt-5.3.2
Prior to reconfiguration, make sure you remove any lefto...
the previous build.
ビルドしインストールします。(ビルドには Mac mini で数時...
$ make
$ sudo make install
config option の表示にあったように /usr/local/Qt-5.3.2 へ...
** SIP のインストール[#kf19bd50]
PyQt をインストールするためには、PyQt の開発元 Riverbank ...
SIP は C/C++ で書かれた Python 用拡張ライブラリの作成を容...
version は 2014/09/24 時点で最新の 4.16.3 です。~
~
SIP のダウンロードページ~
http://www.riverbankcomputing.com/software/sip/download~
から~
http://sourceforge.net/projects/pyqt/files/sip/sip-4.16.3...
をダウンロードします。~
展開して configure を行い、ビルドしてインストールします。~
$ tar xvf sip-4.16.3.tar.gz
$ cd sip-4.16.3
$ python configure.py
This is SIP 4.16.3 for Python 2.7.5 on darwin.
The SIP code generator will be installed in
/System/Library/Frameworks/Python.framework/Versions/2.7...
The sip module will be installed in /Library/Python/2.7/...
The sip.h header file will be installed in
/System/Library/Frameworks/Python.framework/Versions/2.7...
The default directory to install .sip files in is
/System/Library/Frameworks/Python.framework/Versions/2.7...
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...
$ make
$ sudo make install
configure で表示された PATH にインストールされます。~
PyQt のインストール時に必要になるので、 sip コマンドのイ...
** PyQt のインストール [#vf9a7aa3]
上記の手順で必要なものがインストールされたので PyQt をイ...
Version は 2014/09/24 時点で最新の 5.3.2 です。~
(対応する Qt と version を同じに揃えられているようです。...
PyQt5 のダウンロードページ~
http://www.riverbankcomputing.com/software/pyqt/download5~
から~
http://sourceforge.net/projects/pyqt/files/PyQt5/PyQt-5.3...
をダウンロードします。
$ tar xvf PyQt-gpl-5.3.2.tar.gz
$ cd PyQt-gpl-5.3.2
ソースコードアーカイブを展開したら、configure を実行する...
(修正を加えないまま configure を実行してビルドすると、We...
$ diff -u configure.py.orig configure.py
--- configure.py.orig 2014-09-24 16:32:32.000000000 +0900
+++ configure.py 2014-09-24 16:32:49.000000000 +0900
@@ -87,7 +87,7 @@
'QtSvg': ModuleMetadata(qmake_QT=['s...
'QtTest': ModuleMetadata(qmake_QT=['t...
'QtWebKit': ModuleMetadata(qmake_QT=['w...
- 'QtWebKitWidgets': ModuleMetadata(qmake_QT=['w...
+ 'QtWebKitWidgets': ModuleMetadata(qmake_QT=['w...
'QtWebSockets': ModuleMetadata(qmake_QT=['w...
'QtWidgets': ModuleMetadata(qmake_QT=['w...
'QtWinExtras': ModuleMetadata(qmake_QT=['w...
修正を加えたら、以下のオプションで configure を実行し、ビ...
$ python configure.py --sip=/System/Library/Frameworks/P...
Querying qmake about your Qt installation...
Determining the details of your Qt installation...
This is the GPL version of PyQt 5.3.2 (licensed under th...
Type 'L' to view the license.
Type 'yes' to accept the terms of the license.
Type 'no' to decline the terms of the license.
Do you accept the terms of the license? yes
Found the license file pyqt-gpl.sip.
Checking to see if the QtGui module should be built...
Checking to see if the QtHelp module should be built...
Checking to see if the QtMultimedia module should be bui...
Checking to see if the QtMultimediaWidgets module should...
Checking to see if the QtNetwork module should be built...
Checking to see if the QtOpenGL module should be built...
Checking to see if the QtPrintSupport module should be b...
Checking to see if the QtQml module should be built...
Checking to see if the QtQuick module should be built...
Checking to see if the QtSql module should be built...
Checking to see if the QtSvg module should be built...
Checking to see if the QtTest module should be built...
Checking to see if the QtWebKit module should be built...
Checking to see if the QtWebKitWidgets module should be ...
Checking to see if the QtWidgets module should be built...
Checking to see if the QtXmlPatterns module should be bu...
Checking to see if the QtDesigner module should be built...
Checking to see if the QAxContainer module should be bui...
Checking to see if the QtDBus module should be built...
Checking to see if the dbus support module should be bui...
DBus v1 does not seem to be installed.
Checking to see if the _QOpenGLFunctions_2_0 module shou...
Checking to see if the QtSensors module should be built...
Checking to see if the QtSerialPort module should be bui...
Checking to see if the QtX11Extras module should be buil...
Checking to see if the QtBluetooth module should be buil...
Checking to see if the QtMacExtras module should be buil...
Checking to see if the QtPositioning module should be bu...
Checking to see if the QtWinExtras module should be buil...
Checking to see if the QtQuickWidgets module should be b...
Checking to see if the QtWebSockets module should be bui...
Checking to see if the Enginio module should be built...
Qt v5.3.2 (Open Source) is being used.
The qmake executable is /usr/local/Qt-5.3.2/bin/qmake.
Qt is built as a shared library.
SIP 4.16.3 is being used.
The sip executable is
/System/Library/Frameworks/Python.framework/Versions/2.7...
These PyQt5 modules will be built: QtCore, QtGui, QtHelp...
QtMultimediaWidgets, QtNetwork, QtOpenGL, QtPrintSupport...
QtSql, QtSvg, QtTest, QtWebKit, QtWebKitWidgets, QtWidge...
QtDesigner, _QOpenGLFunctions_2_0, QtSensors, QtSerialPo...
QtMacExtras, QtPositioning, QtQuickWidgets, QtWebSockets...
The PyQt5 Python package will be installed in
/System/Library/Frameworks/Python.framework/Versions/2.7...
PyQt5 is being built with generated docstrings.
PyQt5 is being built with 'protected' redefined as 'publ...
The Designer plugin will be installed in /usr/local/Qt-5...
The qmlscene plugin will be installed in /usr/local/Qt-5...
The PyQt5 .sip files will be installed in
/System/Library/Frameworks/Python.framework/Versions/2.7...
pyuic5, pyrcc5 and pylupdate5 will be installed in
/System/Library/Frameworks/Python.framework/Versions/2.7...
The interpreter used by pyuic5 is pythonw2.7.
Generating the C++ source for the QtCore module...
Embedding sip flags...
Generating the .pro file for the QtCore module...
Generating the Makefile for the QtCore module...
Generating the C++ source for the QtGui module...
Generating the .pro file for the QtGui module...
Generating the Makefile for the QtGui module...
Generating the C++ source for the QtHelp module...
Generating the .pro file for the QtHelp module...
Generating the Makefile for the QtHelp module...
Generating the C++ source for the QtMultimedia module...
Generating the .pro file for the QtMultimedia module...
Generating the Makefile for the QtMultimedia module...
Generating the C++ source for the QtMultimediaWidgets mo...
Generating the .pro file for the QtMultimediaWidgets mod...
Generating the Makefile for the QtMultimediaWidgets modu...
Generating the C++ source for the QtNetwork module...
Generating the .pro file for the QtNetwork module...
Generating the Makefile for the QtNetwork module...
Generating the C++ source for the QtOpenGL module...
Generating the .pro file for the QtOpenGL module...
Generating the Makefile for the QtOpenGL module...
Generating the C++ source for the QtPrintSupport module...
Generating the .pro file for the QtPrintSupport module...
Generating the Makefile for the QtPrintSupport module...
Generating the C++ source for the QtQml module...
Generating the .pro file for the QtQml module...
Generating the Makefile for the QtQml module...
Generating the C++ source for the QtQuick module...
Generating the .pro file for the QtQuick module...
Generating the Makefile for the QtQuick module...
Generating the C++ source for the QtSql module...
Generating the .pro file for the QtSql module...
Generating the Makefile for the QtSql module...
Generating the C++ source for the QtSvg module...
Generating the .pro file for the QtSvg module...
Generating the Makefile for the QtSvg module...
Generating the C++ source for the QtTest module...
Generating the .pro file for the QtTest module...
Generating the Makefile for the QtTest module...
Generating the C++ source for the QtWebKit module...
Generating the .pro file for the QtWebKit module...
Generating the Makefile for the QtWebKit module...
Generating the C++ source for the QtWebKitWidgets module...
Generating the .pro file for the QtWebKitWidgets module...
Generating the Makefile for the QtWebKitWidgets module...
Generating the C++ source for the QtWidgets module...
Generating the .pro file for the QtWidgets module...
Generating the Makefile for the QtWidgets module...
Generating the C++ source for the QtXmlPatterns module...
Generating the .pro file for the QtXmlPatterns module...
Generating the Makefile for the QtXmlPatterns module...
Generating the C++ source for the QtDesigner module...
Generating the .pro file for the QtDesigner module...
Generating the Makefile for the QtDesigner module...
Generating the C++ source for the _QOpenGLFunctions_2_0 ...
Generating the .pro file for the _QOpenGLFunctions_2_0 m...
Generating the Makefile for the _QOpenGLFunctions_2_0 mo...
Generating the C++ source for the QtSensors module...
Generating the .pro file for the QtSensors module...
Generating the Makefile for the QtSensors module...
Generating the C++ source for the QtSerialPort module...
Generating the .pro file for the QtSerialPort module...
Generating the Makefile for the QtSerialPort module...
Generating the C++ source for the QtBluetooth module...
Generating the .pro file for the QtBluetooth module...
Generating the Makefile for the QtBluetooth module...
Generating the C++ source for the QtMacExtras module...
Generating the .pro file for the QtMacExtras module...
Generating the Makefile for the QtMacExtras module...
Generating the C++ source for the QtPositioning module...
Generating the .pro file for the QtPositioning module...
Generating the Makefile for the QtPositioning module...
Generating the C++ source for the QtQuickWidgets module...
Generating the .pro file for the QtQuickWidgets module...
Generating the Makefile for the QtQuickWidgets module...
Generating the C++ source for the QtWebSockets module...
Generating the .pro file for the QtWebSockets module...
Generating the Makefile for the QtWebSockets module...
Generating the C++ source for the Enginio module...
Generating the .pro file for the Enginio module...
Generating the Makefile for the Enginio module...
Generating the C++ source for the Qt module...
Generating the .pro file for the Qt module...
Generating the Makefile for the Qt module...
Generating the .pro file for pylupdate5...
Generating the Makefile for pylupdate5...
Generating the .pro file for pyrcc5...
Generating the Makefile for pyrcc5...
Generating the pyuic5 wrapper...
Generating the Qt Designer plugin .pro file...
Generating the Qt Designer plugin Makefile...
Generating the qmlscene plugin .pro file...
Generating the qmlscene plugin Makefile...
Re-writing
/Users/otsuka/Downloads/Qt/PyQt-gpl-5.3.2/examples/quick...
Generating the top-level .pro file...
Making the pyuic5 wrapper executable...
Generating the top-level Makefile...
Satoshi-no-Mac-mini:PyQt-gpl-5.3.2 otsuka$
$ make
$ sudo make install
/System/Library/Frameworks/Python.framework/Versions/2.7/...
にインストールされます。
**PyQt examples の実行 [#i56072c3]
インストールが完了したので、PyQt のソースコードアーカイブ...
正常に動作するか確認します。~
以下のように PYTHONPATH を設定し、examples の qtdemo を実...
$ export set PYTHONPATH=$PYTHONPATH:/System/Library/Fram...
$ cd PyQt-gpl-5.3.2/examples/qtdemo
$ python qtdemo.py
以下のスクリーンショットのような GUI アプリケーションが起...
メニューから呼び出せる機能を実行できれば OK です。
#ref(pyqt_examples_gui.png)
** 更新履歴 [#j0d6560c]
2014/09/24 初稿公開 ~
RIGHT:Satoshi OTSUKA
終了行:
[[Python]]~
[[OS X]]
#contents
MacOS X Mavericks で PyQt を動作させる手順です。~
**PyQt とは [#fdc0f383]
PyQt は、クロスプラットフォームの GUI ツールキットである ...
Python で GUI プログラミングをするときの選択肢の一つです。~
(PyQt の他には PySide、PyGTK、wxPython、Tkinter などの P...
PyQt はイギリス Riverbank Computing によって開発されてお...
PyQt はクロスプラットフォームなツールキットであり、Window...
http://www.riverbankcomputing.com/software/pyqt/intro~
**インストール環境 [#v42fa969]
インストールを行ったマシンは Mac mini (Late 2012) で、~
~
MacOS X Maverikcs は 2014/09/24 時点で最新の更新である 10...
$ sw_vers
ProductName: Mac OS X
ProductVersion: 10.9.5
BuildVersion: 13F34
Xcode は 2014/09/24 時点で最新の更新である 6.0.1
$ xcode-select -p
/Applications/Xcode.app/Contents/Developer
$ xcodebuild -version
Xcode 6.0.1
Build version 6A317
です。
**Qt のインストール[#me852862]
まず Qt をインストールします。~
version は 2014/09/24 時点で最新の 5.3.2 です。~
最初は Qt Project のダウンロードページ~
http://qt-project.org/downloads~
から ~
Qt Online Installer for MacOS (qt-opensource-mac-x64-1.6....
をダウンロードしてインストールしましたが、~
10.9.5 への対応がまだ出来てないようで同梱の QtCreater が...
ソースコードからビルドしてインストールします。~
~
同ページ上で Show Downloads をクリックし、表示されるソー...
http://download.qt-project.org/official_releases/qt/5.3/5...
をダウンロードします。~
~
展開し、configure を実行します。config の option は defau...
$ tar xvf qt-everywhere-opensource-src-5.3.2.tar.gz
$ cd qt-everywhere-opensource-src-5.3.2
$ ./configure
+ cd qtbase
+ /Users/otsuka/Downloads/Qt/qt-everywhere-opensource-sr...
Which edition of Qt do you want to use ?
Type 'c' if you want to use the Commercial Edition.
Type 'o' if you want to use the Open Source Edition.
o
This is the Qt Open Source Edition.
You are licensed to use this software under the terms of
the Lesser GNU General Public License (LGPL) versions 2.1.
You are also licensed to use this software under the ter...
the GNU General Public License (GPL) versions 3.
Type '3' to view the GNU General Public License version 3.
Type 'L' to view the Lesser GNU General Public License v...
Type 'yes' to accept this license offer.
Type 'no' to decline this license offer.
Do you accept the terms of either license? yes
Creating qmake...
........ 以下略
script の選択肢に入力で回答し実行することで以下のような c...
Running configuration tests...
Configure summary
Build type: macx-clang (x86_64, CPU features: cx16 mm...
Build options:
Configuration .......... absolute_library_soname acces...
corewlan cups debug d...
large-config largefil...
qt_framework reduce_e...
Build parts ............ libs tools examples
Mode ................... debug and release; default li...
Using C++11 ............ yes
Using PCH .............. yes
Target compiler supports:
SSE2/SSE3/SSSE3 ...... yes/yes/yes
SSE4.1/SSE4.2 ........ yes/yes
AVX/AVX2 ............. yes/yes
Qt modules and options:
Qt D-Bus ............... no
Qt Concurrent .......... yes
Qt GUI ................. yes
Qt Widgets ............. yes
Large File ............. yes
QML debugging .......... yes
Use system proxies ..... no
Support enabled for:
Accessibility .......... yes
ALSA ................... no
CUPS ................... yes
Evdev .................. no
FontConfig ............. no
FreeType ............... yes (bundled copy)
Glib ................... no
GTK theme .............. no
HarfBuzz ............... yes
Iconv .................. yes
ICU .................... no
Image formats:
GIF .................. yes (plugin, using bundled co...
JPEG ................. yes (plugin, using bundled co...
PNG .................. yes (in QtGui, using bundled ...
journald ............... no
mtdev .................. no
Networking:
CoreWlan ............. yes
getaddrinfo .......... yes
getifaddrs ........... yes
IPv6 ifname .......... yes
OpenSSL .............. yes (loading libraries at run...
NIS .................... yes
OpenGL / OpenVG:
EGL .................. no
OpenGL ............... desktop
OpenVG ............... no
PCRE ................... yes (bundled copy)
pkg-config ............. yes
PulseAudio ............. no
QPA backends:
DirectFB ............. no
EGLFS ................ no
KMS .................. no
LinuxFB .............. no
XCB .................. no
Session management ..... yes
SQL drivers:
DB2 .................. no
InterBase ............ no
MySQL ................ no
OCI .................. no
ODBC ................. no
PostgreSQL ........... no
SQLite 2 ............. no
SQLite ............... yes (plugin, using bundled co...
TDS .................. no
udev ................... no
xkbcommon .............. no
zlib ................... yes (system library)
Info: creating super cache file /Users/otsuka/Downloads/...
Info: creating stash file /Users/otsuka/Downloads/Qt/qt-...
Qt is now configured for building. Just run 'make'.
Once everything is built, you must run 'make install'.
Qt will be installed into /usr/local/Qt-5.3.2
Prior to reconfiguration, make sure you remove any lefto...
the previous build.
ビルドしインストールします。(ビルドには Mac mini で数時...
$ make
$ sudo make install
config option の表示にあったように /usr/local/Qt-5.3.2 へ...
** SIP のインストール[#kf19bd50]
PyQt をインストールするためには、PyQt の開発元 Riverbank ...
SIP は C/C++ で書かれた Python 用拡張ライブラリの作成を容...
version は 2014/09/24 時点で最新の 4.16.3 です。~
~
SIP のダウンロードページ~
http://www.riverbankcomputing.com/software/sip/download~
から~
http://sourceforge.net/projects/pyqt/files/sip/sip-4.16.3...
をダウンロードします。~
展開して configure を行い、ビルドしてインストールします。~
$ tar xvf sip-4.16.3.tar.gz
$ cd sip-4.16.3
$ python configure.py
This is SIP 4.16.3 for Python 2.7.5 on darwin.
The SIP code generator will be installed in
/System/Library/Frameworks/Python.framework/Versions/2.7...
The sip module will be installed in /Library/Python/2.7/...
The sip.h header file will be installed in
/System/Library/Frameworks/Python.framework/Versions/2.7...
The default directory to install .sip files in is
/System/Library/Frameworks/Python.framework/Versions/2.7...
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...
$ make
$ sudo make install
configure で表示された PATH にインストールされます。~
PyQt のインストール時に必要になるので、 sip コマンドのイ...
** PyQt のインストール [#vf9a7aa3]
上記の手順で必要なものがインストールされたので PyQt をイ...
Version は 2014/09/24 時点で最新の 5.3.2 です。~
(対応する Qt と version を同じに揃えられているようです。...
PyQt5 のダウンロードページ~
http://www.riverbankcomputing.com/software/pyqt/download5~
から~
http://sourceforge.net/projects/pyqt/files/PyQt5/PyQt-5.3...
をダウンロードします。
$ tar xvf PyQt-gpl-5.3.2.tar.gz
$ cd PyQt-gpl-5.3.2
ソースコードアーカイブを展開したら、configure を実行する...
(修正を加えないまま configure を実行してビルドすると、We...
$ diff -u configure.py.orig configure.py
--- configure.py.orig 2014-09-24 16:32:32.000000000 +0900
+++ configure.py 2014-09-24 16:32:49.000000000 +0900
@@ -87,7 +87,7 @@
'QtSvg': ModuleMetadata(qmake_QT=['s...
'QtTest': ModuleMetadata(qmake_QT=['t...
'QtWebKit': ModuleMetadata(qmake_QT=['w...
- 'QtWebKitWidgets': ModuleMetadata(qmake_QT=['w...
+ 'QtWebKitWidgets': ModuleMetadata(qmake_QT=['w...
'QtWebSockets': ModuleMetadata(qmake_QT=['w...
'QtWidgets': ModuleMetadata(qmake_QT=['w...
'QtWinExtras': ModuleMetadata(qmake_QT=['w...
修正を加えたら、以下のオプションで configure を実行し、ビ...
$ python configure.py --sip=/System/Library/Frameworks/P...
Querying qmake about your Qt installation...
Determining the details of your Qt installation...
This is the GPL version of PyQt 5.3.2 (licensed under th...
Type 'L' to view the license.
Type 'yes' to accept the terms of the license.
Type 'no' to decline the terms of the license.
Do you accept the terms of the license? yes
Found the license file pyqt-gpl.sip.
Checking to see if the QtGui module should be built...
Checking to see if the QtHelp module should be built...
Checking to see if the QtMultimedia module should be bui...
Checking to see if the QtMultimediaWidgets module should...
Checking to see if the QtNetwork module should be built...
Checking to see if the QtOpenGL module should be built...
Checking to see if the QtPrintSupport module should be b...
Checking to see if the QtQml module should be built...
Checking to see if the QtQuick module should be built...
Checking to see if the QtSql module should be built...
Checking to see if the QtSvg module should be built...
Checking to see if the QtTest module should be built...
Checking to see if the QtWebKit module should be built...
Checking to see if the QtWebKitWidgets module should be ...
Checking to see if the QtWidgets module should be built...
Checking to see if the QtXmlPatterns module should be bu...
Checking to see if the QtDesigner module should be built...
Checking to see if the QAxContainer module should be bui...
Checking to see if the QtDBus module should be built...
Checking to see if the dbus support module should be bui...
DBus v1 does not seem to be installed.
Checking to see if the _QOpenGLFunctions_2_0 module shou...
Checking to see if the QtSensors module should be built...
Checking to see if the QtSerialPort module should be bui...
Checking to see if the QtX11Extras module should be buil...
Checking to see if the QtBluetooth module should be buil...
Checking to see if the QtMacExtras module should be buil...
Checking to see if the QtPositioning module should be bu...
Checking to see if the QtWinExtras module should be buil...
Checking to see if the QtQuickWidgets module should be b...
Checking to see if the QtWebSockets module should be bui...
Checking to see if the Enginio module should be built...
Qt v5.3.2 (Open Source) is being used.
The qmake executable is /usr/local/Qt-5.3.2/bin/qmake.
Qt is built as a shared library.
SIP 4.16.3 is being used.
The sip executable is
/System/Library/Frameworks/Python.framework/Versions/2.7...
These PyQt5 modules will be built: QtCore, QtGui, QtHelp...
QtMultimediaWidgets, QtNetwork, QtOpenGL, QtPrintSupport...
QtSql, QtSvg, QtTest, QtWebKit, QtWebKitWidgets, QtWidge...
QtDesigner, _QOpenGLFunctions_2_0, QtSensors, QtSerialPo...
QtMacExtras, QtPositioning, QtQuickWidgets, QtWebSockets...
The PyQt5 Python package will be installed in
/System/Library/Frameworks/Python.framework/Versions/2.7...
PyQt5 is being built with generated docstrings.
PyQt5 is being built with 'protected' redefined as 'publ...
The Designer plugin will be installed in /usr/local/Qt-5...
The qmlscene plugin will be installed in /usr/local/Qt-5...
The PyQt5 .sip files will be installed in
/System/Library/Frameworks/Python.framework/Versions/2.7...
pyuic5, pyrcc5 and pylupdate5 will be installed in
/System/Library/Frameworks/Python.framework/Versions/2.7...
The interpreter used by pyuic5 is pythonw2.7.
Generating the C++ source for the QtCore module...
Embedding sip flags...
Generating the .pro file for the QtCore module...
Generating the Makefile for the QtCore module...
Generating the C++ source for the QtGui module...
Generating the .pro file for the QtGui module...
Generating the Makefile for the QtGui module...
Generating the C++ source for the QtHelp module...
Generating the .pro file for the QtHelp module...
Generating the Makefile for the QtHelp module...
Generating the C++ source for the QtMultimedia module...
Generating the .pro file for the QtMultimedia module...
Generating the Makefile for the QtMultimedia module...
Generating the C++ source for the QtMultimediaWidgets mo...
Generating the .pro file for the QtMultimediaWidgets mod...
Generating the Makefile for the QtMultimediaWidgets modu...
Generating the C++ source for the QtNetwork module...
Generating the .pro file for the QtNetwork module...
Generating the Makefile for the QtNetwork module...
Generating the C++ source for the QtOpenGL module...
Generating the .pro file for the QtOpenGL module...
Generating the Makefile for the QtOpenGL module...
Generating the C++ source for the QtPrintSupport module...
Generating the .pro file for the QtPrintSupport module...
Generating the Makefile for the QtPrintSupport module...
Generating the C++ source for the QtQml module...
Generating the .pro file for the QtQml module...
Generating the Makefile for the QtQml module...
Generating the C++ source for the QtQuick module...
Generating the .pro file for the QtQuick module...
Generating the Makefile for the QtQuick module...
Generating the C++ source for the QtSql module...
Generating the .pro file for the QtSql module...
Generating the Makefile for the QtSql module...
Generating the C++ source for the QtSvg module...
Generating the .pro file for the QtSvg module...
Generating the Makefile for the QtSvg module...
Generating the C++ source for the QtTest module...
Generating the .pro file for the QtTest module...
Generating the Makefile for the QtTest module...
Generating the C++ source for the QtWebKit module...
Generating the .pro file for the QtWebKit module...
Generating the Makefile for the QtWebKit module...
Generating the C++ source for the QtWebKitWidgets module...
Generating the .pro file for the QtWebKitWidgets module...
Generating the Makefile for the QtWebKitWidgets module...
Generating the C++ source for the QtWidgets module...
Generating the .pro file for the QtWidgets module...
Generating the Makefile for the QtWidgets module...
Generating the C++ source for the QtXmlPatterns module...
Generating the .pro file for the QtXmlPatterns module...
Generating the Makefile for the QtXmlPatterns module...
Generating the C++ source for the QtDesigner module...
Generating the .pro file for the QtDesigner module...
Generating the Makefile for the QtDesigner module...
Generating the C++ source for the _QOpenGLFunctions_2_0 ...
Generating the .pro file for the _QOpenGLFunctions_2_0 m...
Generating the Makefile for the _QOpenGLFunctions_2_0 mo...
Generating the C++ source for the QtSensors module...
Generating the .pro file for the QtSensors module...
Generating the Makefile for the QtSensors module...
Generating the C++ source for the QtSerialPort module...
Generating the .pro file for the QtSerialPort module...
Generating the Makefile for the QtSerialPort module...
Generating the C++ source for the QtBluetooth module...
Generating the .pro file for the QtBluetooth module...
Generating the Makefile for the QtBluetooth module...
Generating the C++ source for the QtMacExtras module...
Generating the .pro file for the QtMacExtras module...
Generating the Makefile for the QtMacExtras module...
Generating the C++ source for the QtPositioning module...
Generating the .pro file for the QtPositioning module...
Generating the Makefile for the QtPositioning module...
Generating the C++ source for the QtQuickWidgets module...
Generating the .pro file for the QtQuickWidgets module...
Generating the Makefile for the QtQuickWidgets module...
Generating the C++ source for the QtWebSockets module...
Generating the .pro file for the QtWebSockets module...
Generating the Makefile for the QtWebSockets module...
Generating the C++ source for the Enginio module...
Generating the .pro file for the Enginio module...
Generating the Makefile for the Enginio module...
Generating the C++ source for the Qt module...
Generating the .pro file for the Qt module...
Generating the Makefile for the Qt module...
Generating the .pro file for pylupdate5...
Generating the Makefile for pylupdate5...
Generating the .pro file for pyrcc5...
Generating the Makefile for pyrcc5...
Generating the pyuic5 wrapper...
Generating the Qt Designer plugin .pro file...
Generating the Qt Designer plugin Makefile...
Generating the qmlscene plugin .pro file...
Generating the qmlscene plugin Makefile...
Re-writing
/Users/otsuka/Downloads/Qt/PyQt-gpl-5.3.2/examples/quick...
Generating the top-level .pro file...
Making the pyuic5 wrapper executable...
Generating the top-level Makefile...
Satoshi-no-Mac-mini:PyQt-gpl-5.3.2 otsuka$
$ make
$ sudo make install
/System/Library/Frameworks/Python.framework/Versions/2.7/...
にインストールされます。
**PyQt examples の実行 [#i56072c3]
インストールが完了したので、PyQt のソースコードアーカイブ...
正常に動作するか確認します。~
以下のように PYTHONPATH を設定し、examples の qtdemo を実...
$ export set PYTHONPATH=$PYTHONPATH:/System/Library/Fram...
$ cd PyQt-gpl-5.3.2/examples/qtdemo
$ python qtdemo.py
以下のスクリーンショットのような GUI アプリケーションが起...
メニューから呼び出せる機能を実行できれば OK です。
#ref(pyqt_examples_gui.png)
** 更新履歴 [#j0d6560c]
2014/09/24 初稿公開 ~
RIGHT:Satoshi OTSUKA
ページ名:
BC::labsへの質問は、bc9-dev @ googlegroups.com までお願い致します。