From 1a976cb67b89fd0ac97ffa503f51244b6f0be0a9 Mon Sep 17 00:00:00 2001 From: Greg Armendariz Date: Tue, 27 May 2014 13:00:36 -0500 Subject: [PATCH] Omaha #3215 - Add option for RPM build, Change-Id: Ic3a50f9a493c9cd7b92ac99aeb026d3d991f69a5 Former-commit-id: 0806135d2e5d321d9e974a96f48230837fba42a8 [formerly 265a455ca1c213d978ec5037654adde80d9dd54c] [formerly 0806135d2e5d321d9e974a96f48230837fba42a8 [formerly 265a455ca1c213d978ec5037654adde80d9dd54c] [formerly a2e157ed357299b87092d1f1cb844673bcf7ca10 [formerly 615c83cb701e3c8ddf7cbcc1c1fb735711771d3b]]] Former-commit-id: a2e157ed357299b87092d1f1cb844673bcf7ca10 Former-commit-id: db01c4b45e347d1e3e13216422f6b76e61a972c2 [formerly 81ca8ed4c694eee450afef2f1924e326b3288229] Former-commit-id: bdbdfdaa7a364d07d0cb74e54165328b169e782c --- rpms/build/common/usage.sh | 1 + rpms/build/x86_64/build.sh | 17 +++++++++++++++++ 2 files changed, 18 insertions(+) diff --git a/rpms/build/common/usage.sh b/rpms/build/common/usage.sh index 5eedad02d7..b00b663769 100644 --- a/rpms/build/common/usage.sh +++ b/rpms/build/common/usage.sh @@ -11,6 +11,7 @@ function usage() echo " -edex only build the EDEX rpms." echo " -qpid build only the QPID rpms." echo " -ldm build the awips2-ldm rpm; requires root privileges." + echo " -dev call functions directly echo " -package create a yum repository tar file with the rpms that were just built." echo " --help display this message and exit." diff --git a/rpms/build/x86_64/build.sh b/rpms/build/x86_64/build.sh index 86afc146ea..46818aad16 100644 --- a/rpms/build/x86_64/build.sh +++ b/rpms/build/x86_64/build.sh @@ -533,5 +533,22 @@ if [ "${1}" = "-package" ]; then exit 0 fi +if [ "${1}" = "-dev" ]; then + + if [ ! $# -eq 2 ]; then + usage + exit 1; + fi + + echo -e "\n*** Executing $2 ***" + $2 + if [ $? -ne 0 ]; then + exit 1 + fi + echo -e "*** $2 Complete ***\n" + exit 0 +fi + + usage exit 0