Skip to content

Update python wheel docker file and build script #270

Update python wheel docker file and build script

Update python wheel docker file and build script #270

Workflow file for this run

name: Tests on OSX
on: [push, pull_request, workflow_dispatch]
jobs:
build:
runs-on: macos-latest
strategy:
matrix:
python-version: ['3.7', '3.8', '3.9', '3.10']
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version }}
- name: Install LLVM and Clang
uses: KyleMayes/install-llvm-action@v1
with:
version: "14.0"
directory: ${{ runner.temp }}/llvm
- name: Install dependencies
run: |
brew install boost
- name: Install Z3
run: |
wget https://github.com/Z3Prover/z3/releases/download/z3-4.8.17/z3-4.8.17-x64-osx-10.16.zip
unzip z3-4.8.17-x64-osx-10.16.zip
sudo python -m pip install z3-solver==4.8.17.0
- name: Download and build GMP
run: |
wget https://ftp.gnu.org/gnu/gmp/gmp-6.2.1.tar.xz
tar xvf gmp-6.2.1.tar.xz
cd gmp-6.2.1/
./configure --with-pic
make
make check
- name: Install Ninja
run: |
brew install 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.1.0 0.1.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-rc2.tar.gz
tar -xf ./5.0-rc2.tar.gz
cd ./capstone-5.0-rc2
bash ./make.sh
sudo make install
cd ../
- name: Install Unicorn
run: |
sudo python -m pip install unicorn==2.0.0
- 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.8.17-x64-osx-10.16/include \
-DZ3_LIBRARIES=${{ github.workspace }}/z3-4.8.17-x64-osx-10.16/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.8.17-x64-osx-10.16/include
Z3_LIBRARIES: ${{ github.workspace }}/z3-4.8.17-x64-osx-10.16/bin/libz3.a
- name: Unittests
run: |
ctest --test-dir build --output-on-failure