LoginSignup
4
4

More than 5 years have passed since last update.

pyinstallerとHomebrewは共存しないで。。。

Last updated at Posted at 2016-06-10

何時からか分かりませんがpyinstallerでMacOSのアプリを作って駆動して見ると

”Crash”
が発生してメモリ問題みたいなログが上がってしまいました。

Process:               test-gui [3465]
Path:                  /Users/USER/Documents/*/test-gui.app/Contents/MacOS/test-gui
Identifier:            test-gui
Version:               0.0.0 (???)
Code Type:             X86-64 (Native)
Parent Process:        test-gui [3463]
Responsible:           test-gui [3463]
User ID:               501

Date/Time:             2015-09-07 17:40:28.796 +1000
OS Version:            Mac OS X 10.10.5 (14F27)
Report Version:        11
Anonymous UUID:        7267BA3C-1EDF-8AD3-E3CD-905E8385C51C


Time Awake Since Boot: 310 seconds

Crashed Thread:        0  Dispatch queue: com.apple.main-thread

Exception Type:        EXC_CRASH (SIGABRT)
Exception Codes:       0x0000000000000000, 0x0000000000000000

Application Specific Information:
abort() called

Thread 0 Crashed:: Dispatch queue: com.apple.main-thread
0   libsystem_kernel.dylib          0x00007fff91dd1286 __pthread_kill + 10
1   libsystem_c.dylib               0x00007fff87c529b3 abort + 129
2   libtcl8.6.dylib                 0x0000000106288633 Tcl_PanicVA + 428
3   libtcl8.6.dylib                 0x00000001062886c7 Tcl_Panic + 148
4   libtcl8.6.dylib                 0x00000001061d5dc1 DeleteInterpProc + 53
5   libtk8.6.dylib                  0x000000010609205a Tk_CreateConsoleWindow + 936
6   libtk8.6.dylib                  0x000000010613d73b TkpInit + 979
... (中略)

最初にはこれがwxPythonのバージョン・アップ問題かと思いました。結果的に一部は正しいでした。 HomeBrewを通じてinstallしたwxPythonが原因でした。

グーグル神様に熱心に問いましたが効果的な答えはありませんでした。wxPythonの再installのみ繰り返すだけ。

ですけどこの間、もう一度グーグル様に問いましたが「brewの問題」というのが書いているサイトを見つけました。

I had the same issue - my setup was python3 and pyqt4, both installed via brew. First I completely removed brew:

cd `brew --prefix`
rm -rf Cellar
brew prune
rm -rf Library .git .gitignore bin/brew README.md share/man/man1/brew
rm -rf ~/Library/Caches/Homebrew

- See more at: http://www.qhmfx.com/article/cgiaicgf-pyqt4-py2app-and-pyinstaller-crash-when-moving-app-to-another-machine.html#sthash.AZGiyyID.dpuf

それでHomebrewをuninstallしてみました。上のようにしてもいいし、スクリプトを提供するサイトもあります。
/usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/uninstall)"

それでbrew+wxPythonを一気に削除され、brewを通じなくてwxPythonをinstallしてpyinstallerを駆動しました。

結果はSucceeded~

MacOSで公式にHomeBrewを支援しない理由を分かるようになりました。

4
4
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
4
4