1 ## Instructions for building Tor with MinGW (http://www.mingw.org/)
4 Stage One: Download and Install MinGW.
5 ---------------------------------------
8 http://prdownloads.sf.net/mingw/MinGW-5.1.3.exe?download
11 http://prdownloads.sf.net/mingw/MSYS-1.0.10.exe?download
13 Download the mingw developer tool kit:
14 http://prdownloads.sf.net/mingw/msysDTK-1.0.1.exe?download
16 Download the mingw autoconf-2.59 update:
17 http://prdownloads.sf.net/mingw/msys-autoconf-2.59.tar.bz2?download
19 Install mingw, msys and mingw-dtk. Extract msys-autoconf-2.59.tar.bz2 into
20 your mingw install location. For example, if you installed mingw into
21 /c/mingw/1.0/ you want to extract msys-autoconf-2.59.tar.bz2 into this
24 Create a directory called "tor-mingw".
26 Stage Two: Download, extract, compile openssl
27 ----------------------------------------------
30 http://www.openssl.org/source/openssl-0.9.8g.tar.gz
33 Copy the openssl tarball into the "tor-mingw" directory.
35 Type "tar zxf openssl-0.9.8g.tar.gz"
37 Make openssl libraries:
38 Type "cd tor-mingw/openssl-0.9.8g/"
39 Type "./Configure -no-idea -no-rc5 -no-mdc2 mingw"
40 Edit Makefile and remove the "test:" and "tests:" sections.
43 Type "find ./ -name "*.h" -exec cp {} ../include/openssl/ \;"
45 Type "find ./ -name "*.h" -exec cp {} ../include/openssl/ \;"
47 Type "cp *.h include/openssl/"
48 # The next steps can take up to 30 minutes to complete.
53 Download the pre-compiled openssl for win32.
57 Stage Three: Download, extract, compile zlib
58 ---------------------------------------------
61 http://www.zlib.net/zlib-1.2.3.tar.gz
64 Copy the zlib tarball into the "tor-mingw" directory
66 Type "tar zxf zlib-1.2.3.tar.gz"
71 Type "cd tor-mingw/zlib-1.2.3/"
79 Type "cd tor-mingw/zlib-1.2.3/"
81 Type "make -f win32/Makefile.gcc"
86 Stage Four: Download, extract, and compile libevent-1.3e
87 ------------------------------------------------------
89 Download the libevent 1.3e release:
90 http://www.monkey.org/~provos/libevent/
92 Copy the libevent tarball into the "tor-mingw" directory.
97 Type "./configure --enable-static --disable-shared"
101 Stage Five: Build Tor
102 ----------------------
104 Download the current Tor alpha release from https://www.torproject.org/download.html.
105 Copy the Tor tarball into the "tor-mingw" directory.
107 Type "tar zxf latest-tor-alpha.tar.gz"
113 You now have a tor.exe in src/or/. This is Tor.
114 You now have a tor-resolve.exe in src/tools/.
116 Stage Six: Build the installer
117 -------------------------------
119 Install the latest NSIS:
120 http://nsis.sourceforge.net/Download
122 Run the package script in contrib:
123 From the Tor build directory above, run:
124 "./contrib/package_nsis-mingw.sh"
126 The resulting Tor installer executable is in ./win_tmp/.