summaryrefslogtreecommitdiff
path: root/README.md
diff options
context:
space:
mode:
authorAzat Khuzhin <a3at.mail@gmail.com>2018-11-22 23:00:11 +0300
committerAzat Khuzhin <a3at.mail@gmail.com>2018-11-23 00:02:18 +0300
commitc9a073eae8f86a74fbbb125db34b881ef40108b7 (patch)
tree3178bd86471372a9272e73e7cd71b706b69ef9d7 /README.md
parentd705e8c0e924d3b815697a075c27a36298f04078 (diff)
downloadlibevent-c9a073eae8f86a74fbbb125db34b881ef40108b7.tar.gz
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)
Diffstat (limited to 'README.md')
-rw-r--r--README.md4
1 files changed, 4 insertions, 0 deletions
diff --git a/README.md b/README.md
index 967fbdfe..61735731 100644
--- a/README.md
+++ b/README.md
@@ -27,6 +27,10 @@ The following Libevent specific CMake variables are as follows (the values being
the default).
```
+# Type of the library to build (SHARED or STATIC)
+# Default is to build BOTH
+EVENT__LIBRARY_TYPE:STRING=DEFAULT
+
# Installation directory for CMake files
EVENT_INSTALL_CMAKE_DIR:PATH=lib/cmake/libevent