Admin/Release/build
changeset 56902 f901a08c5653
parent 51064 9c425ed4a52c
child 57685 34ec8a580917
     1.1 --- a/Admin/Release/build	Wed May 07 14:54:06 2014 +0200
     1.2 +++ b/Admin/Release/build	Wed May 07 18:09:08 2014 +0200
     1.3 @@ -19,6 +19,7 @@
     1.4    echo
     1.5    echo "  Options are:"
     1.6    echo "    -j INT       maximum number of parallel jobs (default 1)"
     1.7 +  echo "    -l           build library"
     1.8    echo "    -r RELEASE   proper release with name"
     1.9    echo
    1.10    echo "  Make Isabelle distribution DIR, using the local repository clone."
    1.11 @@ -46,15 +47,19 @@
    1.12  # options
    1.13  
    1.14  JOBS=""
    1.15 +LIBRARY=""
    1.16  RELEASE=""
    1.17  
    1.18 -while getopts "j:r:" OPT
    1.19 +while getopts "j:lr:" OPT
    1.20  do
    1.21    case "$OPT" in
    1.22      j)
    1.23        check_number "$OPTARG"
    1.24        JOBS="-j $OPTARG"
    1.25        ;;
    1.26 +    l)
    1.27 +      LIBRARY="true"
    1.28 +      ;;
    1.29      r)
    1.30        RELEASE="$OPTARG"
    1.31        ;;
    1.32 @@ -89,6 +94,8 @@
    1.33  
    1.34  ## main
    1.35  
    1.36 +# make dist
    1.37 +
    1.38  if [ -z "$RELEASE" ]; then
    1.39    DISTNAME="Isabelle_$(env LC_ALL=C date "+%d-%b-%Y")"
    1.40    "$ISABELLE_TOOL" makedist -d "$BASE_DIR" $JOBS
    1.41 @@ -101,6 +108,8 @@
    1.42  DISTBASE="$BASE_DIR/dist-${DISTNAME}"
    1.43  
    1.44  
    1.45 +# make bundles
    1.46 +
    1.47  for PLATFORM_FAMILY in linux macos windows
    1.48  do
    1.49  
    1.50 @@ -112,5 +121,32 @@
    1.51  
    1.52  done
    1.53  
    1.54 -"$THIS/build_library" $JOBS "$DISTBASE/${DISTNAME}_${ISABELLE_PLATFORM_FAMILY}.tar.gz"
    1.55 +
    1.56 +# minimal index
    1.57 +
    1.58 +cat > "$DISTBASE/index.html" <<EOF
    1.59 +<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 3.2//EN">
    1.60 +<html>
    1.61 +<head>
    1.62 +<title>${DISTNAME}</title>
    1.63 +</head>
    1.64  
    1.65 +<body>
    1.66 +<h1>${DISTNAME}</h1>
    1.67 +<ul>
    1.68 +<li><a href="${DISTNAME}_linux.tar.gz">Linux</a></li>
    1.69 +<li><a href="${DISTNAME}.exe">Windows</a></li>
    1.70 +<li><a href="${DISTNAME}.dmg">Mac OS X</a></li>
    1.71 +</ul>
    1.72 +</body>
    1.73 +
    1.74 +</html>
    1.75 +EOF
    1.76 +
    1.77 +
    1.78 +# HTML library
    1.79 +
    1.80 +if [ -n "$LIBRARY" ]; then
    1.81 +  "$THIS/build_library" $JOBS "$DISTBASE/${DISTNAME}_${ISABELLE_PLATFORM_FAMILY}.tar.gz"
    1.82 +fi
    1.83 +