Enhancements for op-build ci.
This patch adds support for running ci for individual platforms,
as well as it can generate firmware images for all the platforms.
Added command line options -p and -a.
-p List of comma separated platform names to build images for those particular platforms.
-a Build firmware images for all the platform defconfig's.
For running ci to individual platforms:
DOCKER_PREFIX=sudo ./ci/build.sh -p palmetto
DOCKER_PREFIX=sudo ./ci/build.sh -p garrison,palmetto
For running ci to all the platforms:
DOCKER_PREFIX=sudo ./ci/build.sh -a
DOCKER_PREFIX=sudo ./ci/build.sh
And also it contains missing packages required for fedora23 Dockerfile.
Signed-off-by: Pridhiviraj Paidipeddi <ppaidipe@linux.vnet.ibm.com>
diff --git a/ci/build-all-defconfigs.sh b/ci/build-all-defconfigs.sh
index 1730e28..f8b1cd4 100755
--- a/ci/build-all-defconfigs.sh
+++ b/ci/build-all-defconfigs.sh
@@ -3,7 +3,20 @@
set -ex
set -eo pipefail
-DEFCONFIGS=`(cd openpower/configs; ls -1 *_defconfig)`
+CONFIGTAG="_defconfig"
+
+DEFCONFIGS=();
+
+if [ -z "$2" ]; then
+ echo "Using all the defconfigs for all the platforms"
+ DEFCONFIGS=`(cd openpower/configs; ls -1 *_defconfig)`
+else
+ IFS=', '
+ for p in $2;
+ do
+ DEFCONFIGS+=($p$CONFIGTAG)
+ done
+fi
if [ -z "$1" or ! -d "$1" ]; then
echo "No output directory specified"
@@ -17,7 +30,7 @@
shopt -s expand_aliases
source op-build-env
-for i in $DEFCONFIGS; do
+for i in ${DEFCONFIGS[@]}; do
op-build $i
echo 'BR2_CCACHE=y' >> output/.config
echo "BR2_CCACHE_DIR=\"$CCACHE_DIR\"" >> output/.config