I love PuTTY, it is by FAR the most used programs on my terminal, but recent threats have made me a little nervous about downloading a 64-bit version from an untrusted source. The source I trust is not updating anymore. So my options were limited and led me to the decision of compiling PuTTY myself. At the end of this article I'll provide the download link, but I really do encourage you to compile these yourself. I trust myself, but there is no reason you should
As with most of my projects I'll be doing this using Centos 7, as it was the most current at the time of this writing.
Install required packages to build PuTTY
yum install mingw64-gcc mingw64-qt5-qtwebsockets
Grab the Windows Sources
Please note that at the time this article was written the official version of PuTTY was 'beta 0.65' and that it would not build properly as a 64-bit application. I used the development snapshot which had resolved these errors. Go to the official PuTTY website and download the source. Don't forget to unpack the zip file to a build directory.
Create the Makefile
The author of PuTTY provides a lot of different methods for building PuTTY. I am only interested in the cygwin make script, which is tailored for our purposes as well. In order to do that we need to run a small perl program in the build directory.
Now change to the windows directory. The script that we just ran has created a nice makefile, but it’s not configured for a 64-bit build. Instead of editing it, I provide the compiler with all the information from the command line.
CFLAGS="-Wall -O2 -D_WINDOWS -DNO_MANIFESTS -DNO_MULTIMON -I.././ -I../charset/ -I../windows/ -I../unix/ -I../macosx/" \
RCFLAGS="--define WIN32=1 --define _WIN32=1 --define WINVER=0x0400 -I.././ -I../charset/ -I../windows/ -I../unix/ -I../macosx/" \
By providing the compiler the flags on the command line I can also avoid the '-mno-cygwin' pitfall as well.
Ok after you go eat some runts (an old eggdrop compile reference) you should have some nice exe files that will run nicely on a windows machine. Just know that 'NO_MANIFESTS' flag is required for 64-bit
Enough, Where are your binaries?
Fine, here they are. But before you download blindly please consider doing this yourself. While I did use direct unaltered sources from the PuTTY site, you can't be sure, and that is kind of my point entirely.
Note: Yes, I know putty does not need to be a 64-bit application.