prereq.sh 820 B

12345678910111213141516171819202122
  1. UNAME=`uname`
  2. NEEDED_PACKAGES_YUM='automake autoconf libtool screen gdb gcc-c++ compat-gcc-32 compat-gcc-32-c++ subversion ncurses-devel unixODBC-devel make wget'
  3. NEEDED_PACAKGES_APT='automake autoconf libtool screen gdb libncurses5-dev unixodbc-dev subversion emacs22-nox gcc g++ make libjpeg-dev'
  4. NEEDED_PACKAGES_PKG_ADD=''
  5. echo ${UNAME} | grep "Linux" && GETTER='wget -c'
  6. echo ${UNAME} | grep "BSD" && GETTER='fetch'
  7. which apt-get >> /dev/null && INSTALLER='apt-get -y install' && NEEDED_PACKAGES=$NEEDED_PACAKGES_APT
  8. which yum >> /dev/null && INSTALLER='yum -y install' && NEEDED_PACKAGES=$NEEDED_PACKAGES_YUM
  9. which pkg_add >> /dev/null && INSTALLER='pkg_add -r' && NEEDED_PACKAGES=$NEEDED_PACKAGES_PKG_ADD
  10. #echo $GETTER and $INSTALLER
  11. #echo ${INSTALLER} ${NEEDED_PACKAGES}
  12. ${INSTALLER} ${NEEDED_PACKAGES}