I build libevent-2.0.16-stable under cygwin-windows with multi-thread feature support but it's seem that configure
didn't detect environment as WIN32, so it did not include evthread_win32.c
as a part of build process, a try call to evthread_use_windows_threads
cause symbol not found.
So i try to set WIN32 flag like CFLAGS=WIN32 ./configure
and it did not work too. So what's is the properly way?
Asked
Active
Viewed 2,639 times
2

secmask
- 7,649
- 5
- 35
- 52
-
1Libevent developer here. I've never tried building Libevent on Cygwin for windows: only with mingw and msvc. So there might be a bug there! It looks like evthread_win32.c is included when BUILD_WIN32 is defined in configure.in, and BUILD_WIN32 is defined by configure.in only when the preprocessor macros "WIN32" is defined by your compiler. Does cygwin GCC define any preprocessor macros that indicate that it is WIN32? [ETA: if you find a solution here, please let us know on the libevent mailing list or bugtracker so we can fix it for others too] – nickm Feb 16 '12 at 03:56
-
I don't think cygwin define a WIN32 flag, configure script show a line such as "checking for WIN32... no, checking for CYGWIN... yes" – secmask Feb 16 '12 at 04:57
1 Answers
1
I had the same problem. So i just configured to use non-cygwin compiller ./configure --binpath=[path to directory with the compiler] CC=[path to my mingw gcc.exe]
and then just ran make

Ziumin
- 4,800
- 1
- 27
- 34