install-r-library.sh 3.17 KB
Newer Older
1
2
#!/bin/bash

Jean-Francois Rey's avatar
Jean-Francois Rey committed
3
4
5
echo "$PATH"
export PATH=/usr/local/bin:$PATH

6
7
### List off systems pre-compiled libraries
declare -a listL=(
Jean-Francois Rey's avatar
Jean-Francois Rey committed
8
9
10
	"bdb-6.2.23-darwin.17-x86_64.tar.gz"
	"boost-1.73.0-darwin.17-x86_64.tar.gz"
	"boost-headers-1.69-0-darwin.17-x86_64.tar.gz"
11
12
	"cairo-1.14.12-darwin.17-x86_64.tar.gz"
	"cairomm-1.11.2-darwin.17-x86_64.tar.gz"
Jean-Francois Rey's avatar
Jean-Francois Rey committed
13
	"ffi-3.3-darwin.17-x86_64.tar.gz"
14
15
16
	"fftw-3.3.8-darwin.17-x86_64.tar.gz"
	"fontconfig-2.13.1-darwin.17-x86_64.tar.gz"
	"freetype-2.10.0-darwin.17-x86_64.tar.gz"
Jean-Francois Rey's avatar
Jean-Francois Rey committed
17
	"freexl-1.0.6-darwin.17-x86_64.tar.gz"
18
19
	"gdal-3.1.1-darwin.17-x86_64.tar.gz"
	"geos-3.8.1-darwin.17-x86_64.tar.gz"
Jean-Francois Rey's avatar
Jean-Francois Rey committed
20
21
	"glpk-4.65-darwin.17-x86_64.tar.gz"
	"gmp-6.2.0-darwin.17-x86_64.tar.gz"
22
	"gsl-2.6-darwin.17-x86_64.tar.gz"
Jean-Francois Rey's avatar
Jean-Francois Rey committed
23
	"hdf5-1.12.0-darwin.17-x86_64.tar.gz"
24
25
26
27
	"icu-67.1-darwin.17-x86_64.tar.gz"
	"jpeg-9-darwin.17-x86_64.tar.gz"
	"libpng-1.6.37-darwin.17-x86_64.tar.gz"
	"libpq-9.6.9-darwin.17-x86_64.tar.gz"
Jean-Francois Rey's avatar
Jean-Francois Rey committed
28
29
30
31
32
33
34
	"libsndfile-1.0.28-darwin.17-x86_64.tar.gz"
	"libsodium-1.0.18-darwin.17-x86_64.tar.gz"
	"libwebp-1.1.0-darwin.17-x86_64.tar.gz"
	"mpfr-4.0.2-darwin.17-x86_64.tar.gz"
	"netcdf-4.7.4-darwin.17-x86_64.tar.gz"
	"openjpeg-2.3.1-darwin.17-x86_64.tar.gz"
	"openssl-1.1.1g-darwin.17-x86_64.tar.gz"
35
	"pcre2-10.34-darwin.17-x86_64.tar.gz"
Jean-Francois Rey's avatar
Jean-Francois Rey committed
36
	"pixman-0.38.4-darwin.17-x86_64.tar.gz"
37
38
	"pkgconfig-0.28-darwin.17-x86_64.tar.gz"
	"proj-6.3.1-darwin.17-x86_64.tar.gz"
Jean-Francois Rey's avatar
Jean-Francois Rey committed
39
	"protobuf-3.11.4-darwin.17-x86_64.tar.gz"
40
	"qpdf-9.1.1-darwin.17-x86_64.tar.gz"
Jean-Francois Rey's avatar
Jean-Francois Rey committed
41
	"QuantLib-1.18-darwin.17-x86_64.tar.gz"
42
	"readline-5.2.14-darwin.17-x86_64.tar.gz"
Jean-Francois Rey's avatar
Jean-Francois Rey committed
43
	"sigc++-4.2.1-darwin.17-x86_64.tar.gz"
44
	"sqlite3-3.32.3-darwin.17-x86_64.tar.gz"
Jean-Francois Rey's avatar
Jean-Francois Rey committed
45
	"szip-2.1.1-darwin.17-x86_64.tar.gz"
46
47
48
49
	"texinfo-6.7-darwin.17-x86_64.tar.gz"
	"tiff-4.1.0-darwin.17-x86_64.tar.gz"
	"udunits-2.2.24-darwin.17-x86_64.tar.gz"
	"xml2-2.9.10-darwin.17-x86_64.tar.gz"
Jean-Francois Rey's avatar
Jean-Francois Rey committed
50
51
	"xz-5.2.4-darwin.17-x86_64.tar.gz"
	"zeromq-4.3.2-darwin.17-x86_64.tar.gz"
52
53
54
55
56
57
	"zlib-system-stub.tar.gz"
)

for i in "${listL[@]}"
do
	echo "Download and install $i"
Jean-Francois Rey's avatar
Jean-Francois Rey committed
58
59
60
	curl -LO "http://mac.R-project.org/libs-4/$i"
	# bsdtar return error... why true is return
	sudo tar fvxz "$i" -C / | true
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
	rm $i
done

echo "Installing R packages"

echo "dir.create(Sys.getenv('R_LIBS_USER'), recursive=TRUE); \
  .libPaths( c(Sys.getenv('R_LIBS_USER'), .libPaths()) ) ; \
  install.packages(c( \
  'deSolve', \
  'sp', \
  'rgeos', \
  'fields', \
  'MASS', \
  'Matrix', \
  'deldir', \
  'pracma', \
  'raster', \
  'fftwtools', \
  'mvtnorm', \
  'rgdal', \
  'sf', \
  'splancs', \
  'knitr', \
  'rmarkdown', \
  'testthat', \
  'Rcpp', \
  'RcppArmadillo', \
  'fasterize', \
  'roxygen2', \
  'shiny', \
  'htmltools', \
  'shinydashboard', \
  'ggplot2', \
  'dplyr', \
  'dbplyr', \
  'DT', \
  'magrittr', \
  'devtools', \
  'shinyjs', \
  'stringi', \
  'stringr', \
  'jsonlite', \
  'data.table', \
  'htmlwidgets', \
  'RSQLite', \
  'BiocManager', \
  'foreach', \
  'doParallel', \
  'mvtnorm', \
  'mapdata', \
  'proj4', \
  'gstat', \
  'automap', \
  'RCALI', \
  'rgenoud', \
  'purrr' \
  ), \
  dependencies=TRUE, \
  repos='https://cran.biotools.fr')" > /tmp/install.R 

Rscript /tmp/install.R

Rscript -e "BiocManager::install(c('Biostrings', ask=FALSE))"
Rscript -e "update.packages(ask=FALSE, repos='https://cran.biotools.fr')"