* installing *source* package ‘twingp’ ... ** package ‘twingp’ successfully unpacked and MD5 sums checked ** using staged installation ** libs using C++ compiler: ‘Apple clang version 14.0.3 (clang-1403.0.22.14.1)’ using SDK: ‘MacOSX13.3.sdk’ clang++ -std=gnu++17 -I"/Users/ripley/R/R-devel/include" -DNDEBUG -I../inst/include/ -I'/Users/ripley/R/Library/Rcpp/include' -I'/Users/ripley/R/Library/nloptr/include' -isystem /opt/R/arm64/include -DEIGEN_MPL2_ONLY -fPIC -g -O2 -Wall -pedantic -Wconversion -Wno-sign-conversion -c RcppExports.cpp -o RcppExports.o clang++ -std=gnu++17 -I"/Users/ripley/R/R-devel/include" -DNDEBUG -I../inst/include/ -I'/Users/ripley/R/Library/Rcpp/include' -I'/Users/ripley/R/Library/nloptr/include' -isystem /opt/R/arm64/include -DEIGEN_MPL2_ONLY -fPIC -g -O2 -Wall -pedantic -Wconversion -Wno-sign-conversion -c glgp.cpp -o glgp.o In file included from glgp.cpp:9: ../inst/include/nanoflann.hpp:680:51: warning: implicit conversion loses integer precision: 'unsigned long' to 'const nanoflann::PooledAllocator::Size' (aka 'const unsigned int') [-Wshorten-64-to-32] const Size size = (req_size + (WORDSIZE - 1)) & ~(WORDSIZE - 1); ~~~~ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~ glgp.cpp:101:28: warning: implicit conversion loses integer precision: 'std::size_t' (aka 'unsigned long') to 'int' [-Wshorten-64-to-32] tree_ = new kdTree(dim_, xy_, nanoflann::KDTreeSingleIndexAdaptorParams(leaf_size_)); ~~~~~~ ^~~~ glgp.cpp:257:20: warning: implicit conversion turns floating-point number into integer: 'const double' to 'int' [-Wfloat-conversion] int max_eval = std::min(500.0, 100.0 * std::log(1.0 + dim_)); ~~~~~~~~ ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ glgp.cpp:230:34: warning: implicit conversion loses integer precision: 'unsigned long' to 'int' [-Wshorten-64-to-32] int opt_dim = nugget_ ? dim_ + 2 : dim_ + 1; ~~~~~~~ ~~~~~^~~ glgp.cpp:230:45: warning: implicit conversion loses integer precision: 'unsigned long' to 'int' [-Wshorten-64-to-32] int opt_dim = nugget_ ? dim_ + 2 : dim_ + 1; ~~~~~~~ ~~~~~^~~ glgp.cpp:252:78: warning: implicit conversion loses integer precision: 'decltype(__x.base() - __y.base())' (aka 'long') to 'int' [-Wshorten-64-to-32] int min_index = std::min_element(nllg_values.begin(), nllg_values.end()) - nllg_values.begin(); ~~~~~~~~~ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~ clang++ -std=gnu++17 -I"/Users/ripley/R/R-devel/include" -DNDEBUG -I../inst/include/ -I'/Users/ripley/R/Library/Rcpp/include' -I'/Users/ripley/R/Library/nloptr/include' -isystem /opt/R/arm64/include -DEIGEN_MPL2_ONLY -fPIC -g -O2 -Wall -pedantic -Wconversion -Wno-sign-conversion -c twinning.cpp -o twinning.o In file included from glgp.cpp:4: In file included from /Users/ripley/R/Library/Rcpp/include/Rcpp.h:40: In file included from /Users/ripley/R/Library/Rcpp/include/Rcpp/Vector.h:58: /Users/ripley/R/Library/Rcpp/include/Rcpp/vector/Matrix.h:138:76: warning: implicit conversion loses integer precision: 'const size_t' (aka 'const unsigned long') to 'int' [-Wshorten-64-to-32] return static_cast< Vector* >( this )->operator[]( offset( i, j ) ) ; ~~~~~~ ^ glgp.cpp:28:69: note: in instantiation of member function 'Rcpp::Matrix<14>::operator()' requested here const double* get_row(const std::size_t idx) const { return &(*df_)(0, idx); } ^ In file included from glgp.cpp:4: In file included from /Users/ripley/R/Library/Rcpp/include/Rcpp.h:40: In file included from /Users/ripley/R/Library/Rcpp/include/Rcpp/Vector.h:58: /Users/ripley/R/Library/Rcpp/include/Rcpp/vector/Matrix.h:138:73: warning: implicit conversion loses integer precision: 'const size_t' (aka 'const unsigned long') to 'int' [-Wshorten-64-to-32] return static_cast< Vector* >( this )->operator[]( offset( i, j ) ) ; ~~~~~~ ^ In file included from glgp.cpp:9: ../inst/include/nanoflann.hpp:1941:33: warning: implicit conversion loses integer precision: 'unsigned long' to 'std::vector::value_type' (aka 'unsigned int') [-Wshorten-64-to-32] index[pos].vAcc.push_back(idx); ~~~~~~~~~ ^~~ ../inst/include/nanoflann.hpp:1915:7: note: in instantiation of member function 'nanoflann::KDTreeSingleIndexDynamicAdaptor, DF, -1, unsigned long>::addPoints' requested here addPoints(0, num_initial_points - 1); ^ glgp.cpp:101:21: note: in instantiation of member function 'nanoflann::KDTreeSingleIndexDynamicAdaptor, DF, -1, unsigned long>::KDTreeSingleIndexDynamicAdaptor' requested here tree_ = new kdTree(dim_, xy_, nanoflann::KDTreeSingleIndexAdaptorParams(leaf_size_)); ^ In file included from twinning.cpp:9: ../inst/include/nanoflann.hpp:680:51: warning: implicit conversion loses integer precision: 'unsigned long' to 'const nanoflann::PooledAllocator::Size' (aka 'const unsigned int') [-Wshorten-64-to-32] const Size size = (req_size + (WORDSIZE - 1)) & ~(WORDSIZE - 1); ~~~~ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~ twinning.cpp:74:25: warning: implicit conversion loses integer precision: 'const std::size_t' (aka 'const unsigned long') to 'int' [-Wshorten-64-to-32] kdTree tree(dim_, data_, nanoflann::KDTreeSingleIndexAdaptorParams(leaf_size_)); ~~~~ ^~~~ twinning.cpp:129:76: warning: implicit conversion loses integer precision: 'decltype(__x.base() - __y.base())' (aka 'long') to 'int' [-Wshorten-64-to-32] int max_index = std::max_element(min_dist.begin(), min_dist.end()) - min_dist.begin(); ~~~~~~~~~ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~ twinning.cpp:159:53: warning: implicit conversion turns floating-point number into integer: 'double' to 'std::size_t' (aka 'unsigned long') [-Wfloat-conversion] std::size_t q01 = (N_ - twinIndices.size()) * 0.01; ~~~ ~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~ twinning.cpp:140:26: warning: implicit conversion loses integer precision: 'unsigned long' to 'int' [-Wshorten-64-to-32] kdTree tree(dim_ - 1, data_, nanoflann::KDTreeSingleIndexAdaptorParams(leaf_size_)); ~~~~ ~~~~~^~~ twinning.cpp:165:21: warning: implicit conversion loses integer precision: 'const std::size_t' (aka 'const unsigned long') to 'int' [-Wshorten-64-to-32] kdTree tree(dim_, data_, nanoflann::KDTreeSingleIndexAdaptorParams(leaf_size_)); ~~~~ ^~~~ In file included from twinning.cpp:4: In file included from /Users/ripley/R/Library/Rcpp/include/Rcpp.h:40: In file included from /Users/ripley/R/Library/Rcpp/include/Rcpp/Vector.h:58: /Users/ripley/R/Library/Rcpp/include/Rcpp/vector/Matrix.h:138:76: warning: implicit conversion loses integer precision: 'const size_t' (aka 'const unsigned long') to 'int' [-Wshorten-64-to-32] return static_cast< Vector* >( this )->operator[]( offset( i, j ) ) ; ~~~~~~ ^ twinning.cpp:24:100: note: in instantiation of member function 'Rcpp::Matrix<14>::operator()' requested here double kdtree_get_pt(const std::size_t idx, const std::size_t dim) const { return subset_ ? (*df_)(dim, indices_->at(idx)) : (*df_)(dim, idx); } ^ In file included from twinning.cpp:4: In file included from /Users/ripley/R/Library/Rcpp/include/Rcpp.h:40: In file included from /Users/ripley/R/Library/Rcpp/include/Rcpp/Vector.h:58: /Users/ripley/R/Library/Rcpp/include/Rcpp/vector/Matrix.h:138:73: warning: implicit conversion loses integer precision: 'const size_t' (aka 'const unsigned long') to 'int' [-Wshorten-64-to-32] return static_cast< Vector* >( this )->operator[]( offset( i, j ) ) ; ~~~~~~ ^ In file included from twinning.cpp:9: ../inst/include/nanoflann.hpp:1941:33: warning: implicit conversion loses integer precision: 'unsigned long' to 'std::vector::value_type' (aka 'unsigned int') [-Wshorten-64-to-32] index[pos].vAcc.push_back(idx); ~~~~~~~~~ ^~~ ../inst/include/nanoflann.hpp:1915:7: note: in instantiation of member function 'nanoflann::KDTreeSingleIndexDynamicAdaptor, DF2, -1, unsigned long>::addPoints' requested here addPoints(0, num_initial_points - 1); ^ twinning.cpp:74:20: note: in instantiation of member function 'nanoflann::KDTreeSingleIndexDynamicAdaptor, DF2, -1, unsigned long>::KDTreeSingleIndexDynamicAdaptor' requested here kdTree tree(dim_, data_, nanoflann::KDTreeSingleIndexAdaptorParams(leaf_size_)); ^ 9 warnings generated. 9 warnings generated. clang++ -std=gnu++17 -dynamiclib -Wl,-headerpad_max_install_names -undefined dynamic_lookup -single_module -multiply_defined suppress -L/Users/ripley/R/R-devel/lib -L/opt/R/arm64/lib -o twingp.so RcppExports.o glgp.o twinning.o -L/Users/ripley/R/R-devel/lib -lRlapack -L/Users/ripley/R/R-devel/lib -lRblas -L/opt/gfortran/lib/gcc/aarch64-apple-darwin20.0/12.2.0 -L/opt/gfortran/lib -lgfortran -lemutls_w -lquadmath -llapacke -L/Users/ripley/R/R-devel/lib -lR -Wl,-framework -Wl,CoreFoundation ld: library not found for -llapacke clang: error: linker command failed with exit code 1 (use -v to see invocation) make[1]: *** [twingp.so] Error 1 make[1]: Target `all' not remade because of errors. ERROR: compilation failed for package ‘twingp’ * removing ‘/Users/ripley/R/packages/tests-devel/twingp.Rcheck/twingp’