R package installation on Linux - r

I installed R and trying to install additional package: rgl. The problem is, I keep getting this error:
installation of package ‘rgl’ had non-zero exit status
Here is a full list of warnings:
> warnings()
Warning messages:
1: In install.packages("rgl") :
installation of package ‘stringi’ had non-zero exit status
2: In install.packages("rgl") :
installation of package ‘yaml’ had non-zero exit status
3: In install.packages("rgl") :
installation of package ‘digest’ had non-zero exit status
4: In install.packages("rgl") :
installation of package ‘httpuv’ had non-zero exit status
5: In install.packages("rgl") :
installation of package ‘mime’ had non-zero exit status
6: In install.packages("rgl") :
installation of package ‘sourcetools’ had non-zero exit status
7: In install.packages("rgl") :
installation of package ‘jsonlite’ had non-zero exit status
8: In install.packages("rgl") :
installation of package ‘markdown’ had non-zero exit status
9: In install.packages("rgl") :
installation of package ‘stringr’ had non-zero exit status
10: In install.packages("rgl") :
installation of package ‘htmltools’ had non-zero exit status
11: In install.packages("rgl") :
installation of package ‘evaluate’ had non-zero exit status
12: In install.packages("rgl") :
installation of package ‘htmlwidgets’ had non-zero exit status
13: In install.packages("rgl") :
installation of package ‘shiny’ had non-zero exit status
14: In install.packages("rgl") :
installation of package ‘knitr’ had non-zero exit status
15: In install.packages("rgl") :
installation of package ‘rgl’ had non-zero exit status
And full installation log:
> install.packages("rgl")
Installing package into ‘/usr/local/lib/R/site-library’
(as ‘lib’ is unspecified)
--- Please select a CRAN mirror for use in this session ---
also installing the dependencies ‘stringi’, ‘yaml’, ‘digest’, ‘evaluate’, ‘markdown’, ‘stringr’, ‘httpuv’, ‘mime’, ‘sourcetools’, ‘htmlwidgets’, ‘htmltools’, ‘knitr’, ‘jsonlite’, ‘shiny’
trying URL 'https://cloud.r-project.org/src/contrib/stringi_1.1.5.tar.gz'
Content type 'application/x-gzip' length 3645872 bytes (3.5 MB)
==================================================
downloaded 3.5 MB
trying URL 'https://cloud.r-project.org/src/contrib/yaml_2.1.14.tar.gz'
Content type 'application/x-gzip' length 81095 bytes (79 KB)
==================================================
downloaded 79 KB
trying URL 'https://cloud.r-project.org/src/contrib/digest_0.6.12.tar.gz'
Content type 'application/x-gzip' length 120337 bytes (117 KB)
==================================================
downloaded 117 KB
trying URL 'https://cloud.r-project.org/src/contrib/evaluate_0.10.1.tar.gz'
Content type 'application/x-gzip' length 22177 bytes (21 KB)
==================================================
downloaded 21 KB
trying URL 'https://cloud.r-project.org/src/contrib/markdown_0.8.tar.gz'
Content type 'application/x-gzip' length 80583 bytes (78 KB)
==================================================
downloaded 78 KB
trying URL 'https://cloud.r-project.org/src/contrib/stringr_1.2.0.tar.gz'
Content type 'application/x-gzip' length 94095 bytes (91 KB)
==================================================
downloaded 91 KB
trying URL 'https://cloud.r-project.org/src/contrib/httpuv_1.3.5.tar.gz'
Content type 'application/x-gzip' length 427638 bytes (417 KB)
==================================================
downloaded 417 KB
trying URL 'https://cloud.r-project.org/src/contrib/mime_0.5.tar.gz'
Content type 'application/x-gzip' length 12634 bytes (12 KB)
==================================================
downloaded 12 KB
trying URL 'https://cloud.r-project.org/src/contrib/sourcetools_0.1.6.tar.gz'
Content type 'application/x-gzip' length 24092 bytes (23 KB)
==================================================
downloaded 23 KB
trying URL 'https://cloud.r-project.org/src/contrib/htmlwidgets_0.9.tar.gz'
Content type 'application/x-gzip' length 944851 bytes (922 KB)
==================================================
downloaded 922 KB
trying URL 'https://cloud.r-project.org/src/contrib/htmltools_0.3.6.tar.gz'
Content type 'application/x-gzip' length 45408 bytes (44 KB)
==================================================
downloaded 44 KB
trying URL 'https://cloud.r-project.org/src/contrib/knitr_1.17.tar.gz'
Content type 'application/x-gzip' length 769923 bytes (751 KB)
==================================================
downloaded 751 KB
trying URL 'https://cloud.r-project.org/src/contrib/jsonlite_1.5.tar.gz'
Content type 'application/x-gzip' length 1096810 bytes (1.0 MB)
==================================================
downloaded 1.0 MB
trying URL 'https://cloud.r-project.org/src/contrib/shiny_1.0.5.tar.gz'
Content type 'application/x-gzip' length 2330710 bytes (2.2 MB)
==================================================
downloaded 2.2 MB
trying URL 'https://cloud.r-project.org/src/contrib/rgl_0.98.1.tar.gz'
Content type 'application/x-gzip' length 2624282 bytes (2.5 MB)
==================================================
downloaded 2.5 MB
* installing *source* package ‘stringi’ ...
** package ‘stringi’ successfully unpacked and MD5 sums checked
checking for local ICUDT_DIR... icu55/data
checking for R_HOME... /usr/lib/R
checking for R... /usr/lib/R/bin/R
checking for R >= 3.1.0 for C++11 use... yes
checking for R < 3.4.0 for CXX1X flag use... no
checking for cat... /bin/cat
checking for gcc... gcc -std=gnu99
checking whether the C compiler works... no
configure: error: in `/tmp/RtmpSv852d/R.INSTALL521c32e70e07/stringi':
configure: error: C compiler cannot create executables
See `config.log' for more details
ERROR: configuration failed for package ‘stringi’
* removing ‘/usr/local/lib/R/site-library/stringi’
* installing *source* package ‘yaml’ ...
** package ‘yaml’ successfully unpacked and MD5 sums checked
** libs
gcc -std=gnu99 -I/usr/share/R/include -DNDEBUG -I. -DNDEBUG -fpic -g -O2 -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2 -g -c api.c -o api.o
gcc: error: unrecognized command line option ‘-fstack-protector-strong’
gcc: error: unrecognized command line option ‘-Wdate-time’
/usr/lib/R/etc/Makeconf:159: recipe for target 'api.o' failed
make: *** [api.o] Error 1
ERROR: compilation failed for package ‘yaml’
* removing ‘/usr/local/lib/R/site-library/yaml’
* installing *source* package ‘digest’ ...
** package ‘digest’ successfully unpacked and MD5 sums checked
** libs
gcc -std=gnu99 -I/usr/share/R/include -DNDEBUG -fpic -g -O2 -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2 -g -c aes.c -o aes.o
gcc: error: unrecognized command line option ‘-fstack-protector-strong’
gcc: error: unrecognized command line option ‘-Wdate-time’
/usr/lib/R/etc/Makeconf:159: recipe for target 'aes.o' failed
make: *** [aes.o] Error 1
ERROR: compilation failed for package ‘digest’
* removing ‘/usr/local/lib/R/site-library/digest’
* installing *source* package ‘httpuv’ ...
** package ‘httpuv’ successfully unpacked and MD5 sums checked
** libs
g++ -std=gnu++11 -I/usr/share/R/include -DNDEBUG -I./libuv/include -I./http-parser -I./sha1 -I./base64 -I"/usr/local/lib/R/site-library/Rcpp/include" -fpic -g -O2 -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2 -g -c RcppExports.cpp -o RcppExports.o
g++ -std=gnu++11 -I/usr/share/R/include -DNDEBUG -I./libuv/include -I./http-parser -I./sha1 -I./base64 -I"/usr/local/lib/R/site-library/Rcpp/include" -fpic -g -O2 -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2 -g -c filedatasource-unix.cpp -o filedatasource-unix.o
g++ -std=gnu++11 -I/usr/share/R/include -DNDEBUG -I./libuv/include -I./http-parser -I./sha1 -I./base64 -I"/usr/local/lib/R/site-library/Rcpp/include" -fpic -g -O2 -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2 -g -c filedatasource-win.cpp -o filedatasource-win.o
g++ -std=gnu++11 -I/usr/share/R/include -DNDEBUG -I./libuv/include -I./http-parser -I./sha1 -I./base64 -I"/usr/local/lib/R/site-library/Rcpp/include" -fpic -g -O2 -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2 -g -c http.cpp -o http.o
g++ -std=gnu++11 -I/usr/share/R/include -DNDEBUG -I./libuv/include -I./http-parser -I./sha1 -I./base64 -I"/usr/local/lib/R/site-library/Rcpp/include" -fpic -g -O2 -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2 -g -c httpuv.cpp -o httpuv.o
gcc -std=gnu99 -I/usr/share/R/include -DNDEBUG -I./libuv/include -I./http-parser -I./sha1 -I./base64 -I"/usr/local/lib/R/site-library/Rcpp/include" -fpic -g -O2 -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2 -g -c md5.c -o md5.o
gcc: error: unrecognized command line option ‘-fstack-protector-strong’
gcc: error: unrecognized command line option ‘-Wdate-time’
/usr/lib/R/etc/Makeconf:159: recipe for target 'md5.o' failed
make: *** [md5.o] Error 1
ERROR: compilation failed for package ‘httpuv’
* removing ‘/usr/local/lib/R/site-library/httpuv’
* installing *source* package ‘mime’ ...
** package ‘mime’ successfully unpacked and MD5 sums checked
** libs
gcc -std=gnu99 -I/usr/share/R/include -DNDEBUG -fpic -g -O2 -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2 -g -c rawmatch.c -o rawmatch.o
gcc: error: unrecognized command line option ‘-fstack-protector-strong’
gcc: error: unrecognized command line option ‘-Wdate-time’
/usr/lib/R/etc/Makeconf:159: recipe for target 'rawmatch.o' failed
make: *** [rawmatch.o] Error 1
ERROR: compilation failed for package ‘mime’
* removing ‘/usr/local/lib/R/site-library/mime’
* installing *source* package ‘sourcetools’ ...
** package ‘sourcetools’ successfully unpacked and MD5 sums checked
** libs
g++ -I/usr/share/R/include -DNDEBUG -I../inst/include -fpic -g -O2 -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2 -g -c Reader.cpp -o Reader.o
g++ -I/usr/share/R/include -DNDEBUG -I../inst/include -fpic -g -O2 -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2 -g -c Tokenizer.cpp -o Tokenizer.o
gcc -std=gnu99 -I/usr/share/R/include -DNDEBUG -I../inst/include -fpic -g -O2 -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2 -g -c sourcetools-init.c -o sourcetools-init.o
gcc: error: unrecognized command line option ‘-fstack-protector-strong’
gcc: error: unrecognized command line option ‘-Wdate-time’
/usr/lib/R/etc/Makeconf:159: recipe for target 'sourcetools-init.o' failed
make: *** [sourcetools-init.o] Error 1
ERROR: compilation failed for package ‘sourcetools’
* removing ‘/usr/local/lib/R/site-library/sourcetools’
* installing *source* package ‘jsonlite’ ...
** package ‘jsonlite’ successfully unpacked and MD5 sums checked
** libs
gcc -std=gnu99 -I/usr/share/R/include -DNDEBUG -Iyajl/api -fpic -g -O2 -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2 -g -c base64.c -o base64.o
gcc: error: unrecognized command line option ‘-fstack-protector-strong’
gcc: error: unrecognized command line option ‘-Wdate-time’
/usr/lib/R/etc/Makeconf:159: recipe for target 'base64.o' failed
make: *** [base64.o] Error 1
ERROR: compilation failed for package ‘jsonlite’
* removing ‘/usr/local/lib/R/site-library/jsonlite’
ERROR: dependency ‘mime’ is not available for package ‘markdown’
* removing ‘/usr/local/lib/R/site-library/markdown’
ERROR: dependency ‘stringi’ is not available for package ‘stringr’
* removing ‘/usr/local/lib/R/site-library/stringr’
ERROR: dependency ‘digest’ is not available for package ‘htmltools’
* removing ‘/usr/local/lib/R/site-library/htmltools’
ERROR: dependency ‘stringr’ is not available for package ‘evaluate’
* removing ‘/usr/local/lib/R/site-library/evaluate’
ERROR: dependencies ‘htmltools’, ‘jsonlite’, ‘yaml’ are not available for package ‘htmlwidgets’
* removing ‘/usr/local/lib/R/site-library/htmlwidgets’
ERROR: dependencies ‘httpuv’, ‘mime’, ‘jsonlite’, ‘digest’, ‘htmltools’, ‘sourcetools’ are not available for package ‘shiny’
* removing ‘/usr/local/lib/R/site-library/shiny’
ERROR: dependencies ‘evaluate’, ‘digest’, ‘markdown’, ‘stringr’, ‘yaml’ are not available for package ‘knitr’
* removing ‘/usr/local/lib/R/site-library/knitr’
ERROR: dependencies ‘htmlwidgets’, ‘htmltools’, ‘knitr’, ‘jsonlite’, ‘shiny’ are not available for package ‘rgl’
* removing ‘/usr/local/lib/R/site-library/rgl’
The downloaded source packages are in
‘/tmp/Rtmpa3Hizf/downloaded_packages’
There were 15 warnings (use warnings() to see them)
Full R version info:
> version
_
platform x86_64-pc-linux-gnu
arch x86_64
os linux-gnu
system x86_64, linux-gnu
status
major 3
minor 4.2
year 2017
month 09
day 28
svn rev 73368
language R
version.string R version 3.4.2 (2017-09-28)
nickname Short Summer
I use Linux Mint 18.2. I know that there are more questions about that error message, but I did not find any working solution. This is basically fresh installation, I did not change any configuration files and tried to install this package with and without root permissions. Does anyone know what can cause this?

