aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTim Newsome <tim@sifive.com>2023-01-05 17:29:51 -0800
committerAndrew Waterman <andrew@sifive.com>2023-01-11 13:19:24 -0800
commit582f4d442ec660affea0d378fad3f8588a7dec16 (patch)
treea9fe6d6c2463c8b87f3220ec0fd0f604ab9231bc
parent9874c1767179250e25094ccc6757a5faad9d99d1 (diff)
downloadriscv-isa-sim-582f4d442ec660affea0d378fad3f8588a7dec16.zip
riscv-isa-sim-582f4d442ec660affea0d378fad3f8588a7dec16.tar.gz
riscv-isa-sim-582f4d442ec660affea0d378fad3f8588a7dec16.tar.bz2
Refactor build-spike out of test-spike.
-rw-r--r--.github/workflows/continuous-integration.yml8
-rwxr-xr-xci-tests/build-spike14
-rwxr-xr-xci-tests/test-spike9
3 files changed, 20 insertions, 11 deletions
diff --git a/.github/workflows/continuous-integration.yml b/.github/workflows/continuous-integration.yml
index 77cc26a..51b65a1 100644
--- a/.github/workflows/continuous-integration.yml
+++ b/.github/workflows/continuous-integration.yml
@@ -25,7 +25,9 @@ jobs:
- name: Install Dependencies
run: sudo xargs apt-get install -y < .github/workflows/apt-packages.txt
- - run: ci-tests/test-spike
+ - run: |
+ ci-tests/build-spike
+ ci-tests/test-spike
test-macos:
name: Test Spike build (MacOS)
@@ -36,4 +38,6 @@ jobs:
- name: Install Dependencies
run: xargs brew install < .github/workflows/brew-packages.txt
- - run: ci-tests/test-spike
+ - run: |
+ ci-tests/build-spike
+ ci-tests/test-spike
diff --git a/ci-tests/build-spike b/ci-tests/build-spike
new file mode 100755
index 0000000..10806c4
--- /dev/null
+++ b/ci-tests/build-spike
@@ -0,0 +1,14 @@
+#!/bin/bash
+set -e
+
+DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null 2>&1 && pwd )"
+
+mkdir build
+cd build
+mkdir install
+CXXFLAGS="-Wnon-virtual-dtor" CFLAGS="-Werror -Wignored-qualifiers -Wunused-function -Wunused-parameter -Wunused-variable" $DIR/../configure --prefix=`pwd`/install
+make -j4
+make install
+
+# check that help message prints without error
+install/bin/spike -h
diff --git a/ci-tests/test-spike b/ci-tests/test-spike
index bafedc8..725ac64 100755
--- a/ci-tests/test-spike
+++ b/ci-tests/test-spike
@@ -3,16 +3,7 @@ set -e
DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null 2>&1 && pwd )"
-mkdir build
cd build
-mkdir install
-CXXFLAGS="-Wnon-virtual-dtor" CFLAGS="-Werror -Wignored-qualifiers -Wunused-function -Wunused-parameter -Wunused-variable" $DIR/../configure --prefix=`pwd`/install
-make -j4
-make install
-
-# check that help message prints without error
-install/bin/spike -h
-
# run a program and check for correct output
mkdir run