Skip to content

ci: Rebuild self with xcodebuild #186

ci: Rebuild self with xcodebuild

ci: Rebuild self with xcodebuild #186

Workflow file for this run

name: CI
on:
push:
branches:
- master
pull_request:
branches:
- master
env:
BUILD_DEPS: cmake libconfig++-dev libxxhash-dev libjemalloc-dev libtsl-hopscotch-map-dev pkg-config python3-jinja2
TEST_DEPS: bc bats clang node-d3 graphviz moreutils fakeroot
jobs:
build-on-macos:
runs-on: macos-12
timeout-minutes: 30
steps:
- name: check if SIP is enabled on this runner
run: |
csrutil status | grep "System Integrity Protection status: disabled"
- uses: actions/checkout@v3
- uses: hendrikmuhs/ccache-action@v1
with:
key: build-on-macos-12
- name: install-deps
run: |
brew update
export HOMEBREW_NO_AUTO_UPDATE=1
# brew often fails due to existing files, hence the --overwrite parameter and the retry
brew bundle -f || (for v in 3.11 3.12; do brew link --overwrite python@${v} ; done; brew bundle -f)
- name: configure vm
run: |
# library validation would prevent loading libfirebuild to some binaries
sudo defaults write /Library/Preferences/com.apple.security.libraryvalidation.plist DisableLibraryValidation -bool true
- name: build-out-of-tree
run: |
cmake -DCMAKE_CXX_FLAGS="-I/usr/local/include" -DCMAKE_EXE_LINKER_FLAGS="-L/usr/local/lib" -DCMAKE_BUILD_TYPE=Debug -B build-make
export XML_CATALOG_FILES=/usr/local/etc/xml/catalog
make -C build-make -j2
- name: test
run: |
export XML_CATALOG_FILES=/usr/local/etc/xml/catalog
make -C build-make check
- name: rebuild-self-with-xcode
run: |
export PYTHONPATH=$(ls -d /usr/local/lib/python*/site-packages | tail -n1)
cd build-make/test
cmake -G Xcode -DCMAKE_CXX_FLAGS="-I/usr/local/include" -DCMAKE_EXE_LINKER_FLAGS="-L/usr/local/lib" -S ../.. -B ../../build-xcode
bash -c "cd ../../build-xcode && xcodebuild"