From: Azat Khuzhin Date: Sun, 24 Mar 2019 22:40:46 +0000 (+0300) Subject: Link test/regress with event_core/event_extra over event X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=2ae875ed1216a8896d8af0414cb4efbcb907bae5;p=libevent Link test/regress with event_core/event_extra over event Due to regress linked with event and event_core (both of them includes evthread.c) there will be two different evthread_id_fn_ variables under mingw64: evthread_id_fn_: &0x5294f20a8 evthread_id_fn_: &0x4ba0030a8 And because of this evthread_use_pthreads() can/will set one copy of variables while evthread*() functions will access another, which will break a lot of things (for example main/del_notify test). Fixes: #792 --- diff --git a/test/include.am b/test/include.am index ee2ab5ff..04375247 100644 --- a/test/include.am +++ b/test/include.am @@ -140,7 +140,7 @@ if BUILD_WIN32 test_regress_SOURCES += test/regress_iocp.c endif -test_regress_LDADD = $(LIBEVENT_GC_SECTIONS) libevent.la $(PTHREAD_LIBS) $(ZLIB_LIBS) +test_regress_LDADD = $(LIBEVENT_GC_SECTIONS) libevent_core.la libevent_extra.la $(PTHREAD_LIBS) $(ZLIB_LIBS) test_regress_CPPFLAGS = $(AM_CPPFLAGS) $(PTHREAD_CFLAGS) $(ZLIB_CFLAGS) -Itest test_regress_LDFLAGS = $(PTHREAD_CFLAGS)