forked from love2d/lua-https
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathconfig.h
More file actions
54 lines (50 loc) · 1.48 KB
/
config.h
File metadata and controls
54 lines (50 loc) · 1.48 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
#pragma once
// MSVC warnings
#if defined(_MSC_VER) && !defined(_CRT_SECURE_NO_WARNINGS)
#define _CRT_SECURE_NO_WARNINGS
#endif
#if defined(HTTPS_HAVE_CONFIG_GENERATED_H)
#include "common/config-generated.h"
#elif defined(WIN32) || defined(_WIN32)
#define HTTPS_BACKEND_SCHANNEL
#define HTTPS_USE_WINSOCK
#define HTTPS_LIBRARY_LOADER_WINDOWS
#include <winapifamily.h>
#if !defined(WINAPI_FAMILY) || (WINAPI_FAMILY == WINAPI_FAMILY_DESKTOP_APP)
// WinINet is only supported on desktop.
#define HTTPS_BACKEND_WININET
#endif
// Visual Studio 2017 supports __has_include
#if defined __has_include
#if __has_include(<curl/curl.h>)
#define HTTPS_BACKEND_CURL
#endif
#endif
#elif defined(__ANDROID__)
#define HTTPS_BACKEND_ANDROID
#define HTTPS_LIBRARY_LOADER_UNIX
#elif defined(__APPLE__)
#define HTTPS_BACKEND_NSURL
#define HTTPS_LIBRARY_LOADER_UNIX
#elif defined(linux) || defined(__linux) || defined(__linux__)
#define HTTPS_LIBRARY_LOADER_UNIX
#if defined __has_include
#if __has_include(<curl/curl.h>)
#define HTTPS_BACKEND_CURL
#endif
#if __has_include(<openssl/ssl.h>)
#define HTTPS_BACKEND_OPENSSL
#endif
#else
// Hope for the best...
#define HTTPS_BACKEND_CURL
#define HTTPS_BACKEND_OPENSSL
#endif
#endif
#if defined(WIN32) || defined(_WIN32) || defined(__CYGWIN__)
#define HTTPS_DLLEXPORT __declspec(dllexport)
#elif defined(__GNUC__) || defined(__clang__)
#define HTTPS_DLLEXPORT __attribute__ ((visibility("default")))
#else
#define HTTPS_DLLEXPORT
#endif