diff options
author | 2024-07-12 13:36:36 +0500 | |
---|---|---|
committer | 2024-07-14 12:22:19 +0500 | |
commit | ce227aa165920d92198c2ca24be6e33b77f470c7 (patch) | |
tree | 903ac6ce6039812d6f05431b28043f7e113df4ea | |
parent | boinc-app.eclass: allow non-standard runtime dir (diff) | |
download | guru-ce227aa165920d92198c2ca24be6e33b77f470c7.tar.gz guru-ce227aa165920d92198c2ca24be6e33b77f470c7.tar.bz2 guru-ce227aa165920d92198c2ca24be6e33b77f470c7.zip |
boinc-app.eclass: allow to set deps for boinc-optional apps
Signed-off-by: Anna (cybertailor) Vyalkova <cyber+gentoo@sysrq.in>
-rw-r--r-- | eclass/boinc-app.eclass | 27 |
1 files changed, 20 insertions, 7 deletions
diff --git a/eclass/boinc-app.eclass b/eclass/boinc-app.eclass index 00ffd39ed..3a26e6738 100644 --- a/eclass/boinc-app.eclass +++ b/eclass/boinc-app.eclass @@ -80,20 +80,33 @@ in order to use this application with BOINC.} # @FUNCTION: boinc-app_add_deps # @USAGE: [--wrapper] # @DESCRIPTION: -# Generate appropriate (R)DEPEND for wrapper-enabled or +# Generate appropriate IUSE and (R)DEPEND for wrapper-enabled or # native application. +# +# If BOINC_APP_OPTIONAL is set to a non-null value, dependencies +# will be added for "boinc" USE-flag. boinc-app_add_deps() { debug-print-function ${FUNCNAME} "${@}" - if [[ $1 == "--wrapper" ]]; then - RDEPEND="sci-misc/boinc-wrapper" + local depend rdepend + if [[ ${1} == "--wrapper" ]]; then + rdepend="sci-misc/boinc-wrapper" else - DEPEND="sci-misc/boinc" - RDEPEND="sci-misc/boinc" + depend="sci-misc/boinc" + rdepend="sci-misc/boinc" fi - DEPEND="${DEPEND} acct-user/boinc" - RDEPEND="${RDEPEND} acct-user/boinc" + depend+=" acct-user/boinc" + rdepend+=" acct-user/boinc" + + if [[ ${BOINC_APP_OPTIONAL} ]]; then + IUSE+=" boinc" + DEPEND+=" boinc? ( ${depend} )" + RDEPEND+=" boinc? ( ${rdepend} )" + else + DEPEND+=" ${depend}" + RDEPEND+=" ${rdepend}" + fi } # @FUNCTION: boinc_master_url_check |