@@ -67,40 +67,49 @@ jobs:
6767 - name : Setup NASM
6868 uses : ilammy/setup-nasm@v1
6969
70- - name : Build a package
70+ - name : Setup OpenBLAS
71+ shell : cmd
7172 run : |
72- python --version
73- python -m pip install --upgrade pip
74- python -m pip install --upgrade setuptools
75- python -m pip install cmake==3.24.2
76- python -m pip install toml && python -c "import toml; c = toml.load('pyproject.toml'); print('\n'.join(c['build-system']['requires']))" >> requirements.txt | python -m pip install -r requirements.txt
77-
7873 setlocal enableextensions enabledelayedexpansion
7974
8075 rem Determine correct architecture
81- if "${{ matrix.platform }} "=="x64" (
76+ if "%{ matrix.platform}% "=="x64" (
8277 set ARCH=x64
8378 set FOLDER=win64
84- ) else (
85- set ARCH=x86
86- set FOLDER=win32
87- )
79+ ) else (
80+ set ARCH=x86
81+ set FOLDER=win32
82+ )
8883
89- echo Using architecture: %ARCH%
9084 mkdir openblas
9185 cd openblas
9286 curl -L -o OpenBLAS.zip https://downloads.sourceforge.net/project/openblas/v0.3.24/OpenBLAS-0.3.24-%ARCH%.zip
9387 powershell -Command "Expand-Archive -Path OpenBLAS.zip -DestinationPath ."
9488
9589 set "OpenBLAS_HOME=%CD%"
90+ echo OpenBLAS_HOME=%OpenBLAS_HOME%
9691 set "PATH=%OpenBLAS_HOME%\bin;%PATH%"
92+
9793 if exist %OpenBLAS_HOME%\bin\libopenblas.dll (
98- copy /y %OpenBLAS_HOME%\bin\libopenblas.dll %OpenBLAS_HOME%\bin\libopenblas.exp.dll
99- )
100-
94+ copy /y %OpenBLAS_HOME%\bin\libopenblas.dll %OpenBLAS_HOME%\bin\libopenblas.exp.dll
95+ )
96+
97+ echo Finished OpenBLAS setup
98+ cd ..
99+ echo set "OpenBLAS_HOME=%OpenBLAS_HOME%" > set_openblas_env.cmd
100+
101+ - name : Build a package
102+ run : |
103+ call set_openblas_env.cmd
104+ python --version
105+ python -m pip install --upgrade pip
106+ python -m pip install --upgrade setuptools
107+ python -m pip install cmake==3.24.2
108+ python -m pip install toml && python -c "import toml; c = toml.load('pyproject.toml'); print('\n'.join(c['build-system']['requires']))" >> requirements.txt | python -m pip install -r requirements.txt
109+
110+ echo Using OpenBLAS_HOME=%OpenBLAS_HOME%
101111 set "CMAKE_ARGS=-DLAPACK=ON -DOpenBLAS_INCLUDE_DIR=%OpenBLAS_HOME%\include -DOpenBLAS_LIBRARIES=%OpenBLAS_HOME%\bin\libopenblas.dll"
102- echo %OpenBLAS_HOME%
103- echo %CMAKE_ARGS%
112+ echo CMAKE_ARGS: %CMAKE_ARGS%
104113 python setup.py bdist_wheel --py-limited-api=cp37 --dist-dir=%cd%\\wheelhouse -v
105114 shell : cmd
106115
0 commit comments