Actions: windows extract env var

This commit is contained in:
Dennis Fokin 2020-01-28 13:09:21 +01:00
parent 3cc00d214a
commit a46a6e4ed3
2 changed files with 10 additions and 8 deletions

View File

@ -5,6 +5,7 @@ on: [push, pull_request]
env:
PYTHON_VER: '3.8.1'
PYTHON_VER_DIRNAME: 'python38'
PYOTHERSIDE_VER: '1.5.9'
jobs:
build:
@ -21,7 +22,7 @@ jobs:
- name: Download dependencies
run: |
wget https://download.qt.io/official_releases/jom/jom.zip -OutFile jom.zip
wget https://github.com/thp/pyotherside/archive/1.5.9.zip -OutFile pyotherside-1.5.9.zip
wget https://github.com/thp/pyotherside/archive/$env:PYOTHERSIDE_VER.zip -OutFile pyotherside-$env:PYOTHERSIDE_VER.zip
wget https://developers.yubico.com/yubikey-personalization/Releases/ykpers-1.20.0-win64.zip -OutFile ykpers-1.20.0-win64.zip
wget https://developers.yubico.com/yubikey-personalization/Releases/ykpers-1.20.0-win64.zip.sig -OutFile ykpers-1.20.0-win64.zip.sig
wget https://github.com/libusb/libusb/releases/download/v1.0.22/libusb-1.0.22.7z -OutFile libusb-1.0.22.7z
@ -47,8 +48,8 @@ jobs:
- name: Prepare pyotherside
run: |
7z x pyotherside-1.5.9.zip
cd pyotherside-1.5.9
7z x pyotherside-$env:PYOTHERSIDE_VER.zip
cd pyotherside-$env:PYOTHERSIDE_VER
(Get-Content .\src\qmldir).replace('pyothersideplugin', 'pyothersideplugin1') | Set-Content .\src\qmldir
Clear-Content python.pri
Add-Content python.pri "PYTHON_CONFIG = python3-config`nQMAKE_LIBS += -LC:\hostedtoolcache\windows\Python\$env:PYTHON_VER\x64\libs -l$env:PYTHON_VER_DIRNAME`nQMAKE_CXXFLAGS += -IC:\hostedtoolcache\windows\Python\$env:PYTHON_VER\x64\include`n"
@ -58,7 +59,7 @@ jobs:
run: |
set PATH=D:\a\yubioath-desktop\yubioath-desktop\5.14.0\msvc2017_64\bin;D:\a\yubioath-desktop\yubioath-desktop;%PATH%
call C:\"Program Files (x86)\Microsoft Visual Studio"\2019\Enterprise\VC\Auxiliary\Build\vcvarsall.bat x64
cd pyotherside-1.5.9
cd pyotherside-$env:PYOTHERSIDE_VER
qmake
jom
jom install

View File

@ -5,6 +5,7 @@ on: [push, pull_request]
env:
PYTHON_VER: '3.8.1'
PYTHON_VER_DIRNAME: 'python38'
PYOTHERSIDE_VER: '1.5.9'
jobs:
build:
@ -21,7 +22,7 @@ jobs:
- name: Download dependencies
run: |
wget https://download.qt.io/official_releases/jom/jom.zip -OutFile jom.zip
wget https://github.com/thp/pyotherside/archive/1.5.9.zip -OutFile pyotherside-1.5.9.zip
wget https://github.com/thp/pyotherside/archive/$env:PYOTHERSIDE_VER.zip -OutFile pyotherside-$env:PYOTHERSIDE_VER.zip
wget https://developers.yubico.com/yubikey-personalization/Releases/ykpers-1.20.0-win32.zip -OutFile ykpers-1.20.0-win32.zip
wget https://developers.yubico.com/yubikey-personalization/Releases/ykpers-1.20.0-win32.zip.sig -OutFile ykpers-1.20.0-win32.zip.sig
wget https://github.com/libusb/libusb/releases/download/v1.0.22/libusb-1.0.22.7z -OutFile libusb-1.0.22.7z
@ -48,8 +49,8 @@ jobs:
- name: Prepare pyotherside
run: |
7z x pyotherside-1.5.9.zip
cd pyotherside-1.5.9
7z x pyotherside-$env:PYOTHERSIDE_VER.zip
cd pyotherside-$env:PYOTHERSIDE_VER
(Get-Content .\src\qmldir).replace('pyothersideplugin', 'pyothersideplugin1') | Set-Content .\src\qmldir
Clear-Content python.pri
Add-Content python.pri "PYTHON_CONFIG = python3-config`nQMAKE_LIBS += -LC:\hostedtoolcache\windows\Python\$env:PYTHON_VER\x86\libs -l$env:PYTHON_VER_DIRNAME`nQMAKE_CXXFLAGS += -IC:\hostedtoolcache\windows\Python\$env:PYTHON_VER\x86\include`n"
@ -59,7 +60,7 @@ jobs:
run: |
set PATH=D:\a\yubioath-desktop\yubioath-desktop\5.14.0\msvc2017\bin;D:\a\yubioath-desktop\yubioath-desktop;%PATH%
call C:\"Program Files (x86)\Microsoft Visual Studio"\2019\Enterprise\VC\Auxiliary\Build\vcvarsall.bat x86
cd pyotherside-1.5.9
cd pyotherside-$env:PYOTHERSIDE_VER
qmake
jom
jom install