Skip to content

Commit cf3c100

Browse files
committed
Use Windows 2022 rather than deprecated Windows 2019
1 parent 6cd56a5 commit cf3c100

File tree

2 files changed

+37
-45
lines changed

2 files changed

+37
-45
lines changed

azure-pipelines.yml

Lines changed: 12 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -29,18 +29,11 @@ jobs:
2929

3030
- template: conda-build.yml
3131
parameters:
32-
name: Windows_VS2019_python39
33-
vmImage: 'windows-2019'
32+
name: Windows_VS2022_python39
33+
vmImage: 'windows-2022'
3434
py_maj: 3
3535
py_min: 9
3636

37-
- template: conda-build.yml
38-
parameters:
39-
name: Ubuntu_22_04_python310
40-
vmImage: 'ubuntu-22.04'
41-
py_maj: 3
42-
py_min: 10
43-
4437
- template: conda-build.yml
4538
parameters:
4639
name: Ubuntu_24_04_python310
@@ -57,15 +50,15 @@ jobs:
5750

5851
- template: conda-build.yml
5952
parameters:
60-
name: Windows_VS2019_python310
61-
vmImage: 'windows-2019'
53+
name: Windows_VS2022_python310
54+
vmImage: 'windows-2022'
6255
py_maj: 3
6356
py_min: 10
6457

6558
- template: conda-build.yml
6659
parameters:
67-
name: Ubuntu_22_04_python311
68-
vmImage: 'ubuntu-22.04'
60+
name: Ubuntu_24_04_python311
61+
vmImage: 'ubuntu-24.04'
6962
py_maj: 3
7063
py_min: 11
7164

@@ -78,15 +71,15 @@ jobs:
7871

7972
- template: conda-build.yml
8073
parameters:
81-
name: Windows_VS2019_python311
82-
vmImage: 'windows-2019'
74+
name: Windows_VS2022_python311
75+
vmImage: 'windows-2022'
8376
py_maj: 3
8477
py_min: 11
8578

8679
- template: conda-build.yml
8780
parameters:
88-
name: Ubuntu_22_04_python312
89-
vmImage: 'ubuntu-22.04'
81+
name: Ubuntu_24_04_python312
82+
vmImage: 'ubuntu-24.04'
9083
py_maj: 3
9184
py_min: 12
9285

@@ -99,7 +92,7 @@ jobs:
9992

10093
- template: conda-build.yml
10194
parameters:
102-
name: Windows_VS2019_python312
103-
vmImage: 'windows-2019'
95+
name: Windows_VS2022_python312
96+
vmImage: 'windows-2022'
10497
py_maj: 3
10598
py_min: 12

conda-build.yml

Lines changed: 25 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,6 @@ parameters:
33
vmImage: 'ubuntu-22.04'
44
py_maj: '3'
55
py_min: '9'
6-
76
jobs:
87
- job: ${{ parameters.name }}
98
timeoutInMinutes: 360
@@ -31,7 +30,6 @@ jobs:
3130
- ${{ if contains(parameters.vmImage, 'win') }}:
3231
- powershell: Write-Host "##vso[task.prependpath]$env:CONDA\Scripts"
3332
displayName: 'Add conda to PATH'
34-
3533
# Ubuntu install opengl items and remove swig packages that conflict with anaconda
3634
- ${{ if contains(parameters.vmImage, 'ubuntu') }}:
3735
- bash: |
@@ -40,38 +38,39 @@ jobs:
4038
sudo apt list --installed && \
4139
sudo apt remove swig swig4.0
4240
displayName: 'Install OpenGL headers'
43-
4441
- bash: |
4542
conda config --set always_yes yes --set changeps1 no && \
4643
conda update -q conda && \
4744
conda info -a && \
4845
conda config --add channels https://conda.anaconda.org/conda-forge
4946
displayName: 'Conda config and info'
50-
51-
- ${{ if eq(parameters.vmImage, 'windows-2019') }}:
52-
- script: |
53-
call "C:\\Program Files (x86)\\Microsoft Visual Studio\\2019\\Enterprise\\VC\\Auxiliary\\Build\\vcvars64.bat"
54-
displayName: 'Set Windows environment'
55-
env:
56-
CXX: "cl.exe"
57-
47+
- bash: conda create --yes --quiet --name build_env conda-build conda-verify libarchive python=${{ parameters.py_maj }}.${{ parameters.py_min }} anaconda-client
48+
displayName: 'Create Anaconda environment'
5849
- ${{ if eq(parameters.vmImage, 'windows-2022') }}:
5950
- script: |
6051
call "C:\\Program Files\\Microsoft Visual Studio\\2022\\Enterprise\\VC\\Auxiliary\\Build\\vcvars64.bat"
61-
displayName: 'Set Windows environment'
52+
echo "PATH=%PATH%"
53+
where cl.exe
54+
set CC=cl.exe
55+
set CXX=cl.exe
56+
call activate build_env
57+
conda-build --no-remove-work-dir --dirty ci/conda
58+
displayName: 'Set Windows environment and build'
6259
env:
6360
CXX: "cl.exe"
64-
65-
- bash: conda create --yes --quiet --name build_env conda-build conda-verify libarchive python=${{ parameters.py_maj }}.${{ parameters.py_min }} anaconda-client
66-
displayName: 'Create Anaconda environment'
67-
68-
- bash: |
69-
source activate build_env && \
70-
conda-build --no-remove-work-dir --dirty ci/conda
71-
displayName: 'Run conda build'
72-
failOnStderr: false
73-
env:
74-
PYTHONBUFFERED: 1
75-
PYTHON_VERSION: ${{ parameters.py_maj }}.${{ parameters.py_min }}
76-
PACKAGE_VERSION: $(Build.SourceBranchName)
77-
TOKEN: $(anaconda.TOKEN)
61+
CC: "cl.exe"
62+
PYTHONBUFFERED: 1
63+
PYTHON_VERSION: ${{ parameters.py_maj }}.${{ parameters.py_min }}
64+
PACKAGE_VERSION: $(Build.SourceBranchName)
65+
TOKEN: $(anaconda.TOKEN)
66+
- ${{ if not(contains(parameters.vmImage, 'win')) }}:
67+
- bash: |
68+
source activate build_env && \
69+
conda-build --no-remove-work-dir --dirty ci/conda
70+
displayName: 'Run conda build'
71+
failOnStderr: false
72+
env:
73+
PYTHONBUFFERED: 1
74+
PYTHON_VERSION: ${{ parameters.py_maj }}.${{ parameters.py_min }}
75+
PACKAGE_VERSION: $(Build.SourceBranchName)
76+
TOKEN: $(anaconda.TOKEN)

0 commit comments

Comments
 (0)