mirror of https://github.com/ArduPilot/ardupilot
ci: set up Azure Pipelines
This commit is contained in:
parent
03ed67a996
commit
c8cace9092
|
@ -0,0 +1,46 @@
|
|||
parameters:
|
||||
action: 'fly'
|
||||
|
||||
jobs:
|
||||
- job: sitl_${{ parameters.name }}_test
|
||||
displayName: ${{ format('Cygwin SITL {0} test', parameters.name) }}
|
||||
pool:
|
||||
vmImage: 'win1803'
|
||||
condition: eq(variables['Build.Reason'], 'Schedule')
|
||||
steps:
|
||||
- script: choco install cygwin --params "/InstallDir:C:\Cygwin /NoStartMenu /NoAdmin"
|
||||
displayName: 'Install Cygwin'
|
||||
- script: choco install gcc-g++ python2 python2-devel python2-future python2-lxml python2-pip python2-pexpect python2-numpy git gettext --source cygwin
|
||||
displayName: 'Install Cygwin packages'
|
||||
- script: git submodule update --recursive --init modules/mavlink
|
||||
displayName: Initialize MAVLink submodule
|
||||
- script: C:\Cygwin\bin\bash --login -c "cd $(cygpath '%BUILD_SOURCESDIRECTORY%')/modules/mavlink/pymavlink && python setup.py build install --user"
|
||||
displayName: 'Install pymavlink from submodule'
|
||||
- script: C:\Cygwin\bin\bash --login -c "pip2 install MAVProxy"
|
||||
displayName: 'Install MAVProxy in Cygwin'
|
||||
- script: C:\Cygwin\bin\bash --login -c "cd $(cygpath '%BUILD_SOURCESDIRECTORY%') && Tools/autotest/autotest.py ${{ format('build.{0} {1}.{2}', parameters.build_target, parameters.action, parameters.action_target) }}"
|
||||
displayName: ${{ format('Run {0} autotest', parameters.name) }}
|
||||
- script: C:\Cygwin\bin\bash --login -c "cd $(cygpath '%BUILD_SOURCESDIRECTORY%') && cp $(cygcheck.exe build/sitl/bin/* | grep Cygwin | grep -v '.exe' | sed 's/^[ \t]*//' | sort | uniq) build/sitl/bin/"
|
||||
displayName: 'Copy dependencies to build dir'
|
||||
- task: PublishBuildArtifacts@1
|
||||
# - task: PublishPipelineArtifact@0
|
||||
displayName: 'Publish build artifacts'
|
||||
inputs:
|
||||
artifactName: 'Cygwin SITL binaries'
|
||||
pathtoPublish: 'build/sitl/bin'
|
||||
# targetPath: 'build/sitl/bin'
|
||||
- task: PublishBuildArtifacts@1
|
||||
# - task: PublishPipelineArtifact@0
|
||||
displayName: 'Publish test folder'
|
||||
inputs:
|
||||
artifactName: ${{ format('{0} Test folder', parameters.name) }}
|
||||
pathtoPublish: ${{ format('test.{0}', parameters.action_target) }}
|
||||
# targetPath: ${{ format('test.{0}', parameters.action_target) }}
|
||||
- task: PublishBuildArtifacts@1
|
||||
# - task: PublishPipelineArtifact@0
|
||||
displayName: 'Publish logs'
|
||||
inputs:
|
||||
artifactName: ${{ format('{0} Logs', parameters.name) }}
|
||||
pathtoPublish: '../buildlogs'
|
||||
# targetPath: '../buildlogs'
|
||||
|
|
@ -0,0 +1,55 @@
|
|||
jobs:
|
||||
- job: sitl
|
||||
displayName: 'Cygwin SITL build'
|
||||
pool:
|
||||
vmImage: 'win1803'
|
||||
condition: ne(variables['Build.Reason'], 'Schedule')
|
||||
steps:
|
||||
- script: choco install cygwin --params "/InstallDir:C:\Cygwin /NoStartMenu /NoAdmin"
|
||||
displayName: 'Install Cygwin'
|
||||
- script: choco install cygwin32-gcc-g++ python2 python2-future python2-lxml git gettext --source cygwin
|
||||
displayName: 'Install Cygwin packages'
|
||||
- script: C:\Cygwin\bin\bash --login -c "cd $(cygpath '%BUILD_SOURCESDIRECTORY%') && ./waf --color yes --toolchain i686-pc-cygwin --board sitl configure bin"
|
||||
displayName: 'Build SITL'
|
||||
- script: C:\Cygwin\bin\bash --login -c "cd $(cygpath '%BUILD_SOURCESDIRECTORY%') && cp -v $(i686-pc-cygwin-g++ -print-sysroot)/usr/bin/*.dll build/sitl/bin/"
|
||||
displayName: 'Copy dependencies to build dir'
|
||||
- task: PublishBuildArtifacts@1
|
||||
# - task: PublishPipelineArtifact@0
|
||||
displayName: 'Publish build artifacts'
|
||||
inputs:
|
||||
artifactName: 'Cygwin SITL binaries'
|
||||
pathtoPublish: 'build/sitl/bin'
|
||||
# targetPath: 'build/sitl/bin'
|
||||
|
||||
- template: autotest_template.yml
|
||||
parameters:
|
||||
name: 'Copter'
|
||||
build_target: 'ArduCopter'
|
||||
action_target: 'ArduCopter'
|
||||
|
||||
- template: autotest_template.yml
|
||||
parameters:
|
||||
name: 'Plane'
|
||||
build_target: 'ArduPlane'
|
||||
action_target: 'ArduPlane'
|
||||
|
||||
- template: autotest_template.yml
|
||||
parameters:
|
||||
name: 'Quadplane'
|
||||
build_target: 'ArduPlane'
|
||||
action_target: 'QuadPlane'
|
||||
|
||||
- template: autotest_template.yml
|
||||
parameters:
|
||||
name: 'Rover'
|
||||
build_target: 'APMrover2'
|
||||
action: 'drive'
|
||||
action_target: 'APMrover2'
|
||||
|
||||
- template: autotest_template.yml
|
||||
parameters:
|
||||
name: 'Sub'
|
||||
build_target: 'ArduSub'
|
||||
action: 'dive'
|
||||
action_target: 'ArduSub'
|
||||
|
Loading…
Reference in New Issue