Closed sagar-m closed 6 years ago
> install.packages("udunits2")
trying URL 'https://cran.rstudio.com/src/contrib/udunits2_0.13.tar.gz'
Content type 'application/x-gzip' length 67182 bytes (65 KB)
==================================================
downloaded 65 KB
* installing *source* package ‘udunits2’ ...
** package ‘udunits2’ 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 for XML_ParserCreate in -lexpat... 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... 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 udunits2.h usability... no
checking udunits2.h presence... no
checking for udunits2.h... no
checking for ut_read_xml in -ludunits2... no
-----Error: libudunits2.a not found-----
If the udunits2 library is installed in a non-standard location,
use --configure-args='--with-udunits2-lib=/usr/local/lib' for example,
or --configure-args='--with-udunits2-include=/usr/include/udunits2'
replacing paths with appropriate values for your installation.
You can alternatively use the UDUNITS2_INCLUDE and UDUNITS2_LIB
environment variables.
If udunits2 is not installed, please install it.
It is required for this package.
ERROR: configuration failed for package ‘udunits2’
* removing ‘/Users/sherrymukim/anaconda3/lib/R/library/udunits2’
Warning in install.packages :
installation of package ‘udunits2’ had non-zero exit status
The downloaded source packages are in
‘/private/var/folders/p9/6qp4xp2536jdmxd8qkzkhp7m0000gn/T/RtmpENRNpn/downloaded_packages’
Updating HTML index of packages in '.Library'
Making 'packages.html' ... done
sudo apt-get install libudunits2-dev
as suggested in this link (stackoverflow.com/questions/42287164/…) does not work on mac.
Yes, you're on a mac, so you need to use the mac package management for installing system requirements.
I don't use mac and so can't help you much, but try: brew install udunits
and described by many people here.
update: this link has a solution that worked for me. I was able to install "udunits2", and "units". However, they do not mention "ClassInt" and it is throwing an error. I have Xcode installed on my mac. And also gcc is installed through brew. I will ask them, probably. Thank you.
Hi, I noticed that I have x86_64-apple-darwin15.5.0-gfortran but not x86_64-apple-darwin13.4.0-gfortran which is needed to install "ClassInt" package in R 3.4.2 on mac os 10.13.2. Any suggestions?
Hi, I am not able to install udunits2 package for R. "sudo apt-get install libudunits2-dev" as suggested in this link (stackoverflow.com/questions/42287164/…) does not work on mac. And none of the other comments worked.
Ultimate goal is to install “sf” in R; the error I get: …anaconda3/bin/x86_64-apple-darwin13.4.0-gfortran: No such file or directory. I think the dependency is on ‘units’, and ‘classInt’, which depend upon udunits2. Any help would be deeply appreciated. Have been struggling for last 1 day. Link.