Skip to content

Commit

Permalink
CI/azure/darwin: use gcc
Browse files Browse the repository at this point in the history
install and use gcc when compiling osc on macOS

Signed-off-by: Cristina Suteu <[email protected]>
  • Loading branch information
cristina-suteu authored and ccraluca committed Jun 26, 2023
1 parent e5fba07 commit 4f133f5
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 11 deletions.
4 changes: 3 additions & 1 deletion CI/azure/build_osc_darwin.sh
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ set -xe

install_deps() {
export APT_PKGS="cmake \
gcc \
fftw \
libmatio \
libxml2 \
Expand Down Expand Up @@ -33,6 +34,7 @@ install_deps() {
}

brew_install_if_not_exists $APT_PKGS
brew cleanup
}

install_adi_pkgs() {
Expand All @@ -43,7 +45,7 @@ install_adi_pkgs() {

build_osc() {
mkdir -p build && cd build
cmake ../
cmake -DCMAKE_C_COMPILER="/usr/bin/gcc" ../
make -j9
}

Expand Down
12 changes: 2 additions & 10 deletions azure-pipelines.yml
Original file line number Diff line number Diff line change
Expand Up @@ -163,17 +163,9 @@ stages:
displayName: "Setup"
- script: |
set -e
sudo docker run --name iio-oscilloscope --platform "linux/$(arch)" -e ARTIFACTNAME=$(artifactName) -v "$(Agent.BuildDirectory)/s":"/ci" -v "/usr/bin/qemu-$(arch)-static":"/usr/bin/qemu-$(arch)-static" "$(image)" /bin/bash -c "cd /ci/ && chmod +x ./CI/azure/build_osc_arm.sh && ./CI/azure/build_osc_arm.sh install_apt_pkgs && ./CI/azure/build_osc_arm.sh install_gtkdatabox && ./CI/azure/build_osc_arm.sh install_adi_debs"
sudo docker run -m=4g --name iio-oscilloscope --platform "linux/$(arch)" -e ARTIFACTNAME=$(artifactName) -v "$(Agent.BuildDirectory)/s":"/ci" -v "/usr/bin/qemu-$(arch)-static":"/usr/bin/qemu-$(arch)-static" "$(image)" /bin/bash -c "cd /ci/ && chmod +x ./CI/azure/build_osc_arm.sh && ./CI/azure/build_osc_arm.sh install_apt_pkgs && ./CI/azure/build_osc_arm.sh install_gtkdatabox && ./CI/azure/build_osc_arm.sh install_adi_debs && ./CI/azure/build_osc_arm.sh build_osc"
sudo docker ps -a
displayName: "Install dependencies"
- script: |
set -e
sudo docker ps -a
sudo docker start iio-oscilloscope
sudo docker stop iio-oscilloscope
sudo docker ps -a
sudo docker run --name iio-oscilloscope "$(image)" /bin/bash -c "cd /ci/ && ./CI/azure/build_osc_arm.sh build_osc"
displayName: "Build"
displayName: "Install dependencies + build"
- task: PublishPipelineArtifact@1
inputs:
targetPath: '$(Build.ArtifactStagingDirectory)'
Expand Down

0 comments on commit 4f133f5

Please sign in to comment.