mirror of
https://github.com/actions/python-versions.git
synced 2025-04-04 14:29:38 +00:00
Update openssl 1.1 to 3 (#316)
* Update openssl to 3 * openssl update 3
This commit is contained in:
@ -68,10 +68,10 @@ class macOSPythonBuilder : NixPythonBuilder {
|
||||
### and then add the appropriate paths for the header and library files to configure command.
|
||||
### Link to documentation (https://cpython-devguide.readthedocs.io/setup/#build-dependencies)
|
||||
if ($this.Version -lt "3.7.0") {
|
||||
$env:LDFLAGS = "-L/usr/local/opt/openssl@1.1/lib -L/usr/local/opt/zlib/lib"
|
||||
$env:CFLAGS = "-I/usr/local/opt/openssl@1.1/include -I/usr/local/opt/zlib/include"
|
||||
$env:LDFLAGS = "-L/usr/local/opt/openssl@3/lib -L/usr/local/opt/zlib/lib"
|
||||
$env:CFLAGS = "-I/usr/local/opt/openssl@3/include -I/usr/local/opt/zlib/include"
|
||||
} else {
|
||||
$configureString += " --with-openssl=/usr/local/opt/openssl@1.1"
|
||||
$configureString += " --with-openssl=/usr/local/opt/openssl@3"
|
||||
|
||||
# For Python 3.7.2 and 3.7.3 we need to provide PATH for zlib to pack it properly. Otherwise the build will fail
|
||||
# with the error: zipimport.ZipImportError: can't decompress data; zlib not available
|
||||
|
@ -54,15 +54,15 @@ else:
|
||||
if os_type == 'Darwin':
|
||||
### Validate openssl links
|
||||
if version_major == 3 and version_minor < 7:
|
||||
expected_ldflags = '-L/usr/local/opt/openssl@1.1/lib'
|
||||
expected_ldflags = '-L/usr/local/opt/openssl@3/lib'
|
||||
ldflags = sysconfig.get_config_var('LDFLAGS')
|
||||
|
||||
if not expected_ldflags in ldflags:
|
||||
print('Invalid ldflags: %s; Expected: %s' % (ldflags, expected_ldflags))
|
||||
exit(1)
|
||||
else:
|
||||
expected_openssl_includes = '-I/usr/local/opt/openssl@1.1/include'
|
||||
expected_openssl_ldflags ='-L/usr/local/opt/openssl@1.1/lib'
|
||||
expected_openssl_includes = '-I/usr/local/opt/openssl@3/include'
|
||||
expected_openssl_ldflags ='-L/usr/local/opt/openssl@3/lib'
|
||||
|
||||
openssl_includes = sysconfig.get_config_var('OPENSSL_INCLUDES')
|
||||
openssl_ldflags = sysconfig.get_config_var('OPENSSL_LDFLAGS')
|
||||
|
Reference in New Issue
Block a user