mirror of
https://github.com/OpenVPN/openvpn3.git
synced 2024-09-20 12:12:15 +02:00
691a641a43
Created a lightweight abstraction layer so that another i/o reactor can be dropped in place of asio. The basic approach is to rename all references to asio::xxx types to openvpn_io::xxx and then make openvpn_io a preprocessor variable that points to the top-level namespace of the i/o reactor implementation. All of the source files that currently include <asio.hpp> now include <openvpn/io/io.hpp> instead: This gives us a lightweight abstraction layer that allows us to define openvpn_io to be something other than asio. Other changes: * Inclusion of asio by scripts/build is now optional, and is enabled by passing ASIO=1 or ASIO_DIR=<dir>. * Refactored openvpn/common/socktypes.hpp to no longer require asio. * Refactored openvpn/log/logthread.hpp to no longer require asio. * Added openvpn::get_hostname() method as alternative to calling asio directly. * openvpn/openssl/util/init.hpp will now #error if USE_ASIO is undefined. Signed-off-by: James Yonan <james@openvpn.net>
24 lines
511 B
Bash
Executable File
24 lines
511 B
Bash
Executable File
#!/bin/bash
|
|
if [ "$(uname)" == "Darwin" ]; then
|
|
cd $O3/core
|
|
. vars/vars-osx64
|
|
. vars/setpath
|
|
cd test/ssl
|
|
ASIO=1 MTLS=1 build proto
|
|
else
|
|
cd $O3/core
|
|
. vars/vars-linux
|
|
. vars/setpath
|
|
cd test/ssl
|
|
if [ "$MO_HYBRID" = "1" ]; then
|
|
# mbedTLS client, OpenSSL server
|
|
ASIO=1 OPENSSL_SYS=1 MTLS=1 build proto
|
|
elif [ "$OSSL" = "1" ]; then
|
|
# OpenSSL client/server
|
|
ASIO=1 OPENSSL_SYS=1 build proto
|
|
else
|
|
# mbedTLS client/server
|
|
ASIO=1 MTLS=1 NOSSL=1 build proto
|
|
fi
|
|
fi
|