From 63e0baf37c8024174aa4bacb12dccc7040de74d8 Mon Sep 17 00:00:00 2001 From: Garrett D'Amore Date: Thu, 28 Dec 2017 20:52:15 -0800 Subject: fixes #172 HTTP and websocket need better conditional inclusion --- CMakeLists.txt | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) (limited to 'CMakeLists.txt') diff --git a/CMakeLists.txt b/CMakeLists.txt index 8e1ef153..df8a58f5 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -5,7 +5,7 @@ # Copyright (c) 2013 GoPivotal, Inc. All rights reserved. # Copyright (c) 2015-2016 Jack R. Dunaway. All rights reserved. # Copyright 2016 Franklin "Snaipe" Mathieu -# Copyright 2017 Garrett D'Amore +# Copyright 2017 Staysail Systems, Inc. # # Permission is hereby granted, free of charge, to any person obtaining a copy # of this software and associated documentation files (the "Software"), @@ -171,6 +171,7 @@ endif () option (NNG_TRANSPORT_WS "Enable WebSocket transport." ON) if (NNG_TRANSPORT_WS) add_definitions (-DNNG_HAVE_WEBSOCKET) + set(NNG_SUPP_WEBSOCKET ON) endif () option (NNG_TRANSPORT_ZEROTIER "Enable ZeroTier transport (requires libzerotiercore)." OFF) @@ -185,6 +186,13 @@ if (NNG_TRANSPORT_TLS) add_definitions (-DNNG_HAVE_TLS) endif() +# dependencies +if (NNG_SUPP_WEBSOCKET) + set(NNG_SUPP_HTTP ON) + set(NNG_SUPP_BASE64 ON) + set(NNG_SUPP_SHA1 ON) +endif() + # Platform checks. if (NNG_ENABLE_COVERAGE) -- cgit v1.2.3-70-g09d2