Skip to content
Snippets Groups Projects
Commit 2bf183d3 authored by Erik von Reis's avatar Erik von Reis
Browse files

rtcds: added orthagonal commandline flags for choosing kernel or user space...

rtcds: added orthagonal commandline flags for choosing kernel or user space model building.  Default is user space, but can be changed by setting USE_KERNEL_MODELS to true.
parent 0e7a09b3
No related branches found
No related tags found
1 merge request!150Update rtcds with user-space model flags
......@@ -4,6 +4,16 @@ log() {
echo "$@" >&2
}
USE_KERNEL_MODELS=${USE_KERNEL_MODELS:-false}
if $USE_KERNEL_MODELS ; then
log "Build kernel-mode models by default"
else
log "Build user mode models by default"
USERLAND_FLAG=0
NOKERNELSPACE_FLAG=0
fi
# capture all command line flags as variables
params=""
ccmd=""
......@@ -17,6 +27,14 @@ while (( "$#" )); do
USERLAND_FLAG=0
shift
;;
--no-user-space|--no-userland)
USERLAND_FLAG=''
shift
;;
--kernel-space)
NOKERNELSPACE_FLAG=''
shift
;;
--no-kernel-space)
NOKERNELSPACE_FLAG=0
shift
......@@ -415,11 +433,20 @@ global_status() {
usage() {
if $USE_KERNEL_MODELS ; then
local udefault=""
local kdefault=" (default)"
else
local udefault=" (default)"
local kdefault=""
fi
if $ALLOW_MODEL_ENABLE ; then
local enable_usage="enable <sys>...|--all enable system start at boot
"
local enable_usage="
enable <sys>...|--all enable system start at boot"
else
local enable_usage=""
local enable_usage="
"
fi
echo "Usage: $(basename $0) <command> [options] [args]
......@@ -428,28 +455,30 @@ Advanced LIGO Real Time System control interface.
Available commands:
build|make <sys>...|--all build system
--user-space|--userland build model in userland (user space)
--no-kernel-space do not build kernel space model
install <sys>...|--all install system
list|ls list systems for host
${enable_usage}disable <sys>...|--all disable system start at boot
start <sys>...|--all start systems
restart <sys>...|--all restart running systems
stop|kill <sys>...|--all stop running systems
status [<sys>] show status for system services
log show logs for system services
-f follow logs
blog <sys> show last build log for system
-i print log paths
lsmod list loaded RTS kernel modules
env print system environment info
version|--version|-v print version
help|--help|-h this help
build|make <sys>...|--all build system
--user-space|--userland build model in userland $udefault
--no-user-space|--no-userland do not build model in userland $kdefault
--kernel-space build model in kernel space $kdefault
--no-kernel-space do not build model in kernel space $udefault
install <sys>...|--all install system
list|ls list systems for host
${enable_usage}
disable <sys>...|--all disable system start at boot
start <sys>...|--all start systems
restart <sys>...|--all restart running systems
stop|kill <sys>...|--all stop running systems
status [<sys>] show status for system services
log show logs for system services
-f follow logs
blog <sys> show last build log for system
-i print log paths
lsmod list loaded RTS kernel modules
env print system environment info
version|--version|-v print version
help|--help|-h this help
"
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment