Cannot install packages to R after brew install - r

I've spent about an hour trying to debug this, but I think it's best to assume I haven't tried anything except brew install r and install.packages("tidycensus") and a few other packages to check if it was tidycensus specifically.
Let me know if there's any information I can provide. I recently wiped the hard drive of my fairly new Mac and started fresh.
The output of install.packages("tidycensus"):
> install.packages("tidycensus")
Installing package into ‘/usr/local/lib/R/3.5/site-library’
(as ‘lib’ is unspecified)
also installing the dependencies ‘rgdal’, ‘sf’, ‘tigris’, ‘units’
trying URL 'https://cloud.r-project.org/src/contrib/rgdal_1.3-4.tar.gz'
Content type 'application/x-gzip' length 1664774 bytes (1.6 MB)
==================================================
downloaded 1.6 MB
trying URL 'https://cloud.r-project.org/src/contrib/sf_0.6-3.tar.gz'
Content type 'application/x-gzip' length 7973054 bytes (7.6 MB)
==================================================
downloaded 7.6 MB
trying URL 'https://cloud.r-project.org/src/contrib/tigris_0.7.tar.gz'
Content type 'application/x-gzip' length 72980 bytes (71 KB)
==================================================
downloaded 71 KB
trying URL 'https://cloud.r-project.org/src/contrib/units_0.6-0.tar.gz'
Content type 'application/x-gzip' length 912393 bytes (891 KB)
==================================================
downloaded 891 KB
trying URL 'https://cloud.r-project.org/src/contrib/tidycensus_0.4.6.tar.gz'
Content type 'application/x-gzip' length 1615516 bytes (1.5 MB)
==================================================
downloaded 1.5 MB
* installing *source* package ‘rgdal’ ...
** package ‘rgdal’ successfully unpacked and MD5 sums checked
configure: R_HOME: /usr/local/Cellar/r/3.5.1/lib/R
configure: CC: clang
configure: CXX: clang++
configure: C++11 support available
configure: rgdal: 1.3-4
checking for /usr/bin/svnversion... yes
configure: svn revision: 766
checking for gdal-config... no
no
configure: error: gdal-config not found or not executable.
ERROR: configuration failed for package ‘rgdal’
* removing ‘/usr/local/lib/R/3.5/site-library/rgdal’
* installing *source* package ‘units’ ...
** package ‘units’ successfully unpacked and MD5 sums checked
configure: units: 0.6-0
checking whether the C++ compiler works... yes
checking for C++ compiler default output file name... a.out
checking for suffix of executables...
checking whether we are cross compiling... no
checking for suffix of object files... o
checking whether we are using the GNU C++ compiler... yes
checking whether clang++ accepts -g... yes
checking how to run the C++ preprocessor... clang++ -E
checking for grep that handles long lines and -e... /usr/bin/grep
checking for egrep... /usr/bin/grep -E
checking for ANSI C header files... rm: conftest.dSYM: is a directory
rm: conftest.dSYM: is a directory
yes
checking for sys/types.h... yes
checking for sys/stat.h... yes
checking for stdlib.h... yes
checking for string.h... yes
checking for memory.h... yes
checking for strings.h... yes
checking for inttypes.h... yes
checking for stdint.h... yes
checking for unistd.h... yes
checking for stdbool.h that conforms to C99... no
checking for _Bool... no
checking for error_at_line... no
checking for gcc... clang
checking whether we are using the GNU C compiler... yes
checking whether clang accepts -g... yes
checking for clang option to accept ISO C89... none needed
checking for XML_ParserCreate in -lexpat... yes
checking udunits2.h usability... no
checking udunits2.h presence... no
checking for udunits2.h... no
checking udunits2/udunits2.h usability... no
checking udunits2/udunits2.h presence... no
checking for udunits2/udunits2.h... no
checking for ut_read_xml in -ludunits2... no
configure: error: in `/private/var/folders/69/wy4n7cc10n5fg5_bc8glmms80000gn/T/RtmpPtsVPP/R.INSTALLf8694f0bf387/units':
configure: error:
--------------------------------------------------------------------------------
libudunits2.so not found!
If the udunits2 library is installed in a non-standard location, use:
--configure-args='--with-udunits2-lib=/usr/local/lib'
for example, if the library was not found, and/or
--configure-args='--with-udunits2-include=/usr/include/udunits2'
if the header was not found, replacing paths with appropriate values for your
installation. You can alternatively use the UDUNITS2_INCLUDE and UDUNITS2_LIBS
environment variables.
If udunits2 is not installed, please install it.
It is required for this package.
--------------------------------------------------------------------------------
See `config.log' for more details
ERROR: configuration failed for package ‘units’
* removing ‘/usr/local/lib/R/3.5/site-library/units’
ERROR: dependency ‘units’ is not available for package ‘sf’
* removing ‘/usr/local/lib/R/3.5/site-library/sf’
ERROR: dependencies ‘rgdal’, ‘sf’ are not available for package ‘tigris’
* removing ‘/usr/local/lib/R/3.5/site-library/tigris’
ERROR: dependencies ‘sf’, ‘tigris’, ‘units’ are not available for package ‘tidycensus’
* removing ‘/usr/local/lib/R/3.5/site-library/tidycensus’
The downloaded source packages are in
‘/private/var/folders/69/wy4n7cc10n5fg5_bc8glmms80000gn/T/Rtmp8iit6a/downloaded_packages’
Warning messages:
1: In install.packages("tidycensus") :
installation of package ‘rgdal’ had non-zero exit status
2: In install.packages("tidycensus") :
installation of package ‘units’ had non-zero exit status
3: In install.packages("tidycensus") :
installation of package ‘sf’ had non-zero exit status
4: In install.packages("tidycensus") :
installation of package ‘tigris’ had non-zero exit status
5: In install.packages("tidycensus") :
installation of package ‘tidycensus’ had non-zero exit status
> install.packages('tidycensus')
Installing package into ‘/usr/local/lib/R/3.5/site-library’
(as ‘lib’ is unspecified)
also installing the dependencies ‘rgdal’, ‘sf’, ‘tigris’, ‘units’
trying URL 'https://cloud.r-project.org/src/contrib/rgdal_1.3-4.tar.gz'
Content type 'application/x-gzip' length 1664774 bytes (1.6 MB)
==================================================
downloaded 1.6 MB
trying URL 'https://cloud.r-project.org/src/contrib/sf_0.6-3.tar.gz'
Content type 'application/x-gzip' length 7973054 bytes (7.6 MB)
==================================================
downloaded 7.6 MB
trying URL 'https://cloud.r-project.org/src/contrib/tigris_0.7.tar.gz'
Content type 'application/x-gzip' length 72980 bytes (71 KB)
==================================================
downloaded 71 KB
trying URL 'https://cloud.r-project.org/src/contrib/units_0.6-0.tar.gz'
Content type 'application/x-gzip' length 912393 bytes (891 KB)
==================================================
downloaded 891 KB
trying URL 'https://cloud.r-project.org/src/contrib/tidycensus_0.4.6.tar.gz'
Content type 'application/x-gzip' length 1615516 bytes (1.5 MB)
==================================================
downloaded 1.5 MB
* installing *source* package ‘rgdal’ ...
** package ‘rgdal’ successfully unpacked and MD5 sums checked
configure: R_HOME: /usr/local/Cellar/r/3.5.1/lib/R
configure: CC: clang
configure: CXX: clang++
configure: C++11 support available
configure: rgdal: 1.3-4
checking for /usr/bin/svnversion... yes
configure: svn revision: 766
checking for gdal-config... no
no
configure: error: gdal-config not found or not executable.
ERROR: configuration failed for package ‘rgdal’
* removing ‘/usr/local/lib/R/3.5/site-library/rgdal’
* installing *source* package ‘units’ ...
** package ‘units’ successfully unpacked and MD5 sums checked
configure: units: 0.6-0
checking whether the C++ compiler works... yes
checking for C++ compiler default output file name... a.out
checking for suffix of executables...
checking whether we are cross compiling... no
checking for suffix of object files... o
checking whether we are using the GNU C++ compiler... yes
checking whether clang++ accepts -g... yes
checking how to run the C++ preprocessor... clang++ -E
checking for grep that handles long lines and -e... /usr/bin/grep
checking for egrep... /usr/bin/grep -E
checking for ANSI C header files... rm: conftest.dSYM: is a directory
rm: conftest.dSYM: is a directory
yes
checking for sys/types.h... yes
checking for sys/stat.h... yes
checking for stdlib.h... yes
checking for string.h... yes
checking for memory.h... yes
checking for strings.h... yes
checking for inttypes.h... yes
checking for stdint.h... yes
checking for unistd.h... yes
checking for stdbool.h that conforms to C99... no
checking for _Bool... no
checking for error_at_line... no
checking for gcc... clang
checking whether we are using the GNU C compiler... yes
checking whether clang accepts -g... yes
checking for clang option to accept ISO C89... none needed
checking for XML_ParserCreate in -lexpat... yes
checking udunits2.h usability... no
checking udunits2.h presence... no
checking for udunits2.h... no
checking udunits2/udunits2.h usability... no
checking udunits2/udunits2.h presence... no
checking for udunits2/udunits2.h... no
checking for ut_read_xml in -ludunits2... no
configure: error: in `/private/var/folders/69/wy4n7cc10n5fg5_bc8glmms80000gn/T/RtmpuOGf6j/R.INSTALLfdd5361d965a/units':
configure: error:
--------------------------------------------------------------------------------
libudunits2.so not found!
If the udunits2 library is installed in a non-standard location, use:
--configure-args='--with-udunits2-lib=/usr/local/lib'
for example, if the library was not found, and/or
--configure-args='--with-udunits2-include=/usr/include/udunits2'
if the header was not found, replacing paths with appropriate values for your
installation. You can alternatively use the UDUNITS2_INCLUDE and UDUNITS2_LIBS
environment variables.
If udunits2 is not installed, please install it.
It is required for this package.
--------------------------------------------------------------------------------
See `config.log' for more details
ERROR: configuration failed for package ‘units’
* removing ‘/usr/local/lib/R/3.5/site-library/units’
ERROR: dependency ‘units’ is not available for package ‘sf’
* removing ‘/usr/local/lib/R/3.5/site-library/sf’
ERROR: dependencies ‘rgdal’, ‘sf’ are not available for package ‘tigris’
* removing ‘/usr/local/lib/R/3.5/site-library/tigris’
ERROR: dependencies ‘sf’, ‘tigris’, ‘units’ are not available for package ‘tidycensus’
* removing ‘/usr/local/lib/R/3.5/site-library/tidycensus’
The downloaded source packages are in
‘/private/var/folders/69/wy4n7cc10n5fg5_bc8glmms80000gn/T/Rtmp8iit6a/downloaded_packages’
Warning messages:
1: In install.packages("tidycensus") :
installation of package ‘rgdal’ had non-zero exit status
2: In install.packages("tidycensus") :
installation of package ‘units’ had non-zero exit status
3: In install.packages("tidycensus") :
installation of package ‘sf’ had non-zero exit status
4: In install.packages("tidycensus") :
installation of package ‘tigris’ had non-zero exit status
5: In install.packages("tidycensus") :
installation of package ‘tidycensus’ had non-zero exit status

