ruby-ng.eclass: Include (-) in RUBY_TARGETS USE-dependencies
authorMichał Górny <mgorny@gentoo.org>
Mon, 30 Dec 2019 19:02:42 +0000 (20:02 +0100)
committerMichał Górny <mgorny@gentoo.org>
Sun, 5 Jan 2020 10:04:54 +0000 (11:04 +0100)
Using 2-style USE dependencies on packages not having the flag
in question is forbidden by PMS.

Signed-off-by: Michał Górny <mgorny@gentoo.org>
eclass/ruby-ng.eclass

index db701d81f4fc07284419afda9e963b9be3b27024..f92547b49a9fd59ccab4d60c409dc3f283670152 100644 (file)
@@ -1,4 +1,4 @@
-# Copyright 1999-2019 Gentoo Authors
+# Copyright 1999-2020 Gentoo Authors
 # Distributed under the terms of the GNU General Public License v2
 
 # @ECLASS: ruby-ng.eclass
@@ -137,7 +137,7 @@ ruby_samelib() {
        local res=
        for _ruby_implementation in $(_ruby_get_all_impls); do
                has -${_ruby_implementation} $@ || \
-                       res="${res}ruby_targets_${_ruby_implementation}?,"
+                       res="${res}ruby_targets_${_ruby_implementation}(-)?,"
        done
 
        echo "[${res%,}]"
@@ -151,9 +151,9 @@ _ruby_atoms_samelib_generic() {
                        "||" | "(" | ")" | *"?")
                                echo "${token}" ;;
                        *])
-                               echo "${token%[*}[RUBYTARGET,${token/*[}" ;;
+                               echo "${token%[*}[RUBYTARGET(-),${token/*[}" ;;
                        *)
-                               echo "${token}[RUBYTARGET]" ;;
+                               echo "${token}[RUBYTARGET(-)]" ;;
                esac
        done
        echo ")"