1
mirror of https://github.com/jedisct1/libsodium.git synced 2024-12-28 22:21:15 -07:00
libsodium/azure-pipelines.yml

147 lines
5.8 KiB
YAML
Raw Normal View History

2019-05-29 05:41:48 -07:00
trigger:
- stable
- next
pr: none
jobs:
2019-05-30 07:04:55 -07:00
- job: "wasi"
pool:
vmImage: "ubuntu-20.04"
2019-05-30 07:04:55 -07:00
steps:
- script: |
2021-07-19 03:55:35 -07:00
sudo apt-get install build-essential curl cmake lld
2019-05-30 07:04:55 -07:00
displayName: Install system packages
- script: |
2019-09-13 08:26:51 -07:00
curl https://get.wasmer.io -sSfL | sh
displayName: Install wasmer
2019-05-30 07:04:55 -07:00
- script: |
curl -sL -o - https://ziglang.org/download/0.10.0/zig-linux-x86_64-0.10.0.tar.xz | tar xJ -f - -C /opt/
sudo mv /opt/zig-* /opt/zig
env PATH=/opt/zig/bin:/opt/zig:$PATH
displayName: Install the Zig SDK
2019-05-30 07:04:55 -07:00
- script: |
env WASMER_DIR=${HOME}/.wasmer PATH=${HOME}/.wasmer/bin:${HOME}/.cargo/bin:$PATH dist-build/wasm32-wasi.sh
2019-05-30 07:04:55 -07:00
displayName: Compile libsodium
- task: PublishBuildArtifacts@1
condition: not(canceled())
inputs:
pathToPublish: libsodium-wasm32-wasi
artifactName: libsodium-wasm32-wasi
2019-05-29 05:41:48 -07:00
- job: "windows"
2021-11-11 04:47:58 -07:00
pool:
vmImage: "windows-2022"
steps:
- powershell: |
cd builds\msvc\build
& .\buildbase.bat ..\vs2022\libsodium.sln 17
displayName: Compile it all
- powershell: |
mkdir bin\include\sodium
Copy-Item "src\libsodium\include\sodium\*.h" -Destination "bin\include\sodium" -Recurse
Copy-Item "src\libsodium\include\*.h" -Destination "bin\include\"
displayName: Copy header files
- task: PublishBuildArtifacts@1
condition: not(canceled())
inputs:
pathToPublish: bin
artifactName: libsodium
- job: "windows_2019"
2019-05-29 05:41:48 -07:00
pool:
vmImage: "windows-2019"
steps:
- powershell: |
cd builds\msvc\build
& .\buildbase.bat ..\vs2019\libsodium.sln 16
displayName: Compile it all
- powershell: |
mkdir bin\include\sodium
Copy-Item "src\libsodium\include\sodium\*.h" -Destination "bin\include\sodium" -Recurse
Copy-Item "src\libsodium\include\*.h" -Destination "bin\include\"
displayName: Copy header files
- task: PublishBuildArtifacts@1
condition: not(canceled())
inputs:
pathToPublish: bin
artifactName: libsodium
- job: mingw64
2019-05-29 05:41:48 -07:00
pool:
vmImage: "windows-2019"
steps:
2020-11-04 09:57:26 -07:00
- powershell: |
2022-12-16 09:28:59 -07:00
(New-Object Net.WebClient).DownloadFile("https://github.com/msys2/msys2-installer/releases/download/2022-12-16/msys2-base-x86_64-20221216.sfx.exe", "sfx.exe")
2020-11-04 09:57:26 -07:00
.\sfx.exe -y -o\
del sfx.exe
2019-05-29 05:41:48 -07:00
displayName: Install MSYS2
- script: |
set PATH=%CD:~0,2%\msys64\usr\bin;C:\Windows\system32;C:\Windows;C:\Windows\System32\Wbem
2020-11-04 09:57:26 -07:00
%CD:~0,2%\msys64\usr\bin\bash -lc
%CD:~0,2%\msys64\usr\bin\bash -lc "pacman --noconfirm -Sydd filesystem"
%CD:~0,2%\msys64\usr\bin\bash -lc 'pacman --noconfirm -Syuu'
%CD:~0,2%\msys64\usr\bin\bash -lc 'pacman --noconfirm -Syuu'
2019-05-29 05:41:48 -07:00
displayName: Update MSYS2
- script: |
set PATH=%CD:~0,2%\msys64\usr\bin;C:\Windows\system32;C:\Windows;C:\Windows\System32\Wbem
%CD:~0,2%\msys64\usr\bin\pacman --noconfirm --needed -S base-devel mingw-w64-x86_64-toolchain
2019-05-29 05:41:48 -07:00
%CD:~0,2%\msys64\usr\bin\pacman --noconfirm -Scc
%CD:~0,2%\msys64\usr\bin\sed -i "s|#CacheDir.*|CacheDir=/c/Users/%USERNAME%/AppData/Local/Temp|g" /etc/pacman.conf
2019-05-29 05:41:48 -07:00
displayName: Install Toolchain
- script: |
set PATH=C:\Windows\system32;C:\Windows;C:\Windows\System32\Wbem;%CD:~0,2%\msys64\usr\bin;%CD:~0,2%\msys64\bin
set MSYS2_ROOT=%CD:~0,2%\msys64
set MSYSTEM=MINGW64
2020-11-04 09:57:26 -07:00
set CHERE_INVOKING=yes
2019-05-29 05:41:48 -07:00
%MSYS2_ROOT%\cmd\msystem MINGW64
%CD:~0,2%\msys64\usr\bin\bash -lc dist-build/msys2-win64.sh
env:
CHERE_INVOKING: yes
MSYS2_ARCH: x86_64
displayName: Compile libsodium
- task: PublishBuildArtifacts@1
condition: not(canceled())
inputs:
pathToPublish: libsodium-win64
artifactName: libsodium-win64
- job: mingw32
pool:
vmImage: "windows-2019"
steps:
2020-11-04 09:57:26 -07:00
- powershell: |
2021-07-25 12:46:37 -07:00
(New-Object Net.WebClient).DownloadFile("https://github.com/msys2/msys2-installer/releases/download/2021-07-25/msys2-base-x86_64-20210725.sfx.exe", "sfx.exe")
2020-11-04 09:57:26 -07:00
.\sfx.exe -y -o\
del sfx.exe
displayName: Install MSYS2
- script: |
set PATH=%CD:~0,2%\msys64\usr\bin;C:\Windows\system32;C:\Windows;C:\Windows\System32\Wbem
2020-11-04 09:57:26 -07:00
%CD:~0,2%\msys64\usr\bin\bash -lc
%CD:~0,2%\msys64\usr\bin\bash -lc "pacman --noconfirm -Sydd filesystem"
%CD:~0,2%\msys64\usr\bin\bash -lc 'pacman --noconfirm -Syuu'
%CD:~0,2%\msys64\usr\bin\bash -lc 'pacman --noconfirm -Syuu'
displayName: Update MSYS2
- script: |
set PATH=%CD:~0,2%\msys64\usr\bin;C:\Windows\system32;C:\Windows;C:\Windows\System32\Wbem
%CD:~0,2%\msys64\usr\bin\pacman --noconfirm --needed -S base-devel mingw-w64-i686-toolchain
%CD:~0,2%\msys64\usr\bin\pacman --noconfirm -Scc
%CD:~0,2%\msys64\usr\bin\sed -i "s|#CacheDir.*|CacheDir=/c/Users/%USERNAME%/AppData/Local/Temp|g" /etc/pacman.conf
displayName: Install Toolchain
- script: |
set PATH=C:\Windows\system32;C:\Windows;C:\Windows\System32\Wbem;%CD:~0,2%\msys64\usr\bin;%CD:~0,2%\msys64\bin
set MSYS2_ROOT=%CD:~0,2%\msys64
set MSYSTEM=MINGW32
2020-11-04 09:57:26 -07:00
set CHERE_INVOKING=yes
%MSYS2_ROOT%\cmd\msystem MINGW32
%CD:~0,2%\msys64\usr\bin\bash -lc dist-build/msys2-win32.sh
env:
CHERE_INVOKING: yes
MSYS2_ARCH: x86_64
displayName: Compile libsodium
2019-05-29 05:41:48 -07:00
- task: PublishBuildArtifacts@1
condition: not(canceled())
inputs:
pathToPublish: libsodium-win32
artifactName: libsodium-win32