ropensci / MODIStsp

An "R" package for automatic download and preprocessing of MODIS Land Products Time Series
https://docs.ropensci.org/MODIStsp
GNU General Public License v3.0
155 stars 51 forks source link

Not able to install package on Ubuntu and MacOS #194

Closed lorenzoFabbri closed 4 years ago

lorenzoFabbri commented 4 years ago

I need this package to create a dataset of training images for a Deep Learning applications. I tried to install it both on MacOS and Ubuntu, but without success.

On Ubuntu I installed R 3.6.3 (fresh install) and then I proceeded following the instructions on the website:

sudo apt-get install r-cran-cairodevice r-cran-rgtk2 libcairo2-dev libatk1.0-dev libpango1.0-dev 
libgtk2.0-dev libglib2.0-dev libcurl4-openssl-dev libgdal-dev libproj-dev

Nonetheless I keep receiving the following error:

ibatk1.0-dev libpango1.0-dev 
[sudo] password for lorenzo: 
Reading package lists... Done
Building dependency tree       
Reading state information... Done
libatk1.0-dev is already the newest version (2.28.1-1).
libcairo2-dev is already the newest version (1.15.10-2ubuntu0.1).
libpango1.0-dev is already the newest version (1.40.14-1ubuntu0.1).
Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help to resolve the situation:

The following packages have unmet dependencies:
 r-cran-cairodevice : Depends: r-api-3.4
 r-cran-rgtk2 : Depends: r-api-3.4
E: Unable to correct problems, you have held broken packages.

But if I use R version 3.4, I receive an error saying that I need a newer version of R to install this package. What am I missing? Thank you.

lorenzoFabbri commented 4 years ago

I think that by running the following code I can install this package on Ubuntu 18.04:

sudo add-apt-repository ppa:marutter/c2d4u3.5
sudo apt-get update

Although I had to manually install several packages with apt-get install.

lbusett commented 4 years ago

Hi,

first of all, could you try installing packages "cairoDevice" and "rgtk2" from CRAN?

install.packages("cairoDevice")
install.packages("RGtk2")

I do not really remember why I had those packages in the apt-get instruction... and then proceed with standard MODIStsp installation?