PageRenderTime 20ms CodeModel.GetById 13ms app.highlight 3ms RepoModel.GetById 1ms app.codeStats 0ms

/config/options

http://github.com/OpenELEC/OpenELEC.tv
#! | 113 lines | 92 code | 21 blank | 0 comment | 0 complexity | 6ad5de6b0cc09fe541209f7f3e62571c MD5 | raw file
  1# set default language for buildsystem
  2  export LC_ALL=C
  3
  4# determines DISTRO, if not forced by user
  5# default is OpenELEC
  6if [ -z "$DISTRO" ]; then
  7  DISTRO="OpenELEC"
  8else
  9  DISTRO="$DISTRO"
 10fi
 11
 12# determines PROJECT, if not forced by user
 13# default is Generic
 14if [ -z "$PROJECT" ]; then
 15  PROJECT="Generic"
 16else
 17  PROJECT="$PROJECT"
 18fi
 19
 20# determines TARGET_ARCH, if not forced by user (x86_64 / arm)
 21# default is x86_64
 22if [ -z "$ARCH" ]; then
 23  TARGET_ARCH="x86_64"
 24else
 25  TARGET_ARCH="$ARCH"
 26fi
 27
 28ROOT=`pwd`
 29DISTRO_DIR="$ROOT/distributions"
 30PROJECT_DIR="$ROOT/projects"
 31LINUX_DEPENDS="$PROJECT_DIR/$PROJECT/linux/linux.$TARGET_ARCH.conf $ROOT/packages/linux/package.mk"
 32
 33# include versioning
 34  . config/version
 35
 36# read distro versioning if available
 37 if [ -f "$DISTRO_DIR/$DISTRO/version" ]; then
 38   . $DISTRO_DIR/$DISTRO/version
 39 fi
 40
 41# read distro options if available
 42 if [ -f "$DISTRO_DIR/$DISTRO/options" ]; then
 43   . $DISTRO_DIR/$DISTRO/options
 44 fi
 45
 46# read project options if available
 47 if [ -f "$PROJECT_DIR/$PROJECT/options" ]; then
 48   . $PROJECT_DIR/$PROJECT/options
 49 fi
 50
 51# Need to point to your actual cc
 52# If you have ccache installed, take care that LOCAL_CC don't point to it
 53  LOCAL_CC=`which gcc`
 54
 55if [ -z "$LOCAL_CC" ] ; then
 56  echo "***** Please install gcc *****"
 57  exit 127
 58fi
 59
 60# Need to point to your actual g++
 61# If you have ccache installed, take care that LOCAL_CXX don't point to it
 62  LOCAL_CXX=`which g++`
 63
 64# Support C++ in toolchain
 65  TOOLCHAIN_CXX="yes"
 66
 67# verbose compilation mode (yes/no)
 68  VERBOSE="yes"
 69
 70# Concurrency make level (-j option)
 71#  Try value 1 (default) to 4 on single CPU computer, or more on
 72#  multi-processor computer (like hyperthreading SMP CPU)
 73  if test -z "${CONCURRENCY_MAKE_LEVEL}"; then
 74    CONCURRENCY_MAKE_LEVEL=`cat /proc/cpuinfo | grep -c '^processor[[:cntrl:]]*:'`
 75  fi
 76
 77# cache size for ccache
 78# Set the maximum size of the files stored in the cache. You can specify a
 79# value in gigabytes, megabytes or kilobytes by appending a G, M or K to the
 80# value. The default is gigabytes. The actual value stored is rounded down to
 81# the nearest multiple of 16 kilobytes.
 82  CCACHE_CACHE_SIZE="30G"
 83
 84# install devtools on development builds
 85  if [ "$OPENELEC_VERSION" = "devel" ]; then
 86    DEVTOOLS=yes
 87  fi
 88
 89# read options from $HOME if available
 90  if [ -f "$HOME/.openelec/options" ]; then
 91    . $HOME/.openelec/options
 92  fi
 93  if [ -f "$HOME/.openelec/projects/$PROJECT/options" ]; then
 94    . $HOME/.openelec/projects/$PROJECT/options
 95  fi
 96
 97# read distro options from $HOME if available
 98  if [ -f "$HOME/.openelec/options.$DISTRO" ]; then
 99    . $HOME/.openelec/options.$DISTRO
100  fi
101
102# overwrite OEM_SUPPORT via commandline
103if [ "$OEM" = yes -o "$OEM" = no ]; then
104  OEM_SUPPORT=$OEM
105fi
106
107# overwrite REPO_DIR via commandline
108if [ -n "$REPO" ]; then
109  REPO_DIR=$REPO
110fi
111
112. config/graphic
113. config/path $1