Worked fine for me. Possible solutions:
Check that you have ggplot installed via github install_github("tidyverse/ggplot2")
Confirm that your R-Version is ≥ 3.3.0
Install package via github install_github("walkerke/tidycensus")
Check other dependencies

My problem was that I had a few stray python3 config files floating around after a non-brew install of python3. I removed python3 and reinstalled with brew.
My recommendation to users having the same problem is to run brew doctor. If you are having the same problem I was, your python3 config files will be displayed as issues, and you can uninstall python3 and reinstall it with brew install python3.
I then had a few dependencies I had to work through, some in R, and some in brew.
#comfort eagle 's suggestion of using install_github() after installing and importing devtools was also helpful.

Related

Cannot install Stringi for R (R-studio 1.1.456, OS X 10.15.2 Catalina)

I get the following error when trying to install stringi:
trying URL 'https://cran.rstudio.com/src/contrib/stringi_1.4.5.tar.gz'
Content type 'application/x-gzip' length 7284255 bytes (6.9 MB)
==================================================
downloaded 6.9 MB
* installing *source* package ‘stringi’ ...
** package ‘stringi’ successfully unpacked and MD5 sums checked
** using staged installation
checking for R_HOME... /Users/USER/Anaconda3/anaconda3/lib/R
checking for R... /Users/USER/Anaconda3/anaconda3/lib/R/bin/R
checking for endianness... little
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 local ICUDT_DIR... icu61/data
checking for gcc... x86_64-apple-darwin13.4.0-clang
checking whether the C compiler works... no
configure: error: in `/private/var/folders/fy/d14lc6rd5nq827m06zkkb1_h0000gn/T/RtmpWRiuI3/R.INSTALL116de6e601bb4/stringi':
configure: error: C compiler cannot create executables
See `config.log' for more details
ERROR: configuration failed for package ‘stringi’
* removing ‘/Users/USER/Anaconda3/anaconda3/lib/R/library/stringi’
* restoring previous ‘/Users/USER/Anaconda3/anaconda3/lib/R/library/stringi’
Warning in install.packages :
installation of package ‘stringi’ had non-zero exit status
I have seen that this has been an issue in the past, eg. here where there is a clash with Makevars, but I don't have Makevars installed so that cannot be it. (I tried to install the package as a binary but got: "package ‘stringi’ is available as a source package but not as a binary").
Thanks!
Edit: I changed the title to install from update. The package was somehow removed and now I can't install it, or run rmarkdown...

