PCFreak Logo (c) Der PCFreak

Howto compile oathtool on Windows with Cygwin

If you want to compile oathtool on Windows using Cygwin you can use this small Howto:

    1. Install Cygwin
    2. Install the following packages into Cygwin (maybe you need less packages, but this is myy actual list grabbed with cygcheck.exe -c) or just try, wait for errors and install the packages based on the error you get._autorebase, _update-info-dir, alternatives, autobuild, autoconf, autoconf2.1, autoconf2.5, automake, automake1.10, automake1.11, automake1.4, automake1.5, automake1.6,
      automake1.7, automake1.8, automake1.9, base-cygwin, base-files, bash, binutils, bzip2, ca-certificates, coreutils, cpio, crypt, cvs, cvsps, cygutils, cygwin, cygwin-doc, dash,
      diffutils, dos2unix, editrights, file, findutils, gawk, gcc-core, gcc-g++, gcc-mingw-core, gcc-mingw-g++, gdb, gettext, git, grep, groff, gzip, ipc-utils, less, libasn1_8, libattr1,
      libbz2_1, libcom_err2, libcurl4, libdb4.5, libexpat1, libffi4, libgcc1, libgcrypt11, libgdbm4, libgmp3, libgnutls26, libgpg-error0, libgssapi3, libheimbase1, libheimntlm0, libhx509_5,
      libiconv2, libidn11, libintl3, libintl8, libkrb5_26, libltdl7, liblzma5, liblzo2_2, libncurses10, libncurses9, libncursesw10, libopenldap2_3_0, libopenssl098, libopenssl100, libpcre0,
      libpopt0, libreadline7, libroken18, libsasl2, libsigsegv2, libsqlite3_0, libssh2_1, libssp0, libstdc++6, libtasn1_3, libtool, libwind0, login, m4, make, man, mercurial, mingw-runtime,
      mingw-w32api, mintty, perl, perl-Error, python, rebase, run, sed, tar, terminfo, texinfo, tzcode, w32api, wget, which, xorg-util-macros, xz, zlib0
    3. Download the source from here. I used oath-toolkit-1.12.4.tar.gz
    4. Unzip the source to your Cygwin home folder
      tar xzvf oath-toolkit-1.12.4.tar.gz
    5. Jump into the newly created folder
      cd  oath-toolkit-1.12.4
    6. Execute the following commands
    7. Pickup the following files and copy them to a separate folder
    8. You can now run oathtool (without Cygwin) from the newly created folder


If you don’t want to compile yourself, you can download my compiled version here (if you trust me!).

2 Comments so far

  1. kevin on April 3rd, 2016

    As a cygwin newbie, I struggled to figure out how to check all those packages were on board, I eventually found that by calling the setup program with the options -q -packages= it would go off and find them itself and check – my command became

    setup-x86_64.exe -q –packages=_autorebase, _update-info-dir,…

    I just copy pasted the list of packages from your article after the -packages=

    A time saver for us noobs (once I found it)

    Thanks for sharing your info

  2. Der PCFreak on April 4th, 2016

    thanks for your comment. I would install as many dependencies as you can during the setup of cygwin (Select Packages) by searching for them. After that try to compile and look for error messages about dependencies. I would also recommend you always install the …-dev packages, too. But you could also download my compiled version if you just need oathtool for testing. It might not have changed that much since I compiled it.
    Have a good one.