aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNancyLi1013 <46708020+NancyLi1013@users.noreply.github.com>2019-11-19 11:42:34 -0800
committerRobert Schumacher <roschuma@microsoft.com>2019-11-19 11:42:34 -0800
commit058f6e2a35e76ee19fc1d448503efe8a7b8c041f (patch)
tree7db52b562fc20b65e8bd198cc1d8d5a4005ac766
parentff6a725392fcffa647880293e4c0a1352f0d3473 (diff)
downloadvcpkg-058f6e2a35e76ee19fc1d448503efe8a7b8c041f.tar.gz
vcpkg-058f6e2a35e76ee19fc1d448503efe8a7b8c041f.zip
[libevent] add features (#8349)
* [libevent] add features * Update version * Add libevent[openssl] dependent for evpp * Update CONTROL file
-rw-r--r--ports/evpp/CONTROL4
-rw-r--r--ports/libevent/CONTROL9
-rw-r--r--ports/libevent/portfile.cmake8
3 files changed, 17 insertions, 4 deletions
diff --git a/ports/evpp/CONTROL b/ports/evpp/CONTROL
index b9ec8d278..5f367929a 100644
--- a/ports/evpp/CONTROL
+++ b/ports/evpp/CONTROL
@@ -1,5 +1,5 @@
Source: evpp
-Version: 0.7.0-1
+Version: 0.7.0-2
Homepage: https://github.com/Qihoo360/evpp
Description: A modern C++ network library based on libevent for developing high performance network services in TCP/UDP/HTTP protocols.
-Build-Depends: glog, libevent, rapidjson, concurrentqueue (!windows), boost-lockfree (!windows)
+Build-Depends: glog, libevent (windows), libevent[openssl] (!windows), rapidjson, concurrentqueue (!windows), boost-lockfree (!windows) \ No newline at end of file
diff --git a/ports/libevent/CONTROL b/ports/libevent/CONTROL
index a05a77edd..59ee136dd 100644
--- a/ports/libevent/CONTROL
+++ b/ports/libevent/CONTROL
@@ -1,5 +1,12 @@
Source: libevent
-Version: 2.1.11
+Version: 2.1.11-1
Build-Depends: openssl
Homepage: https://github.com/libevent/libevent
Description: An event notification library
+
+Feature: openssl
+Description: Support for openssl
+Build-Depends: openssl
+
+Feature: thread
+Description: Support for thread \ No newline at end of file
diff --git a/ports/libevent/portfile.cmake b/ports/libevent/portfile.cmake
index 1ce0ab450..e04e5f58d 100644
--- a/ports/libevent/portfile.cmake
+++ b/ports/libevent/portfile.cmake
@@ -14,6 +14,12 @@ vcpkg_from_github(
fix-crt_linkage.patch
)
+vcpkg_check_features(OUT_FEATURE_OPTIONS FEATURE_OPTIONS
+ INVERTED_FEATURES
+ openssl EVENT__DISABLE_OPENSSL
+ thread EVENT__DISABLE_THREAD_SUPPORT
+)
+
if (VCPKG_LIBRARY_LINKAGE STREQUAL "dynamic")
set(LIBEVENT_LIB_TYPE SHARED)
else()
@@ -23,7 +29,7 @@ endif()
vcpkg_configure_cmake(
SOURCE_PATH ${SOURCE_PATH}
PREFER_NINJA
- OPTIONS
+ OPTIONS ${FEATURE_OPTIONS}
-DEVENT_INSTALL_CMAKE_DIR:PATH=share/libevent
-DEVENT__LIBRARY_TYPE=${LIBEVENT_LIB_TYPE}
-DVCPKG_CRT_LINKAGE=${VCPKG_CRT_LINKAGE}