Unable to install warbleR package using Mac OS

When trying to install the warbleR package, I keep getting this error message:
> install.packages("warbleR")
also installing the dependency ‘bioacoustics’
There is a binary version available but the source version is later:
binary source needs_compilation
warbleR 1.1.14 1.1.15 FALSE
Package which is only available in source form, and may need compilation of C/C++/Fortran:
‘bioacoustics’
Do you want to attempt to install these from sources? (Yes/no/cancel) Yes
installing the source packages ‘bioacoustics’, ‘warbleR’
trying URL 'https://cran.rstudio.com/src/contrib/bioacoustics_0.1.5.tar.gz'
Content type 'application/x-gzip' length 834645 bytes (815 KB)
==================================================
downloaded 815 KB
trying URL 'https://cran.rstudio.com/src/contrib/warbleR_1.1.15.tar.gz'
Content type 'application/x-gzip' length 2348150 bytes (2.2 MB)
==================================================
downloaded 2.2 MB
* installing *source* package ‘bioacoustics’ ...
** package ‘bioacoustics’ successfully unpacked and MD5 sums checked
checking for gcc... clang
checking whether the C compiler works... yes
checking for C compiler default output file name... a.out
checking for suffix of executables...
checking whether we are cross compiling... no
checking for suffix of object files... o
checking whether we are using the GNU C compiler... yes
checking whether clang accepts -g... yes
checking for clang option to accept ISO C89... none needed
checking whether we are using the GNU C++ compiler... yes
checking whether clang++ -std=gnu++11 accepts -g... yes
configure: CXX: clang++ -std=gnu++11
checking for cmake... not found
configure: error: Could not find cmake
ERROR: configuration failed for package ‘bioacoustics’
* removing ‘/Library/Frameworks/R.framework/Versions/3.5/Resources/library/bioacoustics’
Warning in install.packages :
installation of package ‘bioacoustics’ had non-zero exit status
ERROR: dependency ‘bioacoustics’ is not available for package ‘warbleR’
* removing ‘/Library/Frameworks/R.framework/Versions/3.5/Resources/library/warbleR’
Warning in install.packages :
installation of package ‘warbleR’ had non-zero exit status
The downloaded source packages are in
‘/private/var/folders/z9/6d_1kkxd0jxcj0r88hng7crm0000gn/T/RtmpSUXFDU/downloaded_packages’
>
As #neilfws pointed out, this could be solved with homebrew running brew install cmake.

