public inbox for isar-users@googlegroups.com
 help / color / mirror / Atom feed
* [PATCH] ci: Add option to build/test a reduced set of configurations
@ 2018-11-19  9:51 Maxim Yu. Osipov
  2018-11-22 12:52 ` Maxim Yu. Osipov
  0 siblings, 1 reply; 2+ messages in thread
From: Maxim Yu. Osipov @ 2018-11-19  9:51 UTC (permalink / raw)
  To: isar-users

Signed-off-by: Maxim Yu. Osipov <mosipov@ilbers.de>
---
 scripts/ci_build.sh   | 18 ++++++++++++------
 scripts/vm_smoke_test | 26 ++++++++++++++++++--------
 2 files changed, 30 insertions(+), 14 deletions(-)

diff --git a/scripts/ci_build.sh b/scripts/ci_build.sh
index d2ed6fe..d5e4d41 100755
--- a/scripts/ci_build.sh
+++ b/scripts/ci_build.sh
@@ -19,7 +19,7 @@ BUILD_DIR=./build
 BB_ARGS="-v"
 
 show_help() {
-    echo "This script builds all the default Isar images."
+    echo "This script builds the default Isar images."
     echo
     echo "Usage:"
     echo "    $0 [params]"
@@ -29,6 +29,7 @@ show_help() {
     echo "                          the build will be started in current path."
     echo "    -c, --cross           enable cross-compilation."
     echo "    -d, --debug           enable debug bitbake output."
+    echo "    -f, --fast            build reduced set of configurations."
     echo "    -q, --quiet           suppress verbose bitbake output."
     echo "    --help                display this message and exit."
     echo
@@ -57,6 +58,9 @@ do
     -d|--debug)
         BB_ARGS="$BB_ARGS -d"
         ;;
+    -f|--fast)
+        FAST_BUILD="1"
+        ;;
     -q|--quiet)
         BB_ARGS=""
         ;;
@@ -77,14 +81,16 @@ source isar-init-build-env $BUILD_DIR
 
 if [ -n "$CROSS_BUILD" ]; then
     sed -i -e 's/ISAR_CROSS_COMPILE ?= "0"/ISAR_CROSS_COMPILE ?= "1"/g' conf/local.conf
+fi
+
+if [ -n "$FAST_BUILD" ]; then
+    # Start build for the reduced set of configurations
+    # Enforce cross-compilation to speed up the build
+    sed -i -e 's/ISAR_CROSS_COMPILE ?= "0"/ISAR_CROSS_COMPILE ?= "1"/g' conf/local.conf
     bitbake $BB_ARGS \
-        multiconfig:qemuarm-jessie:isar-image-base \
         multiconfig:qemuarm-stretch:isar-image-base \
-        multiconfig:qemuarm-buster:isar-image-base \
         multiconfig:qemuarm64-stretch:isar-image-base \
-        multiconfig:qemuamd64-jessie:isar-image-base \
-        multiconfig:qemuamd64-stretch:isar-image-base \
-        multiconfig:qemuamd64-buster:isar-image-base
+        multiconfig:qemuamd64-stretch:isar-image-base
 else
     # Start build for all possible configurations
     bitbake $BB_ARGS \
diff --git a/scripts/vm_smoke_test b/scripts/vm_smoke_test
index 76c2e16..d497653 100755
--- a/scripts/vm_smoke_test
+++ b/scripts/vm_smoke_test
@@ -84,12 +84,13 @@ run_test () {
 }
 
 show_help() {
-    echo "This script tests all the default Isar images in QEMU."
+    echo "This script tests the Isar images for default targets in QEMU."
     echo
     echo "Usage:"
     echo "    $0 [params]"
     echo
     echo "Parameters:"
+    echo "    -f,--fast             test reduced set of supported targets."
     echo "    -o,--output FILE      specify file to store console output."
     echo "                          The default is: /tmp/isar_console"
     echo "    -p,--pid-file FILE    specify file to store QEMU process PID."
@@ -125,6 +126,9 @@ do
         PID_FILE=$2
         shift
         ;;
+    -f|--fast)
+        FAST_BUILD="1"
+        ;;
     -q|--quiet)
         VERBOSE=0
         ;;
@@ -142,19 +146,25 @@ do
 done
 
 # ARM machine
-run_test arm jessie
+if [ -z "$FAST_BUILD" ]; then
+    run_test arm jessie
+    run_test arm buster
+fi
 run_test arm stretch
-run_test arm buster
 
 # AMD64 machine
-run_test amd64 jessie
+if [ -z "$FAST_BUILD" ]; then
+    run_test amd64 jessie
+    run_test amd64 buster
+fi
 run_test amd64 stretch
-run_test amd64 buster
 
 # i386 machine
-run_test i386 jessie
-run_test i386 stretch
-run_test i386 buster
+if [ -z "$FAST_BUILD" ]; then
+    run_test i386 jessie
+    run_test i386 stretch
+    run_test i386 buster
+fi
 
 # ARM64 machine
 run_test arm64 stretch
-- 
2.11.0


^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2018-11-22 12:52 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-11-19  9:51 [PATCH] ci: Add option to build/test a reduced set of configurations Maxim Yu. Osipov
2018-11-22 12:52 ` Maxim Yu. Osipov

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox