CMakeLists.txt


Log

Author Commit Date CI Message
Azat Khuzhin 86f55b04 2019-09-03T00:34:35 arc4random: replace sysctl() with getrandom (on linux) Since sysctl() is deprecated for a long-long time, according to sysctl(2): Since Linux 2.6.24, uses of this system call result in warnings in the kernel log. Fixes: #890 Suggested-by: Pierce Lopez
Boris.Dergachov b5e1d911 2019-09-02T11:11:58 Fixes spelling
yuangongji 1d1c1909 2019-08-23T21:48:05 cmake: attach doxygen target into all target v2: Disable non-html generator for doxygen by default v3: convert cmake option to doxygen config
yuangongji 669a53f3 2019-07-10T00:30:12 cmake: set library names to be the same as with autotools libtool has VERSION_INFO [1], cmake has SOVERSION/VERSION instead (although it has different format). Also libtool has RELEASE [2] while cmake do not have analog yet [3], hence manual symlinks should be created. [1]: https://www.gnu.org/software/libtool/manual/html_node/Libtool-versioning.html [2]: https://www.gnu.org/software/libtool/manual/html_node/Release-numbers.html [3]: https://gitlab.kitware.com/cmake/cmake/issues/17652 Plus osx has compatibility_version/current_version dylib properties and cmake do not have separate properties for them [4], hence manual LINK_FLAGS. And also there INSTALL_NAME_DIR property which should be adjusted too. [4]: https://public.kitware.com/Bug/view.php?id=4383 So after all changes, here is an example before/after for osx and linux: # osx # autotools .libs/libevent_pthreads-2.2.1.dylib .libs/libevent_pthreads.dylib -> libevent_pthreads-2.2.1.dylib /usr/local/lib/libevent_pthreads-2.2.1.dylib (compatibility version 2.0.0, current version 2.0.0) # cmake # before patch lib/libevent_pthreads.2.2.0.dylib lib/libevent_pthreads.dylib -> libevent_pthreads.2.2.0.dylib @rpath/libevent_pthreads.2.2.0.dylib (compatibility version 2.2.0, current version 0.0.0) # after patch lib/libevent_pthreads-2.2.1.dylib lib/libevent_pthreads.dylib -> libevent_pthreads-2.2.1.dylib /vagrant/.cmake/inst/lib/libevent_pthreads-2.2.1.dylib (compatibility version 2.0.0, current version 2.0.0) # linux # autotools .libs/libevent_pthreads-2.2.so.1 -> libevent_pthreads-2.2.so.1.0.0 .libs/libevent_pthreads-2.2.so.1.0.0 .libs/libevent_pthreads.so -> libevent_pthreads-2.2.so.1.0.0 # cmake # before patch lib/libevent_pthreads.so -> libevent_pthreads.so.2.2.0 lib/libevent_pthreads.so.2.2.0 # after patch lib/libevent_pthreads-2.2.so -> libevent_pthreads-2.2.so.1 lib/libevent_pthreads-2.2.so.1 -> libevent_pthreads-2.2.so.1.0.0 lib/libevent_pthreads-2.2.so.1.0.0 lib/libevent_pthreads.so -> libevent_pthreads-2.2.so.1.0.0 Closes: #838 (cherry-picked) Closes: #760
Keith Smiley 41c95abb 2019-07-08T14:06:55 Enable _GNU_SOURCE for Android When targeting the Android NDK _GNU_SOURCE is not enabled by default: ``` /* * With bionic, you always get all C and POSIX API. * * If you want BSD and/or GNU extensions, _BSD_SOURCE and/or _GNU_SOURCE are * expected to be defined by callers before *any* standard header file is * included. * * In our header files we test against __USE_BSD and __USE_GNU. */ #if defined(_GNU_SOURCE) # define __USE_BSD 1 # define __USE_GNU 1 #endif ``` Because of this `pipe2` is not available: ``` #if defined(__USE_GNU) int pipe2(int __fds[2], int __flags) __INTRODUCED_IN(9); #endif ``` The function used to check if it does exist: ``` CHECK_FUNCTION_EXISTS_EX(pipe2 EVENT__HAVE_PIPE2) ``` Just check that the _linking_ succeeds, which it does, it's just not visible in the import, leading to a warning (or error): ``` evutil.c:2637:6: error: implicit declaration of function 'pipe2' is invalid in C99 [-Werror,-Wimplicit-function-declaration] if (pipe2(fd, O_NONBLOCK|O_CLOEXEC) == 0) ^ ``` When targeting the NDK it should be safe to always opt into this. Clang would pass the right flag for us automatically _if_ the source was C++ instead of C.
Keith Smiley 0d7d85c2 2019-07-02T10:47:47 Enable kqueue for APPLE targets The CMAKE_CROSSCOMPILING variable is not set for Apple targets seemingly because of cmake implementation details (more info https://cmake.org/cmake/help/latest/variable/CMAKE_CROSSCOMPILING.html). Since Apple targets have working kqueue implementations this check makes sure we enable it always when those are the targets, without users having to explicitly set EVENT__HAVE_WORKING_KQUEUE
Azat Khuzhin 69466cde 2019-06-26T01:27:20 cmake: link against shell32.lib/advapi32.lib Fixes: #844 Refs: #760 (cmake-vs-autotools)
Azat Khuzhin bd2de483 2019-06-26T00:59:41 Require cmake >= 3.1.2 (for correct openssl 1.0.2 detection) @ygj6 reported: "My platform is MacOS 10.13.5, This problem only happens on Mac. As written in the file CMakeLists.txt, the minimum required version of cmake is 3.1: cmake_minimum_required(VERSION 3.1 FATAL_ERROR) So I built this project with cmake-3.1.0, but I got the following errors: CMake Error at /usr/local/cmake-3.1.0/share/cmake/Modules/FindOpenSSL.cmake:293 (list): list GET given empty list Call Stack (most recent call first): CMakeLists.txt:824 (find_package) CMake Error at /usr/local/cmake-3.1.0/share/cmake/Modules/FindOpenSSL.cmake:294 (list): list GET given empty list Call Stack (most recent call first): CMakeLists.txt:824 (find_package) CMake Error at /usr/local/cmake-3.1.0/share/cmake/Modules/FindOpenSSL.cmake:296 (list): list GET given empty list Call Stack (most recent call first): CMakeLists.txt:824 (find_package) CMake Error at /usr/local/cmake-3.1.0/share/cmake/Modules/FindOpenSSL.cmake:298 (list): list GET given empty list Call Stack (most recent call first): CMakeLists.txt:824 (find_package) I googled this error and got this answer: https://bugs.archlinux.org/task/43688 It is a bug in FindOpenSSL.cmake on cmake-3.1.0 and fixed on cmake-3.1.2 . Of course, It was successful when rebuilding with cmake-3.1.2 . So I suggest setting the minimum version required for cmake to 3.1.2 or higher. " Closes: #845 Refs: https://github.com/Kitware/CMake/commit/de4ccee75a89519f95fcbcca75abc46577bfefea
yuangongji 7201062f 2019-06-09T20:15:37 cmake: add missing autotools targets (doxygen, uninstall, event_rpcgen.py) Close: #832 (cherry-picked)
Jan Beich 236762a3 2019-05-28T12:45:59 cmake: limit MSVC to Clang-CL
Azat Khuzhin 49a367e6 2019-05-25T17:28:53 cmake: add -Wmissing-prototypes (like autotools has)
Azat Khuzhin da112175 2019-05-12T16:12:06 build: struct sockaddr_un detection (sys/un.h, afunix.h) - On UNIX: sys/un.h - Since win10: afunix.h And windows has AF_UNIX but do not have sockaddr_un (before windows build 17061 [1]), hence the sockaddr_un detection. [1]: https://devblogs.microsoft.com/commandline/af_unix-comes-to-windows/
Dan Rosen 2f184f8b 2019-03-26T13:33:57 evwatch: Add "prepare" and "check" watchers. Adds two new callbacks: "prepare" watchers, which fire immediately before we poll for I/O, and "check" watchers, which fire immediately after we finish polling and before we process events. This allows other event loops to be embedded into libevent's, and enables certain performance monitoring. Closes: #710
Azat Khuzhin d5b24cc0 2019-03-05T21:34:31 sample/becat: bufferevent cat, ncat/nc/telnet analog
Azat Khuzhin 42d5a36b 2019-03-13T00:02:39 cmake: sync warnings with autotools v2 By some reason gcc reports next error: ../http.c:3330:11: warning: assignment discards ‘const’ qualifier from pointer target type [-Wdiscarded-qualifiers] value = ""; Only under -Wwrite-strings, well this is logical, but this information does not reflected in any documentation. Follow-up: 8348b413 ("cmake: add various warning flags like autotools has") f
Enji Cooper 5f87be42 2019-02-25T11:59:15 Define `_GNU_SOURCE` properly/consistently per autoconf Although `_GNU_SOURCE` can be defined as an arbitrary #define per the glibc docs [1], it's best to define it in a manner consistent with the way that autoconf defines it, i.e., `1`. While this shouldn't matter in most cases, it does when the headers from other projects follow the poorly defined GNU convention implemented by autoconf and are included after the libevent's util.h header. An example failure with clang, similar to the failure I encountered, is as follows: ``` $ printf "#define _GNU_SOURCE\n#define _GNU_SOURCE 1" | clang -c -x c - <stdin>:2:9: warning: '_GNU_SOURCE' macro redefined [-Wmacro-redefined] ^ <stdin>:1:9: note: previous definition is here ^ 1 warning generated. ``` This happened when compiling python [2] with a stale homebrew util.h file from libevent (which admittedly would not happen in a correct libevent install, as the header should be installed under /usr/local/include/event2/util.h). However, if both headers had been combined (which is more likely), it would have failed as shown above. Removing the ad hoc definition unbreaks compiling python's pyconfig.h.in header when included after util.h from libevent. 1. http://www.gnu.org/software/libc/manual/html_node/Feature-Test-Macros.html 2. https://github.com/python/cpython/blob/master/configure.ac#L126 Closes: #773 (cherry-picked) Signed-off-by: Enji Cooper <yaneurabeya@gmail.com>
Azat Khuzhin 8e87de3c 2019-02-04T22:18:45 cmake: fix checking of devpoll backend (like in autotools, by devpoll.h existence)
Azat Khuzhin 246f4404 2018-12-17T21:31:54 cmake: support static runtime (MSVC) Fixes: #737
Fredrik Strupe f33c2ce5 2018-12-15T12:54:31 cmake: Fix some typos in option descriptions
Azat Khuzhin 90d80ef4 2018-11-23T00:29:55 cmake: do not build both (SHARED and STATIC) for MSVC/win32 MSVC does not support SHARED and STATIC libraries with the same name, so let's just build SHARED libraries by default instead (yes we can add prefix but let's stick with this). The reason for this is that in windows shared libraries requires .lib file too, but this is not static library it is imported library for shared (doh...), for more info [1] and [2]. [1]: https://docs.microsoft.com/en-us/windows/desktop/dlls/dynamic-link-library-creation [2]: https://blogs.msdn.microsoft.com/oldnewthing/20091013-00/?p=16403 And when we build both static library can and will override shared library imported part, let's take a look at event_extra.lib: - before patch [3]: $ less libevent-fail/lib/Debug/event_extra.lib | head ==> use library:contained_file to view a file in the archive rw-rw-rw- 100666/100666 59568 Nov 21 23:55 2018 event_extra_static.dir/Debug/evrpc.obj rw-rw-rw- 100666/100666 252219 Nov 21 23:55 2018 event_extra_static.dir/Debug/evdns.obj rw-rw-rw- 100666/100666 203850 Nov 21 23:55 2018 event_extra_static.dir/Debug/http.obj rw-rw-rw- 100666/100666 25907 Nov 21 23:55 2018 event_extra_static.dir/Debug/event_tagging.obj [3]: https://ci.appveyor.com/project/azat/libevent/builds/20472024/job/t0o93v042jai0dj7 - "after patch" [4] (not after but the same effect): $ less libevent-ok/lib/Debug/event_extra.lib | head ==> use library:contained_file to view a file in the archive --------- 0/0 509 Nov 21 23:38 2018 event_extra.dll ... [4]: https://ci.appveyor.com/project/azat/libevent/builds/20478998/job/ca9k3c76amc4qr76 Refs: #691
Azat Khuzhin c9a073ea 2018-11-22T23:00:11 cmake: introduce EVENT__LIBRARY_TYPE option Long time ago in [1] cmake build was forced to compile both libraries (SHARED and STATIC), since this is how our autotools build works. [1]: 7182c2f561570cd9ceb704623ebe9ae3608c7b43 ("cmake: build SHARED and STATIC libraries (like autoconf does)") And there is no way to configure this (and indeed you need to do this for MSVC for example), so let's introduce option for this -- EVENT__LIBRARY_TYPE. Plus now we have INTERFACE libraries, that we can use internally in libevent's cmake rules to avoid strict to _shared/_static variant of the libraries to link with samples/tests (we prefer SHARED over STATIC for linking). Also bump minimal cmake required version to 3.1 by the following reasons: - 3.1 is required for RPATH configuration under APPLE - 3.0 is required for add_library(INTERFACE) (did not found it in 2.8.x documentation) - remove extra conditions (anyway 3.1 was release 4 years ago, so I guess that most of the systems will have it)
Azat Khuzhin d705e8c0 2018-11-21T07:31:57 cmake: drop redundant add_dependencies()
Azat Khuzhin bdd71f18 2018-11-13T10:48:41 s/http-server: graceful cleanup
Azat Khuzhin 6d3a5396 2018-11-05T18:30:38 cmake: set CMP0075 to NEW (for ws2_32.lib in win32) Otherwise cmake complains: Policy CMP0075 is not set: Include file check macros honor CMAKE_REQUIRED_LIBRARIES. Run "cmake --help-policy CMP0075" for policy details. Use the cmake_policy command to set the policy and suppress this warning. CMAKE_REQUIRED_LIBRARIES is set to: ws2_32.lib For compatibility with CMake 3.11 and below this check is ignoring it.
Azat Khuzhin 65904773 2018-11-05T18:23:31 cmake: set CMP0074 to NEW (for OPENSSL_ROOT in appveyor) We have $env:OPENSSL_ROOT (env) equals to -DOPENSSL_ROOT (cmake variable) anyway. cmake complains: Policy CMP0074 is not set: find_package uses <PackageName>_ROOT variables. Run "cmake --help-policy CMP0074" for policy details. Use the cmake_policy command to set the policy and suppress this warning. Environment variable OpenSSL_ROOT is set to: C:/OpenSSL-Win64/bin For compatibility, CMake is ignoring the variable. This warning is for project developers. Use -Wno-dev to suppress it.
Azat Khuzhin 3ed93997 2018-11-04T19:48:11 cmake: do not detect _GNU_SOURCE/__GNU_LIBRARY__ if it is cached
Azat Khuzhin 8348b413 2018-10-27T14:58:30 cmake: add various warning flags like autotools has This is mostly to match autotools and reduce amount mixiing declarations and code. Added: - -Wextra (the same as -W), -Wno-unused-parameter -Wstrict-aliasing - -fno-strict-aliasing (gcc 2.9.5+) - -Winit-self -Wmissing-field-initializers -Wdeclaration-after-statement (4.0+) - -Waddress -Wno-unused-function -Wnormalized=id -Woverride-init (4.2+) - -Wlogical-op (4.5+) Removed: - -Wformat (include in -Wall) Plus use CMAKE_C_COMPILER_ID over CMAKE_COMPILER_IS_GNUCC, as cmake-variables(7) suggesting, and add common GNUC/CLANG variables. v2: drop checks for flags, since add_compiler_flags() will check if such flags exists anyway (but just to note, gcc ignores non existing warning flags by default).
Azat Khuzhin cec4a371 2018-10-17T11:14:48 Add -fdiagnostics-color=always for Ninja
Azat Khuzhin e85818d2 2018-06-19T10:15:08 Cleanup __func__ detection First of all __func__ is not a macro, it is char[] array, so the code that we had before in cmake, was incorrect, i.e.: #if defined (__func__) #define EVENT____func__ __func__ #elif defined(__FUNCTION__) #define EVENT____func__ __FUNCTION__ #else #define EVENT____func__ __FILE__ #endif So just detect do we have __func__/__FUNCTION__ in configure/cmake before build and define EVENT__HAVE___func__/EVENT__HAVE___FUNCTION__ to use the later to choose which should be used as a __func__ (if it is not presented). Closes: #644
Philip Prindeville 755896ef 2018-06-16T16:44:06 Get rid of macros which are never used There are no expansions of these macros or tests for their existence. Signed-off-by: Philip Prindeville <philipp@redfish-solutions.com>
Azat Khuzhin 6e5c15d0 2017-12-16T23:28:41 Fix typo in cmake because of which EVENT__SIZEOF_SIZE_T was wrong Fixes: #580
Andrey Okoshkin 6ee73ea9 2017-11-29T11:13:51 Fix generation of LibeventConfig.cmake for the installation tree 'LIBEVENT_INCLUDE_DIRS' is properly initialized in 'LibeventConfig.cmake' as 'LibeventConfig.cmake.in' contains usage of 'LIBEVENT_CMAKE_DIR' and 'EVENT_INSTALL_INCLUDE_DIR' variables but not 'EVENT_CMAKE_DIR' and 'EVENT__INCLUDE_DIRS'. Related typos are fixed.
lightningkay 3f19c5eb 2017-11-02T14:58:17 cmake doesn't has POLICY CMP0054 in low version
Kiyoshi Aman 8b0aa7b3 2017-09-14T17:39:20 Port `event_rpcgen.py` and `test/check-dumpevents.py` to Python 3. These scripts remain compatible with Python 2.
Carlo Marcelo Arenas Belón 63c4bf78 2017-09-01T15:50:36 test: fix 32bit linux regress
Azat Khuzhin 2773a5ed 2017-05-29T18:48:48 cmake: set CMP0054 to NEW to avoid variables over expansion (since cmake 3.8) ==> win: CMake Warning (dev) at CMakeLists.txt:782 (elseif): ==> win: Policy CMP0054 is not set: Only interpret if() arguments as variables or ==> win: keywords when unquoted. Run "cmake --help-policy CMP0054" for policy ==> win: details. Use the cmake_policy command to set the policy and suppress this ==> win: warning. ==> win: ==> win: Quoted variables like "MSVC" will no longer be dereferenced when the policy ==> win: is set to NEW. Since the policy is not set the OLD behavior will be used. ==> win: This warning is for project developers. Use -Wno-dev to suppress it.
Azat Khuzhin 8b29b136 2017-05-29T16:36:24 cmake: fix building bench/bench_cascade under win32 (missing getopt) Because of typo in cmake, now rewrote to make it less error prone (since even for non-win32 there are variables overlap).
Azat Khuzhin 346f8e17 2017-05-29T16:32:30 cmake: avoid requiring cmake 3.1 on win32 for dns-example Avoid using target_sources() from cmake 3.1, just pass needable sources as list.
Azat Khuzhin 30f2a969 2017-03-14T00:07:17 cmake: eliminate EVENT_BUILDING_REGRESS_TEST, since we link with shared libs Before 7182c2f561570cd9ceb704623ebe9ae3608c7b43 ("cmake: build SHARED and STATIC libraries (like autoconf does)") it links with *.c.
Azat Khuzhin d5e10870 2017-03-13T21:54:33 cmake: clean not used #defines from event-config.h - _LARGE_FILES: we have it in evconfig-private.h.in, drop from event-config.h - EVENT___FILE_OFFSET_BITS: remove it for now - EVENT__const
Azat Khuzhin 2d2299cf 2017-03-13T22:02:45 cmake: add <pthread.h> only for non-win32 Fixes: b2b4b4d74e78a3e4fe7a74224d1e6aada5bde351 ("cmake: add <pthread.h> into CMAKE_REQUIRED_INCLUDES for sizeof(pthread_t)")
Azat Khuzhin 805e1aa8 2017-03-13T15:49:11 cmake: support visibility for AppleClang too Defaults apple linker behaviour is -two_levelnamespace, and you cannot use "-undefined suppress" with it, so let's link non event_core with event_core library to avoid undefined symbols.
Azat Khuzhin fd5a3fc0 2017-03-13T03:18:02 cmake: fix export absolute path and relative path and cleanup a bit Remove next vars, since I don't think that somebody want to change it: - bin - lib - include And fix exports problem: CMake Error: INSTALL(EXPORT "LibeventTargets") given absolute DESTINATION "/usr/lib/cmake/libevent" but the export references an installation of target "event_core_static" which has relative DESTINATION "lib".
Azat Khuzhin 7182c2f5 2017-03-12T23:31:59 cmake: build SHARED and STATIC libraries (like autoconf does) Since they are useful for debugging, and if autotools build them then cmamke has to do this too, to make migration more simple. And now: - tests: uses shared libraries (since this is upstreams one) - other binaries: uses static libraries This removes next private config: - EVENT__NEED_DLLIMPORT
Azat Khuzhin 72ef9d16 2016-11-07T00:46:45 cmake: add missing event_openssl/event_pthreads libraries This will remove openssl requirement if you don't use it (i.e. if you not link with openssl_pthreads). Plus it fixes some linking dependencies: - libm required only for test-ratelim And fix some coding style alignment issues. Refs: #246
Shuo Chen 65870949 2017-03-12T01:00:41 Fix detection of timerfd_create() in CMake.
Azat Khuzhin 819d0493 2017-03-08T23:15:33 Do not add epoll_sub (syscall wrappers) for epoll in cmake Nowadays mostly all supported OS'es has this wrappers, and some of them (like SmartOS) has wrappers but doesn't have __NR_epoll* defines for syscall numbers, so just drop them (instead of adding yet another check int cmake like autotools has, since this will break building in cross-compile environment). Also one minor note, configure doesn't added epoll_sub.c either, since it check epoll_create() in runtime. And I tested it in SmartOS and it even works (`make verify`). Fixes: #463
Marek Sebera 6541168d 2017-03-06T00:55:16 Detect arch4random_addrandom() existence Refs: #370 Refs: #475
Azat Khuzhin 71a56bd3 2017-03-06T00:30:21 cmake: detect _GNU_SOURCE not by __GNU_LIBRARY__ only (fallback to _GNU_SOURCE) Fixes pipe2() on Android-9/armv7-a Refs: #475
Azat Khuzhin 66a4eb0c 2017-03-06T00:05:50 Check for WNOWAIT in waitpid() in runtime (not in cmake/configure) Because checking in cmake breaks cross-compiling. Introduced-in: 43eb56c7c738e3642f0981e3dd6ab9e082eec798. Fixes: #482 Fixes: #462 Refs: #475 v2: use waitid() with WNOWAIT v3: use WNOWAIT only if it available in waitpid(), because not all netbsd supports it
Azat Khuzhin b2b4b4d7 2017-03-05T22:07:23 cmake: add <pthread.h> into CMAKE_REQUIRED_INCLUDES for sizeof(pthread_t) Fixes: #475
Azat Khuzhin fa135bdc 2017-01-30T03:17:41 cmake: Fix checking of enum values from sysctl.h CheckSymbolExists do not do this, so add new CheckConstExists that will use CheckCSourceCompiles() to check this. v2: use set() instead of string(APPEND)
Pierce Lopez 5d18d879 2017-03-02T21:09:32 Do not check for ERR_remove_thread_state() (do not link ssl into every library) This reverts commit c4e9d9bd662de7f575f2172c160795d452ebe709 ("sample/https-client: check for ERR_remove_thread_state() existence"). Calling AC_SEARCH_LIBS() modifies LIBS - -lcrypto incorrectly ends up in LIBS, and thus linked to by libevent_core.so. Checking for ERR_remove_thread_state should no longer be needed because it was introduced in openssl 1.0.0, and the previous line 0.9.8 had support discontinued at the end of 2015. Fixes: #473
Trond Norbye cc0e04d7 2017-02-21T12:54:02 Fix RPATH for APPLE By setting the CMake minimum version to 3.1 CMake automatically adds the correct magic to make the library relocatable on the filesystem (instead of burning the location of the library at link time into the binary). ex: otool -L bin/http-connect bin/http-connect: @rpath/libevent_extra.2.2.0.dylib (compatibility version 2.2.0, current version 0.0.0) /usr/lib/libz.1.dylib (compatibility version 1.0.0, current version 1.2.8) /usr/lib/libSystem.B.dylib (compatibility version 1.0.0, current version 1238.0.0) Fixes: #468 (cherry-picked)
Azat Khuzhin b24a78cc 2017-01-29T23:05:18 cmake: check for 'struct linger' existence
Azat Khuzhin fe2c2622 2017-01-29T20:19:06 Make EVENT_STAGE_NAME non cached It did not work before correctly anyway, since cmake do not reset cache entries by default, so that reset to "beta" didn't work. But I don't think that making this variable cached is useful, so let's remove this.
Azat Khuzhin efcfa046 2017-01-29T18:13:07 Bump version in master to 2.2.0-alpha-dev And according to f8d80a285cf941505277d9060d0357b5b7e543d2 ("Bump version to 2.1.3-alpha-dev") numeric version have 1 at the end, since it means "-dev".
Azat Khuzhin 9b63b5d4 2017-01-22T18:21:57 Bump version to 2.1.8-stable everywhere P.S. in referenced commit I made a mistake and instead of *-rc* I wrote *-beta*. See-also: f4489b8323cda0bf8eed7c1353911a852d7a947c ("Bump version to 2.1.7-beta everywhere")
Azat Khuzhin f4489b83 2016-11-02T00:31:31 Bump version to 2.1.7-beta everywhere - cmake basic - cmake detecting from git -- event_fuzzy_version_from_git() - autotools - win32 - appveyor
Azat Khuzhin 40fbffc0 2016-11-01T23:33:11 Fix cmake -DEVENT__COVERAGE=ON - do not use compiler check from the root cmake rules with syntax error, let CodeCoverage check it - fix CodeCoverage to check C compiler not CXX - case insensitive checking of CMAKE_BUILD_TYPE - replace flags with --coverage, and fix flags with linking with --coverate, otherwise it will not compile during checking flags and fails.
Azat Khuzhin 3453c081 2016-10-30T11:19:43 cmake: fix finding python2, and check that it is really 2 python version check removed in a4d044c0cd97f68b4b3dde414b83d609719d33d7 ("cmake: use PYTHON_EXECUTABLE to find python2"), but in bcb990ab7cf4921c2c30a1aa4fcb4c0131fffe94 ("cmake/win32: fix running regress, but fixing finding python2 interpreter") we set PYTHON_EXECUTABLE only if it exists.
Zonr Chang dc624adf 2016-08-24T16:19:01 cmake: cleanup - Remove a redundant check on netdb.h (EVENT__HAVE_NETDB_H). - Properly setup EVENT__SIZEOF_SSIZE_T for the case where "ssize_t" is not "int". - Remove unused EVENT__HAVE_PTHREAD. - Set EVENT__HAVE_LIBZ instead of EVENT__HAVE_ZLIB (and remove the latter). Closes: #391 (cherry-picked from PR)
Azat Khuzhin bcb990ab 2016-10-26T00:51:56 cmake/win32: fix running regress, but fixing finding python2 interpreter Could not find executable C:/projects/libevent/build/bin/regress Looked in the following places: C:/projects/libevent/build/bin/regress C:/projects/libevent/build/bin/regress.exe ... 9/13 Test #9: regress__WIN32_debug ................***Not Run 0.00 sec Link: https://ci.appveyor.com/project/nmathewson/libevent/build/2.1.6.271/job/wvy2jp7uojcut5cx#L1256 Fixes: #411
Azat Khuzhin a4d044c0 2016-10-04T23:21:37 cmake: use PYTHON_EXECUTABLE to find python2 Since most of the distros have symlinks for this.
Azat Khuzhin 91559607 2016-10-03T03:17:18 Add -DEVENT__DISABLE_CLOCK_GETTIME switch for cmake See-also: adc402ba5f0e15f4c77505852507f33b50f37ab6 ("Adding option to ignore clock_gettime: --disable-clock-gettime")
Azat Khuzhin 51019e94 2016-07-13T17:40:48 Bump version to 2.1.6-beta everywhere - cmake basic - cmake detecting from git -- event_fuzzy_version_from_git() - autotools - win32 - appveyor
Azat Khuzhin 43eb56c7 2016-08-11T16:15:45 tests: use waitpid(..., WNOWAIT) to fix failing of main/fork under solaris According to solaris docs: "One instance of a SIGCHLD signal is queued for each child process whose status has changed. If waitpid() returns because the status of a child process is available, and WNOWAIT was not specified in options, any pending SIGCHLD signal associated with the process ID of that child process is discarded. Any other pending SIGCHLD signals remain pending." And interesting thing that it works if you add sleep(1) before waitpid(), and also if you run with --verbose (some race or what). But linux doesn't support WNOWAIT in waitpid() so add detection into cmake/autotools. Fixes: #387 Link: https://bugzilla.redhat.com/show_bug.cgi?id=840782
Azat Khuzhin dc95823c 2016-08-10T00:27:59 cmake/solaris: set CMAKE_REQUIRED_LIBRARIES to fix functions detections Otherwise we will not detect next functions for instance: - gethostbyname_r # and related And now both autotools/cmake builds passes all regress tests in basic env (on solaris of course). Fixes: dns/client_fail_requests_getaddrinfo
Azat Khuzhin 050bfc7f 2016-08-10T00:16:48 cmake/solaris: fix building (link with socket,nsl)
Azat Khuzhin c4dfb93f 2016-08-09T10:56:34 cmake: check for ZLIB_INCLUDE_DIR, since we can have only library without headers
Azat Khuzhin de0c1965 2016-08-08T15:50:46 cmake/win32: do not compile regress_thread on -DEVENT__DISABLE_THREAD_SUPPORT=ON
Azat Khuzhin ecb0ec82 2016-08-08T15:45:29 cmake/win32: do not compile evthread_win32 on -DEVENT__DISABLE_THREAD_SUPPORT=ON There is duplicated "evthread_win32.c" appending to ${SRC_CORE} list, leave only one that under if EVENT__DISABLE_THREAD_SUPPORT Fixes: https://ci.appveyor.com/project/azat/libevent/build/2.1.5.96/job/44q3rgifasny7gek
Azat Khuzhin e35f2241 2016-08-07T23:46:26 cmake: fix -DEVENT__ENABLE_VERBOSE_DEBUG (typo on -DUSE_DEBUG) Fixes: 8b228e27f57300be61b57a41a2ec8666b726dc34 ("Lot's of cmake updates")
Azat Khuzhin 38716c65 2016-08-07T23:07:44 cmake: do not use stderr for notifications/version-info For all except "STATUS" message() will write to stderr, and this also includes case when you does not have <mode> at all. Plus for every message in stderr powershell generates exception and make appveyor fails. Fixes: https://ci.appveyor.com/project/azat/libevent/build/2.1.5.85/job/i10k7m0t80330mtr
Mark Ellzey 30316177 2016-06-28T10:37:24 [#372] check for errno.h
Azat Khuzhin 87f7238f 2016-03-10T01:50:12 cmake: require 3.1 only for win32 to make it work under ubunty precise Also I [TRIED] wily but ubuntu can't upgrade transparently. TRIED: https://travis-ci.org/azat/libevent/jobs/114924723 Fixes: https://travis-ci.org/libevent/libevent/jobs/114917275
Azat Khuzhin c46ead5d 2016-03-10T01:07:54 cmake: require at least 3.1 for target_sources()
Azat Khuzhin 36588e16 2016-03-10T00:33:04 cmake: fix adding of compiler flags, and now it will - add_compiler_flags() must accept array IOW just ARGN will be enoough - add_compiler_flags() called with variable name instead of it's value P.S. and fix some alignments issues P.P.S. more cmake issues expected since now CFLAGS actually works P.P.P.S. some issues with cmake cache is possible, so just reset it
Azat Khuzhin f29f59e8 2016-03-10T00:25:09 Replace -Wswitch-enum with -Wswitch, and add it into cmake rules too According to https://gcc.gnu.org/onlinedocs/gcc/Warning-Options.html: -Wswitch-enum Warn whenever a switch statement has an index of enumerated type and lacks a case for one or more of the named codes of that enumeration. case labels outside the enumeration range also provoke warnings when this option is used. The only difference between -Wswitch and this option is that this option gives a warning about an omitted enumeration code even if there is a *default label*.
Azat Khuzhin a1609a87 2016-01-12T01:57:07 cmake: fix building dns-example under win32 (missing getopt)
Azat Khuzhin 7707f6b0 2016-01-07T17:51:40 cmake: Fix detection of ssize_t/SSIZE_T Since ssize_it is POSIX, windows/VS also have this but with BaseTsd.h, plus the logic prefers "ssize_t" (lower) instead of "SSIZE_T" (upper) when the latest only available -- fix this too. Refs: #311
Mark Ellzey d56efd94 2015-12-21T17:43:00 Fixed issue with cmake version generation
Mark Ellzey 7f9646d2 2015-12-21T04:36:24 Cmake is now officially working. Though I am currently breaking out things that seem to be repetitive, and a cooler version macro and changelog updater. More to come.
Mark Ellzey 49a53811 2015-12-20T21:44:04 More cmake updates, lot's of missing definitions
Mark Ellzey a9db46ae 2015-12-20T00:43:46 CMAKE CMAKE CMAKE CLEANUPS It's almost useful.
Mark Ellzey 8b228e27 2015-12-19T01:47:49 Lot's of cmake updates This is still not done, cmake here was a horrid mess, but we're getting our act together now.
Azat Khuzhin c4e9d9bd 2015-11-23T18:44:03 sample/https-client: check for ERR_remove_thread_state() existence Fixes: freebsd 9.2 build
Azat Khuzhin cf2cf2a0 2015-09-02T11:51:00 test: run regress with EVENT_DEBUG_MODE=1 and without This could show some bugs like "event_assign called on an already added event", and some others that debugging mode could track.
Azat Khuzhin 1d34498e 2015-08-18T12:18:31 sample: add HTTP CONNECT tunnelling example using libevent http layer
Joakim Söderberg 19ba4543 2015-02-05T00:56:58 This fixes a bug introduced in 27bd9faf498b91923296cc91643e03ec4055c230 CMake configuration files are intended to be used by other projects to find the library. Specifically the CMake find_package command can use it to find all files related to the project. The idea is to support 2 different CMake configuration files for Libevent. One if you simply build libevent that is generated for the build tree. And a second one that is generated for an install target that will be installed on the system and point to where on the system the lib files and such can be find. So for instance, in the build tree the config would set the cmake variable `LIBEVENT_INCLUDE_DIRS` to `/path/to/libevent/build/include`. And for the system config it would be set to `/usr/local/include` (or whatever target the user chose when running cmake). 27bd9faf498b91923296cc91643e03ec4055c230 changed this behavior so that both configs would point to the system wide path `/usr/local/include` This meant that projects just wanting to import directly for the build tree would fail.
Nick Mathewson 683f5568 2015-01-05T09:16:12 Increment version to 2.1.5-beta
Nobuaki Sukegawa e69d9109 2015-01-03T02:22:31 Fix CMake shared library build This fixes following problems in shared library build: * visibility=hidden was not enabled for gcc because of incorrect variable name * test programs that need internal APIs caused link errors
Joakim Soderberg 5c7282f7 2014-09-24T13:46:09 Fix compilation for older OpenSSL versions. For instance OpenSSL 0.9.7 does not have SSL_set_tlsext_host_name. Also add the missing EVENT__DISABLE_SAMPLES CMake option.
Sergey Nikulov 27bd9faf 2014-09-02T18:25:52 updates in cmake build
Trond Norbye 15d90cce 2014-03-24T15:01:02 Add missing headerfile for cmake
Nick Mathewson de268feb 2014-03-21T13:20:34 Increment version to 2.1.4-alpha-dev
Trond Norbye 73474042 2014-03-21T12:12:10 Fixup make install for cmake projects Install all of the public headers and put the dll's in the same directory as the binaries.
Nick Mathewson d08273ec 2014-03-16T12:09:24 Increment version to 2.1.4-alpha
Nick Mathewson 8896a92b 2014-03-03T13:47:21 Merge remote-tracking branch 'origin/pr/110'
Trond Norbye 4545fa9b 2014-02-19T06:31:27 Add option to build shared library