From 5f550b606d47d04b7ee60976cdb18a51c391992c Mon Sep 17 00:00:00 2001 From: Jiuyang Liu Date: Thu, 29 Jul 2021 10:55:52 +0800 Subject: Revert "Just install z3 from apt-get in CI (#2056)" This reverts commit 1e7829eb674eed85a4cd537896d9fd9ee0bc5ff4. --- .github/workflows/test.yml | 27 +++++++++++++++++++++++++-- 1 file changed, 25 insertions(+), 2 deletions(-) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index f5a1f811..b2620d2f 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -18,6 +18,7 @@ jobs: jvm: ["adopt@1.8"] scala: ["2.13.6", "2.12.13"] verilator: ["4.204"] + z3: ["4.8.10"] espresso: ["2.4"] runs-on: ${{ matrix.system }} @@ -25,10 +26,32 @@ jobs: - name: Checkout uses: actions/checkout@v2 - - name: Install Z3 + - name: Install Z3 Build Dependencies(Ubuntu) if: matrix.system == 'ubuntu-20.04' + run: sudo apt-get install -y libfl2 libfl-dev + + - name: Cache Z3 ${{ matrix.z3 }} + uses: actions/cache@v2 + id: cache-z3 + with: + path: z3-z3-${{ matrix.z3 }} + key: ${{ matrix.system }}-z3-${{ matrix.z3 }} + - name: Compile Z3 + if: steps.cache-z3.outputs.cache-hit != 'true' + run: | + wget https://github.com/Z3Prover/z3/archive/refs/tags/z3-${{ matrix.z3 }}.tar.gz + tar xvf z3-${{ matrix.z3 }}.tar.gz + cd z3-z3-${{ matrix.z3 }} + mkdir -p build + cd build + cmake .. \ + -DCMAKE_BUILD_TYPE=Release \ + -DZ3_LINK_TIME_OPTIMIZATION=1 + make + - name: Install Z3 ${{ matrix.z3 }} run: | - sudo apt-get install -y z3 + cd z3-z3-${{ matrix.z3 }}/build + sudo make install z3 --version - name: Cache Verilator ${{ matrix.verilator }} -- cgit v1.2.3 From 886d60ca6412a017ad345e3ce346eefe383c4a7e Mon Sep 17 00:00:00 2001 From: Jiuyang Liu Date: Thu, 29 Jul 2021 11:06:15 +0800 Subject: switch to ninja --- .github/workflows/test.yml | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index b2620d2f..94a30f12 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -45,13 +45,14 @@ jobs: mkdir -p build cd build cmake .. \ + -GNinja \ -DCMAKE_BUILD_TYPE=Release \ -DZ3_LINK_TIME_OPTIMIZATION=1 - make + ninja - name: Install Z3 ${{ matrix.z3 }} run: | cd z3-z3-${{ matrix.z3 }}/build - sudo make install + sudo ninja install z3 --version - name: Cache Verilator ${{ matrix.verilator }} -- cgit v1.2.3 From b940d9f83f87567fe69c068a1faf63fd8d3bf091 Mon Sep 17 00:00:00 2001 From: Jiuyang Liu Date: Thu, 29 Jul 2021 11:08:02 +0800 Subject: apt install ninja --- .github/workflows/test.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 94a30f12..10742b96 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -28,7 +28,7 @@ jobs: - name: Install Z3 Build Dependencies(Ubuntu) if: matrix.system == 'ubuntu-20.04' - run: sudo apt-get install -y libfl2 libfl-dev + run: sudo apt-get install -y libfl2 libfl-dev ninja-build - name: Cache Z3 ${{ matrix.z3 }} uses: actions/cache@v2 -- cgit v1.2.3 From 0952a6ecf0811663f21379371707abc679a9cea4 Mon Sep 17 00:00:00 2001 From: Jiuyang Liu Date: Thu, 29 Jul 2021 11:16:55 +0800 Subject: don't hit cache --- .github/workflows/test.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 10742b96..dca07648 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -35,7 +35,7 @@ jobs: id: cache-z3 with: path: z3-z3-${{ matrix.z3 }} - key: ${{ matrix.system }}-z3-${{ matrix.z3 }} + key: ${{ matrix.system }}-z3-ninja-${{ matrix.z3 }} - name: Compile Z3 if: steps.cache-z3.outputs.cache-hit != 'true' run: | -- cgit v1.2.3 From bc963e741df2f949c236db65aa51b686abdd41a1 Mon Sep 17 00:00:00 2001 From: Jiuyang Liu Date: Thu, 29 Jul 2021 12:14:27 +0800 Subject: timestamp seems to be fixed in actions/cache#397 --- .github/workflows/test.yml | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index dca07648..22a04c35 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -31,7 +31,7 @@ jobs: run: sudo apt-get install -y libfl2 libfl-dev ninja-build - name: Cache Z3 ${{ matrix.z3 }} - uses: actions/cache@v2 + uses: actions/cache@v2.1.6 id: cache-z3 with: path: z3-z3-${{ matrix.z3 }} @@ -56,7 +56,7 @@ jobs: z3 --version - name: Cache Verilator ${{ matrix.verilator }} - uses: actions/cache@v2 + uses: actions/cache@v2.1.6 id: cache-verilator with: path: verilator-${{ matrix.verilator }} @@ -77,7 +77,7 @@ jobs: verilator --version - name: Cache Espresso ${{ matrix.espresso }} - uses: actions/cache@v2 + uses: actions/cache@v2.1.6 id: cache-espresso with: path: espresso-${{ matrix.espresso }} @@ -97,7 +97,6 @@ jobs: cd espresso-${{ matrix.espresso }}/build sudo make install - - name: Setup Scala uses: olafurpg/setup-scala@v10 with: -- cgit v1.2.3 From 42f1363c1956976cad62a68c3f34f57941b08003 Mon Sep 17 00:00:00 2001 From: Jiuyang Liu Date: Wed, 18 Aug 2021 12:59:59 +0800 Subject: switch espresso to ninja. --- .github/workflows/test.yml | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 22a04c35..3438dcf9 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -48,7 +48,7 @@ jobs: -GNinja \ -DCMAKE_BUILD_TYPE=Release \ -DZ3_LINK_TIME_OPTIMIZATION=1 - ninja + ninja - name: Install Z3 ${{ matrix.z3 }} run: | cd z3-z3-${{ matrix.z3 }}/build @@ -81,7 +81,7 @@ jobs: id: cache-espresso with: path: espresso-${{ matrix.espresso }} - key: ${{ matrix.system }}-espresso-${{ matrix.espresso }} + key: ${{ matrix.system }}-espresso-ninja-${{ matrix.espresso }} - name: Compile Espresso ${{ matrix.espresso }} if: steps.cache-espresso.outputs.cache-hit != 'true' run: | @@ -90,12 +90,14 @@ jobs: cd espresso-${{ matrix.espresso }} mkdir -p build cd build - cmake .. - make + cmake .. \ + -GNinja \ + -DCMAKE_BUILD_TYPE=Release + ninja - name: Install Espresso ${{ matrix.espresso }} run: | cd espresso-${{ matrix.espresso }}/build - sudo make install + sudo ninja install - name: Setup Scala uses: olafurpg/setup-scala@v10 -- cgit v1.2.3