config.h 916 B

123456789101112131415161718192021222324252627282930313233
  1. #pragma once
  2. #if defined(HTTPS_HAVE_CONFIG_GENERATED_H)
  3. #include "common/config-generated.h"
  4. #elif defined(WIN32) || defined(_WIN32)
  5. #define HTTPS_BACKEND_SCHANNEL
  6. #define HTTPS_USE_WINSOCK
  7. #elif defined(__ANDROID__)
  8. #define HTTPS_BACKEND_ANDROID
  9. #elif defined(__APPLE__)
  10. #define HTTPS_BACKEND_NSURL
  11. #elif defined(linux) || defined(__linux) || defined(__linux__)
  12. #if defined __has_include
  13. #if __has_include(<curl/curl.h>)
  14. #define HTTPS_BACKEND_CURL
  15. #endif
  16. #if __has_include(<openssl/ssl.h>)
  17. #define HTTPS_BACKEND_OPENSSL
  18. #endif
  19. #else
  20. // Hope for the best...
  21. #define HTTPS_BACKEND_CURL
  22. #define HTTPS_BACKEND_OPENSSL
  23. #endif
  24. #endif
  25. #if defined(WIN32) || defined(_WIN32) || defined(__CYGWIN__)
  26. #define HTTPS_DLLEXPORT __declspec(dllexport)
  27. #elif defined(__GNUC__) || defined(__clang__)
  28. #define HTTPS_DLLEXPORT __attribute__ ((visibility("default")))
  29. #else
  30. #define HTTPS_DLLEXPORT
  31. #endif