www-client/firefox: ensure that LLVM deps are in sync with used LLVM slot
authorThomas Deutschmann <whissi@gentoo.org>
Fri, 8 Mar 2019 22:26:11 +0000 (23:26 +0100)
committerThomas Deutschmann <whissi@gentoo.org>
Fri, 8 Mar 2019 22:49:56 +0000 (23:49 +0100)
Bug: https://bugs.gentoo.org/678098
Bug: https://bugs.gentoo.org/679598
Package-Manager: Portage-2.3.62, Repoman-2.3.12
Signed-off-by: Thomas Deutschmann <whissi@gentoo.org>
eclass/mozconfig-v6.60.eclass
www-client/firefox/firefox-60.5.2.ebuild
www-client/firefox/firefox-65.0.2.ebuild

index 059ec55f2caba2574f5fdaba4bb9ffc6837da129..0cd728743e47079e4ea8a477566f925574ba1812 100644 (file)
@@ -158,9 +158,47 @@ DEPEND="app-arch/zip
        app-arch/unzip
        >=sys-devel/binutils-2.30
        sys-apps/findutils
-       clang? (
-               >=sys-devel/llvm-4.0.1[gold]
-               >=sys-devel/lld-4.0.1
+       || (
+               (
+                       sys-devel/clang:4
+                       !clang? ( sys-devel/llvm:4 )
+                       clang? (
+                               =sys-devel/lld-4*
+                               sys-devel/llvm:4[gold]
+                       )
+               )
+               (
+                       sys-devel/clang:5
+                       !clang? ( sys-devel/llvm:5 )
+                       clang? (
+                               =sys-devel/lld-5*
+                               sys-devel/llvm:5[gold]
+                       )
+               )
+               (
+                       sys-devel/clang:6
+                       !clang? ( sys-devel/llvm:6 )
+                       clang? (
+                               =sys-devel/lld-6*
+                               sys-devel/llvm:6[gold]
+                       )
+               )
+               (
+                       sys-devel/clang:7
+                       !clang? ( sys-devel/llvm:7 )
+                       clang? (
+                               =sys-devel/lld-7*
+                               sys-devel/llvm:7[gold]
+                       )
+               )
+               (
+                       sys-devel/clang:8
+                       !clang? ( sys-devel/llvm:8 )
+                       clang? (
+                               =sys-devel/lld-8*
+                               sys-devel/llvm:8[gold]
+                       )
+               )
        )
        pulseaudio? ( media-sound/pulseaudio )
        elibc_glibc? (
index ec418bbfeeef9a6b98729cea24a29c07c3239398..a96c670e53efe1b041c46dafc3acef51742377b2 100644 (file)
@@ -63,8 +63,6 @@ RDEPEND="
        selinux? ( sec-policy/selinux-mozilla )"
 
 DEPEND="${RDEPEND}
-       >=sys-devel/llvm-4.0.1
-       >=sys-devel/clang-4.0.1
        amd64? ( ${ASM_DEPEND} virtual/opengl )
        x86? ( ${ASM_DEPEND} virtual/opengl )"
 
@@ -81,7 +79,19 @@ if [[ -z $GMP_PLUGIN_LIST ]]; then
 fi
 
 llvm_check_deps() {
-       has_version "sys-devel/clang:${LLVM_SLOT}"
+       if ! has_version "sys-devel/clang:${LLVM_SLOT}" ; then
+               ewarn "sys-devel/clang:${LLVM_SLOT} is missing! Cannot use LLVM slot ${LLVM_SLOT} ..."
+               return 1
+       fi
+
+       if use clang ; then
+               if ! has_version "=sys-devel/lld-${LLVM_SLOT}*" ; then
+                       ewarn "=sys-devel/lld-${LLVM_SLOT}* is missing! Cannot use LLVM slot ${LLVM_SLOT} ..."
+                       return 1
+               fi
+       fi
+
+       einfo "Will use LLVM slot ${LLVM_SLOT}!"
 }
 
 pkg_setup() {
index 5d08b2b8a5b6e87547375b4e2195736aea2153d0..b869ca7f95a02f2a463b73e3040643f81a00e1ed 100644 (file)
@@ -114,12 +114,52 @@ DEPEND="${CDEPEND}
        >=net-libs/nodejs-8.11.0
        >=sys-devel/binutils-2.30
        sys-apps/findutils
-       >=sys-devel/llvm-4.0.1
-       >=sys-devel/clang-4.0.1
-       clang? (
-               >=sys-devel/llvm-4.0.1[gold]
-               >=sys-devel/lld-4.0.1
-               pgo? ( >=sys-libs/compiler-rt-sanitizers-4.0.1[profile] )
+       || (
+               (
+                       sys-devel/clang:4
+                       !clang? ( sys-devel/llvm:4 )
+                       clang? (
+                               =sys-devel/lld-4*
+                               sys-devel/llvm:4[gold]
+                               pgo? ( =sys-libs/compiler-rt-sanitizers-4*[profile] )
+                       )
+               )
+               (
+                       sys-devel/clang:5
+                       !clang? ( sys-devel/llvm:5 )
+                       clang? (
+                               =sys-devel/lld-5*
+                               sys-devel/llvm:5[gold]
+                               pgo? ( =sys-libs/compiler-rt-sanitizers-5*[profile] )
+                       )
+               )
+               (
+                       sys-devel/clang:6
+                       !clang? ( sys-devel/llvm:6 )
+                       clang? (
+                               =sys-devel/lld-6*
+                               sys-devel/llvm:6[gold]
+                               pgo? ( =sys-libs/compiler-rt-sanitizers-6*[profile] )
+                       )
+               )
+               (
+                       sys-devel/clang:7
+                       !clang? ( sys-devel/llvm:7 )
+                       clang? (
+                               =sys-devel/lld-7*
+                               sys-devel/llvm:7[gold]
+                               pgo? ( =sys-libs/compiler-rt-sanitizers-7*[profile] )
+                       )
+               )
+               (
+                       sys-devel/clang:8
+                       !clang? ( sys-devel/llvm:8 )
+                       clang? (
+                               =sys-devel/lld-8*
+                               sys-devel/llvm:8[gold]
+                               pgo? ( =sys-libs/compiler-rt-sanitizers-8*[profile] )
+                       )
+               )
        )
        pulseaudio? ( media-sound/pulseaudio )
        >=virtual/cargo-1.30.0
@@ -146,7 +186,26 @@ if [[ -z $GMP_PLUGIN_LIST ]] ; then
 fi
 
 llvm_check_deps() {
-       has_version "sys-devel/clang:${LLVM_SLOT}"
+       if ! has_version "sys-devel/clang:${LLVM_SLOT}" ; then
+               ewarn "sys-devel/clang:${LLVM_SLOT} is missing! Cannot use LLVM slot ${LLVM_SLOT} ..."
+               return 1
+       fi
+
+       if use clang ; then
+               if ! has_version "=sys-devel/lld-${LLVM_SLOT}*" ; then
+                       ewarn "=sys-devel/lld-${LLVM_SLOT}* is missing! Cannot use LLVM slot ${LLVM_SLOT} ..."
+                       return 1
+               fi
+
+               if use pgo ; then
+                       if ! has_version "=sys-libs/compiler-rt-sanitizers-${LLVM_SLOT}*" ; then
+                               ewarn "=sys-libs/compiler-rt-sanitizers-${LLVM_SLOT}* is missing! Cannot use LLVM slot ${LLVM_SLOT} ..."
+                               return 1
+                       fi
+               fi
+       fi
+
+       einfo "Will use LLVM slot ${LLVM_SLOT}!"
 }
 
 pkg_setup() {