diff options
| author | Griffin Downs <grdowns@microsoft.com> | 2019-02-27 16:44:17 -0800 |
|---|---|---|
| committer | Griffin Downs <grdowns@microsoft.com> | 2019-02-27 16:44:17 -0800 |
| commit | 1908903508bf057ad05d8a344e5bc55477944cb6 (patch) | |
| tree | 2a23595f1e7d8cc9a6358bfd44a00eb7368d8a1b /ports/wt | |
| parent | b0a2ff18c9f2c9131aed131f5bf0d97c0e23da8e (diff) | |
| parent | 8564602d06d7c4ce236f96a4f0f3ba7c2d769cb0 (diff) | |
| download | vcpkg-1908903508bf057ad05d8a344e5bc55477944cb6.tar.gz vcpkg-1908903508bf057ad05d8a344e5bc55477944cb6.zip | |
Merge branch 'master' of https://github.com/microsoft/vcpkg into dev/grdowns/4802
Diffstat (limited to 'ports/wt')
| -rw-r--r-- | ports/wt/0001-boost-1.66.patch | 370 | ||||
| -rw-r--r-- | ports/wt/0004-link-ssl.patch | 46 | ||||
| -rw-r--r-- | ports/wt/CONTROL | 2 | ||||
| -rw-r--r-- | ports/wt/portfile.cmake | 13 |
4 files changed, 56 insertions, 375 deletions
diff --git a/ports/wt/0001-boost-1.66.patch b/ports/wt/0001-boost-1.66.patch deleted file mode 100644 index b11ffdb05..000000000 --- a/ports/wt/0001-boost-1.66.patch +++ /dev/null @@ -1,370 +0,0 @@ -From a0fd67d85947c835cd55078edacf3c2ac84ca53f Mon Sep 17 00:00:00 2001 -From: Robert Schumacher <roschuma@microsoft.com> -Date: Fri, 23 Feb 2018 03:12:00 -0800 -Subject: [PATCH 1/3] boost 1.66 - - -diff --git a/src/Wt/Http/Client.C b/src/Wt/Http/Client.C -index 85230d1..a2c893e 100644 ---- a/src/Wt/Http/Client.C -+++ b/src/Wt/Http/Client.C -@@ -642,7 +642,7 @@ private: - - protected: - asio::io_service& ioService_; -- asio::strand strand_; -+ asio::io_context::strand strand_; - tcp::resolver resolver_; - asio::streambuf requestBuf_; - asio::streambuf responseBuf_; -diff --git a/src/Wt/Http/Client.h b/src/Wt/Http/Client.h -index f3c7169..0f638e8 100644 ---- a/src/Wt/Http/Client.h -+++ b/src/Wt/Http/Client.h -@@ -21,11 +21,7 @@ - #include <string> - - #ifdef WT_ASIO_IS_BOOST_ASIO --namespace boost { -- namespace asio { -- class io_service; -- } --} -+#include <boost/asio/io_service.hpp> - #else // WT_ASIO_IS_STANDALONE_ASIO - namespace asio { - class io_service; -diff --git a/src/http/Connection.C b/src/http/Connection.C -index cab7708..cca4e0a 100644 ---- a/src/http/Connection.C -+++ b/src/http/Connection.C -@@ -78,7 +78,7 @@ void Connection::scheduleStop() - - void Connection::start() - { -- LOG_DEBUG(socket().native() << ": start()"); -+ LOG_DEBUG(socket().native_handle() << ": start()"); - - request_parser_.reset(); - request_.reset(); -@@ -106,7 +106,7 @@ void Connection::stop() - void Connection::setReadTimeout(int seconds) - { - if (seconds != 0) { -- LOG_DEBUG(socket().native() << " setting read timeout (ws: " -+ LOG_DEBUG(socket().native_handle() << " setting read timeout (ws: " - << request_.webSocketVersion << ")"); - state_ |= Reading; - -@@ -118,7 +118,7 @@ void Connection::setReadTimeout(int seconds) - - void Connection::setWriteTimeout(int seconds) - { -- LOG_DEBUG(socket().native() << " setting write timeout (ws: " -+ LOG_DEBUG(socket().native_handle() << " setting write timeout (ws: " - << request_.webSocketVersion << ")"); - state_ |= Writing; - -@@ -129,7 +129,7 @@ void Connection::setWriteTimeout(int seconds) - - void Connection::cancelReadTimer() - { -- LOG_DEBUG(socket().native() << " cancel read timeout"); -+ LOG_DEBUG(socket().native_handle() << " cancel read timeout"); - state_.clear(Reading); - - readTimer_.cancel(); -@@ -137,7 +137,7 @@ void Connection::cancelReadTimer() - - void Connection::cancelWriteTimer() - { -- LOG_DEBUG(socket().native() << " cancel write timeout"); -+ LOG_DEBUG(socket().native_handle() << " cancel write timeout"); - state_.clear(Writing); - - writeTimer_.cancel(); -@@ -163,7 +163,7 @@ void Connection::handleReadRequest0() - - #ifdef DEBUG - try { -- LOG_DEBUG(socket().native() << "incoming request: " -+ LOG_DEBUG(socket().native_handle() << "incoming request: " - << socket().remote_endpoint().port() << " (avail= " - << (rcv_buffer_size_ - (rcv_remaining_ - buffer.data())) << "): " - << std::string(rcv_remaining_, -@@ -189,7 +189,7 @@ void Connection::handleReadRequest0() - if (doWebSockets) - request_.enableWebSocket(); - -- LOG_DEBUG(socket().native() << "request: " << status); -+ LOG_DEBUG(socket().native_handle() << "request: " << status); - - if (status >= 300) - sendStockReply(status); -@@ -242,7 +242,7 @@ void Connection::sendStockReply(StockReply::status_type status) - void Connection::handleReadRequest(const Wt::AsioWrapper::error_code& e, - std::size_t bytes_transferred) - { -- LOG_DEBUG(socket().native() << ": handleReadRequest(): " << e.message()); -+ LOG_DEBUG(socket().native_handle() << ": handleReadRequest(): " << e.message()); - - cancelReadTimer(); - -@@ -261,7 +261,7 @@ void Connection::close() - cancelReadTimer(); - cancelWriteTimer(); - -- LOG_DEBUG(socket().native() << ": close()"); -+ LOG_DEBUG(socket().native_handle() << ": close()"); - - ConnectionManager_.stop(shared_from_this()); - } -@@ -274,7 +274,7 @@ bool Connection::closed() const - - void Connection::handleError(const Wt::AsioWrapper::error_code& e) - { -- LOG_DEBUG(socket().native() << ": error: " << e.message()); -+ LOG_DEBUG(socket().native_handle() << ": error: " << e.message()); - - close(); - } -@@ -349,7 +349,7 @@ void Connection::handleReadBody0(ReplyPtr reply, - const Wt::AsioWrapper::error_code& e, - std::size_t bytes_transferred) - { -- LOG_DEBUG(socket().native() << ": handleReadBody0(): " << e.message()); -+ LOG_DEBUG(socket().native_handle() << ": handleReadBody0(): " << e.message()); - - if (disconnectCallback_) { - if (e && e != asio::error::operation_aborted) { -@@ -357,7 +357,7 @@ void Connection::handleReadBody0(ReplyPtr reply, - disconnectCallback_ = boost::function<void()>(); - f(); - } else if (!e) { -- LOG_ERROR(socket().native() -+ LOG_ERROR(socket().native_handle() - << ": handleReadBody(): while waiting for disconnect, " - "received unexpected data, closing"); - close(); -@@ -403,14 +403,14 @@ void Connection::startWriteResponse(ReplyPtr reply) - int size = asio::buffer_size(buffers[i]); - s += size; - #ifdef DEBUG_DUMP -- char *data = (char *)asio::detail::buffer_cast_helper(buffers[i]); -+ char *data = asio::buffer_cast<char*>(buffers[i]); - for (int j = 0; j < size; ++j) - std::cerr << data[j]; - #endif - } - #endif - -- LOG_DEBUG(socket().native() << " sending: " << s << "(buffers: " -+ LOG_DEBUG(socket().native_handle() << " sending: " << s << "(buffers: " - << buffers.size() << ")"); - - if (!buffers.empty()) { -@@ -423,7 +423,7 @@ void Connection::startWriteResponse(ReplyPtr reply) - - void Connection::handleWriteResponse(ReplyPtr reply) - { -- LOG_DEBUG(socket().native() << ": handleWriteResponse() " << -+ LOG_DEBUG(socket().native_handle() << ": handleWriteResponse() " << - haveResponse_ << " " << responseDone_); - if (haveResponse_) - startWriteResponse(reply); -@@ -458,7 +458,7 @@ void Connection::handleWriteResponse0(ReplyPtr reply, - const Wt::AsioWrapper::error_code& e, - std::size_t bytes_transferred) - { -- LOG_DEBUG(socket().native() << ": handleWriteResponse0(): " -+ LOG_DEBUG(socket().native_handle() << ": handleWriteResponse0(): " - << bytes_transferred << " ; " << e.message()); - - cancelWriteTimer(); -diff --git a/src/http/Connection.h b/src/http/Connection.h -index b0b71a3..bc0b6ed 100644 ---- a/src/http/Connection.h -+++ b/src/http/Connection.h -@@ -61,7 +61,7 @@ public: - virtual ~Connection(); - - Server *server() const { return server_; } -- asio::strand& strand() { return strand_; } -+ asio::io_context::strand& strand() { return strand_; } - - /// Stop all asynchronous operations associated with the connection. - void scheduleStop(); -@@ -104,7 +104,7 @@ protected: - /// The manager for this connection. - ConnectionManager& ConnectionManager_; - -- asio::strand strand_; -+ asio::io_context::strand strand_; - - void finishReply(); - -diff --git a/src/http/Reply.C b/src/http/Reply.C -index 0d79e39..5e6c615 100644 ---- a/src/http/Reply.C -+++ b/src/http/Reply.C -@@ -596,7 +596,7 @@ bool Reply::encodeNextContentBuffer( - originalSize += bs; - - gzipStrm_.avail_in = bs; -- gzipStrm_.next_in = (unsigned char *)asio::detail::buffer_cast_helper(b); -+ gzipStrm_.next_in = (unsigned char *)b.data(); - - unsigned char out[16*1024]; - do { -diff --git a/src/http/Server.h b/src/http/Server.h -index 3d3229a..373073f 100644 ---- a/src/http/Server.h -+++ b/src/http/Server.h -@@ -129,7 +129,7 @@ private: - Wt::WLogger accessLogger_; - - /// The strand for handleTcpAccept(), handleSslAccept() and handleStop() -- asio::strand accept_strand_; -+ asio::io_context::strand accept_strand_; - - /// Acceptors used to listen for incoming http connections. - std::vector<TcpListener> tcp_listeners_; -diff --git a/src/http/SessionProcess.C b/src/http/SessionProcess.C -index 72d9a88..92320b0 100644 ---- a/src/http/SessionProcess.C -+++ b/src/http/SessionProcess.C -@@ -80,7 +80,7 @@ void SessionProcess::asyncExec(const Configuration &config, - if (!ec) - acceptor_->listen(0, ec); - #ifndef WT_WIN32 -- fcntl(acceptor_->native(), F_SETFD, FD_CLOEXEC); -+ fcntl(acceptor_->native_handle(), F_SETFD, FD_CLOEXEC); - #endif // !WT_WIN32 - if (ec) { - LOG_ERROR("Couldn't create listening socket: " << ec.message()); -diff --git a/src/http/SslConnection.C b/src/http/SslConnection.C -index 74c8642..2c34b53 100644 ---- a/src/http/SslConnection.C -+++ b/src/http/SslConnection.C -@@ -81,9 +81,9 @@ void SslConnection::handleHandshake(const Wt::AsioWrapper::error_code& error) - - void SslConnection::stop() - { -- LOG_DEBUG(socket().native() << ": stop()"); -+ LOG_DEBUG(socket().native_handle() << ": stop()"); - finishReply(); -- LOG_DEBUG(socket().native() << ": SSL shutdown"); -+ LOG_DEBUG(socket().native_handle() << ": SSL shutdown"); - - Connection::stop(); - -@@ -108,20 +108,20 @@ void SslConnection::stopNextLayer(const Wt::AsioWrapper::error_code& ec) - // In case of timeout, we will get here twice. - sslShutdownTimer_.cancel(); - if (ec) { -- LOG_DEBUG(socket().native() << ": ssl_shutdown failed:" -+ LOG_DEBUG(socket().native_handle() << ": ssl_shutdown failed:" - << ec.message()); - } - try { - if (socket().is_open()) { - Wt::AsioWrapper::error_code ignored_ec; -- LOG_DEBUG(socket().native() << ": socket shutdown"); -+ LOG_DEBUG(socket().native_handle() << ": socket shutdown"); - socket().shutdown(asio::ip::tcp::socket::shutdown_both, - ignored_ec); -- LOG_DEBUG(socket().native() << "closing socket"); -+ LOG_DEBUG(socket().native_handle() << "closing socket"); - socket().close(); - } - } catch (Wt::AsioWrapper::system_error& e) { -- LOG_DEBUG(socket().native() << ": error " << e.what()); -+ LOG_DEBUG(socket().native_handle() << ": error " << e.what()); - } - } - -@@ -161,7 +161,7 @@ void SslConnection::startAsyncReadBody(ReplyPtr reply, - Buffer& buffer, int timeout) - { - if (state_ & Reading) { -- LOG_DEBUG(socket().native() << ": state_ = " -+ LOG_DEBUG(socket().native_handle() << ": state_ = " - << (state_ & Reading ? "reading " : "") - << (state_ & Writing ? "writing " : "")); - stop(); -@@ -198,7 +198,7 @@ void SslConnection - int timeout) - { - if (state_ & Writing) { -- LOG_DEBUG(socket().native() << ": state_ = " -+ LOG_DEBUG(socket().native_handle() << ": state_ = " - << (state_ & Reading ? "reading " : "") - << (state_ & Writing ? "writing " : "")); - stop(); -diff --git a/src/http/TcpConnection.C b/src/http/TcpConnection.C -index ad73164..4eaf83b 100644 ---- a/src/http/TcpConnection.C -+++ b/src/http/TcpConnection.C -@@ -38,17 +38,17 @@ asio::ip::tcp::socket& TcpConnection::socket() - - void TcpConnection::stop() - { -- LOG_DEBUG(socket().native() << ": stop()"); -+ LOG_DEBUG(socket().native_handle() << ": stop()"); - - finishReply(); - - try { - Wt::AsioWrapper::error_code ignored_ec; - socket_.shutdown(asio::ip::tcp::socket::shutdown_both, ignored_ec); -- LOG_DEBUG(socket().native() << ": closing socket"); -+ LOG_DEBUG(socket().native_handle() << ": closing socket"); - socket_.close(); - } catch (Wt::AsioWrapper::system_error& e) { -- LOG_DEBUG(socket().native() << ": error " << e.what()); -+ LOG_DEBUG(socket().native_handle() << ": error " << e.what()); - } - - Connection::stop(); -@@ -56,10 +56,10 @@ void TcpConnection::stop() - - void TcpConnection::startAsyncReadRequest(Buffer& buffer, int timeout) - { -- LOG_DEBUG(socket().native() << ": startAsyncReadRequest"); -+ LOG_DEBUG(socket().native_handle() << ": startAsyncReadRequest"); - - if (state_ & Reading) { -- LOG_DEBUG(socket().native() << ": state_ = " -+ LOG_DEBUG(socket().native_handle() << ": state_ = " - << (state_ & Reading ? "reading " : "") - << (state_ & Writing ? "writing " : "")); - stop(); -@@ -81,10 +81,10 @@ void TcpConnection::startAsyncReadRequest(Buffer& buffer, int timeout) - void TcpConnection::startAsyncReadBody(ReplyPtr reply, - Buffer& buffer, int timeout) - { -- LOG_DEBUG(socket().native() << ": startAsyncReadBody"); -+ LOG_DEBUG(socket().native_handle() << ": startAsyncReadBody"); - - if (state_ & Reading) { -- LOG_DEBUG(socket().native() << ": state_ = " -+ LOG_DEBUG(socket().native_handle() << ": state_ = " - << (state_ & Reading ? "reading " : "") - << (state_ & Writing ? "writing " : "")); - stop(); -@@ -109,10 +109,10 @@ void TcpConnection::startAsyncWriteResponse - const std::vector<asio::const_buffer>& buffers, - int timeout) - { -- LOG_DEBUG(socket().native() << ": startAsyncWriteResponse"); -+ LOG_DEBUG(socket().native_handle() << ": startAsyncWriteResponse"); - - if (state_ & Writing) { -- LOG_DEBUG(socket().native() << ": state_ = " -+ LOG_DEBUG(socket().native_handle() << ": state_ = " - << (state_ & Reading ? "reading " : "") - << (state_ & Writing ? "writing " : "")); - stop(); --- -2.16.2.windows.1 - diff --git a/ports/wt/0004-link-ssl.patch b/ports/wt/0004-link-ssl.patch new file mode 100644 index 000000000..8579223dc --- /dev/null +++ b/ports/wt/0004-link-ssl.patch @@ -0,0 +1,46 @@ +diff --git a/cmake/WtFindSsl.txt b/cmake/WtFindSsl.txt +index c5f7bbc8..6e2c2f4d 100644 +--- a/cmake/WtFindSsl.txt ++++ b/cmake/WtFindSsl.txt +@@ -121,6 +121,16 @@ ELSEIF(APPLE) + /usr/local/lib + NO_DEFAULT_PATH + ) ++ FIND_LIBRARY(CRYPTO_LIB ++ NAMES ++ crypto ++ PATHS ++ ${SSL_PREFIX}/lib ++ ${SSL_PREFIX}/lib/VC ++ /usr/lib ++ /usr/local/lib ++ NO_DEFAULT_PATH ++ ) + ELSE (WIN32) + FIND_LIBRARY(SSL_LIB + NAMES +@@ -131,6 +141,15 @@ ELSE (WIN32) + /usr/lib + /usr/local/lib + ) ++ FIND_LIBRARY(CRYPTO_LIB ++ NAMES ++ crypto ++ PATHS ++ ${SSL_PREFIX}/lib ++ ${SSL_PREFIX}/lib/VC ++ /usr/lib ++ /usr/local/lib ++ ) + ENDIF (WIN32) + + IF(SSL_LIB +@@ -144,7 +163,7 @@ IF(SSL_LIB + ENDIF(SSL_TOO_LIB) + ELSE(WIN32) + SET(SSL_FOUND true) +- SET(SSL_LIBRARIES ${SSL_LIB} -lcrypto) ++ SET(SSL_LIBRARIES ${SSL_LIB} ${CRYPTO_LIB}) + ENDIF(WIN32) + ENDIF(SSL_LIB + AND SSL_INCLUDE_DIRS) diff --git a/ports/wt/CONTROL b/ports/wt/CONTROL index ff99b10b5..5db330a5c 100644 --- a/ports/wt/CONTROL +++ b/ports/wt/CONTROL @@ -1,4 +1,4 @@ Source: wt -Version: 4.0.4 +Version: 4.0.5 Description: Wt is a C++ library for developing web applications Build-Depends: openssl, sqlite3, libpq, pango, glew, boost-date-time, boost-regex, boost-program-options, boost-signals, boost-system, boost-filesystem, boost-thread, boost-random, boost-multi-index, boost-signals2, boost-asio, boost-ublas, boost-conversion, boost-array, boost-smart-ptr, boost-tuple, boost-algorithm, boost-logic, boost-interprocess diff --git a/ports/wt/portfile.cmake b/ports/wt/portfile.cmake index 614480168..c9fb520f6 100644 --- a/ports/wt/portfile.cmake +++ b/ports/wt/portfile.cmake @@ -3,13 +3,13 @@ include(vcpkg_common_functions) vcpkg_from_github( OUT_SOURCE_PATH SOURCE_PATH REPO emweb/wt - REF 4.0.4 - SHA512 7f9fee9b1c145adb610bf9b0860867a2f09699a1c914418938955c5648b3207db361ec48b3afe9e6faa6cc0b5874bedd44481fdd8adb8fc558cfc3dc17369ee7 + REF 4.0.5 + SHA512 5513b428bfd3e778726c947606677f3e0774b38e640e61cd94906a2e0c75d204a68072b54ddeb3614a7ba08f5668e6eb3a96d9c8df3744b09dc36ad9be12d924 HEAD_REF master PATCHES - 0001-boost-1.66.patch 0002-link-glew.patch 0003-disable-boost-autolink.patch + 0004-link-ssl.patch ) string(COMPARE EQUAL "${VCPKG_LIBRARY_LINKAGE}" "dynamic" SHARED_LIBS) @@ -36,13 +36,18 @@ vcpkg_configure_cmake( -DUSE_SYSTEM_SQLITE3=ON -DUSE_SYSTEM_GLEW=ON + + -DCMAKE_INSTALL_DIR=share ) vcpkg_install_cmake() -vcpkg_fixup_cmake_targets(CONFIG_PATH lib/cmake/wt) +vcpkg_fixup_cmake_targets(CONFIG_PATH share/wt) # There is no way to suppress installation of the headers and resource files in debug build. file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/debug/include ${CURRENT_PACKAGES_DIR}/debug/share) +file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/var) +file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/debug/var) + file(INSTALL ${SOURCE_PATH}/LICENSE DESTINATION ${CURRENT_PACKAGES_DIR}/share/wt RENAME copyright) vcpkg_copy_pdbs() |