I fixed that error thanks to Harutyun Khachatryan from the r-sig-debian mailing list.
The solution is here: https://askubuntu.com/questions/26498/choose-gcc-and-g-version
The only difference is that I used gcc and g++ with versions 4.8 and 4.9 (instead of 4.3 and 4.4).
All commands I used to fix it:
sudo update-alternatives --remove-all gcc
sudo update-alternatives --remove-all g++
sudo apt-get install gcc-4.3 gcc-4.4 g++-4.3 g++-4.4
sudo apt-get install gcc-4.8 gcc-4.8 g++-4.9 g++-4.9
sudo update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-4.8 10
sudo update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-4.9 20
sudo update-alternatives --install /usr/bin/g++ g++ /usr/bin/g++-4.8 10
sudo update-alternatives --install /usr/bin/g++ g++ /usr/bin/g++-4.9 20
sudo update-alternatives --install /usr/bin/cc cc /usr/bin/gcc 30
sudo update-alternatives --set cc /usr/bin/gcc
sudo update-alternatives --install /usr/bin/c++ c++ /usr/bin/g++ 30
sudo update-alternatives --set c++ /usr/bin/g++
sudo update-alternatives --config gcc
sudo update-alternatives --config g++
Now the packages in R are successfully compiled.

Related

Installation Of DevTools Has A Non-Zero Exit Status

