summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorScott Talbert <swt@techie.net>2022-01-21 17:26:08 -0500
committerScott Talbert <swt@techie.net>2022-01-21 17:42:01 -0500
commitc84ec53601c12cc0ed1d5115463eb24cb24a6350 (patch)
tree3818ca62a9fd4715e814f2478980e679f1dcde45
parent3e792014dcd932e763838ed4c84aa7737d30edcd (diff)
downloadpycurl-c84ec53601c12cc0ed1d5115463eb24cb24a6350.tar.gz
Support --openssl-dir setup.py argument on Windows
-rw-r--r--setup.py7
1 files changed, 6 insertions, 1 deletions
diff --git a/setup.py b/setup.py
index e0083e3..fb9f266 100644
--- a/setup.py
+++ b/setup.py
@@ -416,6 +416,10 @@ ignore this message.''')
return ssl_lib_detected
def configure_windows(self):
+ OPENSSL_DIR = scan_argv(self.argv, "--openssl-dir=")
+ if OPENSSL_DIR is not None:
+ self.include_dirs.append(os.path.join(OPENSSL_DIR, "include"))
+ self.library_dirs.append(os.path.join(OPENSSL_DIR, "lib"))
# Windows users have to pass --curl-dir parameter to specify path
# to libcurl, because there is no curl-config on windows at all.
curl_dir = scan_argv(self.argv, "--curl-dir=")
@@ -620,7 +624,7 @@ def strip_pycurl_options(argv):
if sys.platform == 'win32':
options = [
'--curl-dir=', '--libcurl-lib-name=', '--use-libcurl-dll',
- '--avoid-stdio', '--with-openssl',
+ '--avoid-stdio', '--with-openssl', '--openssl-dir=',
]
else:
options = ['--openssl-dir=', '--curl-config=', '--avoid-stdio']
@@ -974,6 +978,7 @@ PycURL Windows options:
--use-libcurl-dll link against libcurl DLL, if not given
link against libcurl statically
--libcurl-lib-name=libcurl_imp.lib override libcurl import library name
+ --openssl-dir=/path/to/openssl/dir path to OpenSSL/LibreSSL/BoringSSL headers and libraries
--with-openssl libcurl is linked against OpenSSL/LibreSSL/BoringSSL
--with-ssl legacy alias for --with-openssl
--link-arg=foo.lib also link against specified library