Update Python versions #1123
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Tests on OSX | |
on: [push, pull_request, workflow_dispatch] | |
jobs: | |
build: | |
# macos-13 = x86 | |
# macos-14 = arm (M1) | |
runs-on: macos-14 | |
strategy: | |
matrix: | |
python-version: ['3.9', '3.10', '3.11', '3.12', '3.13'] | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
- name: Set up Python ${{ matrix.python-version }} | |
uses: actions/setup-python@v5 | |
with: | |
python-version: ${{ matrix.python-version }} | |
- name: Install LLVM and Clang | |
uses: KyleMayes/install-llvm-action@v2 | |
with: | |
version: "14.0" | |
directory: ${{ runner.temp }}/llvm | |
- name: Install Z3 | |
run: | | |
wget https://github.com/Z3Prover/z3/releases/download/z3-4.13.3/z3-4.13.3-arm64-osx-13.7.zip | |
unzip z3-4.13.3-arm64-osx-13.7.zip | |
sudo python -m pip install z3-solver==4.13.3.0 | |
- name: Install Deps | |
run: | | |
brew install gmp pkgconfig ninja | |
- name: Install Meson | |
run: | | |
python -m pip install meson | |
- name: Install Bitwuzla | |
run: | | |
git clone https://github.com/bitwuzla/bitwuzla.git | |
cd bitwuzla | |
git checkout -b 0.7.0 0.7.0 | |
python ./configure.py --shared --prefix $(pwd)/install | |
cd build | |
sudo ninja install | |
cd .. | |
- name: Install Capstone | |
run: | | |
wget https://github.com/aquynh/capstone/archive/5.0.3.tar.gz | |
tar -xf ./5.0.3.tar.gz | |
cd ./capstone-5.0.3 | |
bash ./make.sh | |
sudo make install | |
cd ../ | |
- name: Install Unicorn | |
run: | | |
sudo python -m pip install unicorn | |
- name: Install LIEF | |
run: | | |
sudo python -m pip install lief | |
- name: Compile Triton | |
run: | | |
mkdir ./build | |
cd ./build | |
cmake .. | |
cmake -DZ3_INTERFACE=ON \ | |
-DZ3_INCLUDE_DIRS=${{ github.workspace }}/z3-4.13.3-arm64-osx-13.7/include \ | |
-DZ3_LIBRARIES=${{ github.workspace }}/z3-4.13.3-arm64-osx-13.7/bin/libz3.a \ | |
-DBITWUZLA_INTERFACE=ON \ | |
-DBITWUZLA_INCLUDE_DIRS=${{ github.workspace }}/bitwuzla/install/include \ | |
-DBITWUZLA_LIBRARIES=${{ github.workspace }}/bitwuzla/install/lib/libbitwuzla.dylib \ | |
-DLLVM_INTERFACE=ON \ | |
-DCMAKE_PREFIX_PATH=${{env.LLVM_PATH}} \ | |
-DBOOST_INTERFACE=OFF .. | |
sudo make -j3 install | |
env: | |
Z3_INCLUDE_DIRS: ${{ github.workspace }}/z3-4.13.3-arm64-osx-13.7/include | |
Z3_LIBRARIES: ${{ github.workspace }}/z3-4.13.3-arm64-osx-13.7/bin/libz3.a | |
# NOTE Tests will fail because currently they only pass with Unicorn | |
# v2.0.0. However, Unicorn v2.0.0 does not build on the macos-14 runner. | |
- name: Unittests | |
run: | |
DYLD_LIBRARY_PATH=/usr/local/lib/ ctest --test-dir build --output-on-failure |