Giter Site home page Giter Site logo

Comments (6)

gtonkinhill avatar gtonkinhill commented on June 21, 2024

Hi, apologies for the slow response. It might be worth trying to reinstall Rcpp using install.packages('Rcpp') before installing fastbaps. This issue can sometimes also be fixed by restarting R.

from fastbaps.

jhawkey avatar jhawkey commented on June 21, 2024

Hi, I am also having this issue with the conda install (Mac OS 10.15.4). I have tried to reinstall Rcpp as suggested, but got the following error:

ld: unknown option: -platform_version
clang-10: error: linker command failed with exit code 1 (use -v to see invocation)
make: *** [/Users/jane/miniconda3/envs/fastbaps/lib/R/share/make/shlib.mk:6: Rcpp.dylib] Error 1
ERROR: compilation failed for package ‘Rcpp’
* removing ‘/Users/jane/miniconda3/envs/fastbaps/lib/R/library/Rcpp’
* restoring previous ‘/Users/jane/miniconda3/envs/fastbaps/lib/R/library/Rcpp’

I also tried restarting R but haven't had any luck unfortunately.

I get the same error when attempting to use the run_fastbaps command line tool.

Any help would be greatly appreciated!

from fastbaps.

gtonkinhill avatar gtonkinhill commented on June 21, 2024

Thanks for flagging this. It looks like something strange is going on with the way conda is handling the c++ dependencies. I will try and take a look in the next day or so. The run_fastbaps command relies on the main library being installed so wont work if that has failed.

Conda and R are often a bit tricky as sometimes local R versions can interfere. Are you able to install the program without conda using devtools::install_github("gtonkinhill/fastbaps") ?

from fastbaps.

jhawkey avatar jhawkey commented on June 21, 2024

Unfortunately I wasn't able to install in R either. I tried the install in a new packrat project to ensure I wasn't getting conflicts with other R packages that I have installed. I also had a look at the other issues raised with installs in R, and attempted to fix it by running

install.packages("Rcpp")
install.packages("RcppArmadillo")

as mentioned in #9, but that didn't help either unfortunately. I also tried the xcode command listed at the bottom of that issue, but my xcode is up to date (according to xcode).

The errors I was getting were different to those in #9, I have reproduced the compilation output in full below.

> devtools::install_github("gtonkinhill/fastbaps")
Downloading GitHub repo gtonkinhill/fastbaps@master
✓  checking for file ‘/private/var/folders/_w/q60cr5_n3ts6561n1dpl_pvw0000gn/T/RtmpNCSCk9/remotes753c509a0346/gtonkinhill-fastbaps-4b70f3f/DESCRIPTION’ ...
─  preparing ‘fastbaps’:
✓  checking DESCRIPTION meta-information ...
─  cleaning src
─  checking for LF line-endings in source and make files and shell scripts
─  checking for empty or unneeded directories
─  building ‘fastbaps_1.0.0.tar.gz’
   
Installing package into ‘/Users/jane/Dropbox/ShigellaSonneiGenotyping/paper/fastbaps_analysis/packrat/lib/x86_64-apple-darwin15.6.0/3.5.3’
(as ‘lib’ is unspecified)
* installing *source* package ‘fastbaps’ ...
** libs
clang++ -std=gnu++11 -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG  -I"/Users/jane/Dropbox/ShigellaSonneiGenotyping/paper/fastbaps_analysis/packrat/lib/x86_64-apple-darwin15.6.0/3.5.3/Rcpp/include" -I"/Users/jane/Dropbox/ShigellaSonneiGenotyping/paper/fastbaps_analysis/packrat/lib/x86_64-apple-darwin15.6.0/3.5.3/RcppArmadillo/include" -I/usr/local/include  -DARMA_64BIT_WORD -fPIC  -Wall -g -O2 -c RcppExports.cpp -o RcppExports.o
clang++ -std=gnu++11 -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG  -I"/Users/jane/Dropbox/ShigellaSonneiGenotyping/paper/fastbaps_analysis/packrat/lib/x86_64-apple-darwin15.6.0/3.5.3/Rcpp/include" -I"/Users/jane/Dropbox/ShigellaSonneiGenotyping/paper/fastbaps_analysis/packrat/lib/x86_64-apple-darwin15.6.0/3.5.3/RcppArmadillo/include" -I/usr/local/include  -DARMA_64BIT_WORD -fPIC  -Wall -g -O2 -c bhier.cpp -o bhier.o
clang++ -std=gnu++11 -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG  -I"/Users/jane/Dropbox/ShigellaSonneiGenotyping/paper/fastbaps_analysis/packrat/lib/x86_64-apple-darwin15.6.0/3.5.3/Rcpp/include" -I"/Users/jane/Dropbox/ShigellaSonneiGenotyping/paper/fastbaps_analysis/packrat/lib/x86_64-apple-darwin15.6.0/3.5.3/RcppArmadillo/include" -I/usr/local/include  -DARMA_64BIT_WORD -fPIC  -Wall -g -O2 -c bhier_parallel.cpp -o bhier_parallel.o
bhier_parallel.cpp:35:22: warning: unused variable 'p1' [-Wunused-variable]
  unsigned int i,j,p,p1,p2;
                     ^
bhier_parallel.cpp:35:25: warning: unused variable 'p2' [-Wunused-variable]
  unsigned int i,j,p,p1,p2;
                        ^
