Pyinstaller挂起添加重定向Microsoft.VC90.MFC

时间:2016-11-02 13:05:30

标签: python pyqt pyinstaller

我正在尝试使用Pyinstaller将python脚本编译为独立应用程序。问题是执行操作时进程挂起:

  

添加重定向Microsoft.VC90.MFC

这是完整的输出。我通过Conda在Windows下运行python 2.7。

C:\Users\Jesucristo\Desktop\qt_compiled\pyqt4>pyinstaller --onefile --windowed
interactiveMPL_app.py
279 INFO: PyInstaller: 3.2
279 INFO: Python: 2.7.12
280 INFO: Platform: Windows-7-6.1.7601-SP1
282 INFO: wrote C:\Users\Jesucristo\Desktop\qt_compiled\pyqt4\interactiveMPL_app
.spec
287 INFO: UPX is not available.
292 INFO: Extending PYTHONPATH with paths
['C:\\Users\\Jesucristo\\Desktop\\qt_compiled\\pyqt4',
 'C:\\Users\\Jesucristo\\Desktop\\qt_compiled\\pyqt4']
292 INFO: checking Analysis
292 INFO: Building Analysis because out00-Analysis.toc is non existent
292 INFO: Initializing module dependency graph...
298 INFO: Initializing module graph hooks...
371 INFO: running Analysis out00-Analysis.toc
378 INFO: Adding Microsoft.VC90.CRT to dependent assemblies of final executable
  required by c:\users\jesucristo\miniconda2\python.exe
536 INFO: Found C:\Windows\WinSxS\Manifests\amd64_policy.9.0.microsoft.vc90.crt_
1fc8b3b9a1e18e3b_9.0.21022.8_none_18f8a87fd1919cd9.manifest
539 INFO: Found C:\Windows\WinSxS\Manifests\amd64_policy.9.0.microsoft.vc90.crt_
1fc8b3b9a1e18e3b_9.0.30729.1_none_3da38fdebd0e6822.manifest
540 INFO: Found C:\Windows\WinSxS\Manifests\amd64_policy.9.0.microsoft.vc90.crt_
1fc8b3b9a1e18e3b_9.0.30729.4148_none_acd0e4ffe1daef0a.manifest
542 INFO: Found C:\Windows\WinSxS\Manifests\amd64_policy.9.0.microsoft.vc90.crt_
1fc8b3b9a1e18e3b_9.0.30729.4940_none_acd19a1fe1da248a.manifest
542 INFO: Found C:\Windows\WinSxS\Manifests\amd64_policy.9.0.microsoft.vc90.crt_
1fc8b3b9a1e18e3b_9.0.30729.6161_none_acd388d7e1d8689f.manifest
694 INFO: Searching for assembly amd64_Microsoft.VC90.CRT_1fc8b3b9a1e18e3b_9.0.3
0729.6161_none ...
696 INFO: Found manifest C:\Windows\WinSxS\Manifests\amd64_microsoft.vc90.crt_1f
c8b3b9a1e18e3b_9.0.30729.6161_none_08e61857a83bc251.manifest
698 INFO: Searching for file msvcr90.dll
698 INFO: Found file C:\Windows\WinSxS\amd64_microsoft.vc90.crt_1fc8b3b9a1e18e3b
_9.0.30729.6161_none_08e61857a83bc251\msvcr90.dll
700 INFO: Searching for file msvcp90.dll
700 INFO: Found file C:\Windows\WinSxS\amd64_microsoft.vc90.crt_1fc8b3b9a1e18e3b
_9.0.30729.6161_none_08e61857a83bc251\msvcp90.dll
700 INFO: Searching for file msvcm90.dll
700 INFO: Found file C:\Windows\WinSxS\amd64_microsoft.vc90.crt_1fc8b3b9a1e18e3b
_9.0.30729.6161_none_08e61857a83bc251\msvcm90.dll
846 INFO: Found C:\Windows\WinSxS\Manifests\amd64_policy.9.0.microsoft.vc90.crt_
1fc8b3b9a1e18e3b_9.0.21022.8_none_18f8a87fd1919cd9.manifest
851 INFO: Found C:\Windows\WinSxS\Manifests\amd64_policy.9.0.microsoft.vc90.crt_
1fc8b3b9a1e18e3b_9.0.30729.1_none_3da38fdebd0e6822.manifest
852 INFO: Found C:\Windows\WinSxS\Manifests\amd64_policy.9.0.microsoft.vc90.crt_
1fc8b3b9a1e18e3b_9.0.30729.4148_none_acd0e4ffe1daef0a.manifest
854 INFO: Found C:\Windows\WinSxS\Manifests\amd64_policy.9.0.microsoft.vc90.crt_
1fc8b3b9a1e18e3b_9.0.30729.4940_none_acd19a1fe1da248a.manifest
855 INFO: Found C:\Windows\WinSxS\Manifests\amd64_policy.9.0.microsoft.vc90.crt_
1fc8b3b9a1e18e3b_9.0.30729.6161_none_acd388d7e1d8689f.manifest
858 INFO: Adding redirect Microsoft.VC90.CRT version (9, 0, 21022, 8) -> (9, 0,
30729, 6161)
7844 INFO: Caching module hooks...
7851 INFO: Analyzing C:\Users\Jesucristo\Desktop\qt_compiled\pyqt4\interactiveMP
L_app.py
9783 INFO: Processing pre-find module path hook   distutils
16548 INFO: Processing pre-safe import module hook   _xmlplus
16782 INFO: Processing pre-safe import module hook   win32com
17786 INFO: Processing pre-find module path hook   site
17803 INFO: site: retargeting to fake-dir 'C:\\Users\\Jesucristo\\Miniconda2\\Li
b\\site-packages\\PyInstaller\\fake-modules'
20504 INFO: Processing pre-safe import module hook   six.moves
27915 INFO: Processing pre-find module path hook   PyQt5.uic.port_v3
27944 INFO: Processing pre-find module path hook   PyQt5.uic.port_v2
28759 INFO: Loading module hooks...
28760 INFO: Loading module hook "hook-distutils.py"...
28782 INFO: Loading module hook "hook-sysconfig.py"...
28799 INFO: Loading module hook "hook-xml.py"...
28800 INFO: Loading module hook "hook-scipy.sparse.csgraph.py"...
28808 INFO: Loading module hook "hook-PyQt5.QtWidgets.py"...
28810 INFO: Loading module hook "hook-httplib.py"...
28812 INFO: Loading module hook "hook-pydoc.py"...
28839 INFO: Excluding import 'Tkinter'
28844 WARNING:   Removing import pydoc from module Tkinter
28845 INFO: Loading module hook "hook-PyQt5.uic.py"...
28871 INFO: Loading module hook "hook-PyQt5.py"...
28894 INFO: Loading module hook "hook-_tkinter.py"...
30312 INFO: checking Tree
30312 INFO: Building Tree because out00-Tree.toc is non existent
30313 INFO: Building Tree out00-Tree.toc
30986 INFO: checking Tree
30986 INFO: Building Tree because out01-Tree.toc is non existent
30986 INFO: Building Tree out01-Tree.toc
31052 INFO: Loading module hook "hook-matplotlib.backends.py"...
32211 INFO:   Matplotlib backend "GTK": ignored
    Gtk* backend requires pygtk to be installed.