Cannot install rgl package

I am running RStudio on Digital Ocean. I want to install a package called rgl. The goal is to install this package without using sudo code. I also tried installing the dependency package 'magick' but no luck. Anyone try this in the past?
I also cannot download xquartz since this in running on digital ocean. That has been an answer I've been researching in order to solve this.
This is the error:
install.packages("rgl", dependencies = TRUE)
Installing package into ‘/home/nick/R/x86_64-pc-linux-gnu-library/3.4’
(as ‘lib’ is unspecified)
also installing the dependency ‘magick’
trying URL 'https://cran.rstudio.com/src/contrib/magick_2.0.tar.gz'
Content type 'application/x-gzip' length 4998781 bytes (4.8 MB)
==================================================
downloaded 4.8 MB
trying URL 'https://cran.rstudio.com/src/contrib/rgl_0.99.16.tar.gz'
Content type 'application/x-gzip' length 3058794 bytes (2.9 MB)
==================================================
downloaded 2.9 MB
* installing *source* package ‘magick’ ...
** package ‘magick’ successfully unpacked and MD5 sums checked
Package Magick++ was not found in the pkg-config search path.
Perhaps you should add the directory containing `Magick++.pc'
to the PKG_CONFIG_PATH environment variable
No package 'Magick++' found
Using PKG_CFLAGS=
Using PKG_LIBS=-lMagick++-6.Q16
------------------------- ANTICONF ERROR ---------------------------
Configuration failed because Magick++ was not found. Try installing:
- deb: 'libmagick++-dev' (Debian, Ubuntu)
- rpm: 'ImageMagick-c++-devel' (Fedora, CentOS, RHEL)
- csw: 'imagemagick_dev' (Solaris)
On MacOS it is recommended to use install ImageMagick-6 from homebrew
with extra support for fontconfig and rsvg rendering:
brew reinstall imagemagick#6 --with-fontconfig --with-librsvg
For older Ubuntu versions Trusty (14.04) and Xenial (16.04) use our PPA:
sudo add-apt-repository -y ppa:opencpu/imagemagick
sudo apt-get update
sudo apt-get install -y libmagick++-dev
If Magick++ is already installed, check that 'pkg-config' is in your
PATH and PKG_CONFIG_PATH contains a Magick++.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: configuration failed for package ‘magick’
* removing ‘/home/nick/R/x86_64-pc-linux-gnu-library/3.4/magick’
Warning in install.packages :
installation of package ‘magick’ had non-zero exit status
* installing *source* package ‘rgl’ ...
** package ‘rgl’ successfully unpacked and MD5 sums checked
checking for gcc... gcc -std=gnu99
checking whether the C compiler works... yes
checking for C compiler default output file name... a.out
checking for suffix of executables...
checking whether we are cross compiling... no
checking for suffix of object files... o
checking whether we are using the GNU C compiler... yes
checking whether gcc -std=gnu99 accepts -g... yes
checking for gcc -std=gnu99 option to accept ISO C89... none needed
checking how to run the C preprocessor... gcc -std=gnu99 -E
checking for gcc... (cached) gcc -std=gnu99
checking whether we are using the GNU C compiler... (cached) yes
checking whether gcc -std=gnu99 accepts -g... (cached) yes
checking for gcc -std=gnu99 option to accept ISO C89... (cached) none needed
checking for libpng-config... yes
configure: using libpng-config
configure: using libpng dynamic linkage
checking for X... no
configure: error: X11 not found but required, configure aborted.
ERROR: configuration failed for package ‘rgl’
* removing ‘/home/nick/R/x86_64-pc-linux-gnu-library/3.4/rgl’
Warning in install.packages :
installation of package ‘rgl’ had non-zero exit status
The downloaded source packages are in
‘/tmp/Rtmp8fiUj6/downloaded_packages’

R calling user path to clang+llvm

how do we reset the paths that R uses to call clang:
When trying to compile R package from source I get the the following error:
* installing *source* package ‘sf’ ...
** package ‘sf’ successfully unpacked and MD5 sums checked
configure: CC: /Users/user_name/opt/clang+llvm-4.0.1-x86_64-apple-macosx10.9.0/bin/clang
configure: CXX: /Users/user_name/opt/clang+llvm-4.0.1-x86_64-apple-macosx10.9.0/bin/clang++
checking for gdal-config... /opt/local/bin/gdal-config
checking gdal-config usability... yes
configure: GDAL: 2.2.4
checking GDAL version >= 2.0.0... yes
checking for gcc... /Users/user_name/opt/clang+llvm-4.0.1-x86_64-apple-macosx10.9.0/bin/clang
checking whether the C compiler works... no
configure: error: in `/private/var/folders/gk/2c8jpk7d63z66990tsly0wzr0000gn/T/RtmpCtBrqR/R.INSTALLb2c5342f3e/sf':
configure: error: C compiler cannot create executables
See `config.log' for more details
ERROR: configuration failed for package ‘sf’
* removing ‘/Library/Frameworks/R.framework/Versions/3.5/Resources/library/sf’
* restoring previous ‘/Library/Frameworks/R.framework/Versions/3.5/Resources/library/sf’
Warning in install.packages :
installation of package ‘sf’ had non-zero exit status
In the 3rd line above it reads:
configure: CC: /Users/user_name/opt/clang+llvm-4.0.1-x86_64-apple-macosx10.9.0/bin/clang
It has a genertic name for account, how do we change this a real account name:
/Users/realaccountname/opt/clang+llvm-4.0.1-x86_64-apple-macosx10.9.0/bin/clang
P

Difficulty installing GTK 2.8 Mac OS X 10.12.6 for installing Rattle package in R.

I only want to install the Rattle package and its dependencies in R, though I got that GTK 2.8 is required. Since I'm not a programmer I went the most simple route and ran homebrew but it installed GTK 2.24.
Now I get this error instead [full code]
> install.packages("rattle")
also installing the dependency ‘RGtk2’
Package which is only available in source form, and may need compilation of
C/C++/Fortran: ‘RGtk2’
Do you want to attempt to install these from sources?
y/n: n
installing the source package ‘rattle’
trying URL 'https://cran.rstudio.com/src/contrib/rattle_4.1.0.tar.gz'
Content type 'application/x-gzip' length 2665410 bytes (2.5 MB)
==================================================
downloaded 2.5 MB
ERROR: dependency ‘RGtk2’ is not available for package ‘rattle’
* removing ‘/Library/Frameworks/R.framework/Versions/3.4/Resources/library/rattle’
Warning in install.packages :
installation of package ‘rattle’ had non-zero exit status
The downloaded source packages are in
‘/private/var/folders/gz/hgc4y87s16gcg7q7b6fgq1hc0000gn/T/RtmpXbOVK8/downloaded_packages’
> install.packages("RGtk2")
Package which is only available in source form, and may need compilation of
C/C++/Fortran: ‘RGtk2’
Do you want to attempt to install these from sources?
y/n: y
installing the source package ‘RGtk2’
trying URL 'https://cran.rstudio.com/src/contrib/RGtk2_2.20.33.tar.gz'
Content type 'application/x-gzip' length 2792938 bytes (2.7 MB)
==================================================
downloaded 2.7 MB
* installing *source* package ‘RGtk2’ ...
** package ‘RGtk2’ successfully unpacked and MD5 sums checked
checking for pkg-config... /usr/local/bin/pkg-config
checking pkg-config is at least version 0.9.0... yes
checking for INTROSPECTION... no
checking for GTK... yes
checking for GTHREAD... yes
checking for gcc... gcc
checking whether the C compiler works... yes
checking for C compiler default output file name... a.out
checking for suffix of executables...
checking whether we are cross compiling... no
checking for suffix of object files... o
checking whether we are using the GNU C compiler... yes
checking whether gcc accepts -g... yes
checking for gcc option to accept ISO C89... none needed
checking how to run the C preprocessor... gcc -E
checking for grep that handles long lines and -e... /usr/bin/grep
checking for egrep... /usr/bin/grep -E
checking for ANSI C header files... yes
checking for sys/types.h... yes
checking for sys/stat.h... yes
checking for stdlib.h... yes
checking for string.h... yes
checking for memory.h... yes
checking for strings.h... yes
checking for inttypes.h... yes
checking for stdint.h... yes
checking for unistd.h... yes
checking for uintptr_t... yes
configure: creating ./config.status
config.status: creating src/Makevars
** libs
clang -I/Library/Frameworks/R.framework/Resources/include -DNDEBUG -D_R_=1 -D_REENTRANT -I/usr/local/Cellar/gtk+/2.24.31_1/include/gtk-2.0 -I/usr/local/Cellar/gtk+/2.24.31_1/lib/gtk-2.0/include -I/usr/local/Cellar/pango/1.40.9/include/pango-1.0 -I/usr/local/Cellar/harfbuzz/1.4.8_1/include/harfbuzz -I/usr/local/Cellar/graphite2/1.3.10/include -I/usr/local/Cellar/pango/1.40.9/include/pango-1.0 -I/usr/local/Cellar/atk/2.24.0/include/atk-1.0 -I/usr/local/Cellar/cairo/1.14.10/include/cairo -I/usr/local/Cellar/pixman/0.34.0_1/include/pixman-1 -I/usr/local/Cellar/fontconfig/2.12.4/include -I/usr/local/opt/freetype/include/freetype2 -I/usr/local/Cellar/libpng/1.6.31/include/libpng16 -I/usr/local/Cellar/gdk-pixbuf/2.36.8/include/gdk-pixbuf-2.0 -I/usr/local/Cellar/libpng/1.6.31/include/libpng16 -I/usr/local/Cellar/glib/2.52.3/include/glib-2.0 -I/usr/local/Cellar/glib/2.52.3/lib/glib-2.0/include -I/usr/local/opt/gettext/include -I/usr/local/Cellar/pcre/8.41/include -I. -DHAVE_UINTPTR_T -I/usr/... <truncated>
RGtkDataFrame.c:502:1: warning: unused function 'r_gtk_data_frame_remove' [-Wunused-function]
r_gtk_data_frame_remove (RGtkDataFrame *data_frame,
^
1 warning generated.
clang -I/Library/Frameworks/R.framework/Resources/include -DNDEBUG -D_R_=1 -D_REENTRANT -I/usr/local/Cellar/gtk+/2.24.31_1/include/gtk-2.0 -I/usr/local/Cellar/gtk+/2.24.31_1/lib/gtk-2.0/include -I/usr/local/Cellar/pango/1.40.9/include/pango-1.0 -I/usr/local/Cellar/harfbuzz/1.4.8_1/include/harfbuzz -I/usr/local/Cellar/graphite2/1.3.10/include -I/usr/local/Cellar/pango/1.40.9/include/pango-1.0 -I/usr/local/Cellar/atk/2.24.0/include/atk-1.0 -I/usr/local/Cellar/cairo/1.14.10/include/cairo -I/usr/local/Cellar/pixman/0.34.0_1/include/pixman-1 -I/usr/local/Cellar/fontconfig/2.12.4/include -I/usr/local/opt/freetype/include/freetype2 -I/usr/local/Cellar/libpng/1.6.31/include/libpng16 -I/usr/local/Cellar/gdk-pixbuf/2.36.8/include/gdk-pixbuf-2.0 -I/usr/local/Cellar/libpng/1.6.31/include/libpng16 -I/usr/local/Cellar/glib/2.52.3/include/glib-2.0 -I/usr/local/Cellar/glib/2.52.3/lib/glib-2.0/include -I/usr/local/opt/gettext/include -I/usr/local/Cellar/pcre/8.41/include -I. -DHAVE_UINTPTR_T -I/usr/... <truncated>
Rgtk.c:7:10: fatal error: 'gdk/gdkx.h' file not found
#include <gdk/gdkx.h>
^
1 error generated.
make: *** [Rgtk.o] Error 1
ERROR: compilation failed for package ‘RGtk2’
* removing ‘/Library/Frameworks/R.framework/Versions/3.4/Resources/library/RGtk2’
Warning in install.packages :
installation of package ‘RGtk2’ had non-zero exit status
The downloaded source packages are in
‘/private/var/folders/gz/hgc4y87s16gcg7q7b6fgq1hc0000gn/T/RtmpXbOVK8/downloaded_packages’
How do i update GTK from 2.24 to 2.8? Homebrew apparently always installs 2.24.
Also, should I install 2.8 or any version above it should work? Usually updated is better - in consumer stuff at least.
Is there a simple guideline for users not very accustomed to terminal on how to do this? I found https://www.hardcoded.net/devlogs/20120426 but simple copy pasting does not work and I'm not comfortable messing around with stuff like this in terminal.

Resources