clarified build -n (no build);
authorwenzelm
Tue Jul 24 12:28:20 2012 +0200 (2012-07-24)
changeset 48469826a771cff33
parent 48468 7f2998b95249
child 48470 7483aa690b4f
clarified build -n (no build);
lib/Tools/build
src/Pure/System/build.scala
     1.1 --- a/lib/Tools/build	Tue Jul 24 12:20:01 2012 +0200
     1.2 +++ b/lib/Tools/build	Tue Jul 24 12:28:20 2012 +0200
     1.3 @@ -19,7 +19,7 @@
     1.4    echo "    -b           build target images"
     1.5    echo "    -d DIR       additional session directory with ROOT file"
     1.6    echo "    -j INT       maximum number of jobs (default 1)"
     1.7 -  echo "    -l           list sessions only"
     1.8 +  echo "    -n           no build -- test dependencies only"
     1.9    echo "    -o OPTION    override session configuration OPTION (via NAME=VAL or NAME)"
    1.10    echo "    -s           system build mode: produce output in ISABELLE_HOME"
    1.11    echo "    -t           inner session timing"
    1.12 @@ -53,7 +53,7 @@
    1.13  ALL_SESSIONS=false
    1.14  BUILD_IMAGES=false
    1.15  MAX_JOBS=1
    1.16 -LIST_ONLY=false
    1.17 +NO_BUILD=false
    1.18  SYSTEM_MODE=false
    1.19  TIMING=false
    1.20  VERBOSE=false
    1.21 @@ -61,7 +61,7 @@
    1.22  declare -a MORE_DIRS=()
    1.23  eval "declare -a BUILD_OPTIONS=($ISABELLE_BUILD_OPTIONS)"
    1.24  
    1.25 -while getopts "abd:j:lo:stv" OPT
    1.26 +while getopts "abd:j:no:stv" OPT
    1.27  do
    1.28    case "$OPT" in
    1.29      a)
    1.30 @@ -77,8 +77,8 @@
    1.31        check_number "$OPTARG"
    1.32        MAX_JOBS="$OPTARG"
    1.33        ;;
    1.34 -    l)
    1.35 -      LIST_ONLY="true"
    1.36 +    n)
    1.37 +      NO_BUILD="true"
    1.38        ;;
    1.39      o)
    1.40        BUILD_OPTIONS["${#BUILD_OPTIONS[@]}"]="$OPTARG"
    1.41 @@ -106,5 +106,5 @@
    1.42  [ -e "$ISABELLE_HOME/Admin/build" ] && { "$ISABELLE_HOME/Admin/build" jars || exit $?; }
    1.43  
    1.44  exec "$ISABELLE_TOOL" java isabelle.Build \
    1.45 -  "$ALL_SESSIONS" "$BUILD_IMAGES" "$MAX_JOBS" "$LIST_ONLY" "$SYSTEM_MODE" "$TIMING" \
    1.46 +  "$ALL_SESSIONS" "$BUILD_IMAGES" "$MAX_JOBS" "$NO_BUILD" "$SYSTEM_MODE" "$TIMING" \
    1.47    "$VERBOSE" "${MORE_DIRS[@]}" $'\n' "${BUILD_OPTIONS[@]}" $'\n' "$@"
     2.1 --- a/src/Pure/System/build.scala	Tue Jul 24 12:20:01 2012 +0200
     2.2 +++ b/src/Pure/System/build.scala	Tue Jul 24 12:28:20 2012 +0200
     2.3 @@ -403,7 +403,7 @@
     2.4    private def sleep(): Unit = Thread.sleep(500)
     2.5  
     2.6    def build(all_sessions: Boolean, build_images: Boolean, max_jobs: Int,
     2.7 -    list_only: Boolean, system_mode: Boolean, timing: Boolean, verbose: Boolean,
     2.8 +    no_build: Boolean, system_mode: Boolean, timing: Boolean, verbose: Boolean,
     2.9      more_dirs: List[Path], more_options: List[String], sessions: List[String]): Int =
    2.10    {
    2.11      val options = (Options.init() /: more_options)(_.define_simple(_))
    2.12 @@ -451,7 +451,7 @@
    2.13        else if (running.size < (max_jobs max 1)) {
    2.14          pending.dequeue(running.isDefinedAt(_)) match {
    2.15            case Some((name, info)) =>
    2.16 -            if (list_only) {
    2.17 +            if (no_build && verbose) {
    2.18                echo(name + " in " + info.dir)
    2.19                loop(pending - name, running, results + (name -> 0))
    2.20              }
    2.21 @@ -488,12 +488,12 @@
    2.22            Properties.Value.Boolean(all_sessions) ::
    2.23            Properties.Value.Boolean(build_images) ::
    2.24            Properties.Value.Int(max_jobs) ::
    2.25 -          Properties.Value.Boolean(list_only) ::
    2.26 +          Properties.Value.Boolean(no_build) ::
    2.27            Properties.Value.Boolean(system_mode) ::
    2.28            Properties.Value.Boolean(timing) ::
    2.29            Properties.Value.Boolean(verbose) ::
    2.30            Command_Line.Chunks(more_dirs, options, sessions) =>
    2.31 -            build(all_sessions, build_images, max_jobs, list_only, system_mode, timing,
    2.32 +            build(all_sessions, build_images, max_jobs, no_build, system_mode, timing,
    2.33                verbose, more_dirs.map(Path.explode), options, sessions)
    2.34          case _ => error("Bad arguments:\n" + cat_lines(args))
    2.35        }