summaryrefslogtreecommitdiffstats
path: root/remote/setup_tools
diff options
context:
space:
mode:
authorSimon Rettberg2013-02-25 20:13:48 +0100
committerSimon Rettberg2013-02-25 20:13:48 +0100
commit8d34cf49ad72e556b88033202f7dde130d80fa74 (patch)
tree3b73845f6e83f6caa47215173ca1899acc0f262d /remote/setup_tools
parentfix tarcopy call for base (diff)
downloadtm-scripts-8d34cf49ad72e556b88033202f7dde130d80fa74.tar.gz
tm-scripts-8d34cf49ad72e556b88033202f7dde130d80fa74.tar.xz
tm-scripts-8d34cf49ad72e556b88033202f7dde130d80fa74.zip
Several fixes and improvements:
- return uid and gid again for add_user and add_group - abort execution if sourcing the .build or .conf file of a module fails - make sure lightdm user and group exists when building the ldm module - use tarcopy in all modules if appropriate
Diffstat (limited to 'remote/setup_tools')
-rwxr-xr-xremote/setup_tools21
1 files changed, 11 insertions, 10 deletions
diff --git a/remote/setup_tools b/remote/setup_tools
index bf3f5157..74cc1c78 100755
--- a/remote/setup_tools
+++ b/remote/setup_tools
@@ -18,20 +18,20 @@ initial_checks ()
read_config ()
{
- local TOOL_CONFIG=${TOOL_DIR}/${TOOL}/${TOOL}.conf
+ local TOOL_CONFIG="${TOOL_DIR}/${TOOL}/${TOOL}.conf"
- [ ! -e ${TOOL_CONFIG} ] && perror "Config for '$TOOL' not found."
+ [ ! -e "${TOOL_CONFIG}" ] && perror "Config for '$TOOL' not found."
- . ${TOOL_CONFIG}
+ . "${TOOL_CONFIG}" || perror "Sourcing '${TOOL_CONFIG}' failed."
}
read_build ()
{
- local BUILD_SCRIPT=${TOOL_DIR}/${TOOL}/${TOOL}.build
+ local BUILD_SCRIPT="${TOOL_DIR}/${TOOL}/${TOOL}.build"
- [ ! -e ${BUILD_SCRIPT} ] && perror "Build script for specified tool not found."
+ [ ! -e "${BUILD_SCRIPT}" ] && perror "Build script for specified tool not found."
- . ${BUILD_SCRIPT}
+ . "${BUILD_SCRIPT}" || perror "Sourcing '${BUILD_SCRIPT}' failed."
}
copyfileswithdependencies ()
@@ -190,13 +190,14 @@ generate_stage32 () {
fi
# now iterate over given tools and copy them
- cd ${TOOL_DIR}
+ cd "${TOOL_DIR}"
while (( "$#" )); do
TOOL=$1
+ TOOL_STR=""
+ pinfo ">>>>>>>>>>>>>>>>> Processing module [ $TOOL ]"
+ TOOL_STR="[${TOOL}]"
if [ -d ${TOOL} ];
then
- TOOL_STR="[${TOOL}]"
- pinfo "## ## Processing module ## ##"
#[ "x$DEBUG" != "x1" ] \
# && echo "Logging to ${TOOL_DIR}/${TOOL}/stage32.log" \
@@ -225,13 +226,13 @@ generate_stage32 () {
#[ "x$DEBUG" != "x1" ] && exec 1>&6 6>&-
# TODO
pinfo "## ## Module completed ## ##"
- TOOL_STR=""
else
perror "Tool directory for '$TOOL' not found."
# maybe make this a warning instead of error?
fi
shift
done
+ TOOL_STR=""
}
clean_tools() {