summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorHans de Graaff <graaff@gentoo.org>2019-07-21 09:44:29 +0200
committerHans de Graaff <graaff@gentoo.org>2019-07-25 08:09:42 +0200
commit1b3ea3098b1549304fdc60b103ba3a5e444e51b6 (patch)
tree6aaf6b2512f8810b1caa2a96b5db89dc4a74dcd4
parentruby-ng.eclass: handle BDEPEND for EAPI 7 (diff)
downloadgentoo-1b3ea3098b1549304fdc60b103ba3a5e444e51b6.tar.gz
gentoo-1b3ea3098b1549304fdc60b103ba3a5e444e51b6.tar.bz2
gentoo-1b3ea3098b1549304fdc60b103ba3a5e444e51b6.zip
ruby-ng.eclass: remove 2-arg calling of depend methods in EAPI 7
No longer allow the deprecated 2 argument calls to the ruby*depend methods in EAPI 7. These are already deprecated for a long time. Signed-off-by: Hans de Graaff <graaff@gentoo.org>
-rw-r--r--eclass/ruby-ng.eclass26
1 files changed, 20 insertions, 6 deletions
diff --git a/eclass/ruby-ng.eclass b/eclass/ruby-ng.eclass
index 9fb6965a0790..a0c03ab6027e 100644
--- a/eclass/ruby-ng.eclass
+++ b/eclass/ruby-ng.eclass
@@ -208,9 +208,16 @@ ruby_add_rdepend() {
case $# in
1) ;;
2)
- [[ "${GENTOO_DEV}" == "yes" ]] && eqawarn "You can now use the usual syntax in ruby_add_rdepend for $CATEGORY/$PF"
- ruby_add_rdepend "$(_ruby_wrap_conditions "$1" "$2")"
- return
+ case ${EAPI} in
+ 4|5|6)
+ [[ "${GENTOO_DEV}" == "yes" ]] && eqawarn "You can now use the usual syntax in ruby_add_rdepend for $CATEGORY/$PF"
+ ruby_add_rdepend "$(_ruby_wrap_conditions "$1" "$2")"
+ return
+ ;;
+ *)
+ die "Use the usual depend syntax with a single argument in ruby_add_rdepend"
+ ;;
+ esac
;;
*)
die "bad number of arguments to $0"
@@ -243,9 +250,16 @@ ruby_add_bdepend() {
case $# in
1) ;;
2)
- [[ "${GENTOO_DEV}" == "yes" ]] && eqawarn "You can now use the usual syntax in ruby_add_bdepend for $CATEGORY/$PF"
- ruby_add_bdepend "$(_ruby_wrap_conditions "$1" "$2")"
- return
+ case ${EAPI} in
+ 4|5|6)
+ [[ "${GENTOO_DEV}" == "yes" ]] && eqawarn "You can now use the usual syntax in ruby_add_bdepend for $CATEGORY/$PF"
+ ruby_add_bdepend "$(_ruby_wrap_conditions "$1" "$2")"
+ return
+ ;;
+ *)
+ die "Use the usual depend syntax with a single argument in ruby_add_bdepend"
+ ;;
+ esac
;;
*)
die "bad number of arguments to $0"