The code I used is here:
install.packages("devtools")
Installing package into ‘/home/user/R/x86_64-pc-linux-gnu-library/4.0’
(as ‘lib’ is unspecified)
also installing the dependencies ‘textshaping’, ‘ragg’, ‘pkgdown’
trying URL 'https://cloud.r-project.org/src/contrib/textshaping_0.3.6.tar.gz'
Content type 'application/x-gzip' length 35722 bytes (34 KB)
==================================================
downloaded 34 KB
trying URL 'https://cloud.r-project.org/src/contrib/ragg_1.2.4.tar.gz'
Content type 'application/x-gzip' length 427579 bytes (417 KB)
==================================================
downloaded 417 KB
trying URL 'https://cloud.r-project.org/src/contrib/pkgdown_2.0.6.tar.gz'
Content type 'application/x-gzip' length 871371 bytes (850 KB)
==================================================
downloaded 850 KB
trying URL 'https://cloud.r-project.org/src/contrib/devtools_2.4.5.tar.gz'
Content type 'application/x-gzip' length 374718 bytes (365 KB)
==================================================
downloaded 365 KB
* installing *source* package ‘textshaping’ ...
** package ‘textshaping’ successfully unpacked and MD5 sums checked
** using staged installation
Package harfbuzz was not found in the pkg-config search path.
Perhaps you should add the directory containing `harfbuzz.pc'
to the PKG_CONFIG_PATH environment variable
No package 'harfbuzz' found
Package fribidi was not found in the pkg-config search path.
Perhaps you should add the directory containing `fribidi.pc'
to the PKG_CONFIG_PATH environment variable
No package 'fribidi' found
Using PKG_CFLAGS=
Using PKG_LIBS=-lfreetype -lharfbuzz -lfribidi -lpng
--------------------------- [ANTICONF] --------------------------------
Configuration failed to find the harfbuzz freetype2 fribidi library. Try installing:
* deb: libharfbuzz-dev libfribidi-dev (Debian, Ubuntu, etc)
* rpm: harfbuzz-devel fribidi-devel (Fedora, EPEL)
* csw: libharfbuzz_dev libfribidi_dev (Solaris)
* brew: harfbuzz fribidi (OSX)
If harfbuzz freetype2 fribidi is already installed, check that 'pkg-config' is in your
PATH and PKG_CONFIG_PATH contains a harfbuzz freetype2 fribidi.pc file. If pkg-config
is unavailable you can set INCLUDE_DIR and LIB_DIR manually via:
R CMD INSTALL --configure-vars='INCLUDE_DIR=... LIB_DIR=...'
-------------------------- [ERROR MESSAGE] ---------------------------
<stdin>:1:10: fatal error: hb-ft.h: No such file or directory
compilation terminated.
--------------------------------------------------------------------
ERROR: configuration failed for package ‘textshaping’
* removing ‘/home/user/R/x86_64-pc-linux-gnu-library/4.0/textshaping’
Warning in install.packages :
installation of package ‘textshaping’ had non-zero exit status
ERROR: dependency ‘textshaping’ is not available for package ‘ragg’
* removing ‘/home/user/R/x86_64-pc-linux-gnu-library/4.0/ragg’
Warning in install.packages :
installation of package ‘ragg’ had non-zero exit status
ERROR: dependency ‘ragg’ is not available for package ‘pkgdown’
* removing ‘/home/user/R/x86_64-pc-linux-gnu-library/4.0/pkgdown’
Warning in install.packages :
installation of package ‘pkgdown’ had non-zero exit status
ERROR: dependency ‘pkgdown’ is not available for package ‘devtools’
* removing ‘/home/user/R/x86_64-pc-linux-gnu-library/4.0/devtools’
Warning in install.packages :
installation of package ‘devtools’ had non-zero exit status
The downloaded source packages are in
‘/tmp/Rtmps8M7e8/downloaded_packages’
I have tried to figure out the dependencies but I keep having issues with this. No matter what I install this seems to occur. Could someone point me in the right direction?
I have done multiple runs of the code. I have tried to install the following to see if it would help
In Terminal
sudo apt-get install libfontconfig1-dev
And then also
sudo apt-get install libxml2-dev
I also tried to install the libs package in R to no avail (as it seems to not be used in the current version of R.
I did the following in terminal
sudo apt-get install libharfbuzz-dev libfribidi-dev
I still get the error
install.packages("devtools")
Installing package into ‘/home/user/R/x86_64-pc-linux-gnu-library/4.0’
(as ‘lib’ is unspecified)
also installing the dependencies ‘textshaping’, ‘ragg’, ‘pkgdown’
trying URL 'https://cloud.r-project.org/src/contrib/textshaping_0.3.6.tar.gz'
Content type 'application/x-gzip' length 35722 bytes (34 KB)
==================================================
downloaded 34 KB
trying URL 'https://cloud.r-project.org/src/contrib/ragg_1.2.4.tar.gz'
Content type 'application/x-gzip' length 427579 bytes (417 KB)
==================================================
downloaded 417 KB
trying URL 'https://cloud.r-project.org/src/contrib/pkgdown_2.0.6.tar.gz'
Content type 'application/x-gzip' length 871371 bytes (850 KB)
==================================================
downloaded 850 KB
trying URL 'https://cloud.r-project.org/src/contrib/devtools_2.4.5.tar.gz'
Content type 'application/x-gzip' length 374718 bytes (365 KB)
==================================================
downloaded 365 KB
* installing *source* package ‘textshaping’ ...
** package ‘textshaping’ successfully unpacked and MD5 sums checked
** using staged installation
Found pkg-config cflags and libs!
Using PKG_CFLAGS=-I/usr/include/harfbuzz -I/usr/include/glib-2.0 -I/usr/lib/x86_64-linux-gnu/glib-2.0/include -I/usr/include/freetype2 -I/usr/include/libpng16 -I/usr/include/fribidi
Using PKG_LIBS=-lharfbuzz -lfreetype -lfribidi
** libs
rm -f textshaping.so cpp11.o face_feature.o hb_shaper.o init.o string_bidi.o string_metrics.o string_shape.o
g++ -std=gnu++11 -I"/usr/share/R/include" -DNDEBUG -DNDEBUG -I/usr/include/harfbuzz -I/usr/include/glib-2.0 -I/usr/lib/x86_64-linux-gnu/glib-2.0/include -I/usr/include/freetype2 -I/usr/include/libpng16 -I/usr/include/fribidi -I'/home/user/R/x86_64-pc-linux-gnu-library/4.0/cpp11/include' -I'/home/user/R/x86_64-pc-linux-gnu-library/4.0/systemfonts/include' -fpic -g -O2 -ffile-prefix-map=/build/r-base-XqSJAD/r-base-4.0.4=. -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2 -g -c cpp11.cpp -o cpp11.o
g++ -std=gnu++11 -I"/usr/share/R/include" -DNDEBUG -DNDEBUG -I/usr/include/harfbuzz -I/usr/include/glib-2.0 -I/usr/lib/x86_64-linux-gnu/glib-2.0/include -I/usr/include/freetype2 -I/usr/include/libpng16 -I/usr/include/fribidi -I'/home/user/R/x86_64-pc-linux-gnu-library/4.0/cpp11/include' -I'/home/user/R/x86_64-pc-linux-gnu-library/4.0/systemfonts/include' -fpic -g -O2 -ffile-prefix-map=/build/r-base-XqSJAD/r-base-4.0.4=. -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2 -g -c face_feature.cpp -o face_feature.o
g++ -std=gnu++11 -I"/usr/share/R/include" -DNDEBUG -DNDEBUG -I/usr/include/harfbuzz -I/usr/include/glib-2.0 -I/usr/lib/x86_64-linux-gnu/glib-2.0/include -I/usr/include/freetype2 -I/usr/include/libpng16 -I/usr/include/fribidi -I'/home/user/R/x86_64-pc-linux-gnu-library/4.0/cpp11/include' -I'/home/user/R/x86_64-pc-linux-gnu-library/4.0/systemfonts/include' -fpic -g -O2 -ffile-prefix-map=/build/r-base-XqSJAD/r-base-4.0.4=. -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2 -g -c hb_shaper.cpp -o hb_shaper.o
g++ -std=gnu++11 -I"/usr/share/R/include" -DNDEBUG -DNDEBUG -I/usr/include/harfbuzz -I/usr/include/glib-2.0 -I/usr/lib/x86_64-linux-gnu/glib-2.0/include -I/usr/include/freetype2 -I/usr/include/libpng16 -I/usr/include/fribidi -I'/home/user/R/x86_64-pc-linux-gnu-library/4.0/cpp11/include' -I'/home/user/R/x86_64-pc-linux-gnu-library/4.0/systemfonts/include' -fpic -g -O2 -ffile-prefix-map=/build/r-base-XqSJAD/r-base-4.0.4=. -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2 -g -c init.cpp -o init.o
g++ -std=gnu++11 -I"/usr/share/R/include" -DNDEBUG -DNDEBUG -I/usr/include/harfbuzz -I/usr/include/glib-2.0 -I/usr/lib/x86_64-linux-gnu/glib-2.0/include -I/usr/include/freetype2 -I/usr/include/libpng16 -I/usr/include/fribidi -I'/home/user/R/x86_64-pc-linux-gnu-library/4.0/cpp11/include' -I'/home/user/R/x86_64-pc-linux-gnu-library/4.0/systemfonts/include' -fpic -g -O2 -ffile-prefix-map=/build/r-base-XqSJAD/r-base-4.0.4=. -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2 -g -c string_bidi.cpp -o string_bidi.o
g++ -std=gnu++11 -I"/usr/share/R/include" -DNDEBUG -DNDEBUG -I/usr/include/harfbuzz -I/usr/include/glib-2.0 -I/usr/lib/x86_64-linux-gnu/glib-2.0/include -I/usr/include/freetype2 -I/usr/include/libpng16 -I/usr/include/fribidi -I'/home/user/R/x86_64-pc-linux-gnu-library/4.0/cpp11/include' -I'/home/user/R/x86_64-pc-linux-gnu-library/4.0/systemfonts/include' -fpic -g -O2 -ffile-prefix-map=/build/r-base-XqSJAD/r-base-4.0.4=. -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2 -g -c string_metrics.cpp -o string_metrics.o
g++ -std=gnu++11 -I"/usr/share/R/include" -DNDEBUG -DNDEBUG -I/usr/include/harfbuzz -I/usr/include/glib-2.0 -I/usr/lib/x86_64-linux-gnu/glib-2.0/include -I/usr/include/freetype2 -I/usr/include/libpng16 -I/usr/include/fribidi -I'/home/user/R/x86_64-pc-linux-gnu-library/4.0/cpp11/include' -I'/home/user/R/x86_64-pc-linux-gnu-library/4.0/systemfonts/include' -fpic -g -O2 -ffile-prefix-map=/build/r-base-XqSJAD/r-base-4.0.4=. -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2 -g -c string_shape.cpp -o string_shape.o
g++ -std=gnu++11 -shared -L/usr/lib/R/lib -Wl,-z,relro -o textshaping.so cpp11.o face_feature.o hb_shaper.o init.o string_bidi.o string_metrics.o string_shape.o -lharfbuzz -lfreetype -lfribidi -L/usr/lib/R/lib -lR
installing to /home/user/R/x86_64-pc-linux-gnu-library/4.0/00LOCK-textshaping/00new/textshaping/libs
** R
** inst
** byte-compile and prepare package for lazy loading
** help
*** installing help indices
*** copying figures
** building package indices
** installing vignettes
** testing if installed package can be loaded from temporary location
** checking absolute paths in shared objects and dynamic libraries
** testing if installed package can be loaded from final location
** testing if installed package keeps a record of temporary installation path
* DONE (textshaping)
* installing *source* package ‘ragg’ ...
** package ‘ragg’ successfully unpacked and MD5 sums checked
** using staged installation
Package libtiff-4 was not found in the pkg-config search path.
Perhaps you should add the directory containing `libtiff-4.pc'
to the PKG_CONFIG_PATH environment variable
No package 'libtiff-4' found
Package libtiff-4 was not found in the pkg-config search path.
Perhaps you should add the directory containing `libtiff-4.pc'
to the PKG_CONFIG_PATH environment variable
No package 'libtiff-4' found
Using PKG_CFLAGS=
Using PKG_LIBS=-lfreetype -lpng16 -ltiff -lz -ljpeg -lbz2
-----------------------------[ ANTICONF ]-------------------------------
Configuration failed to find one of freetype2 libpng libtiff-4. Try installing:
* deb: libfreetype6-dev libpng-dev libtiff5-dev libjpeg-dev (Debian, Ubuntu, etc)
* rpm: freetype-devel libpng-devel libtiff-devel libjpeg-turbo-devel (Fedora, CentOS, RHEL)
* csw: libfreetype_dev libpng16_dev libtiff_dev libjpeg_dev (Solaris)
If freetype2 libpng libtiff-4 is already installed, check that 'pkg-config' is in your
PATH and PKG_CONFIG_PATH contains a freetype2 libpng libtiff-4.pc file. If pkg-config
is unavailable you can set INCLUDE_DIR and LIB_DIR manually via:
R CMD INSTALL --configure-vars='INCLUDE_DIR=... LIB_DIR=...'
-------------------------- [ERROR MESSAGE] ---------------------------
<stdin>:1:10: fatal error: ft2build.h: No such file or directory
compilation terminated.
--------------------------------------------------------------------
ERROR: configuration failed for package ‘ragg’
* removing ‘/home/user/R/x86_64-pc-linux-gnu-library/4.0/ragg’
Warning in install.packages :
installation of package ‘ragg’ had non-zero exit status
ERROR: dependency ‘ragg’ is not available for package ‘pkgdown’
* removing ‘/home/user/R/x86_64-pc-linux-gnu-library/4.0/pkgdown’
Warning in install.packages :
installation of package ‘pkgdown’ had non-zero exit status
ERROR: dependency ‘pkgdown’ is not available for package ‘devtools’
* removing ‘/home/user/R/x86_64-pc-linux-gnu-library/4.0/devtools’
Warning in install.packages :
installation of package ‘devtools’ had non-zero exit status
The downloaded source packages are in
‘/tmp/Rtmpll67sZ/downloaded_packages’
What I am hoping for:
That I can install and use devtools as I need it for the course I am taking.

mvtnorm installation in R, error trying to exec gfortran-4.2 Bad CPU type in executable

I have just installed R using brew and try to install mvtnorm package, but I get the following error:
Any suggestions how to solve this?
> install.packages("mvtnorm")
Installing package into ‘/usr/local/lib/R/4.1/site-library’
(as ‘lib’ is unspecified)
trying URL 'https://cran.rstudio.com/src/contrib/mvtnorm_1.1-2.tar.gz'
Content type 'application/x-gzip' length 166202 bytes (162 KB)
==================================================
downloaded 162 KB
* installing *source* package ‘mvtnorm’ ...
** package ‘mvtnorm’ successfully unpacked and MD5 sums checked
** using staged installation
** libs
clang -I"/usr/local/Cellar/r/4.1.0/lib/R/include" -DNDEBUG -I/usr/local/opt/gettext/include -I/usr/local/opt/readline/include -I/usr/local/opt/xz/include -I/usr/local/include -fPIC -Wno-implicit-function-declaration -c C_FORTRAN_interface.c -o C_FORTRAN_interface.o
clang -I"/usr/local/Cellar/r/4.1.0/lib/R/include" -DNDEBUG -I/usr/local/opt/gettext/include -I/usr/local/opt/readline/include -I/usr/local/opt/xz/include -I/usr/local/include -fPIC -Wno-implicit-function-declaration -c miwa.c -o miwa.o
gfortran -fno-optimize-sibling-calls -fPIC -g -O2 -c mvt.f -o mvt.o
gfortran-4.2: error trying to exec '/usr/local/bin/i686-apple-darwin8-gfortran-4.2': execvp: Bad CPU type in executable
make: *** [mvt.o] Error 255
ERROR: compilation failed for package ‘mvtnorm’
* removing ‘/usr/local/lib/R/4.1/site-library/mvtnorm’
Warning in install.packages :
installation of package ‘mvtnorm’ had non-zero exit status
The downloaded source packages are in
‘/private/var/folders/4l/y1pqv07934x_2qv3bzj_93s40000gn/T/RtmpHUys7l/downloaded_packages’
>
Finally, I installed gfortran 10.2 (thanks to https://github.com/fxcoudert/gfortran-for-macOS/issues/17) now I am able to install mvtnorm and some other packages having the same problem.

`isoband` package installation fails, `testthat.h` not found

I have R (version 3.6.3 (2020-02-29), Holding the Windsock) installed on Ubuntu 18.04.4 LTS. When I try to install ggplot2 from source, the installation of dependency package isoband fails with testthat.h not found. The full output:
> install.packages("ggplot2")
Installing package into ‘/home/oszkar/R/x86_64-pc-linux-gnu-library/3.6’
(as ‘lib’ is unspecified)
also installing the dependency ‘isoband’
trying URL 'https://cloud.r-project.org/src/contrib/isoband_0.2.1.tar.gz'
Content type 'application/x-gzip' length 2293333 bytes (2.2 MB)
==================================================
downloaded 2.2 MB
trying URL 'https://cloud.r-project.org/src/contrib/ggplot2_3.3.0.tar.gz'
Content type 'application/x-gzip' length 3031461 bytes (2.9 MB)
==================================================
downloaded 2.9 MB
* installing *source* package ‘isoband’ ...
** package ‘isoband’ successfully unpacked and MD5 sums checked
** using staged installation
** libs
g++ -std=gnu++11 -I"/usr/share/R/include" -DNDEBUG
-I"/home/oszkar/R/x86_64-pc-linux-gnu-library/3.6/Rcpp/include"
-I"/usr/local/lib/R/site-library/testthat/include" -fpic -g -O2
-fdebug-prefix-map=/build/r-base-V28x5H/r-base-3.6.3=.
-fstack-protector-strong -Wformat -Werror=format-security -Wdate-time
-D_FORTIFY_SOURCE=2 -g -c RcppExports.cpp -o RcppExports.o
g++ -std=gnu++11 -I"/usr/share/R/include" -DNDEBUG
-I"/home/oszkar/R/x86_64-pc-linux-gnu-library/3.6/Rcpp/include"
-I"/usr/local/lib/R/site-library/testthat/include" -fpic -g -O2
-fdebug-prefix-map=/build/r-base-V28x5H/r-base-3.6.3=.
-fstack-protector-strong -Wformat -Werror=format-security -Wdate-time
-D_FORTIFY_SOURCE=2 -g -c clip-lines.cpp -o clip-lines.o
g++ -std=gnu++11 -I"/usr/share/R/include" -DNDEBUG
-I"/home/oszkar/R/x86_64-pc-linux-gnu-library/3.6/Rcpp/include"
-I"/usr/local/lib/R/site-library/testthat/include" -fpic -g -O2
-fdebug-prefix-map=/build/r-base-V28x5H/r-base-3.6.3=.
-fstack-protector-strong -Wformat -Werror=format-security -Wdate-time
-D_FORTIFY_SOURCE=2 -g -c isoband.cpp -o isoband.o
g++ -std=gnu++11 -I"/usr/share/R/include" -DNDEBUG
-I"/home/oszkar/R/x86_64-pc-linux-gnu-library/3.6/Rcpp/include"
-I"/usr/local/lib/R/site-library/testthat/include" -fpic -g -O2
-fdebug-prefix-map=/build/r-base-V28x5H/r-base-3.6.3=.
-fstack-protector-strong -Wformat -Werror=format-security -Wdate-time
-D_FORTIFY_SOURCE=2 -g -c polygon.cpp -o polygon.o
g++ -std=gnu++11 -I"/usr/share/R/include" -DNDEBUG
-I"/home/oszkar/R/x86_64-pc-linux-gnu-library/3.6/Rcpp/include"
-I"/usr/local/lib/R/site-library/testthat/include" -fpic -g -O2
-fdebug-prefix-map=/build/r-base-V28x5H/r-base-3.6.3=.
-fstack-protector-strong -Wformat -Werror=format-security -Wdate-time
-D_FORTIFY_SOURCE=2 -g -c separate-polygons.cpp -o separate-polygons.o
separate-polygons.cpp:4:10: fatal error: testthat.h: No such file or directory
#include <testthat.h>
^~~~~~~~~~~~
compilation terminated.
/usr/lib/R/etc/Makeconf:177: recipe for target 'separate-polygons.o' failed
make: *** [separate-polygons.o] Error 1
ERROR: compilation failed for package ‘isoband’
* removing ‘/home/oszkar/R/x86_64-pc-linux-gnu-library/3.6/isoband’
Warning in install.packages :
installation of package ‘isoband’ had non-zero exit status
ERROR: dependency ‘isoband’ is not available for package ‘ggplot2’
* removing ‘/home/oszkar/R/x86_64-pc-linux-gnu-library/3.6/ggplot2’
Warning in install.packages :
installation of package ‘ggplot2’ had non-zero exit status
The downloaded source packages are in
‘/tmp/Rtmp5aYRcO/downloaded_packages’
I have already tried to install testthat manually, but it seems not to be available for R 3.6.3:
> install.packages("testthat")
...
Error: package or namespace load failed for ‘pkgload’:
.onLoad failed in loadNamespace() for 'pkgload', details:
call: NULL
error: package ‘testthat’ was installed by an R version with different internals;
it needs to be reinstalled for use with this R version
Error: loading failed
Execution halted
ERROR: loading failed
* removing ‘/home/oszkar/R/x86_64-pc-linux-gnu-library/3.6/pkgload’
Warning in install.packages :
installation of package ‘pkgload’ had non-zero exit status
ERROR: dependency ‘pkgload’ is not available for package ‘testthat’
* removing ‘/home/oszkar/R/x86_64-pc-linux-gnu-library/3.6/testthat’
Warning in install.packages :
installation of package ‘testthat’ had non-zero exit status
The downloaded source packages are in
‘/tmp/Rtmp5aYRcO/downloaded_packages’
Any idea would be appreciated.
Solved. The cause of the problem was that after a series of Ubuntu and R upgrades there were some outdated packages installed from source remained on my system.
First I opened up an R console and looking for the paths for R packages built with pre 3.6 version:
> unique(subset(as.data.frame(installed.packages()),
grepl("^3\\.[^6]", Built))[, "LibPath"])
[1] /usr/local/lib/R/site-library /usr/lib/R/library
As it is not possible to apply remove.packages() on these outdated packages, I switched to bash, and listed all the package paths:
>grep 'Built: R 3.[0-5]' /usr/local/lib/R/site-library/*/DESCRIPTION /usr/lib/R/library/*/
DESCRIPTION
I have removed (simply deleted from /usr/local/lib/R/site-library/ and /usr/lib/R/library/) the packages on the previous commands output, and now everything works.

How to install odbc package to Databricks cluster?

I need to access an Azure SQL Database from an R notebook in Databricks. To do this I aimed to use the odbc package, which installed fine on my local instance of R.
I have tried to install the package to the cluster using Databricks' interface, which always fails. I have also tried the following code within a notebook:
install.packages("odbc")
which results in:
Installing package into ‘/databricks/spark/R/lib’
(as ‘lib’ is unspecified)
trying URL 'https://cloud.r-project.org/src/contrib/odbc_1.1.6.tar.gz'
Content type 'application/x-gzip' length 288033 bytes (281 KB)
==================================================
downloaded 281 KB
* installing *source* package ‘odbc’ ...
** package ‘odbc’ successfully unpacked and MD5 sums checked
PKG_CFLAGS=
PKG_LIBS=-lodbc
<stdin>:1:17: fatal error: sql.h: No such file or directory
compilation terminated.
------------------------- ANTICONF ERROR ---------------------------
Configuration failed because odbc was not found. Try installing:
* deb: unixodbc-dev (Debian, Ubuntu, etc)
* rpm: unixODBC-devel (Fedora, CentOS, RHEL)
* csw: unixodbc_dev (Solaris)
* brew: unixodbc (Mac OSX)
To use a custom odbc set INCLUDE_DIR and LIB_DIR manually via:
R CMD INSTALL --configure-vars='INCLUDE_DIR=... LIB_DIR=...'
--------------------------------------------------------------------
ERROR: configuration failed for package ‘odbc’
* removing ‘/databricks/spark/R/lib/odbc’
The downloaded source packages are in
‘/tmp/RtmpqHp2QM/downloaded_packages’
I have also tried installing from github:
library(devtools)
devtools::install_github("r-dbi/odbc")
Which gives a different error:
Downloading GitHub repo r-dbi/odbc#master
Installing 3 packages: assertthat, BH, Rcpp
Installing packages into ‘/databricks/spark/R/lib’
(as ‘lib’ is unspecified)
trying URL 'https://cloud.r-project.org/src/contrib/assertthat_0.2.1.tar.gz'
Content type 'application/x-gzip' length 12742 bytes (12 KB)
==================================================
downloaded 12 KB
trying URL 'https://cloud.r-project.org/src/contrib/BH_1.69.0-1.tar.gz'
Content type 'application/x-gzip' length 12378154 bytes (11.8 MB)
==================================================
downloaded 11.8 MB
trying URL 'https://cloud.r-project.org/src/contrib/Rcpp_1.0.1.tar.gz'
Content type 'application/x-gzip' length 3661123 bytes (3.5 MB)
==================================================
downloaded 3.5 MB
* installing *source* package ‘assertthat’ ...
** package ‘assertthat’ successfully unpacked and MD5 sums checked
** R
** preparing package for lazy loading
** help
*** installing help indices
** building package indices
** testing if installed package can be loaded
* DONE (assertthat)
* installing *source* package ‘BH’ ...
** package ‘BH’ successfully unpacked and MD5 sums checked
** inst
** help
*** installing help indices
** building package indices
** testing if installed package can be loaded
* DONE (BH)
* installing *source* package ‘Rcpp’ ...
** package ‘Rcpp’ successfully unpacked and MD5 sums checked
** libs
g++ -I/usr/share/R/include -DNDEBUG -I../inst/include/ -fpic -g -O2 -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2 -g -c Date.cpp -o Date.o
g++ -I/usr/share/R/include -DNDEBUG -I../inst/include/ -fpic -g -O2 -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2 -g -c Module.cpp -o Module.o
g++ -I/usr/share/R/include -DNDEBUG -I../inst/include/ -fpic -g -O2 -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2 -g -c Rcpp_init.cpp -o Rcpp_init.o
g++ -I/usr/share/R/include -DNDEBUG -I../inst/include/ -fpic -g -O2 -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2 -g -c api.cpp -o api.o
g++ -I/usr/share/R/include -DNDEBUG -I../inst/include/ -fpic -g -O2 -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2 -g -c attributes.cpp -o attributes.o
g++ -I/usr/share/R/include -DNDEBUG -I../inst/include/ -fpic -g -O2 -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2 -g -c barrier.cpp -o barrier.o
g++ -shared -L/usr/lib/R/lib -Wl,-Bsymbolic-functions -Wl,-z,relro -o Rcpp.so Date.o Module.o Rcpp_init.o api.o attributes.o barrier.o -L/usr/lib/R/lib -lR
installing to /databricks/spark/R/lib/Rcpp/libs
** R
** inst
** preparing package for lazy loading
** help
*** installing help indices
** building package indices
** installing vignettes
** testing if installed package can be loaded
* DONE (Rcpp)
The downloaded source packages are in
‘/tmp/RtmpqHp2QM/downloaded_packages’
Error in processx::run(bin, args = real_cmdargs, stdout_line_callback = real_callback(stdout), :
System command error
In addition: Warning messages:
1: In install.packages("odbc") :
installation of package ‘odbc’ had non-zero exit status
2: In install.packages("odbc") :
installation of package ‘odbc’ had non-zero exit status
Any idea why this package will not install on Databricks when it works fine locally and when all other packages I have tried install on Databricks work fine using the same syntax?
Best option to access a SQL Database is using the preinstalled JDBC connectivity (see the Documentation).
If you want to use ODBC this requires (as mentioned in one of the comments) unix odbc. Good practice to install multiple packages is using init-scripts. Following python code is for creating an init-script for pyodbc installation.
script = """
sudo apt-get -q -y install unixodbc unixodbc-dev
sudo apt-get -q -y install python3-dev
sudo pip install pyodbc
curl https://packages.microsoft.com/keys/microsoft.asc | apt-key add -
sudo curl https://packages.microsoft.com/config/ubuntu/16.04/prod.list > /etc/apt/sources.list.d/mssql-release.list
sudo apt-get update
sudo ACCEPT_EULA=Y apt-get -q -y install msodbcsql
"""
dbutils.fs.put("/databricks/init/pyodbc/pyodbc.sh", script, True)
Hope this helps.

RStudio AWS EC2 error when installing packages dependent on gsl

I set up an AWS EC2 instance of RStudio using the AMI provided by Louis Aslett.
However, when i try to install the package "topicsmodels" or "gsl" i get the following errors:
> install.packages("gsl")
Installing package into ‘/home/rstudio/R/x86_64-pc-linux-gnu-library/3.4’
(as ‘lib’ is unspecified)
trying URL 'https://cran.rstudio.com/src/contrib/gsl_1.9-10.3.tar.gz'
Content type 'application/x-gzip' length 172529 bytes (168 KB)
==================================================
downloaded 168 KB
* installing *source* package ‘gsl’ ...
** package ‘gsl’ successfully unpacked and MD5 sums checked
checking for gsl-config... no
configure: error: gsl-config not found, is GSL installed?
ERROR: configuration failed for package ‘gsl’
* removing ‘/home/rstudio/R/x86_64-pc-linux-gnu-library/3.4/gsl’
Warning in install.packages :
installation of package ‘gsl’ had non-zero exit status
The downloaded source packages are in
‘/tmp/RtmpBItbU2/downloaded_packages’
and
> install.packages("topicmodels")
Installing package into ‘/home/rstudio/R/x86_64-pc-linux-gnu-library/3.4’
(as ‘lib’ is unspecified)
trying URL 'https://cran.rstudio.com/src/contrib/topicmodels_0.2-6.tar.gz'
Content type 'application/x-gzip' length 712766 bytes (696 KB)
==================================================
downloaded 696 KB
* installing *source* package ‘topicmodels’ ...
** package ‘topicmodels’ successfully unpacked and MD5 sums checked
** libs
gcc -std=gnu99 -I/usr/share/R/include -DNDEBUG -fpic -g -O2 -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2 -g -c cokus.c -o cokus.o
gcc -std=gnu99 -I/usr/share/R/include -DNDEBUG -fpic -g -O2 -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2 -g -c common.c -o common.o
gcc -std=gnu99 -I/usr/share/R/include -DNDEBUG -fpic -g -O2 -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2 -g -c ctm.c -o ctm.o
ctm.c:29:25: fatal error: gsl/gsl_rng.h: No such file or directory
compilation terminated.
/usr/lib/R/etc/Makeconf:159: recipe for target 'ctm.o' failed
make: *** [ctm.o] Error 1
ERROR: compilation failed for package ‘topicmodels’
* removing ‘/home/rstudio/R/x86_64-pc-linux-gnu-library/3.4/topicmodels’
Warning in install.packages :
installation of package ‘topicmodels’ had non-zero exit status
The downloaded source packages are in
‘/tmp/RtmpBItbU2/downloaded_packages’
My knowledge of linux and RStudio server edition is fairly limited. I've tried following some intsructions from others who've experienced a similar problem, but none have worked (or i am unable to follow the instructions).
After googling a while this did work for me:
In Ubuntu to get topicmodels to install I needed to make sure that both:
GNU Scientific Library(GSL) -- binary package
GNU Scientific Library(GSL) -- development pacakage
were installed.

Resources