2010-03-26 20:14:51 +00:00
|
|
|
Instructions for building the Win32 installer
|
|
|
|
---------------------------------------------
|
|
|
|
|
|
|
|
Dependencies:
|
2011-12-15 17:00:41 +00:00
|
|
|
- Deluge build: http://dev.deluge-torrent.org/wiki/Installing/Source
|
|
|
|
- Bbfreeze: http://pypi.python.org/pypi/bbfreeze
|
|
|
|
- StartX: http://www.naughter.com/startx.html
|
|
|
|
- NSIS: http://nsis.sourceforge.net/Main_Page
|
2010-03-26 20:14:51 +00:00
|
|
|
|
2011-12-15 17:00:41 +00:00
|
|
|
The assumption in the following is that Python 2.6 is installed in C:\Python26.
|
|
|
|
The GTK+ runtime libraries are installed separately (anywhere, in the Windows PATH).
|
2010-03-26 20:14:51 +00:00
|
|
|
|
2011-12-15 17:00:41 +00:00
|
|
|
1) Build Deluge on Windows
|
2010-03-26 20:14:51 +00:00
|
|
|
|
2011-12-15 17:00:41 +00:00
|
|
|
2) Use a slightly hacked bbfreeze to create a standalone "executable" which does not need the the Python libs
|
2010-03-26 20:14:51 +00:00
|
|
|
|
2012-04-18 12:15:52 +00:00
|
|
|
The modification is to add these lines to:
|
2010-03-26 20:14:51 +00:00
|
|
|
|
2012-04-18 12:15:52 +00:00
|
|
|
C:\Python26\Lib\site-packages\bbfreeze-0.96.5-py2.6-win32.egg\bbfreeze\recipes.py
|
2010-03-26 20:14:51 +00:00
|
|
|
|
2012-04-18 12:15:52 +00:00
|
|
|
Right at the top of the Python function 'recipe_gtk_and_friends':
|
|
|
|
return True
|
2010-03-26 20:14:51 +00:00
|
|
|
|
2012-04-18 12:15:52 +00:00
|
|
|
We want to include all the gtk libraries in the installer so that users don't
|
|
|
|
require a separate GTK+ installation.
|
2010-03-26 20:14:51 +00:00
|
|
|
|
2011-12-15 17:00:41 +00:00
|
|
|
3) Edit the 'build_version' variable in the Python script:
|
2010-03-26 20:14:51 +00:00
|
|
|
|
2011-12-15 17:00:41 +00:00
|
|
|
win32/build-bbfreeze.py
|
2010-03-26 20:14:51 +00:00
|
|
|
|
2011-12-15 17:00:41 +00:00
|
|
|
and run the script from the win32 directory:
|
2012-04-18 12:15:52 +00:00
|
|
|
|
2011-12-15 17:00:41 +00:00
|
|
|
python build-bbfreeze.py
|
2012-04-18 12:15:52 +00:00
|
|
|
|
2011-12-15 17:00:41 +00:00
|
|
|
The script places the bbfreeze'd version of deluge in
|
2010-03-26 20:14:51 +00:00
|
|
|
|
2011-12-15 17:00:41 +00:00
|
|
|
build-win32/deluge-bbfreeze-build_version
|
2010-03-26 20:14:51 +00:00
|
|
|
|
2011-12-15 17:00:41 +00:00
|
|
|
Note: the build-bbfreeze.py script assumes that Python 2.6 is installed in C:\Python26,
|
|
|
|
otherwise the 'python_path' variable should be changed.
|
2010-03-26 20:14:51 +00:00
|
|
|
|
|
|
|
|
2011-12-15 17:00:41 +00:00
|
|
|
4) Edit the variable 'PROGRAM_VERSION' in the NSIS script
|
2010-03-26 20:14:51 +00:00
|
|
|
|
2011-12-15 17:00:41 +00:00
|
|
|
win32/deluge-win32-installer.nsi
|
2010-03-26 20:14:51 +00:00
|
|
|
|
2011-12-15 17:00:41 +00:00
|
|
|
and run the NSIS script.
|
2010-03-26 20:14:51 +00:00
|
|
|
|
2012-04-18 12:15:52 +00:00
|
|
|
The result is a standalone installer. The only dependency for the installer is the GTK+ runtime,
|
2011-12-15 17:00:41 +00:00
|
|
|
which is downloaded by the Deluge installer if it isn't installed in the system.
|
2010-03-26 20:14:51 +00:00
|
|
|
|
2011-12-15 17:00:41 +00:00
|
|
|
The GTK+ installer is downloaded from http://download.deluge-torrent.org/windows/deps/
|
|
|
|
and placed in the user temp directory (not deleted after installation).
|
2010-03-26 20:14:51 +00:00
|
|
|
|
2012-04-18 12:15:52 +00:00
|
|
|
The post install script creates the deluge.cmd file using startX.exe with the correct path
|
2011-12-15 17:00:41 +00:00
|
|
|
and sets up the file association for .torrent.
|
2010-03-26 20:14:51 +00:00
|
|
|
|
|
|
|
|
2011-12-15 17:00:41 +00:00
|
|
|
5) The Uninstaller will remove everything from the installation directory. Also the file
|
|
|
|
association for '.torrent' will be removed but only if it's associated with Deluge
|
2010-03-26 20:14:51 +00:00
|
|
|
|