diff options
| author | Tim D. Smith | 2014-11-02 00:45:33 -0700 |
|---|---|---|
| committer | Tim D. Smith | 2014-11-02 07:39:04 -0800 |
| commit | 745e4aee29057c3c737f42e76bfb4abd64b90091 (patch) | |
| tree | 04f38b86afd242104b048c23fafd8d7aec49db82 | |
| parent | 2b70fa3fd942ea6d4ac67e59ede84687c06a62d1 (diff) | |
| download | homebrew-745e4aee29057c3c737f42e76bfb4abd64b90091.tar.bz2 | |
pypy3: build cffi extensions in lib_pypy
Fixes a problem reported on IRC where these modules can't be imported by
a different user than the user that installed Homebrew because building
the cffi extensions writes files to the Cellar. Pypy's packaging script
normally generates these but it isn't invoked by Homebrew.
Closes #33813.
| -rw-r--r-- | Library/Formula/pypy3.rb | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/Library/Formula/pypy3.rb b/Library/Formula/pypy3.rb index a4fa14052..a0321d40b 100644 --- a/Library/Formula/pypy3.rb +++ b/Library/Formula/pypy3.rb @@ -58,6 +58,12 @@ class Pypy3 < Formula end def post_install + # Precompile cffi extensions in lib_pypy + # list from create_cffi_import_libraries in pypy/tool/release/package.py + %w[_sqlite3 _curses syslog gdbm _tkinter].each do |module_name| + quiet_system bin/"pypy3", "-c", "import #{module_name}" + end + # Post-install, fix up the site-packages and install-scripts folders # so that user-installed Python software survives minor updates, such # as going from 1.7.0 to 1.7.1. |
