lib/scripts/isabelle-platform
author wenzelm
Sat, 05 Apr 2014 15:03:40 +0200
changeset 56421 1ffd7eaa778b
parent 50182 30177ec0be36
child 62879 4764473c9b8d
permissions -rw-r--r--
updated to jedit_build-20140405: Code2HTML.jar, CommonControls.jar, Console.jar, kappalayout.jar, Navigator.jar, SideKick.jar, doc with jEdit manuals (ant dist-manuals);

# -*- shell-script -*- :mode=shellscript:
#
# determine general hardware and operating system type for Isabelle
#
# NOTE: The ML system or JVM may have their own idea about the platform!

ISABELLE_PLATFORM_FAMILY=""
ISABELLE_PLATFORM32=""
ISABELLE_PLATFORM64=""

case $(uname -s) in
  Linux)
    ISABELLE_PLATFORM_FAMILY="linux"
    case $(uname -m) in
      i?86)
        ISABELLE_PLATFORM32=x86-linux
        ;;
      x86_64)
        ISABELLE_PLATFORM32=x86-linux
        ISABELLE_PLATFORM64=x86_64-linux
        ;;
    esac
    ;;
  Darwin)
    ISABELLE_PLATFORM_FAMILY="macos"
    case $(uname -m) in
      i?86)
        ISABELLE_PLATFORM32=x86-darwin
        if [ "$(sysctl -n hw.optional.x86_64 2>/dev/null)" = 1 ]; then
          ISABELLE_PLATFORM64=x86_64-darwin
        fi
        ;;
      x86_64)
        ISABELLE_PLATFORM32=x86-darwin
        ISABELLE_PLATFORM64=x86_64-darwin
        ;;
    esac
    ;;
  CYGWIN_NT*)
    ISABELLE_PLATFORM_FAMILY="windows"
    case $(uname -m) in
      i?86 | x86_64)
        ISABELLE_PLATFORM32=x86-cygwin
        ;;
    esac
    ;;
  *BSD)
    ISABELLE_PLATFORM_FAMILY="linux"
    case $(uname -m) in
      i?86 | x86_64)
        ISABELLE_PLATFORM32=x86-linux  #cf. BSD Linux Binary Compatibility
        ;;
    esac
    ;;
esac

ISABELLE_PLATFORM="$ISABELLE_PLATFORM32"