Skip to content

Commit 52fce91

Browse files
committed
rv: simplify running configs
Pull in reproducible build stuff & allmodconfig -> defconfig stuff from Bjorn. Disable most of the compilation based configs (for now). Co-developed-by: Björn Töpel <[email protected]> Signed-off-by: Björn Töpel <[email protected]> Signed-off-by: Conor Dooley <[email protected]>
1 parent 5d2c424 commit 52fce91

File tree

5 files changed

+22
-12
lines changed

5 files changed

+22
-12
lines changed

tests_rv/patch/build_boot_rv64/build_boot_rv64.sh

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,9 @@ tmpdir=$(mktemp -d)
77
rc=0
88

99
tuxmake --wrapper ccache --target-arch riscv -e PATH=$PATH --directory . \
10-
-o $tmpdir --toolchain gcc-11 --kconfig allmodconfig || rc=1
10+
--environment=KBUILD_BUILD_TIMESTAMP=@1621270510 \
11+
--environment=KBUILD_BUILD_USER=tuxmake --environment=KBUILD_BUILD_HOST=tuxmake \
12+
-o $tmpdir --toolchain gcc --kconfig allmodconfig || rc=1
1113

1214
if [ $rc -ne 0 ]; then
1315
echo "Build failed" >&$DESC_FD
Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
{
22
"run": ["build_boot_rv64.sh"],
3-
"pull-requests": true
3+
"pull-requests": true,
4+
"disabled": true
45
}

tests_rv/patch/build_boot_rv64_clang/build_boot_rv64_clang.sh

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,9 @@ tmpdir=$(mktemp -d)
77
rc=0
88

99
tuxmake --wrapper ccache --target-arch riscv -e PATH=$PATH --directory . \
10-
-o $tmpdir --toolchain clang --kconfig allmodconfig LLVM=1 || rc=1
10+
--environment=KBUILD_BUILD_TIMESTAMP=@1621270510 \
11+
--environment=KBUILD_BUILD_USER=tuxmake --environment=KBUILD_BUILD_HOST=tuxmake \
12+
-o $tmpdir --toolchain llvm --kconfig allmodconfig || rc=1
1113

1214
if [ $rc -ne 0 ]; then
1315
echo "Build failed" >&$DESC_FD
Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
{
22
"run": ["build_boot_rv64_clang.sh"],
3-
"pull-requests": true
3+
"pull-requests": true,
4+
"disabled": true
45
}

tests_rv/patch/build_warn_rv64/build_warn_rv64.sh

Lines changed: 12 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -3,14 +3,12 @@
33
#
44
# Copyright (C) 2019 Netronome Systems, Inc.
55

6-
# Modified tests/patch/build_allmodconfig_warn.sh for RISC-V builds
6+
# Modified tests/patch/build_defconfig_warn.sh for RISC-V builds
77

88
tmpfile_o=$(mktemp)
99
tmpfile_n=$(mktemp)
1010

11-
tmpdir0=$(mktemp -d)
12-
tmpdir1=$(mktemp -d)
13-
tmpdir2=$(mktemp -d)
11+
tmpdir0=build
1412

1513
rc=0
1614

@@ -24,14 +22,18 @@ git log -1 --pretty='%h ("%s")' HEAD~
2422
echo "Baseline building the tree"
2523

2624
tuxmake --wrapper ccache --target-arch riscv -e PATH=$PATH --directory . \
27-
-o $tmpdir0 --toolchain gcc-11 --kconfig allmodconfig -K CONFIG_WERROR=n W=1
25+
--environment=KBUILD_BUILD_TIMESTAMP=@1621270510 \
26+
--environment=KBUILD_BUILD_USER=tuxmake --environment=KBUILD_BUILD_HOST=tuxmake \
27+
-o $tmpdir0 --toolchain gcc --kconfig defconfig -K CONFIG_WERROR=n W=1
2828

2929
git checkout -q HEAD~
3030

3131
echo "Building the tree before the patch"
3232

3333
tuxmake --wrapper ccache --target-arch riscv -e PATH=$PATH --directory . \
34-
-o $tmpdir1 --toolchain gcc-11 --kconfig allmodconfig -K CONFIG_WERROR=n W=1 \
34+
-o $tmpdir0 --toolchain gcc --kconfig defconfig -K CONFIG_WERROR=n W=1 \
35+
--environment=KBUILD_BUILD_TIMESTAMP=@1621270510 \
36+
--environment=KBUILD_BUILD_USER=tuxmake --environment=KBUILD_BUILD_HOST=tuxmake \
3537
2> >(tee $tmpfile_o >&2)
3638
incumbent=$(grep -i -c "\(warn\|error\)" $tmpfile_o)
3739

@@ -40,7 +42,9 @@ echo "Building the tree with the patch"
4042
git checkout -q $HEAD
4143

4244
tuxmake --wrapper ccache --target-arch riscv -e PATH=$PATH --directory . \
43-
-o $tmpdir2 --toolchain gcc-11 --kconfig allmodconfig -K CONFIG_WERROR=n W=1 \
45+
--environment=KBUILD_BUILD_TIMESTAMP=@1621270510 \
46+
--environment=KBUILD_BUILD_USER=tuxmake --environment=KBUILD_BUILD_HOST=tuxmake \
47+
-o $tmpdir0 --toolchain gcc --kconfig defconfig -K CONFIG_WERROR=n W=1 \
4448
2> >(tee $tmpfile_n >&2) || rc=1
4549

4650
current=$(grep -i -c "\(warn\|error\)" $tmpfile_n)
@@ -66,6 +70,6 @@ if [ $current -gt $incumbent ]; then
6670
rc=1
6771
fi
6872

69-
rm -rf $tmpdir0 $tmpdir1 $tmpdir2 $tmpfile_o $tmpfile_n
73+
rm -rf $tmpdir0 $tmpfile_o $tmpfile_n
7074

7175
exit $rc

0 commit comments

Comments
 (0)