Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    text
    copied!<p>Expanding on Aaron Digulla's answer, using git to get the file list right can be really handy. I usually do something like this (from an msysGit shell):</p> <pre><code># Create temp git repo for the pristine Python installation $ cd /c/Python27 $ git init -q $ git add . $ git commit -qm "Initial commit" </code></pre> <p>Then run the installer for PyQt4 (or whatever). After that, make a tarball of the files that the installer added and delete the temp git repo, as follows:</p> <pre><code># Stage the PyQt4-installed files and feed a list of their names to tar # (note that there's no need to actually commit them) $ git add --all $ git diff --cached --name-only | tar -jcf pyqt4.tar.bz2 --files-from=- $ rm -rf .git </code></pre> <p>Then you can run PyQt4's uninstaller (if you don't want to clutter up your system Python), and simply untar <code>pyqt4.tar.bz2</code> into your virtualenv folder. If you're already comfortable using git, this is a great way to ensure you get <em>all</em> the PyQt4-installed files.</p> <p><strong>NOTE</strong>: Installing PyQt4 using the packaged installer also installs SIP. If you actually want to <em>use</em> this SIP to create bindings for your own C/C++ code inside your virtualenv, you'll want to modify the paths in the <code>sipconfig.py</code> file after you copy it over. Otherwise, SIP's build system will still be pointing at the system Python folder (e.g., <code>C:\Python32</code> or whatever), which won't work if you delete all the PyQt4-installed files from there. (If you don't have any intention of using SIP yourself, you can probably skip this.)</p>
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload