You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@bigtop.apache.org by se...@apache.org on 2020/11/12 09:24:29 UTC
[bigtop] branch branch-1.5 updated: BIGTOP-3443: Building Spark
fails on Ubuntu 16.04 (#697)
This is an automated email from the ASF dual-hosted git repository.
sekikn pushed a commit to branch branch-1.5
in repository https://gitbox.apache.org/repos/asf/bigtop.git
The following commit(s) were added to refs/heads/branch-1.5 by this push:
new 682717d BIGTOP-3443: Building Spark fails on Ubuntu 16.04 (#697)
682717d is described below
commit 682717d0dac4e2b0162dda7c1c0d3ede20548f6e
Author: Yuqi Gu <yu...@arm.com>
AuthorDate: Thu Nov 12 17:18:57 2020 +0800
BIGTOP-3443: Building Spark fails on Ubuntu 16.04 (#697)
* BIGTOP-3443: Building Spark fails on Ubuntu 16.04
R version in Ubuntu16.04 is 3.2.3.
The packages 'digest' and 'htmltools' are not available (for R version 3.2.3).
There are some other dependency issues in R-3.2 which seems to be deprecated.
Upgrade the R version to 3.4 for ubuntu-16.04.
Change-Id: I1b5b5116ed09c24da701e6247ce5108ad28f1a79
Signed-off-by: Yuqi Gu <yu...@arm.com>
* Fix typo and unify code style
Change-Id: If606e03e225077d14177062f630b943bba21397b
Signed-off-by: Yuqi Gu <yu...@arm.com>
(cherry picked from commit b4784868fa9dc26f42d0e60271586e448486b754)
---
bigtop_toolchain/manifests/renv.pp | 64 +++++++++++++++++++++++++++++++-------
1 file changed, 53 insertions(+), 11 deletions(-)
diff --git a/bigtop_toolchain/manifests/renv.pp b/bigtop_toolchain/manifests/renv.pp
index 30ad009..16fc484 100644
--- a/bigtop_toolchain/manifests/renv.pp
+++ b/bigtop_toolchain/manifests/renv.pp
@@ -33,22 +33,64 @@ class bigtop_toolchain::renv {
]
}
/(Ubuntu|Debian)/: {
- $pkgs = [
- "r-base",
- "r-base-dev",
- "pandoc"
- ]
+ if (versioncmp($operatingsystemmajrelease, '16.04') == 0) {
+ $pkgs = [
+ "r-base",
+ "r-base-dev",
+ "libcairo2-dev",
+ "pandoc",
+ "pandoc-citeproc",
+ ]
+ $rpkgs = "install_r_packages_ubt16.04"
+ } else {
+ $pkgs = [
+ "r-base",
+ "r-base-dev",
+ "pandoc",
+ ]
+ $rpkgs = "install_r_packages"
+ }
}
}
+
package { $pkgs:
ensure => installed,
- before => [Exec['install_r_packages']]
+ before => [Exec[$rpkgs]]
}
- # Install required R packages
- exec { 'install_r_packages':
- cwd => "/usr/bin",
- command => "/usr/bin/R -e \"install.packages(c('devtools', 'evaluate', 'rmarkdown', 'knitr', 'roxygen2', 'testthat', 'e1071'), repos = 'http://cran.us.r-project.org')\"",
- timeout => 6000
+ # BIGTOP-3443:
+ # Upgrade R version to 3.4.4 to fix dependency issue in R 3.2
+ #
+ # Then Install required R packages dependency
+ if ($operatingsystem == 'Ubuntu' and versioncmp($operatingsystemmajrelease, '16.04') == 0) {
+ $url = "https://cran.rstudio.com/src/base/R-3/"
+ $rfile = "R-3.4.4.tar.gz"
+ $rdir = "R-3.4.4"
+
+ exec { "download_R":
+ cwd => "/usr/src",
+ command => "/usr/bin/wget $url/$rfile && mkdir -p $rdir && /bin/tar -xvzf $rfile -C $rdir --strip-components=1 && cd $rdir",
+ creates => "/usr/src/$rdir",
+ }
+ exec { "install_R":
+ cwd => "/usr/src/$rdir",
+ command => "/usr/src/$rdir/configure --with-recommended-packages=yes --without-x --with-cairo --with-libpng --with-libtiff --with-jpeglib --with-tcltk --with-blas --with-lapack --enable-R-shlib --prefix=/usr/local && /usr/bin/make && /usr/bin/make install && /sbin/ldconfig",
+ creates => "/usr/local/bin/R",
+ require => [Exec["download_R"]],
+ timeout => 3000
+ }
+
+ exec { $rpkgs :
+ cwd => "/usr/local/bin",
+ command => "/usr/local/bin/R -e \"install.packages(c('devtools', 'evaluate', 'rmarkdown', 'knitr', 'roxygen2', 'testthat', 'e1071'), repos = 'http://cran.us.r-project.org')\"",
+ require => [Exec["install_R"]],
+ timeout => 6000
+ }
+ } else {
+ exec { $rpkgs :
+ cwd => "/usr/bin",
+ command => "/usr/bin/R -e \"install.packages(c('devtools', 'evaluate', 'rmarkdown', 'knitr', 'roxygen2', 'testthat', 'e1071'), repos = 'http://cran.us.r-project.org')\"",
+ timeout => 6000
+ }
}
}