33210 INFO:   Matplotlib backend "GTKAgg": ignored
    Gtk* backend requires pygtk to be installed.
33825 INFO:   Matplotlib backend "GTKCairo": ignored
    No module named gtk
34648 INFO:   Matplotlib backend "MacOSX": ignored
    cannot import name _macosx
35618 INFO:   Matplotlib backend "Qt4Agg": added
36565 INFO:   Matplotlib backend "Qt5Agg": added
37374 INFO:   Matplotlib backend "TkAgg": added
38253 INFO:   Matplotlib backend "WX": ignored
    Matplotlib backend_wx and backend_wxagg require wxPython >=2.8.12
39164 INFO:   Matplotlib backend "WXAgg": ignored
    Matplotlib backend_wx and backend_wxagg require wxPython >=2.8.12
39776 INFO:   Matplotlib backend "GTK3Cairo": ignored
    Gtk3 backend requires pygobject to be installed.
40595 INFO:   Matplotlib backend "GTK3Agg": ignored
    Gtk3 backend requires pygobject to be installed.
41157 INFO:   Matplotlib backend "WebAgg": ignored
    Traceback (most recent call last):
  File "<string>", line 12, in <module>
  File "C:\Users\Jesucristo\Miniconda2\Lib\site-packages\matplotlib\backends\bac
kend_webagg.py", line 30, in <module>
    raise RuntimeError("The WebAgg backend requires Tornado.")
RuntimeError: The WebAgg backend requires Tornado.
41739 INFO:   Matplotlib backend "nbAgg": ignored
    No module named tornado.ioloop
42617 INFO:   Matplotlib backend "agg": added
43181 INFO:   Matplotlib backend "cairo": ignored
    Cairo backend requires that cairocffi or pycairo is installed.
43736 INFO:   Matplotlib backend "emf": ignored
    No module named backend_emf
44356 INFO:   Matplotlib backend "gdk": ignored
    No module named gobject
