Tor core build under Windows/64

Hello.
I tried many DEV-ENV to compile tor master core on Windows/64.
Never find a solution to get a tor.exe!
I always got errors on libevent!

Tried,
- cygwin, no way
- MSYS2, no way
- Linux cross compiling (mingw), no way

Is there a definitive tutorial step-by-step to make a build of tor.exe x86_64 inside a Windows/64?
Thanks.

This works for me:

./autogen.sh && ./configure --enable-static-tor --with-libevent-dir=$MINGW_PREFIX/lib --with-openssl-dir=$MINGW_PREFIX/lib --with-zlib-dir=$MINGW_PREFIX/lib --disable-unittests --disable-module-dirauth --disable-manpage --disable-html-manual --disable-asciidoc && make

You need to install it probably.
Execute pacman -Ss libevent and then select package depending on your compiler. For example, pacman -S mingw-w64-clang-x86_64-libevent for clang.

2 Likes

Solved!
Many thanks.

Recap:

$ echo $MINGW_PREFIX
/ucrt64

$ pacman -Ss libevent
clangarm64/mingw-w64-clang-aarch64-libevent 2.1.12-7
    An event notification library (mingw-w64)
mingw32/mingw-w64-i686-libevent 2.1.12-7
    An event notification library (mingw-w64)
mingw64/mingw-w64-x86_64-libevent 2.1.12-7 [installed]
    An event notification library (mingw-w64)
ucrt64/mingw-w64-ucrt-x86_64-libevent 2.1.12-7 [installed] <<< THIS WAS NOT INSTALLED!!!
    An event notification library (mingw-w64)
clang64/mingw-w64-clang-x86_64-libevent 2.1.12-7 [installed]
    An event notification library (mingw-w64)
msys/libevent 2.1.12-4 [installed]
    An event notification library
msys/libevent-devel 2.1.12-4 (development) [installed]
    Libevent headers and libraries

A simple “pacman -S mingw-w64-ucrt-x86_64-libevent” solved the problem :clap::clap::clap::clap::clap:
Thank you very much!!! :+1::+1::+1:

2 Likes

This topic was automatically closed 24 hours after the last reply. New replies are no longer allowed.