Skip to content

Commit 71129be

Browse files
Add support for 3.7.3 python version (actions#219)
1 parent dfc7050 commit 71129be

File tree

2 files changed

+10
-1
lines changed

2 files changed

+10
-1
lines changed

builders/macos-python-builder.psm1

+8
Original file line numberDiff line numberDiff line change
@@ -64,6 +64,14 @@ class macOSPythonBuilder : NixPythonBuilder {
6464
$env:CFLAGS = "-I/usr/local/opt/openssl@1.1/include -I/usr/local/opt/zlib/include"
6565
} else {
6666
$configureString += " --with-openssl=/usr/local/opt/openssl@1.1"
67+
68+
# 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
69+
# with the error: zipimport.ZipImportError: can't decompress data; zlib not available
70+
if ($this.Version -eq "3.7.2" -or $this.Version -eq "3.7.3") {
71+
$env:LDFLAGS = "-L/usr/local/opt/zlib/lib"
72+
$env:CFLAGS = "-I/usr/local/opt/zlib/include"
73+
}
74+
6775
if ($this.Version -gt "3.7.12") {
6876
$configureString += " --with-tcltk-includes='-I /usr/local/opt/tcl-tk/include' --with-tcltk-libs='-L/usr/local/opt/tcl-tk/lib -ltcl8.6 -ltk8.6'"
6977
}

tests/python-tests.ps1

+2-1
Original file line numberDiff line numberDiff line change
@@ -93,7 +93,8 @@ Describe "Tests" {
9393
It "Validate Pyinstaller" {
9494
"pip install pyinstaller" | Should -ReturnZeroExitCode
9595
"pyinstaller --onefile ./sources/simple-test.py" | Should -ReturnZeroExitCode
96-
"./dist/simple-test" | Should -ReturnZeroExitCode
96+
$distPath = [IO.Path]::Combine($pwd, "dist", "simple-test")
97+
"$distPath" | Should -ReturnZeroExitCode
9798
}
9899
}
99100

0 commit comments

Comments
 (0)