Skip to content

Commit

Permalink
don't install onnx for build_asan
Browse files Browse the repository at this point in the history
  • Loading branch information
Yi Zhang committed Mar 27, 2024
1 parent 568cca7 commit 388a14d
Show file tree
Hide file tree
Showing 2 changed files with 36 additions and 32 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,10 @@ parameters:
type: boolean
default: false

- name: InstallONNX
type: boolean
default: true

- name: WITHCACHE
type: boolean
default: false
Expand Down Expand Up @@ -106,34 +110,35 @@ steps:
displayName: Install ccache and update PATH to use linked versions of gcc, cc, etc
- ${{ if eq(parameters.WITHCACHE, true) }}:
- task: Cache@2
# machinepool is used to ensure the compiler is same
- $${{ if eq(parameters.InstallONNX, true}}:
- ${{ if eq(parameters.WITHCACHE, true) }}:
- task: Cache@2
# machinepool is used to ensure the compiler is same
inputs:
key: '"$(TODAY)" | ${{ parameters.buildArch }} | ${{ parameters.BuildConfig }} | ${{ parameters.MachinePool }} | $(Build.SourcesDirectory)/cmake/deps.txt, $(Build.SourcesDirectory)/tools/ci_build/github/windows/install_third_party_deps.ps1, $(Build.SourcesDirectory)/tools/ci_build/github/windows/helpers.ps1'
path: $(Agent.TempDirectory)/deps_ccache
restoreKeys: |
"$(TODAY)" | ${{ parameters.buildArch }} | ${{ parameters.BuildConfig }} | ${{ parameters.MachinePool }}
displayName: Cache Task

- task: PowerShell@2
displayName: 'Install ONNX'
inputs:
key: '"$(TODAY)" | ${{ parameters.buildArch }} | ${{ parameters.BuildConfig }} | ${{ parameters.MachinePool }} | $(Build.SourcesDirectory)/cmake/deps.txt, $(Build.SourcesDirectory)/tools/ci_build/github/windows/install_third_party_deps.ps1, $(Build.SourcesDirectory)/tools/ci_build/github/windows/helpers.ps1'
path: $(Agent.TempDirectory)/deps_ccache
restoreKeys: |
"$(TODAY)" | ${{ parameters.buildArch }} | ${{ parameters.BuildConfig }} | ${{ parameters.MachinePool }}
displayName: Cache Task

- task: PowerShell@2
displayName: 'Install ONNX'
inputs:
filePath: '$(Build.SourcesDirectory)/tools/ci_build/github/windows/install_third_party_deps.ps1'
workingDirectory: '$(Build.BinariesDirectory)'
filePath: '$(Build.SourcesDirectory)/tools/ci_build/github/windows/install_third_party_deps.ps1'
workingDirectory: '$(Build.BinariesDirectory)'
${{ if eq(parameters.WITHCACHE, true) }}:
arguments: -cpu_arch ${{ parameters.buildArch }} -install_prefix $(Build.BinariesDirectory)\${{ parameters.BuildConfig }}\installed -build_config ${{ parameters.BuildConfig }} -use_cache
${{ else }}:
arguments: -cpu_arch ${{ parameters.buildArch }} -install_prefix $(Build.BinariesDirectory)\${{ parameters.BuildConfig }}\installed -build_config ${{ parameters.BuildConfig }}
${{ if eq(parameters.WITHCACHE, true) }}:
arguments: -cpu_arch ${{ parameters.buildArch }} -install_prefix $(Build.BinariesDirectory)\${{ parameters.BuildConfig }}\installed -build_config ${{ parameters.BuildConfig }} -use_cache
${{ else }}:
arguments: -cpu_arch ${{ parameters.buildArch }} -install_prefix $(Build.BinariesDirectory)\${{ parameters.BuildConfig }}\installed -build_config ${{ parameters.BuildConfig }}
${{ if eq(parameters.WITHCACHE, true) }}:
env:
CCACHE_DIR: $(Agent.TempDirectory)/deps_ccache
CCACHE_COMPILERCHECK: content

- ${{ if eq(parameters.WITHCACHE, true) }}:
- powershell: |
ccache -sv
ccache -z
displayName: cache stat
env:
CCACHE_DIR: $(Agent.TempDirectory)/deps_ccache
env:
CCACHE_DIR: $(Agent.TempDirectory)/deps_ccache
CCACHE_COMPILERCHECK: content

- ${{ if eq(parameters.WITHCACHE, true) }}:
- powershell: |
ccache -sv
ccache -z
displayName: cache stat
env:
CCACHE_DIR: $(Agent.TempDirectory)/deps_ccache
5 changes: 2 additions & 3 deletions tools/ci_build/github/azure-pipelines/win-ci-pipeline.yml
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,7 @@ stages:
BuildConfig: Debug
MachinePool: 'onnxruntime-Win-CPU-2022'
WithCache: false
InstallONNX: false
Today: $(TODAY)

- task: PythonScript@0
Expand Down Expand Up @@ -155,7 +156,7 @@ stages:
GenerateDocumentation: false
WITH_CACHE: false
MachinePool: 'onnxruntime-Win-CPU-2022'

- stage: x86_release
dependsOn: []
jobs:
Expand Down Expand Up @@ -256,5 +257,3 @@ stages:
GenerateDocumentation: false
WITH_CACHE: false
MachinePool: 'onnxruntime-Win-CPU-2022'


0 comments on commit 388a14d

Please sign in to comment.