diff mbox series

[U-Boot,v3,9/9] Add Microsoft Azure Pipelines configuration

Message ID 1572178788-26246-10-git-send-email-bmeng.cn@gmail.com
State Accepted
Commit d2e680fa557539e324928838781bd38245caeb98
Delegated to: Tom Rini
Headers show
Series tools: Support building U-Boot host tools for Windows via MSYS2 | expand

Commit Message

Bin Meng Oct. 27, 2019, 12:19 p.m. UTC
Microsoft Azure Pipelines [1] provides unlimited CI/CD minutes and
10 parallel jobs to every open source project for free.

This adds a configuration file for Azure Pipelines to utilize the
free Windows VM hosted by Microsoft to ensure no build broken in
building U-Boot host tools for Windows.

[1] https://azure.microsoft.com/en-us/blog/announcing-azure-pipelines-with-unlimited-ci-cd-minutes-for-open-source/

Signed-off-by: Bin Meng <bmeng.cn@gmail.com>

---
See the build result at:
https://dev.azure.com/bmeng/GitHub/_build/results?buildId=53

Changes in v3:
- rename to .azure-pipelines.yml
- correct typo in the commit summary

Changes in v2:
- new patch: Add Microsoft Azure pipelines configuration

 .azure-pipelines.yml | 38 ++++++++++++++++++++++++++++++++++++++
 1 file changed, 38 insertions(+)
 create mode 100644 .azure-pipelines.yml

Comments

Tom Rini Oct. 30, 2019, 5:03 p.m. UTC | #1
On Sun, Oct 27, 2019 at 05:19:48AM -0700, Bin Meng wrote:

> Microsoft Azure Pipelines [1] provides unlimited CI/CD minutes and
> 10 parallel jobs to every open source project for free.
> 
> This adds a configuration file for Azure Pipelines to utilize the
> free Windows VM hosted by Microsoft to ensure no build broken in
> building U-Boot host tools for Windows.
> 
> [1] https://azure.microsoft.com/en-us/blog/announcing-azure-pipelines-with-unlimited-ci-cd-minutes-for-open-source/
> 
> Signed-off-by: Bin Meng <bmeng.cn@gmail.com>

Applied to u-boot/master, thanks!
diff mbox series

Patch

diff --git a/.azure-pipelines.yml b/.azure-pipelines.yml
new file mode 100644
index 0000000..6c6b24e
--- /dev/null
+++ b/.azure-pipelines.yml
@@ -0,0 +1,38 @@ 
+variables:
+  windows_vm: vs2015-win2012r2
+
+jobs:
+  - job: tools_only_windows
+    displayName: 'Ensure host tools build for Windows'
+    pool:
+      vmImage: $(windows_vm)
+    strategy:
+      matrix:
+        i686:
+          MSYS_DIR: msys32
+          BASE_REPO: msys2-ci-base-i686
+        x86_64:
+          MSYS_DIR: msys64
+          BASE_REPO: msys2-ci-base
+    steps:
+      - script: |
+          git clone https://github.com/msys2/$(BASE_REPO).git %CD:~0,2%\$(MSYS_DIR)
+        displayName: 'Install MSYS2'
+      - script: |
+          set PATH=%CD:~0,2%\$(MSYS_DIR)\usr\bin;C:\Windows\system32;C:\Windows;C:\Windows\System32\Wbem
+          %CD:~0,2%\$(MSYS_DIR)\usr\bin\pacman --noconfirm -Syyuu
+        displayName: 'Update MSYS2'
+      - script: |
+          set PATH=%CD:~0,2%\$(MSYS_DIR)\usr\bin;C:\Windows\system32;C:\Windows;C:\Windows\System32\Wbem
+          %CD:~0,2%\$(MSYS_DIR)\usr\bin\pacman --noconfirm --needed -S make gcc bison diffutils openssl-devel
+        displayName: 'Install Toolchain'
+      - script: |
+          set PATH=C:\Windows\system32;C:\Windows;C:\Windows\System32\Wbem
+          echo make tools-only_defconfig tools-only NO_SDL=1 > build-tools.sh
+          %CD:~0,2%\$(MSYS_DIR)\usr\bin\bash -lc "bash build-tools.sh"
+        displayName: 'Build Host Tools'
+        env:
+          # Tell MSYS2 we need a POSIX emulation layer
+          MSYSTEM: MSYS
+          # Tell MSYS2 not to ‘cd’ our startup directory to HOME
+          CHERE_INVOKING: yes