onnxruntime/tools/ci_build/github/azure-pipelines/mac-coreml-ci-pipeline.yml
Yi Zhang 962d8d2b19
Add compilation cache in react native CI (#15329)
### Description
1. Replacing jobs with stages for better debugging and maintainance
2. Added compilation cache to accelerate the workflow.
3. Splited building protobuf and major code as 2 tasks



### Motivation and Context
Reduced compilation time about one hour.
test run:

https://dev.azure.com/onnxruntime/onnxruntime/_build/results?buildId=943695&view=logs&j=de302ec2-2305-57e0-e8c6-cd89c569f2a3&t=8b360243-7783-51da-8079-2304089d3d1d
2023-04-06 10:39:14 +08:00

34 lines
932 B
YAML

jobs:
- job: CoreML_CI
workspace:
clean: all
pool:
vmImage: 'macOS-12'
variables:
MACOSX_DEPLOYMENT_TARGET: '10.14'
TODAY: $[format('{0:dd}{0:MM}{0:yyyy}', pipeline.startTime)]
CCACHE_DIR: '$(Pipeline.Workspace)/ccache'
timeoutInMinutes: 120
steps:
- script: brew install coreutils ninja
displayName: Install coreutils and ninja
- template: templates/mac-build-step-with-cache.yml
parameters:
TODAY: $(TODAY)
AdditionalKey: coreml
CacheDir: $(CCACHE_DIR)
BuildStep:
- script: |
python3 tools/ci_build/build.py \
--build_dir build \
--skip_submodule_sync \
--cmake_generator=Ninja \
--parallel \
--build_shared_lib \
--config Debug \
--use_cache \
--use_coreml
displayName: CoreML EP, Build and Test on macOS
env:
CCACHE_COMPILERCHECK: content