]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commitdiff
install-deps.sh: use gcc-8 on xenial and trusty 30089/head
authorKefu Chai <kchai@redhat.com>
Tue, 14 May 2019 14:37:00 +0000 (22:37 +0800)
committerKefu Chai <kchai@redhat.com>
Tue, 3 Sep 2019 05:13:14 +0000 (13:13 +0800)
to be consistent with #27183 and https://github.com/ceph/ceph-build/pull/1286

Signed-off-by: Kefu Chai <kchai@redhat.com>
(cherry picked from commit f52d69ea9295b8e6a12cc83c49c380cd761a7bd8)

install-deps.sh

index bc1736b4bbfdf0a8f50b0c49fa869d681581d6c1..daf2ae2c1f7b1a428adf84c940f2ef323b5fd673 100755 (executable)
@@ -70,7 +70,7 @@ function ensure_decent_gcc_on_ubuntu {
     local old=$(gcc -dumpfullversion -dumpversion)
     local new=$1
     local codename=$2
-    if dpkg --compare-versions $old ge 7.0; then
+    if dpkg --compare-versions $old ge ${new}.0; then
        return
     fi
 
@@ -97,7 +97,7 @@ msyaQpNl/m/lNtOLhR64v5ZybofB2EWkMxUzX8D/FQ==
 -----END PGP PUBLIC KEY BLOCK-----
 ENDOFKEY
        $SUDO env DEBIAN_FRONTEND=noninteractive apt-get update -y || true
-       $SUDO env DEBIAN_FRONTEND=noninteractive apt-get install -y g++-7
+       $SUDO env DEBIAN_FRONTEND=noninteractive apt-get install -y g++-${new}
     fi
 
     case $codename in
@@ -274,10 +274,10 @@ else
         $SUDO apt-get install -y dpkg-dev
         case "$VERSION" in
             *Trusty*)
-                ensure_decent_gcc_on_ubuntu 7 trusty
+                ensure_decent_gcc_on_ubuntu 8 trusty
                 ;;
             *Xenial*)
-                ensure_decent_gcc_on_ubuntu 7 xenial
+                ensure_decent_gcc_on_ubuntu 8 xenial
                 install_boost_on_ubuntu xenial
                 ;;
             *Bionic*)