Version 10 (modified by rb07, 13 years ago) (diff)

Update to version 1.83

Building Transmission Qt for Windows

The following procedure in not the only one possible, it was just the easiest for me.

If you have a MinGW development environment (Qt SDK installs the basic tools but with an old winapi that is not enough) then you can skip the first part, add as many ported packages as you can find, port the rest, and try the 2nd part.

Cross build environment

Using the excellent tools from the Fedora project we can build Transmission for running on Windows (XP and above).

You don't need to install Fedora 11, I run it under Windows on a virtual machine (VMWare Player, the Fedora 11 image is from one of the available options

Once you have it, log in, su to root, and install the cross-development tools:

  • Create the file /etc/yum.repos.d/mingw.repo running:
    echo "[mingw]
    name=Fedora Windows cross-compiler, libraries, and tools.
    " > /etc/yum.repos.d/mingw.repo
  • yum install mingw32-gcc mingw32-gtk2 mingw32-crossreport mingw32-nsiswrapper wine
  • yum install mingw32-curl
  • yum install mingw32-qt
  • yum install mingw32-gcc-c++
  • yum install patch

Curl and its dependencies was already ported, so we got that for free. If you are working on MinGW, go to the Curl site, the downloads include libraries and everything ported to Windows. I'm not building a multi-language version, just English, so I'm skipping the step about installing intltool (which is not in the yum repository, you have to build it, and I did for the Gtk version which requires it; not difficult).

Building Transmission library

For native MinGW replace mingw32-configure with ./configure, qmake-qt4 with qmake, and i686-pc-mingw32-g++ with g++.

Start by downloading and installing the source in your workspace:

We are using one patch BuildingTransmissionQtWindows/transmission-1.83-Qt-build.diff; the download is done in one of the steps below.


  • cd transmission-1.83
  • curl "" -O transmission-1.83-Qt-build.diff
  • patch -p1 < transmission-1.83-Qt-build.diff
  • mingw32-configure --disable-nls --disable-largefile --disable-cli --disable-gtk
  • make CFLAGS="-pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions --param=ssp-buffer-size=4 -mms-bitfields -DSTATICLIB"
  • make install

Build Transmission Qt

  • cd qt
  • export QMAKESPEC=fedora-win32-cross
  • export PKG_CONFIG_LIBDIR=/usr/i686-pc-mingw32/sys-root/mingw/lib/pkgconfig
  • qmake-qt4 -win32 QT_LIBINFIX=4
  • perl -pi -e 's/-fno-rtti' Makefile.Debug Makefile.Release
  • make clean && make release
  • INSTALL_ROOT=/usr/i686-pc-mingw32/sys-root/mingw make release-install

Make the Windows installer

The following steps are to correct a deficiency of nsiswrapper :

  • ln -s /usr/i686-pc-mingw32/sys-root/mingw/bin/QtCore4.dll /usr/i686-pc-mingw32/sys-root/mingw/bin/qtcore4.dll
  • ln -s /usr/i686-pc-mingw32/sys-root/mingw/bin/QtGui4.dll /usr/i686-pc-mingw32/sys-root/mingw/bin/qtgui4.dll
  • ln -s /usr/i686-pc-mingw32/sys-root/mingw/bin/QtNetwork4.dll /usr/i686-pc-mingw32/sys-root/mingw/bin/qtnetwork4.dll

You may also have to set the PATH to include /usr/i686-pc-mingw32/sys-root/mingw/bin (unless my latest patch is already included in the distributed nsiswrapper).

Finally create the installer:

  • nsiswrapper --run --name "QtTransmission" --outfile QtTransmission-1.83_installer.exe --installdir 'C:\Program Files\Transmission' /usr/i686-pc-mingw32/sys-root/mingw/bin/qtr.exe

That's it, now just copy the installer to Windows, I use ftp but of course I have a ftp server... haven't tried other means but scp (putty or OpenSSH) should work, also using a flash drive, or a Windows/Samba? share.