download_and_compile.sh: simplify the definition of _usage()
This commit is contained in:
+80
-80
@@ -843,86 +843,86 @@ function _printVersion(){
|
|||||||
}
|
}
|
||||||
|
|
||||||
function _usage() {
|
function _usage() {
|
||||||
echo "$PROGNAME [OPTION...] [--] [COMPONENT...]"
|
echo "$PROGNAME [OPTION...] [--] [COMPONENT...]
|
||||||
echo "Download and compile components belonging to the FlightGear ecosystem."
|
Download and compile components belonging to the FlightGear ecosystem.
|
||||||
echo
|
|
||||||
echo "Without any COMPONENT listed, or if ALL is specified, recompile all"
|
Without any COMPONENT listed, or if ALL is specified, recompile all
|
||||||
echo "components listed in the WHATTOBUILDALL variable. Each COMPONENT may"
|
components listed in the WHATTOBUILDALL variable. Each COMPONENT may
|
||||||
echo "be one of the following words:"
|
be one of the following words:
|
||||||
echo
|
|
||||||
echo " ALL, $(_joinBy ', ' "${WHATTOBUILD_AVAIL[@]}")."
|
ALL, $(_joinBy ', ' "${WHATTOBUILD_AVAIL[@]}").
|
||||||
echo
|
|
||||||
echo "Available options:"
|
Available options:
|
||||||
echo " -h, --help show this help message and exit"
|
-h, --help show this help message and exit
|
||||||
echo " --version print version and license information, then exit"
|
--version print version and license information, then exit
|
||||||
echo " -e compile FlightGear with --with-eventinput option (experimental)"
|
-e compile FlightGear with --with-eventinput option (experimental)
|
||||||
echo " -i compile SimGear and FlightGear with -D ENABLE_RTI=ON option (experimental)"
|
-i compile SimGear and FlightGear with -D ENABLE_RTI=ON option (experimental)
|
||||||
echo " -b RELEASE_TYPE default=RelWithDebInfo"
|
-b RELEASE_TYPE default=RelWithDebInfo
|
||||||
echo " set build type to RELEASE_TYPE (Release|RelWithDebInfo|Debug)"
|
set build type to RELEASE_TYPE (Release|RelWithDebInfo|Debug)
|
||||||
echo " -a y|n y=run 'PACKAGE_MANAGER update', n=don't default=y"
|
-a y|n y=run 'PACKAGE_MANAGER update', n=don't default=y
|
||||||
echo " (PACKAGE_MANAGER being a program like 'apt-get', see below)"
|
(PACKAGE_MANAGER being a program like 'apt-get', see below)
|
||||||
echo " -p y|n y=install packages using PACKAGE_MANAGER, n=don't default=y"
|
-p y|n y=install packages using PACKAGE_MANAGER, n=don't default=y
|
||||||
echo " -c y|n y=compile programs, n=don't default=y"
|
-c y|n y=compile programs, n=don't default=y
|
||||||
echo " -d y|n y=fetch programs from the Internet (Git, svn, etc.), n=don't default=y"
|
-d y|n y=fetch programs from the Internet (Git, svn, etc.), n=don't default=y
|
||||||
echo " --cleanup Remove all build and installation directories. Try this if a"
|
--cleanup Remove all build and installation directories. Try this if a
|
||||||
echo ' compilation fails and the "base directory" was not "fresh" when'
|
compilation fails and the \"base directory\" was not \"fresh\" when
|
||||||
echo " you started ${PROGNAME}. If this option is given and no"
|
you started ${PROGNAME}. If this option is given and no
|
||||||
echo " component has been specified on the command line, then only the"
|
component has been specified on the command line, then only the
|
||||||
echo " cleanup routine is run."
|
cleanup routine is run.
|
||||||
echo " --git-clone-default-proto=PROTO default=https"
|
--git-clone-default-proto=PROTO default=https
|
||||||
echo " default protocol to use for 'git clone' (https, git or ssh)"
|
default protocol to use for 'git clone' (https, git or ssh)
|
||||||
echo " --git-clone-site-params=SITE=PROTOCOL[:USERNAME]"
|
--git-clone-site-params=SITE=PROTOCOL[:USERNAME]
|
||||||
echo " use PROTOCOL as USERNAME when cloning a Git repository located"
|
use PROTOCOL as USERNAME when cloning a Git repository located
|
||||||
echo " at SITE (sample sites: 'sourceforge', 'github'; valid"
|
at SITE (sample sites: 'sourceforge', 'github'; valid
|
||||||
echo " protocols: 'ssh', 'https', 'git'; USERNAME is required when"
|
protocols: 'ssh', 'https', 'git'; USERNAME is required when
|
||||||
echo " using 'ssh'). You may pass this option several times with"
|
using 'ssh'). You may pass this option several times with
|
||||||
echo " different sites."
|
different sites.
|
||||||
echo " --package-manager=PACKAGE_MANAGER default=apt-get"
|
--package-manager=PACKAGE_MANAGER default=apt-get
|
||||||
echo " program used to install packages; must be compatible with"
|
program used to install packages; must be compatible with
|
||||||
echo " 'apt-get' for the operations performed by $PROGNAME."
|
'apt-get' for the operations performed by $PROGNAME.
|
||||||
echo " --sudo=SUDO_PROGRAM default=sudo"
|
--sudo=SUDO_PROGRAM default=sudo
|
||||||
echo " program used to run PACKAGE_MANAGER with appropriate rights"
|
program used to run PACKAGE_MANAGER with appropriate rights
|
||||||
echo " (pass an empty value to run the package manager directly)."
|
(pass an empty value to run the package manager directly).
|
||||||
echo " Passing 'echo' as the SUDO_PROGRAM can be useful to see what"
|
Passing 'echo' as the SUDO_PROGRAM can be useful to see what
|
||||||
echo " would be done with the package manager without actually running"
|
would be done with the package manager without actually running
|
||||||
echo " the commands."
|
the commands.
|
||||||
echo " -j X pass -jX to the Make program"
|
-j X pass -jX to the Make program
|
||||||
echo " -O X pass -OX to the Make program"
|
-O X pass -OX to the Make program
|
||||||
echo " -r y|n y=reconfigure programs before compiling them, n=don't reconfigure default=y"
|
-r y|n y=reconfigure programs before compiling them, n=don't reconfigure default=y
|
||||||
echo " --ignore-intercomponent-deps"
|
--ignore-intercomponent-deps
|
||||||
echo " Ignore dependencies between components (default: don't)."
|
Ignore dependencies between components (default: don't).
|
||||||
echo " Example: TERRAGEAR depends on SIMGEAR. Passing the option can be"
|
Example: TERRAGEAR depends on SIMGEAR. Passing the option can be
|
||||||
echo " useful if you want to update, rebuild, etc. TERRAGEAR without"
|
useful if you want to update, rebuild, etc. TERRAGEAR without
|
||||||
echo " doing the same for SIMGEAR (e.g., if doing repeated TERRAGEAR"
|
doing the same for SIMGEAR (e.g., if doing repeated TERRAGEAR
|
||||||
echo " builds and you know your SIMGEAR is already fine and up-to-date)."
|
builds and you know your SIMGEAR is already fine and up-to-date).
|
||||||
echo " --lts compile the latest Long Term Stable release of FlightGear (and"
|
--lts compile the latest Long Term Stable release of FlightGear (and
|
||||||
echo " corresponding versions for other components)"
|
corresponding versions for other components)
|
||||||
echo " --old-lts compile the previous Long Term Stable release of FlightGear (and"
|
--old-lts compile the previous Long Term Stable release of FlightGear (and
|
||||||
echo " corresponding versions for other components)"
|
corresponding versions for other components)
|
||||||
echo " -s compile the latest stable release of FlightGear (and"
|
-s compile the latest stable release of FlightGear (and
|
||||||
echo " corresponding versions of the other components)"
|
corresponding versions of the other components)
|
||||||
echo " --component-branch=COMPONENT=BRANCH"
|
--component-branch=COMPONENT=BRANCH
|
||||||
echo " Override the default branch for COMPONENT. For the specified"
|
Override the default branch for COMPONENT. For the specified
|
||||||
echo " component, this overrides the effect of options -s, --lts and"
|
component, this overrides the effect of options -s, --lts and
|
||||||
echo " --old-lts. This option may be given several times."
|
--old-lts. This option may be given several times.
|
||||||
echo " --sg-cmake-arg=ARGUMENT"
|
--sg-cmake-arg=ARGUMENT
|
||||||
echo " Pass ARGUMENT to CMake when building SimGear."
|
Pass ARGUMENT to CMake when building SimGear.
|
||||||
echo " This option may be given several times."
|
This option may be given several times.
|
||||||
echo " --fg-cmake-arg=ARGUMENT"
|
--fg-cmake-arg=ARGUMENT
|
||||||
echo " Pass ARGUMENT to CMake when building FlightGear."
|
Pass ARGUMENT to CMake when building FlightGear.
|
||||||
echo " This option may be given several times."
|
This option may be given several times.
|
||||||
echo " --compositor"
|
--compositor
|
||||||
echo " build FlightGear with compositor enabled"
|
build FlightGear with compositor enabled
|
||||||
echo " --non-interactive"
|
--non-interactive
|
||||||
echo " don't ask any question; always assume the default answer in"
|
don't ask any question; always assume the default answer in
|
||||||
echo " situations where a question would normally be asked."
|
situations where a question would normally be asked.
|
||||||
echo
|
|
||||||
echo "More detailed information can be found on the FlightGear wiki:"
|
More detailed information can be found on the FlightGear wiki:
|
||||||
echo ""
|
|
||||||
echo " http://wiki.flightgear.org/Scripted_Compilation_on_Linux_Debian/Ubuntu"
|
http://wiki.flightgear.org/Scripted_Compilation_on_Linux_Debian/Ubuntu
|
||||||
echo ""
|
|
||||||
echo "The wiki may sometimes be a bit outdated; if in doubt, consider this help text"
|
The wiki may sometimes be a bit outdated; if in doubt, consider this help text
|
||||||
echo "as the reference."
|
as the reference."
|
||||||
}
|
}
|
||||||
|
|
||||||
#######################################################
|
#######################################################
|
||||||
|
|||||||
Reference in New Issue
Block a user