45220 INFO:   Matplotlib backend "pdf": added
46431 INFO:   Matplotlib backend "pgf": added
47300 INFO:   Matplotlib backend "ps": added
48193 INFO:   Matplotlib backend "svg": added
49128 INFO:   Matplotlib backend "template": added
49469 INFO: Loading module hook "hook-matplotlib.py"...
50112 INFO: Loading module hook "hook-pkg_resources.py"...
50115 INFO: Loading module hook "hook-scipy.linalg.py"...
50118 INFO: Loading module hook "hook-PyQt5.QtCore.py"...
50254 INFO: Loading module hook "hook-PyQt5.QtGui.py"...
51132 INFO: Loading module hook "hook-pytz.py"...
51417 INFO: Loading module hook "hook-pywintypes.py"...
51724 INFO: Loading module hook "hook-setuptools.py"...
51743 INFO: Loading module hook "hook-scipy.special._ellip_harm_2.py"...
52835 INFO: Loading module hook "hook-PyQt5.Qt.py"...
52851 INFO: Loading module hook "hook-encodings.py"...
53598 INFO: Loading module hook "hook-scipy.special._ufuncs.py"...
53618 INFO: Loading module hook "hook-win32com.py"...
53787 INFO: Loading module hook "hook-pythoncom.py"...
54121 INFO: Loading module hook "hook-PyQt5.QtPrintSupport.py"...
54401 INFO: Looking for ctypes DLLs
54447 INFO: Analyzing run-time hooks ...
54470 INFO: Including run-time hook 'pyi_rth_pkgres.py'
54476 INFO: Including run-time hook 'pyi_rth_win32comgenpy.py'
54479 INFO: Including run-time hook 'pyi_rth_qt5.py'
54480 INFO: Including run-time hook 'pyi_rth_qt5plugins.py'
54483 INFO: Including run-time hook 'pyi_rth_mplconfig.py'
54484 INFO: Including run-time hook 'pyi_rth_mpldata.py'
54529 INFO: Looking for dynamic libraries
150553 INFO: Found C:\Windows\WinSxS\Manifests\amd64_policy.9.0.microsoft.vc90.m
fc_1fc8b3b9a1e18e3b_9.0.30729.1_none_3624aa14c1dce505.manifest
150571 INFO: Found C:\Windows\WinSxS\Manifests\amd64_policy.9.0.microsoft.vc90.m
fc_1fc8b3b9a1e18e3b_9.0.30729.4148_none_a551ff35e6a96bed.manifest
150572 INFO: Found C:\Windows\WinSxS\Manifests\amd64_policy.9.0.microsoft.vc90.m
fc_1fc8b3b9a1e18e3b_9.0.30729.6161_none_a554a30de6a6e582.manifest
150723 INFO: Searching for assembly amd64_Microsoft.VC90.MFC_1fc8b3b9a1e18e3b_9.
0.30729.6161_none ...
150724 INFO: Found manifest C:\Windows\WinSxS\Manifests\amd64_microsoft.vc90.mfc
_1fc8b3b9a1e18e3b_9.0.30729.6161_none_044aad0bab1eb146.manifest
150727 INFO: Searching for file mfc90.dll
150727 INFO: Found file C:\Windows\WinSxS\amd64_microsoft.vc90.mfc_1fc8b3b9a1e18
e3b_9.0.30729.6161_none_044aad0bab1eb146\mfc90.dll
150729 INFO: Searching for file mfc90u.dll
150729 INFO: Found file C:\Windows\WinSxS\amd64_microsoft.vc90.mfc_1fc8b3b9a1e18
e3b_9.0.30729.6161_none_044aad0bab1eb146\mfc90u.dll
150730 INFO: Searching for file mfcm90.dll
150730 INFO: Found file C:\Windows\WinSxS\amd64_microsoft.vc90.mfc_1fc8b3b9a1e18
e3b_9.0.30729.6161_none_044aad0bab1eb146\mfcm90.dll
150730 INFO: Searching for file mfcm90u.dll
150730 INFO: Found file C:\Windows\WinSxS\amd64_microsoft.vc90.mfc_1fc8b3b9a1e18
e3b_9.0.30729.6161_none_044aad0bab1eb146\mfcm90u.dll
150879 INFO: Found C:\Windows\WinSxS\Manifests\amd64_policy.9.0.microsoft.vc90.m
fc_1fc8b3b9a1e18e3b_9.0.30729.1_none_3624aa14c1dce505.manifest
150881 INFO: Found C:\Windows\WinSxS\Manifests\amd64_policy.9.0.microsoft.vc90.m
fc_1fc8b3b9a1e18e3b_9.0.30729.4148_none_a551ff35e6a96bed.manifest
150882 INFO: Found C:\Windows\WinSxS\Manifests\amd64_policy.9.0.microsoft.vc90.m
fc_1fc8b3b9a1e18e3b_9.0.30729.6161_none_a554a30de6a6e582.manifest
150884 INFO: Adding redirect Microsoft.VC90.MFC version (9, 0, 21022, 8) -> (9,
0, 30729, 6161)

1 个答案:

答案 0 :(得分:3)

将pyinstaller v3.2降级到v3.1对我有用。尝试pip install -Iv pyinstaller == 3.1然后再次构建你的.exe