Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

add SunOS requirements

  • Loading branch information...
commit 664413724765b4aef9325d88b0930b056735433f 1 parent 30f3936
@mpapis mpapis authored
View
58 scripts/functions/requirements/openindiana
@@ -0,0 +1,58 @@
+#!/usr/bin/env bash
+
+function requirements_gentoo()
+{
+ typeset -a command_to_run command_flags
+ command_to_run=()
+ command_flags=()
+
+ while
+ (( $# ))
+ do
+ case "$1" in
+ (echo)
+ command_to_run+=( $1 )
+ shift
+ ;;
+ (force)
+ shift
+ ;;
+ (*)
+ break
+ ;;
+ esac
+ done
+
+ (( UID == 0 )) || command_to_run+=( sudo )
+
+ while
+ (( $# ))
+ do
+ case "$1" in
+ (update-system)
+ true
+ ;;
+ (rvm)
+ "${command_to_run[@]}" pkg install bash curl git patch
+ ;;
+ (jruby-head*)
+ "${command_to_run[@]}" pkg install jdk apache-ant
+ ;;
+ (jruby*)
+ "${command_to_run[@]}" pkg install jdk
+ ;;
+ (ir*)
+ "${command_to_run[@]}" pkg install mono
+ ;;
+ (opal)
+ "${command_to_run[@]}" pkg install node-devel
+ ;;
+ (*)
+ "${command_to_run[@]}" pkg install text/gnu-patch runtime/gcc developer/library/lint system/header system/library/math/header-math file/gnu-coreutils
+ ;;
+ esac
+ shift
+ done
+}
+
+requirements_gentoo "$@"
View
58 scripts/functions/requirements/smartos
@@ -0,0 +1,58 @@
+#!/usr/bin/env bash
+
+function requirements_gentoo()
+{
+ typeset -a command_to_run command_flags
+ command_to_run=()
+ command_flags=()
+
+ while
+ (( $# ))
+ do
+ case "$1" in
+ (echo)
+ command_to_run+=( $1 )
+ shift
+ ;;
+ (force)
+ shift
+ ;;
+ (*)
+ break
+ ;;
+ esac
+ done
+
+ (( UID == 0 )) || command_to_run+=( sudo )
+
+ while
+ (( $# ))
+ do
+ case "$1" in
+ (update-system)
+ true
+ ;;
+ (rvm)
+ "${command_to_run[@]}" pkgin bash curl git patch
+ ;;
+ (jruby-head*)
+ "${command_to_run[@]}" pkgin jdk apache-ant
+ ;;
+ (jruby*)
+ "${command_to_run[@]}" pkgin jdk
+ ;;
+ (ir*)
+ "${command_to_run[@]}" pkgin mono
+ ;;
+ (opal)
+ "${command_to_run[@]}" pkgin node-devel
+ ;;
+ (*)
+ "${command_to_run[@]}" pkgin coreutils gcc47 gmake readline scmgit-base sqlite3 libxml2 libxslt ncurses autoconf automake
+ ;;
+ esac
+ shift
+ done
+}
+
+requirements_gentoo "$@"
View
58 scripts/functions/requirements/solaris
@@ -0,0 +1,58 @@
+#!/usr/bin/env bash
+
+function requirements_gentoo()
+{
+ typeset -a command_to_run command_flags
+ command_to_run=()
+ command_flags=()
+
+ while
+ (( $# ))
+ do
+ case "$1" in
+ (echo)
+ command_to_run+=( $1 )
+ shift
+ ;;
+ (force)
+ shift
+ ;;
+ (*)
+ break
+ ;;
+ esac
+ done
+
+ (( UID == 0 )) || command_to_run+=( sudo )
+
+ while
+ (( $# ))
+ do
+ case "$1" in
+ (update-system)
+ true
+ ;;
+ (rvm)
+ "${command_to_run[@]}" pkg install bash curl git patch
+ ;;
+ (jruby-head*)
+ "${command_to_run[@]}" pkg install jdk apache-ant
+ ;;
+ (jruby*)
+ "${command_to_run[@]}" pkg install jdk
+ ;;
+ (ir*)
+ "${command_to_run[@]}" pkg install mono
+ ;;
+ (opal)
+ "${command_to_run[@]}" pkg install node-devel
+ ;;
+ (*)
+ "${command_to_run[@]}" pkg install text/gnu-patch developer/gcc-45 developer/library/lint system/header system/library/math/header-math file/gnu-coreutils
+ ;;
+ esac
+ shift
+ done
+}
+
+requirements_gentoo "$@"
View
11 scripts/functions/utility
@@ -453,17 +453,18 @@ __rvm_detect_system()
;;
(SunOS)
_system_type="sunos"
+ _system_name="solaris"
_system_version="$(uname -v)"
if
- __rvm_string_match "$(uname -v)" "+([[:digit:]]).+([[:digit:]])*"
+ __rvm_string_match "${_system_version}" "joyent*"
then
- _system_name="solaris"
+ _system_name="smartos"
+ _system_version="${_system_version#* }"
elif
- __rvm_string_match "$(uname -v)" "oi*"
+ __rvm_string_match "${_system_version}" "oi*"
then
_system_name="openindiana"
- else
- return 3
+ _system_version="${_system_version#* }"
fi
;;
(OpenBSD)
View
64 scripts/requirements
@@ -11,7 +11,7 @@ rvm_pretty_print stdout || unset rvm_error_clr rvm_warn_clr rvm_debug_clr rvm_no
__rvm_detect_system
-if [[ "linux" == "$_system_type" || "bsd" == "$_system_type" ]]
+if [[ "linux" == "$_system_type" || "bsd" == "$_system_type" || "solaris" == "$_system_type" ]]
then
printf "%b" "Requirements for $_system_name/$_system_version/$_system_arch\n"
case ${1:-echo} in
@@ -33,68 +33,6 @@ Additional Dependencies:
bash "${rvm_scripts_path:-"$rvm_path/scripts"}/functions/requirements/$_system_name" ${1:-echo} $_type
done
-elif [[ "SunOS" == "$system" ]]
-then
- version="$(uname -v)"
- if [[ "11.0" == "$version" ]]
- then
- # looks like Solaris 11
- printf "%b" "
-RVM requirements for Solaris 11:
-
-# For Ruby / Ruby HEAD (MRI, Rubinius, & REE), install the following:
- ruby: pkg install text/gnu-patch developer/gcc-45 developer/library/lint system/header \\
- system/library/math/header-math file/gnu-coreutils
-
-# For JRuby, install the following:
- jruby: # The Oracle java runtime environment and development kit.
-
-# For Opal, install the following:
- opal: # Nodejs with NPM (version 0.8 or greater is recommended)
-"
- elif [[ "$version" =~ ^oi ]]
- then
- # looks like OpenIndiana
- printf "%b" "
-RVM requirements for OpenIndiana
-
-# For Ruby / Ruby HEAD (MRI, Rubinius, & REE), install the following:
- ruby: pkg install text/gnu-patch runtime/gcc developer/library/lint system/header \\
- system/library/math/header-math file/gnu-coreutils
-
-# For JRuby, install the following:
- jruby: # The Oracle java runtime environment and development kit.
-
-# For Opal, install the following:
-opal: # Nodejs with NPM (version 0.8 or greater is recommended)
-"
- elif [[ "$version" =~ ^joyent ]]
- then
- # looks like SmartOS
- printf "%b" "
-RVM requirements for SmartOS
-
-# For Ruby / Ruby HEAD (MRI, Rubinius, & REE), install the following:
- ruby: sudo pkgin install coreutils patch gcc47 gmake readline curl scmgit-base sqlite3 \\
- libxml2 libxslt ncurses autoconf automake
-
-# For JRuby, install the following:
- jruby: sudo pkgin install sun-jdk6
-"
- else
- printf "%b" "
-RVM requirements for unrecognised Solaris system.
-
-# For Ruby / Ruby HEAD (MRI, Rubinius, & REE), install the following:
- ruby: you will need to install: gcc, gnu-patch, lint library, system header, system
- math header and gnu-coreutils.
-
- Check you package publisher(s) for installing these.
-
-# For JRuby, install the following:
- jruby: # The Oracle java runtime environment and development kit.
-"
- fi
elif [[ "$MACHTYPE" == *darwin* ]]
then
Please sign in to comment.
Something went wrong with that request. Please try again.