|
| 1 | +#!/usr/bin/env bash |
| 2 | + |
| 3 | +requirements_solus_lib_installed() |
| 4 | +{ |
| 5 | + eopkg li --no-color | __rvm_grep "^$1[[:space:]]\+" > /dev/null 2>&1 || return $? |
| 6 | +} |
| 7 | + |
| 8 | +requirements_solus_lib_available() |
| 9 | +{ |
| 10 | + eopkg la --no-color | __rvm_grep "^$1[[:space:]]\+" > /dev/null 2>&1 || return $? |
| 11 | +} |
| 12 | + |
| 13 | +requirements_solus_install_custom() |
| 14 | +{ |
| 15 | + requirements_rvm_pkg_libs_install "$@" || return $? |
| 16 | +} |
| 17 | + |
| 18 | +requirements_solus_libs_install() |
| 19 | +{ |
| 20 | + __rvm_try_sudo eopkg --no-color --yes-all it "$@" || return $? |
| 21 | +} |
| 22 | + |
| 23 | +requirements_solus_check_binary() |
| 24 | +{ |
| 25 | + __rvm_which "$1" >/dev/null || return $? |
| 26 | +} |
| 27 | + |
| 28 | +requirements_solus_define() |
| 29 | +{ |
| 30 | + case "$1" in |
| 31 | + (rvm) |
| 32 | + requirements_check bash curl patch ca-certs gawk bzip2 |
| 33 | + ;; |
| 34 | + (jruby*) |
| 35 | + if |
| 36 | + is_head_or_disable_binary "$1" |
| 37 | + then |
| 38 | + requirements_solus_check_binary javac || |
| 39 | + requirements_check_fallback openjdk-8-devel |
| 40 | + requirements_check git |
| 41 | + if is_jruby_post17 "$1" |
| 42 | + then requirements_check_custom_after mvn=maven |
| 43 | + fi |
| 44 | + else |
| 45 | + requirements_solus_check_binary java || |
| 46 | + requirements_check_fallback openjdk-8 |
| 47 | + fi |
| 48 | + ;; |
| 49 | + (ir*) |
| 50 | + true |
| 51 | + ;; |
| 52 | + (opal) |
| 53 | + true |
| 54 | + ;; |
| 55 | + (*-head) |
| 56 | + requirements_check git |
| 57 | + requirements_solus_define "${1%-head}" |
| 58 | + requirements_version_minimal autoconf 2.67 |
| 59 | + ;; |
| 60 | + (*) |
| 61 | + if [[ ${#rvm_patch_names[@]} -gt 0 ]] |
| 62 | + then requirements_version_minimal autoconf 2.67 |
| 63 | + fi |
| 64 | + requirements_check autoconf gcc g++ glibc-devel patch readline readline-devel \ |
| 65 | + zlib zlib-devel libffi-devel openssl-devel make bzip2 automake libtool \ |
| 66 | + bison sqlite3-devel yaml-devel gmp-devel pkg-config ncurses-devel binutils \ |
| 67 | + kernel-libc-devel |
| 68 | + ;; |
| 69 | + esac |
| 70 | +} |
| 71 | + |
0 commit comments