Closed igordot closed 9 years ago
Your problem is not relevant to the SNPRelate package itself, and the library gfortran
is the default library the R system uses.
Reinstalling R with the latest version should be able to solve your problem.
I have a fresh install of R.
I have never had the directory /usr/local/lib/gcc/i686-apple-darwin8/4.2.3. I think it's very odd that it is coming up.
I have met the same problem with the installation of SNPrelate, with exactly the same error messages. see:
ERROR: package installation failed Erreur : Command failed (1)
It is a Mac book, with Mac OS10.95, and R3.03.
gfortran
has to be installed in your Apple system (http://hpc.sourceforge.net).
Dear Xiuwen Thank you for your answer. Installing gfortran was not enough. There is a path issue in the R framework (/Library/Frameworks/R.framework/Resources/etc/Makeconf): this line: FLIBS = -L/usr/local/lib/gcc/i686-apple-darwin8/4.2.3/x86_64 -L/usr/local/lib/x86_64 -L/usr/local/lib/gcc/i686-apple-darwin8/4.2.3 -lgfortran
has to be changed to FLIBS = -L/usr/local/lib/gcc/i686-apple-darwin8/4.2.3/x86_64 -L/usr/local/lib/x86_64 -L/usr/local/lib/gcc/i686-apple-darwin8/4.2.3 -L/usr/local/lib/x86_64-apple-darwin13.1.0/4.9.0 -lgfortran
in order to update the version of darwin. In fact I should have removed ancient version which are not found on the computer.
I managed to compile from Gihub, after these change, and got a package. However when using SNPRelate I got error messages (may be gdsfmt?). Meanwhile, thanks to snphylo website, from I realized that I had not witen the proper interaction for installing the package so that with “source “ option it worked. I also ad to downgrade the version of gdsfmt.
Now it works. Thank you for all. Best.
JL
Le 21 sept. 2014 à 01:27, Xiuwen Zheng notifications@github.com a écrit :
gfortran has to be installed in your Apple system (http://hpc.sourceforge.net).
— Reply to this email directly or view it on GitHub.
If you get an error like:
> library(SNPRelate)
Error : .onAttach failed in attachNamespace() for 'SNPRelate', details:
call: fun(libname, pkgname)
error: function 'GDS_Mach_GetNumOfCPU' not provided by package 'gdsfmt'
Error: package or namespace load failed for ‘SNPRelate’
Please reinstall the SNPRelate package (v0.99.2) from Bioconductor.
I have also struggled with this same error: Solved my compiling issues by replacing the line in (/Library/Frameworks/R.framework/Resources/etc/Makeconf): FLIBS = -L/usr/local/lib/gcc/i686-apple-darwin8/4.2.3/x86_64 -L/usr/local/lib/x86_64 -L/usr/local/lib/gcc/i686-apple-darwin8/4.2.3 -lgfortran
with this line: FLIBS = -L/usr/local/lib/gcc/x86_64-apple-darwin13.4.0/4.9.2/ -lgfortran
I am trying to install SNPRelate on a Mac using:
install_github("zhengxwen/SNPRelate")
I was able to install gdsfmt just fine this way. However, with SNPRelate, I get the following error:It appears that the problem is with locating the gfortran shared library (libgfortran.a). I have the library. I am not sure why it was not found (maybe it's due to the fact that it was installed using Homebrew). After I copied libgfortran.a to /usr/local/lib, the installation was able to complete successfully.
I am not sure why the installer is looking for those three directories that generate the warnings. I don't have any of them. Instead of /usr/local/lib/gcc/i686-apple-darwin8/4.2.3, I have /usr/local/lib/gcc/i686-apple-darwin11/4.2.1 where libgfortran.a is located. The installer has the right general idea, but I don't knew where it's getting the darwin8 directory (corresponds to Mac OS X 10.4, so this seems to be some legacy issue). I couldn't find any references to those directories in the source files.
I don't know if this is an easy fix, but certainly something to look into.