brew update
brew upgrade
brew install Caskroom/cask/xquartz
logout/login
brew tap homebrew/science
install R 3.3.3 from CPAN
brew install Caskroom/cask/rstudio
GTK 2.24.30
brew install gtk+
[possibly not needed]export PATH=/opt/local/bin:/opt/local/sbin:$PATH
brew install cairo
add in ~/.shrc: export LANG=en_US.UTF-8 export LC_ALL=en_US.UTF-8 export PKG_CONFIG_PATH=/opt/X11/lib/pkgconfig:$PKG_CONFIG_PATH
Good sign
pkg-config --cflags gtk+-2.0
shows a list of folders
install binary rgtk2 in R
install.packages("RGtk2", dependencies = T, type = 'mac.binary.mavericks')
++++ 3.4.0 didn’t work (doesnt have binary) install.packages("RGtk2", dependencies = T, type = “source” ) throws error about gtk.h maybe try http://stackoverflow.com/questions/22953206/gulp-issues-with-cario-install-command-not-found-when-trying-to-installing-canva/23988317#23988317 add export PKG_CONFIG_PATH=/opt/X11/lib/pkgconfig
links https://gist.github.com/sebkopf/9405675 Homebrew/legacy-homebrew#13546