From 3af0e76d1e71995b7790c74e79b76af86ee7c681 Mon Sep 17 00:00:00 2001 From: Daniel Stenberg Date: Sun, 21 Jul 2019 23:48:58 +0200 Subject: HTTP3: initial (experimental) support USe configure --with-ngtcp2 or --with-quiche Using either option will enable a HTTP3 build. Co-authored-by: Alessandro Ghedini Closes #3500 --- lib/quic.c | 38 ++++++++++++++++++++++++++++++++++++++ 1 file changed, 38 insertions(+) create mode 100644 lib/quic.c (limited to 'lib/quic.c') diff --git a/lib/quic.c b/lib/quic.c new file mode 100644 index 000000000..746f00564 --- /dev/null +++ b/lib/quic.c @@ -0,0 +1,38 @@ +/*************************************************************************** + * _ _ ____ _ + * Project ___| | | | _ \| | + * / __| | | | |_) | | + * | (__| |_| | _ <| |___ + * \___|\___/|_| \_\_____| + * + * Copyright (C) 1998 - 2019, Daniel Stenberg, , et al. + * + * This software is licensed as described in the file COPYING, which + * you should have received as part of this distribution. The terms + * are also available at https://curl.haxx.se/docs/copyright.html. + * + * You may opt to use, copy, modify, merge, publish, distribute and/or sell + * copies of the Software, and permit persons to whom the Software is + * furnished to do so, under the terms of the COPYING file. + * + * This software is distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY + * KIND, either express or implied. + * + ***************************************************************************/ + +#include "curl_setup.h" + +#ifdef ENABLE_QUIC +#include "quic.h" +/* backend-independent QUIC functionality */ +const char *Curl_quic_backend(void) +{ +#ifdef USE_NGTCP2 + return "ngtcp2"; +#endif +#ifdef USE_QUICHE + return "quiche"; +#endif +} +#endif + -- cgit v1.2.3