2 warnings generated.
clang++ -std=gnu++11 -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG  -I"/Users/jane/Dropbox/ShigellaSonneiGenotyping/paper/fastbaps_analysis/packrat/lib/x86_64-apple-darwin15.6.0/3.5.3/Rcpp/include" -I"/Users/jane/Dropbox/ShigellaSonneiGenotyping/paper/fastbaps_analysis/packrat/lib/x86_64-apple-darwin15.6.0/3.5.3/RcppArmadillo/include" -I/usr/local/include  -DARMA_64BIT_WORD -fPIC  -Wall -g -O2 -c calc_ddk.cpp -o calc_ddk.o
calc_ddk.cpp:19:7: warning: unused variable 'n_snps' [-Wunused-variable]
  int n_snps = snp_matrix.n_rows;
      ^
calc_ddk.cpp:22:18: warning: unused variable 'j' [-Wunused-variable]
  unsigned int i,j,m,partition_length,left,right;
                 ^
calc_ddk.cpp:22:22: warning: unused variable 'partition_length' [-Wunused-variable]
  unsigned int i,j,m,partition_length,left,right;
                     ^
calc_ddk.cpp:23:7: warning: unused variable 'count' [-Wunused-variable]
  int count = 0;
      ^
4 warnings generated.
clang++ -std=gnu++11 -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG  -I"/Users/jane/Dropbox/ShigellaSonneiGenotyping/paper/fastbaps_analysis/packrat/lib/x86_64-apple-darwin15.6.0/3.5.3/Rcpp/include" -I"/Users/jane/Dropbox/ShigellaSonneiGenotyping/paper/fastbaps_analysis/packrat/lib/x86_64-apple-darwin15.6.0/3.5.3/RcppArmadillo/include" -I/usr/local/include  -DARMA_64BIT_WORD -fPIC  -Wall -g -O2 -c import_fasta_to_vector_each_nt.cpp -o import_fasta_to_vector_each_nt.o
In file included from import_fasta_to_vector_each_nt.cpp:6:
In file included from /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/zlib.h:34:
In file included from /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/zconf.h:462:
In file included from /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/unistd.h:655:
/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/gethostuuid.h:39:17: error: C++ requires a type specifier for all declarations
int gethostuuid(uuid_t, const struct timespec *) __OSX_AVAILABLE_STARTING(__MAC_10_5, __IPHONE_NA);
                ^
In file included from import_fasta_to_vector_each_nt.cpp:6:
In file included from /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/zlib.h:34:
In file included from /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/zconf.h:462:
/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/unistd.h:662:27: error: unknown type name 'uuid_t'; did you mean 'uid_t'?
int      getsgroups_np(int *, uuid_t);
                              ^
/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/_types/_uid_t.h:31:31: note: 'uid_t' declared here
typedef __darwin_uid_t        uid_t;
                              ^
In file included from import_fasta_to_vector_each_nt.cpp:6:
In file included from /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/zlib.h:34:
In file included from /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/zconf.h:462:
/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/unistd.h:664:27: error: unknown type name 'uuid_t'; did you mean 'uid_t'?
int      getwgroups_np(int *, uuid_t);
                              ^
/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/_types/_uid_t.h:31:31: note: 'uid_t' declared here
typedef __darwin_uid_t        uid_t;
                              ^
In file included from import_fasta_to_vector_each_nt.cpp:6:
In file included from /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/zlib.h:34:
In file included from /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/zconf.h:462:
/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/unistd.h:727:31: error: unknown type name 'uuid_t'; did you mean 'uid_t'?
int      setsgroups_np(int, const uuid_t);
                                  ^
/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/_types/_uid_t.h:31:31: note: 'uid_t' declared here
typedef __darwin_uid_t        uid_t;
                              ^
In file included from import_fasta_to_vector_each_nt.cpp:6:
In file included from /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/zlib.h:34:
In file included from /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/zconf.h:462:
/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/unistd.h:729:31: error: unknown type name 'uuid_t'; did you mean 'uid_t'?
int      setwgroups_np(int, const uuid_t);
                                  ^
/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/_types/_uid_t.h:31:31: note: 'uid_t' declared here
typedef __darwin_uid_t        uid_t;
                              ^
5 errors generated.
make: *** [import_fasta_to_vector_each_nt.o] Error 1
ERROR: compilation failed for package ‘fastbaps’
* removing ‘/Users/jane/Dropbox/ShigellaSonneiGenotyping/paper/fastbaps_analysis/packrat/lib/x86_64-apple-darwin15.6.0/3.5.3/fastbaps’
Error: Failed to install 'fastbaps' from GitHub:
  (converted from warning) installation of package ‘/var/folders/_w/q60cr5_n3ts6561n1dpl_pvw0000gn/T//RtmpNCSCk9/file753c69e3d3cc/fastbaps_1.0.0.tar.gz’ had non-zero exit status

from fastbaps.

gtonkinhill avatar gtonkinhill commented on June 21, 2024

Ah I think I may have run into this previously. It was a mac specific issue with Rcpp and was possible to fix by installing the dev version of Rcpp as suggested here. However, I think a new release of Rcpp was created 2 days ago which may include the fix. Are you able to try updating Rcpp using devtools::install_github("RcppCore/Rcpp")

I am still looking into what might be going on with the conda version.

from fastbaps.

jhawkey avatar jhawkey commented on June 21, 2024

Ah excellent! That appears to have solved my problem. Thank you!

from fastbaps.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.