From 1df68222674a4965b037ff132395ad6ec56462eb Mon Sep 17 00:00:00 2001 From: Adrian Stanea Date: Wed, 13 Dec 2023 16:50:27 +0200 Subject: [PATCH] ci/macOS: export libiio .pkg from azure artifacts - latest libm2k version is only compatilbe with libiio-v0. The CI builds libiio-v0 and libm2k-v0 and exports them as .pkg files Signed-off-by: Adrian Stanea --- CI/macOS/install_deps | 19 +++++++++++++++---- azure-pipelines.yml | 10 ++++++++++ 2 files changed, 25 insertions(+), 4 deletions(-) diff --git a/CI/macOS/install_deps b/CI/macOS/install_deps index 81374a7a..def74c07 100755 --- a/CI/macOS/install_deps +++ b/CI/macOS/install_deps @@ -26,8 +26,19 @@ sudo make install echo "Building libiio - version $LIBIIO_VERSION" cd ${TOP_DIR} git clone https://github.com/analogdevicesinc/libiio.git -b $LIBIIO_VERSION libiio -mkdir ./libiio/build && cd ./libiio/build -cmake ../ +cd libiio +## build .pkg +mkdir build && cd build +cmake .. -Werror=dev -DCOMPILE_WARNING_AS_ERROR=ON -DOSX_PACKAGE=ON -DCPP_BINDINGS=ON -DPYTHON_BINDINGS=ON -DWITH_EXAMPLES=ON -DWITH_SERIAL_BACKEND=ON -DWITH_ZSTD=OFF make -sudo make install - +sudo make install +cd .. +## built tar +mkdir build_tar && cd build_tar +cmake .. -Werror=dev -DCOMPILE_WARNING_AS_ERROR=ON -DOSX_PACKAGE=OFF -DENABLE_PACKAGING=ON -DCPP_BINDINGS=ON -DPYTHON_BINDINGS=ON -DWITH_SERIAL_BACKEND=ON -DWITH_ZSTD=OFF -DCPACK_SYSTEM_NAME=${ARTIFACTNAME} +make +make package +mv ../CI/azure/macos_tar_fixup.sh . +chmod +x macos_tar_fixup.sh +./macos_tar_fixup.sh +cd .. \ No newline at end of file diff --git a/azure-pipelines.yml b/azure-pipelines.yml index 256cf540..0c998d8c 100644 --- a/azure-pipelines.yml +++ b/azure-pipelines.yml @@ -123,6 +123,16 @@ jobs: - script: ./CI/macOS/install_deps displayName: "Install Dependencies" condition: ne(variables['agentName'],'macOS_arm64') + - task: CopyFiles@2 + inputs: + sourceFolder: '$(Agent.BuildDirectory)/s/libiio/build/' + contents: '$(Agent.BuildDirectory)/s/libiio/build/?(*.pkg)' + targetFolder: '$(Build.ArtifactStagingDirectory)' + - task: CopyFiles@2 + inputs: + sourceFolder: '$(Agent.BuildDirectory)/s/libiio/build_tar/' + contents: '$(Agent.BuildDirectory)/s/libiio/build_tar/?(*.tar.gz)' + targetFolder: '$(Build.ArtifactStagingDirectory)' - script: ./CI/macOS/make_macOS displayName: "Build" - ${{ each pyVersion in parameters.pythonVersions }}: