diff options
Diffstat (limited to 'src/modules/java-nsplugin.eselect.in')
-rw-r--r-- | src/modules/java-nsplugin.eselect.in | 19 |
1 files changed, 11 insertions, 8 deletions
diff --git a/src/modules/java-nsplugin.eselect.in b/src/modules/java-nsplugin.eselect.in index dc41267..6b9c7eb 100644 --- a/src/modules/java-nsplugin.eselect.in +++ b/src/modules/java-nsplugin.eselect.in @@ -18,12 +18,15 @@ SYSTEM_PLUGIN="${SYSTEM_PLUGIN_DIR}/javaplugin.so" SYSTEM_PLUGIN_32="${SYSTEM_PLUGIN_DIR_32}/javaplugin.so" SYSTEM_PLUGIN_64="${SYSTEM_PLUGIN_DIR_64}/javaplugin.so" -libdirs=$(list_libdirs) -if has lib32 ${libdirs} && has lib64 ${libdirs}; then - IS_MULTILIB="true" -else - IS_MULTILIB="false" -fi +is_multilib() { + local libdirs=$(list_libdirs) + if has lib32 ${libdirs} && has lib64 ${libdirs}; then + return 0 + else + return 1 + fi +} + ### show action ## {{{ show stuff @@ -64,7 +67,7 @@ fi } do_list() { - if [[ ${IS_MULTILIB} != "true" ]]; then + if ! is_multilib; then MULTILIB_MODE="none" local system_name=$(get_system_plugin_vm) local targets=( $(get_targets) ) @@ -104,7 +107,7 @@ fi } do_set() { - if [[ ${IS_MULTILIB} != "true" ]]; then + if ! is_multilib; then if [[ ${#} != 1 ]] ; then die -q "Usage: set [nsplugin-vm]" fi |