juliuspfadt / bayesrel Goto Github PK
View Code? Open in Web Editor NEWR-Package "Bayesrel" provides both Bayesian and frequentist reliability estimates
R-Package "Bayesrel" provides both Bayesian and frequentist reliability estimates
Either ranlib should be used or right flags set, otherwise the static lib is broken:
---> Extracting Bayesrel_0.7.7.tar.gz
Executing: cd "/opt/local/var/macports/build/_opt_PPCSnowLeopardPorts_R_R-Bayesrel/R-Bayesrel/work" && /usr/bin/gzip -dc '/opt/local/var/macports/distfiles/R-Bayesrel/Bayesrel_0.7.7.tar.gz' | /usr/bin/gnutar --no-same-owner -xf -
---> Configuring R-Bayesrel
Executing: cd "/opt/local/var/macports/build/_opt_PPCSnowLeopardPorts_R_R-Bayesrel/R-Bayesrel/work/Bayesrel" && /opt/local/bin/R CMD build . --no-manual --no-build-vignettes
* checking for file ‘./DESCRIPTION’ ... OK
* preparing ‘Bayesrel’:
* checking DESCRIPTION meta-information ... OK
* cleaning src
* running ‘cleanup’
* installing the package to process help pages
-----------------------------------
* installing *source* package ‘Bayesrel’ ...
file ‘build/partial.rdb’ is missing
** using staged installation
Using bundled CSDP
checking for gcc... /opt/local/bin/gcc-mp-12
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 /opt/local/bin/gcc-mp-12 accepts -g... yes
checking for /opt/local/bin/gcc-mp-12 option to accept ISO C89... none needed
checking how to run the C preprocessor... /opt/local/bin/gcc-mp-12 -E
checking whether we are using the GNU C++ compiler... yes
checking whether /opt/local/bin/g++-mp-12 -std=gnu++17 accepts -g... yes
checking how to run the C++ preprocessor... /opt/local/bin/g++-mp-12 -std=gnu++17 -E
checking whether we are using the GNU C++ compiler... (cached) yes
checking whether /opt/local/bin/g++-mp-12 -std=gnu++17 accepts -g... (cached) yes
configure: creating ./config.status
config.status: creating src/Makevars
** libs
using C++ compiler: ‘g++-mp-12 (MacPorts gcc12 12.3.0_0) 12.3.0’
Warning in system2("xcrun", "--show-sdk-path", TRUE, TRUE) :
running command ''xcrun' --show-sdk-path 2>&1' had status 64
using SDK: ‘NA’‘NA’‘NA’‘NA’‘NA’‘NA’
/opt/local/bin/g++-mp-12 -std=gnu++17 -I"/opt/local/Library/Frameworks/R.framework/Resources/include" -DNDEBUG -ICsdp/include -DNOSHORTS -DARMA_NO_DEBUG=1 -DARMA_DONT_USE_FORTRAN_HIDDEN_ARGS -I'/opt/local/Library/Frameworks/R.framework/Versions/4.3/Resources/library/Rcpp/include' -I'/opt/local/Library/Frameworks/R.framework/Versions/4.3/Resources/library/RcppArmadillo/include' -isystem/opt/local/include/LegacySupport -I/opt/local/include -fPIC -pipe -Os -arch ppc -c BayesrelCpp.cpp -o BayesrelCpp.o
/opt/local/bin/g++-mp-12 -std=gnu++17 -I"/opt/local/Library/Frameworks/R.framework/Resources/include" -DNDEBUG -ICsdp/include -DNOSHORTS -DARMA_NO_DEBUG=1 -DARMA_DONT_USE_FORTRAN_HIDDEN_ARGS -I'/opt/local/Library/Frameworks/R.framework/Versions/4.3/Resources/library/Rcpp/include' -I'/opt/local/Library/Frameworks/R.framework/Versions/4.3/Resources/library/RcppArmadillo/include' -isystem/opt/local/include/LegacySupport -I/opt/local/include -fPIC -pipe -Os -arch ppc -c LowBoundsCpp.cpp -o LowBoundsCpp.o
/opt/local/bin/g++-mp-12 -std=gnu++17 -I"/opt/local/Library/Frameworks/R.framework/Resources/include" -DNDEBUG -ICsdp/include -DNOSHORTS -DARMA_NO_DEBUG=1 -DARMA_DONT_USE_FORTRAN_HIDDEN_ARGS -I'/opt/local/Library/Frameworks/R.framework/Versions/4.3/Resources/library/Rcpp/include' -I'/opt/local/Library/Frameworks/R.framework/Versions/4.3/Resources/library/RcppArmadillo/include' -isystem/opt/local/include/LegacySupport -I/opt/local/include -fPIC -pipe -Os -arch ppc -c RcppExports.cpp -o RcppExports.o
/opt/local/bin/g++-mp-12 -std=gnu++17 -I"/opt/local/Library/Frameworks/R.framework/Resources/include" -DNDEBUG -ICsdp/include -DNOSHORTS -DARMA_NO_DEBUG=1 -DARMA_DONT_USE_FORTRAN_HIDDEN_ARGS -I'/opt/local/Library/Frameworks/R.framework/Versions/4.3/Resources/library/Rcpp/include' -I'/opt/local/Library/Frameworks/R.framework/Versions/4.3/Resources/library/RcppArmadillo/include' -isystem/opt/local/include/LegacySupport -I/opt/local/include -fPIC -pipe -Os -arch ppc -c convertCpp.cpp -o convertCpp.o
/opt/local/bin/g++-mp-12 -std=gnu++17 -I"/opt/local/Library/Frameworks/R.framework/Resources/include" -DNDEBUG -ICsdp/include -DNOSHORTS -DARMA_NO_DEBUG=1 -DARMA_DONT_USE_FORTRAN_HIDDEN_ARGS -I'/opt/local/Library/Frameworks/R.framework/Versions/4.3/Resources/library/Rcpp/include' -I'/opt/local/Library/Frameworks/R.framework/Versions/4.3/Resources/library/RcppArmadillo/include' -isystem/opt/local/include/LegacySupport -I/opt/local/include -fPIC -pipe -Os -arch ppc -c customsdpCpp.cpp -o customsdpCpp.o
/opt/local/bin/g++-mp-12 -std=gnu++17 -I"/opt/local/Library/Frameworks/R.framework/Resources/include" -DNDEBUG -ICsdp/include -DNOSHORTS -DARMA_NO_DEBUG=1 -DARMA_DONT_USE_FORTRAN_HIDDEN_ARGS -I'/opt/local/Library/Frameworks/R.framework/Versions/4.3/Resources/library/Rcpp/include' -I'/opt/local/Library/Frameworks/R.framework/Versions/4.3/Resources/library/RcppArmadillo/include' -isystem/opt/local/include/LegacySupport -I/opt/local/include -fPIC -pipe -Os -arch ppc -c initArma.cpp -o initArma.o
/opt/local/bin/g++-mp-12 -std=gnu++17 -I"/opt/local/Library/Frameworks/R.framework/Resources/include" -DNDEBUG -ICsdp/include -DNOSHORTS -DARMA_NO_DEBUG=1 -DARMA_DONT_USE_FORTRAN_HIDDEN_ARGS -I'/opt/local/Library/Frameworks/R.framework/Versions/4.3/Resources/library/Rcpp/include' -I'/opt/local/Library/Frameworks/R.framework/Versions/4.3/Resources/library/RcppArmadillo/include' -isystem/opt/local/include/LegacySupport -I/opt/local/include -fPIC -pipe -Os -arch ppc -c pfaCpp.cpp -o pfaCpp.o
(cd Csdp/lib && \
(make libsdp.a CC="/opt/local/bin/gcc-mp-12" CFLAGS="-DDEFINE_FUNCTIONS_LAPACK_BLAS -I'/opt/local/Library/Frameworks/R.framework/Versions/4.3/Resources/library/Rcpp/include' -I'/opt/local/Library/Frameworks/R.framework/Versions/4.3/Resources/library/RcppArmadillo/include' -pipe -Os -arch ppc -fPIC -DNOSHORTS -I../include" AR="ar" RANLIB="ranlib") && \
touch Csdp.ts)
/opt/local/bin/gcc-mp-12 -DDEFINE_FUNCTIONS_LAPACK_BLAS -I'/opt/local/Library/Frameworks/R.framework/Versions/4.3/Resources/library/Rcpp/include' -I'/opt/local/Library/Frameworks/R.framework/Versions/4.3/Resources/library/RcppArmadillo/include' -pipe -Os -arch ppc -fPIC -DNOSHORTS -I../include -isystem/opt/local/include/LegacySupport -I/opt/local/include -c -o readprob.o readprob.c
/opt/local/bin/gcc-mp-12 -DDEFINE_FUNCTIONS_LAPACK_BLAS -I'/opt/local/Library/Frameworks/R.framework/Versions/4.3/Resources/library/Rcpp/include' -I'/opt/local/Library/Frameworks/R.framework/Versions/4.3/Resources/library/RcppArmadillo/include' -pipe -Os -arch ppc -fPIC -DNOSHORTS -I../include -isystem/opt/local/include/LegacySupport -I/opt/local/include -c -o sdp.o sdp.c
/opt/local/bin/gcc-mp-12 -DDEFINE_FUNCTIONS_LAPACK_BLAS -I'/opt/local/Library/Frameworks/R.framework/Versions/4.3/Resources/library/Rcpp/include' -I'/opt/local/Library/Frameworks/R.framework/Versions/4.3/Resources/library/RcppArmadillo/include' -pipe -Os -arch ppc -fPIC -DNOSHORTS -I../include -isystem/opt/local/include/LegacySupport -I/opt/local/include -c -o op_o.o op_o.c
/opt/local/bin/gcc-mp-12 -DDEFINE_FUNCTIONS_LAPACK_BLAS -I'/opt/local/Library/Frameworks/R.framework/Versions/4.3/Resources/library/Rcpp/include' -I'/opt/local/Library/Frameworks/R.framework/Versions/4.3/Resources/library/RcppArmadillo/include' -pipe -Os -arch ppc -fPIC -DNOSHORTS -I../include -isystem/opt/local/include/LegacySupport -I/opt/local/include -c -o psd_feas.o psd_feas.c
/opt/local/bin/gcc-mp-12 -DDEFINE_FUNCTIONS_LAPACK_BLAS -I'/opt/local/Library/Frameworks/R.framework/Versions/4.3/Resources/library/Rcpp/include' -I'/opt/local/Library/Frameworks/R.framework/Versions/4.3/Resources/library/RcppArmadillo/include' -pipe -Os -arch ppc -fPIC -DNOSHORTS -I../include -isystem/opt/local/include/LegacySupport -I/opt/local/include -c -o op_a.o op_a.c
/opt/local/bin/gcc-mp-12 -DDEFINE_FUNCTIONS_LAPACK_BLAS -I'/opt/local/Library/Frameworks/R.framework/Versions/4.3/Resources/library/Rcpp/include' -I'/opt/local/Library/Frameworks/R.framework/Versions/4.3/Resources/library/RcppArmadillo/include' -pipe -Os -arch ppc -fPIC -DNOSHORTS -I../include -isystem/opt/local/include/LegacySupport -I/opt/local/include -c -o op_at.o op_at.c
/opt/local/bin/gcc-mp-12 -DDEFINE_FUNCTIONS_LAPACK_BLAS -I'/opt/local/Library/Frameworks/R.framework/Versions/4.3/Resources/library/Rcpp/include' -I'/opt/local/Library/Frameworks/R.framework/Versions/4.3/Resources/library/RcppArmadillo/include' -pipe -Os -arch ppc -fPIC -DNOSHORTS -I../include -isystem/opt/local/include/LegacySupport -I/opt/local/include -c -o Fnorm.o Fnorm.c
/opt/local/bin/gcc-mp-12 -DDEFINE_FUNCTIONS_LAPACK_BLAS -I'/opt/local/Library/Frameworks/R.framework/Versions/4.3/Resources/library/Rcpp/include' -I'/opt/local/Library/Frameworks/R.framework/Versions/4.3/Resources/library/RcppArmadillo/include' -pipe -Os -arch ppc -fPIC -DNOSHORTS -I../include -isystem/opt/local/include/LegacySupport -I/opt/local/include -c -o calc_pobj.o calc_pobj.c
/opt/local/bin/gcc-mp-12 -DDEFINE_FUNCTIONS_LAPACK_BLAS -I'/opt/local/Library/Frameworks/R.framework/Versions/4.3/Resources/library/Rcpp/include' -I'/opt/local/Library/Frameworks/R.framework/Versions/4.3/Resources/library/RcppArmadillo/include' -pipe -Os -arch ppc -fPIC -DNOSHORTS -I../include -isystem/opt/local/include/LegacySupport -I/opt/local/include -c -o calc_dobj.o calc_dobj.c
/opt/local/bin/gcc-mp-12 -DDEFINE_FUNCTIONS_LAPACK_BLAS -I'/opt/local/Library/Frameworks/R.framework/Versions/4.3/Resources/library/Rcpp/include' -I'/opt/local/Library/Frameworks/R.framework/Versions/4.3/Resources/library/RcppArmadillo/include' -pipe -Os -arch ppc -fPIC -DNOSHORTS -I../include -isystem/opt/local/include/LegacySupport -I/opt/local/include -c -o trace_prod.o trace_prod.c
/opt/local/bin/gcc-mp-12 -DDEFINE_FUNCTIONS_LAPACK_BLAS -I'/opt/local/Library/Frameworks/R.framework/Versions/4.3/Resources/library/Rcpp/include' -I'/opt/local/Library/Frameworks/R.framework/Versions/4.3/Resources/library/RcppArmadillo/include' -pipe -Os -arch ppc -fPIC -DNOSHORTS -I../include -isystem/opt/local/include/LegacySupport -I/opt/local/include -c -o zero_mat.o zero_mat.c
/opt/local/bin/gcc-mp-12 -DDEFINE_FUNCTIONS_LAPACK_BLAS -I'/opt/local/Library/Frameworks/R.framework/Versions/4.3/Resources/library/Rcpp/include' -I'/opt/local/Library/Frameworks/R.framework/Versions/4.3/Resources/library/RcppArmadillo/include' -pipe -Os -arch ppc -fPIC -DNOSHORTS -I../include -isystem/opt/local/include/LegacySupport -I/opt/local/include -c -o mat_mult.o mat_mult.c
/opt/local/bin/gcc-mp-12 -DDEFINE_FUNCTIONS_LAPACK_BLAS -I'/opt/local/Library/Frameworks/R.framework/Versions/4.3/Resources/library/Rcpp/include' -I'/opt/local/Library/Frameworks/R.framework/Versions/4.3/Resources/library/RcppArmadillo/include' -pipe -Os -arch ppc -fPIC -DNOSHORTS -I../include -isystem/opt/local/include/LegacySupport -I/opt/local/include -c -o sym_mat.o sym_mat.c
/opt/local/bin/gcc-mp-12 -DDEFINE_FUNCTIONS_LAPACK_BLAS -I'/opt/local/Library/Frameworks/R.framework/Versions/4.3/Resources/library/Rcpp/include' -I'/opt/local/Library/Frameworks/R.framework/Versions/4.3/Resources/library/RcppArmadillo/include' -pipe -Os -arch ppc -fPIC -DNOSHORTS -I../include -isystem/opt/local/include/LegacySupport -I/opt/local/include -c -o copy_mat.o copy_mat.c
/opt/local/bin/gcc-mp-12 -DDEFINE_FUNCTIONS_LAPACK_BLAS -I'/opt/local/Library/Frameworks/R.framework/Versions/4.3/Resources/library/Rcpp/include' -I'/opt/local/Library/Frameworks/R.framework/Versions/4.3/Resources/library/RcppArmadillo/include' -pipe -Os -arch ppc -fPIC -DNOSHORTS -I../include -isystem/opt/local/include/LegacySupport -I/opt/local/include -c -o addscaledmat.o addscaledmat.c
/opt/local/bin/gcc-mp-12 -DDEFINE_FUNCTIONS_LAPACK_BLAS -I'/opt/local/Library/Frameworks/R.framework/Versions/4.3/Resources/library/Rcpp/include' -I'/opt/local/Library/Frameworks/R.framework/Versions/4.3/Resources/library/RcppArmadillo/include' -pipe -Os -arch ppc -fPIC -DNOSHORTS -I../include -isystem/opt/local/include/LegacySupport -I/opt/local/include -c -o user_exit.o user_exit.c
/opt/local/bin/gcc-mp-12 -DDEFINE_FUNCTIONS_LAPACK_BLAS -I'/opt/local/Library/Frameworks/R.framework/Versions/4.3/Resources/library/Rcpp/include' -I'/opt/local/Library/Frameworks/R.framework/Versions/4.3/Resources/library/RcppArmadillo/include' -pipe -Os -arch ppc -fPIC -DNOSHORTS -I../include -isystem/opt/local/include/LegacySupport -I/opt/local/include -c -o make_i.o make_i.c
/opt/local/bin/gcc-mp-12 -DDEFINE_FUNCTIONS_LAPACK_BLAS -I'/opt/local/Library/Frameworks/R.framework/Versions/4.3/Resources/library/Rcpp/include' -I'/opt/local/Library/Frameworks/R.framework/Versions/4.3/Resources/library/RcppArmadillo/include' -pipe -Os -arch ppc -fPIC -DNOSHORTS -I../include -isystem/opt/local/include/LegacySupport -I/opt/local/include -c -o allocmat.o allocmat.c
/opt/local/bin/gcc-mp-12 -DDEFINE_FUNCTIONS_LAPACK_BLAS -I'/opt/local/Library/Frameworks/R.framework/Versions/4.3/Resources/library/Rcpp/include' -I'/opt/local/Library/Frameworks/R.framework/Versions/4.3/Resources/library/RcppArmadillo/include' -pipe -Os -arch ppc -fPIC -DNOSHORTS -I../include -isystem/opt/local/include/LegacySupport -I/opt/local/include -c -o initsoln.o initsoln.c
/opt/local/bin/gcc-mp-12 -DDEFINE_FUNCTIONS_LAPACK_BLAS -I'/opt/local/Library/Frameworks/R.framework/Versions/4.3/Resources/library/Rcpp/include' -I'/opt/local/Library/Frameworks/R.framework/Versions/4.3/Resources/library/RcppArmadillo/include' -pipe -Os -arch ppc -fPIC -DNOSHORTS -I../include -isystem/opt/local/include/LegacySupport -I/opt/local/include -c -o initparams.o initparams.c
/opt/local/bin/gcc-mp-12 -DDEFINE_FUNCTIONS_LAPACK_BLAS -I'/opt/local/Library/Frameworks/R.framework/Versions/4.3/Resources/library/Rcpp/include' -I'/opt/local/Library/Frameworks/R.framework/Versions/4.3/Resources/library/RcppArmadillo/include' -pipe -Os -arch ppc -fPIC -DNOSHORTS -I../include -isystem/opt/local/include/LegacySupport -I/opt/local/include -c -o add_mat.o add_mat.c
/opt/local/bin/gcc-mp-12 -DDEFINE_FUNCTIONS_LAPACK_BLAS -I'/opt/local/Library/Frameworks/R.framework/Versions/4.3/Resources/library/Rcpp/include' -I'/opt/local/Library/Frameworks/R.framework/Versions/4.3/Resources/library/RcppArmadillo/include' -pipe -Os -arch ppc -fPIC -DNOSHORTS -I../include -isystem/opt/local/include/LegacySupport -I/opt/local/include -c -o writesol.o writesol.c
/opt/local/bin/gcc-mp-12 -DDEFINE_FUNCTIONS_LAPACK_BLAS -I'/opt/local/Library/Frameworks/R.framework/Versions/4.3/Resources/library/Rcpp/include' -I'/opt/local/Library/Frameworks/R.framework/Versions/4.3/Resources/library/RcppArmadillo/include' -pipe -Os -arch ppc -fPIC -DNOSHORTS -I../include -isystem/opt/local/include/LegacySupport -I/opt/local/include -c -o readsol.o readsol.c
/opt/local/bin/gcc-mp-12 -DDEFINE_FUNCTIONS_LAPACK_BLAS -I'/opt/local/Library/Frameworks/R.framework/Versions/4.3/Resources/library/Rcpp/include' -I'/opt/local/Library/Frameworks/R.framework/Versions/4.3/Resources/library/RcppArmadillo/include' -pipe -Os -arch ppc -fPIC -DNOSHORTS -I../include -isystem/opt/local/include/LegacySupport -I/opt/local/include -c -o easysdp.o easysdp.c
/opt/local/bin/gcc-mp-12 -DDEFINE_FUNCTIONS_LAPACK_BLAS -I'/opt/local/Library/Frameworks/R.framework/Versions/4.3/Resources/library/Rcpp/include' -I'/opt/local/Library/Frameworks/R.framework/Versions/4.3/Resources/library/RcppArmadillo/include' -pipe -Os -arch ppc -fPIC -DNOSHORTS -I../include -isystem/opt/local/include/LegacySupport -I/opt/local/include -c -o writeprob.o writeprob.c
/opt/local/bin/gcc-mp-12 -DDEFINE_FUNCTIONS_LAPACK_BLAS -I'/opt/local/Library/Frameworks/R.framework/Versions/4.3/Resources/library/Rcpp/include' -I'/opt/local/Library/Frameworks/R.framework/Versions/4.3/Resources/library/RcppArmadillo/include' -pipe -Os -arch ppc -fPIC -DNOSHORTS -I../include -isystem/opt/local/include/LegacySupport -I/opt/local/include -c -o solvesys.o solvesys.c
/opt/local/bin/gcc-mp-12 -DDEFINE_FUNCTIONS_LAPACK_BLAS -I'/opt/local/Library/Frameworks/R.framework/Versions/4.3/Resources/library/Rcpp/include' -I'/opt/local/Library/Frameworks/R.framework/Versions/4.3/Resources/library/RcppArmadillo/include' -pipe -Os -arch ppc -fPIC -DNOSHORTS -I../include -isystem/opt/local/include/LegacySupport -I/opt/local/include -c -o makefill.o makefill.c
/opt/local/bin/gcc-mp-12 -DDEFINE_FUNCTIONS_LAPACK_BLAS -I'/opt/local/Library/Frameworks/R.framework/Versions/4.3/Resources/library/Rcpp/include' -I'/opt/local/Library/Frameworks/R.framework/Versions/4.3/Resources/library/RcppArmadillo/include' -pipe -Os -arch ppc -fPIC -DNOSHORTS -I../include -isystem/opt/local/include/LegacySupport -I/opt/local/include -c -o mat_multsp.o mat_multsp.c
/opt/local/bin/gcc-mp-12 -DDEFINE_FUNCTIONS_LAPACK_BLAS -I'/opt/local/Library/Frameworks/R.framework/Versions/4.3/Resources/library/Rcpp/include' -I'/opt/local/Library/Frameworks/R.framework/Versions/4.3/Resources/library/RcppArmadillo/include' -pipe -Os -arch ppc -fPIC -DNOSHORTS -I../include -isystem/opt/local/include/LegacySupport -I/opt/local/include -c -o norms.o norms.c
/opt/local/bin/gcc-mp-12 -DDEFINE_FUNCTIONS_LAPACK_BLAS -I'/opt/local/Library/Frameworks/R.framework/Versions/4.3/Resources/library/Rcpp/include' -I'/opt/local/Library/Frameworks/R.framework/Versions/4.3/Resources/library/RcppArmadillo/include' -pipe -Os -arch ppc -fPIC -DNOSHORTS -I../include -isystem/opt/local/include/LegacySupport -I/opt/local/include -c -o linesearch.o linesearch.c
/opt/local/bin/gcc-mp-12 -DDEFINE_FUNCTIONS_LAPACK_BLAS -I'/opt/local/Library/Frameworks/R.framework/Versions/4.3/Resources/library/Rcpp/include' -I'/opt/local/Library/Frameworks/R.framework/Versions/4.3/Resources/library/RcppArmadillo/include' -pipe -Os -arch ppc -fPIC -DNOSHORTS -I../include -isystem/opt/local/include/LegacySupport -I/opt/local/include -c -o matvec.o matvec.c
/opt/local/bin/gcc-mp-12 -DDEFINE_FUNCTIONS_LAPACK_BLAS -I'/opt/local/Library/Frameworks/R.framework/Versions/4.3/Resources/library/Rcpp/include' -I'/opt/local/Library/Frameworks/R.framework/Versions/4.3/Resources/library/RcppArmadillo/include' -pipe -Os -arch ppc -fPIC -DNOSHORTS -I../include -isystem/opt/local/include/LegacySupport -I/opt/local/include -c -o chol.o chol.c
/opt/local/bin/gcc-mp-12 -DDEFINE_FUNCTIONS_LAPACK_BLAS -I'/opt/local/Library/Frameworks/R.framework/Versions/4.3/Resources/library/Rcpp/include' -I'/opt/local/Library/Frameworks/R.framework/Versions/4.3/Resources/library/RcppArmadillo/include' -pipe -Os -arch ppc -fPIC -DNOSHORTS -I../include -isystem/opt/local/include/LegacySupport -I/opt/local/include -c -o qreig.o qreig.c
/opt/local/bin/gcc-mp-12 -DDEFINE_FUNCTIONS_LAPACK_BLAS -I'/opt/local/Library/Frameworks/R.framework/Versions/4.3/Resources/library/Rcpp/include' -I'/opt/local/Library/Frameworks/R.framework/Versions/4.3/Resources/library/RcppArmadillo/include' -pipe -Os -arch ppc -fPIC -DNOSHORTS -I../include -isystem/opt/local/include/LegacySupport -I/opt/local/include -c -o tweakgap.o tweakgap.c
/opt/local/bin/gcc-mp-12 -DDEFINE_FUNCTIONS_LAPACK_BLAS -I'/opt/local/Library/Frameworks/R.framework/Versions/4.3/Resources/library/Rcpp/include' -I'/opt/local/Library/Frameworks/R.framework/Versions/4.3/Resources/library/RcppArmadillo/include' -pipe -Os -arch ppc -fPIC -DNOSHORTS -I../include -isystem/opt/local/include/LegacySupport -I/opt/local/include -c -o freeprob.o freeprob.c
/opt/local/bin/gcc-mp-12 -DDEFINE_FUNCTIONS_LAPACK_BLAS -I'/opt/local/Library/Frameworks/R.framework/Versions/4.3/Resources/library/Rcpp/include' -I'/opt/local/Library/Frameworks/R.framework/Versions/4.3/Resources/library/RcppArmadillo/include' -pipe -Os -arch ppc -fPIC -DNOSHORTS -I../include -isystem/opt/local/include/LegacySupport -I/opt/local/include -c -o packed.o packed.c
/opt/local/bin/gcc-mp-12 -DDEFINE_FUNCTIONS_LAPACK_BLAS -I'/opt/local/Library/Frameworks/R.framework/Versions/4.3/Resources/library/Rcpp/include' -I'/opt/local/Library/Frameworks/R.framework/Versions/4.3/Resources/library/RcppArmadillo/include' -pipe -Os -arch ppc -fPIC -DNOSHORTS -I../include -isystem/opt/local/include/LegacySupport -I/opt/local/include -c -o sortentries.o sortentries.c
ar cr libsdp.a readprob.o sdp.o op_o.o psd_feas.o op_a.o op_at.o Fnorm.o calc_pobj.o calc_dobj.o trace_prod.o zero_mat.o mat_mult.o sym_mat.o copy_mat.o addscaledmat.o user_exit.o make_i.o allocmat.o initsoln.o initparams.o add_mat.o writesol.o readsol.o easysdp.o writeprob.o solvesys.o makefill.o mat_multsp.o norms.o linesearch.o matvec.o chol.o qreig.o tweakgap.o freeprob.o packed.o sortentries.o
/opt/local/bin/g++-mp-12 -std=gnu++17 -dynamiclib -Wl,-headerpad_max_install_names -undefined dynamic_lookup -single_module -multiply_defined suppress -L/opt/local/Library/Frameworks/R.framework/Resources/lib -Wl,-headerpad_max_install_names -Wl,-rpath,/opt/local/lib/libgcc -L/opt/local/lib -lMacportsLegacySupport -arch ppc -o Bayesrel.so BayesrelCpp.o LowBoundsCpp.o RcppExports.o convertCpp.o customsdpCpp.o initArma.o pfaCpp.o -LCsdp/lib -lsdp -L/opt/local/Library/Frameworks/R.framework/Resources/lib -lRlapack -L/opt/local/Library/Frameworks/R.framework/Resources/lib -lRblas -lMacportsLegacySupport -lgfortran -lef_ppc -lm -F/opt/local/Library/Frameworks/R.framework/.. -framework R -Wl,-framework -Wl,CoreFoundation
ld: in Csdp/lib/libsdp.a, archive has no table of contents
collect2: error: ld returned 1 exit status
make: *** [Bayesrel.so] Error 1
ERROR: compilation failed for package ‘Bayesrel’
@juliuspfadt Could you take a quick look, please? I am having a strange issue, and I am clueless what goes wrong :)
It worked before on the same system. Since then Bayesrel
code did not change, but R
was updated to 4.4 (perhaps irrelevant) and there were minor changes to our build system (but should be irrelevant for this too).
Now it fails to link:
---> Configuring R-Bayesrel
Executing: cd "/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_R_R-Bayesrel/R-Bayesrel/work/Bayesrel" && /opt/local/bin/R CMD build . --no-manual --no-build-vignettes --keep-empty-dirs
* checking for file ‘./DESCRIPTION’ ... OK
* preparing ‘Bayesrel’:
* checking DESCRIPTION meta-information ... OK
* cleaning src
* running ‘cleanup’
* installing the package to process help pages
-----------------------------------
* installing *source* package ‘Bayesrel’ ...
file ‘build/partial.rdb’ is missing
file ‘src/Csdp/lib/Makefile’ has the wrong MD5 checksum
** using staged installation
Using bundled CSDP
checking for gcc... /opt/local/bin/gcc-mp-13
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 /opt/local/bin/gcc-mp-13 accepts -g... yes
checking for /opt/local/bin/gcc-mp-13 option to accept ISO C89... none needed
checking how to run the C preprocessor... /opt/local/bin/gcc-mp-13 -E
checking whether we are using the GNU C++ compiler... yes
checking whether /opt/local/bin/g++-mp-13 -std=gnu++17 accepts -g... yes
checking how to run the C++ preprocessor... /opt/local/bin/g++-mp-13 -std=gnu++17 -E
checking whether we are using the GNU C++ compiler... (cached) yes
checking whether /opt/local/bin/g++-mp-13 -std=gnu++17 accepts -g... (cached) yes
configure: creating ./config.status
config.status: creating src/Makevars
** libs
using C++ compiler: ‘g++-mp-13 (MacPorts gcc13 13.2.0_4+stdlib_flag) 13.2.0’
Warning in system2("xcrun", "--show-sdk-path", TRUE, TRUE) :
running command ''xcrun' --show-sdk-path 2>&1' had status 64
using SDK: ‘NA’‘NA’‘NA’‘NA’‘NA’‘NA’
/opt/local/bin/g++-mp-13 -std=gnu++17 -I"/opt/local/Library/Frameworks/R.framework/Resources/include" -DNDEBUG -ICsdp/include -DNOSHORTS -DARMA_NO_DEBUG=1 -DARMA_DONT_USE_FORTRAN_HIDDEN_ARGS -I'/opt/local/Library/Frameworks/R.framework/Versions/4.4/Resources/library/Rcpp/include' -I'/opt/local/Library/Frameworks/R.framework/Versions/4.4/Resources/library/RcppArmadillo/include' -isystem/opt/local/include/LegacySupport -I/opt/local/include -fPIC -pipe -Os -arch ppc -c BayesrelCpp.cpp -o BayesrelCpp.o
/opt/local/bin/g++-mp-13 -std=gnu++17 -I"/opt/local/Library/Frameworks/R.framework/Resources/include" -DNDEBUG -ICsdp/include -DNOSHORTS -DARMA_NO_DEBUG=1 -DARMA_DONT_USE_FORTRAN_HIDDEN_ARGS -I'/opt/local/Library/Frameworks/R.framework/Versions/4.4/Resources/library/Rcpp/include' -I'/opt/local/Library/Frameworks/R.framework/Versions/4.4/Resources/library/RcppArmadillo/include' -isystem/opt/local/include/LegacySupport -I/opt/local/include -fPIC -pipe -Os -arch ppc -c LowBoundsCpp.cpp -o LowBoundsCpp.o
/opt/local/bin/g++-mp-13 -std=gnu++17 -I"/opt/local/Library/Frameworks/R.framework/Resources/include" -DNDEBUG -ICsdp/include -DNOSHORTS -DARMA_NO_DEBUG=1 -DARMA_DONT_USE_FORTRAN_HIDDEN_ARGS -I'/opt/local/Library/Frameworks/R.framework/Versions/4.4/Resources/library/Rcpp/include' -I'/opt/local/Library/Frameworks/R.framework/Versions/4.4/Resources/library/RcppArmadillo/include' -isystem/opt/local/include/LegacySupport -I/opt/local/include -fPIC -pipe -Os -arch ppc -c RcppExports.cpp -o RcppExports.o
/opt/local/bin/g++-mp-13 -std=gnu++17 -I"/opt/local/Library/Frameworks/R.framework/Resources/include" -DNDEBUG -ICsdp/include -DNOSHORTS -DARMA_NO_DEBUG=1 -DARMA_DONT_USE_FORTRAN_HIDDEN_ARGS -I'/opt/local/Library/Frameworks/R.framework/Versions/4.4/Resources/library/Rcpp/include' -I'/opt/local/Library/Frameworks/R.framework/Versions/4.4/Resources/library/RcppArmadillo/include' -isystem/opt/local/include/LegacySupport -I/opt/local/include -fPIC -pipe -Os -arch ppc -c convertCpp.cpp -o convertCpp.o
/opt/local/bin/g++-mp-13 -std=gnu++17 -I"/opt/local/Library/Frameworks/R.framework/Resources/include" -DNDEBUG -ICsdp/include -DNOSHORTS -DARMA_NO_DEBUG=1 -DARMA_DONT_USE_FORTRAN_HIDDEN_ARGS -I'/opt/local/Library/Frameworks/R.framework/Versions/4.4/Resources/library/Rcpp/include' -I'/opt/local/Library/Frameworks/R.framework/Versions/4.4/Resources/library/RcppArmadillo/include' -isystem/opt/local/include/LegacySupport -I/opt/local/include -fPIC -pipe -Os -arch ppc -c customsdpCpp.cpp -o customsdpCpp.o
/opt/local/bin/g++-mp-13 -std=gnu++17 -I"/opt/local/Library/Frameworks/R.framework/Resources/include" -DNDEBUG -ICsdp/include -DNOSHORTS -DARMA_NO_DEBUG=1 -DARMA_DONT_USE_FORTRAN_HIDDEN_ARGS -I'/opt/local/Library/Frameworks/R.framework/Versions/4.4/Resources/library/Rcpp/include' -I'/opt/local/Library/Frameworks/R.framework/Versions/4.4/Resources/library/RcppArmadillo/include' -isystem/opt/local/include/LegacySupport -I/opt/local/include -fPIC -pipe -Os -arch ppc -c initArma.cpp -o initArma.o
/opt/local/bin/g++-mp-13 -std=gnu++17 -I"/opt/local/Library/Frameworks/R.framework/Resources/include" -DNDEBUG -ICsdp/include -DNOSHORTS -DARMA_NO_DEBUG=1 -DARMA_DONT_USE_FORTRAN_HIDDEN_ARGS -I'/opt/local/Library/Frameworks/R.framework/Versions/4.4/Resources/library/Rcpp/include' -I'/opt/local/Library/Frameworks/R.framework/Versions/4.4/Resources/library/RcppArmadillo/include' -isystem/opt/local/include/LegacySupport -I/opt/local/include -fPIC -pipe -Os -arch ppc -c pfaCpp.cpp -o pfaCpp.o
(cd Csdp/lib && \
(make libsdp.a CC="/opt/local/bin/gcc-mp-13" CFLAGS="-DDEFINE_FUNCTIONS_LAPACK_BLAS -I'/opt/local/Library/Frameworks/R.framework/Versions/4.4/Resources/library/Rcpp/include' -I'/opt/local/Library/Frameworks/R.framework/Versions/4.4/Resources/library/RcppArmadillo/include' -pipe -Os -arch ppc -fPIC -DNOSHORTS -I../include" AR="ar" RANLIB="ranlib") && \
touch Csdp.ts)
/opt/local/bin/gcc-mp-13 -DDEFINE_FUNCTIONS_LAPACK_BLAS -I'/opt/local/Library/Frameworks/R.framework/Versions/4.4/Resources/library/Rcpp/include' -I'/opt/local/Library/Frameworks/R.framework/Versions/4.4/Resources/library/RcppArmadillo/include' -pipe -Os -arch ppc -fPIC -DNOSHORTS -I../include -isystem/opt/local/include/LegacySupport -I/opt/local/include -c -o readprob.o readprob.c
/opt/local/bin/gcc-mp-13 -DDEFINE_FUNCTIONS_LAPACK_BLAS -I'/opt/local/Library/Frameworks/R.framework/Versions/4.4/Resources/library/Rcpp/include' -I'/opt/local/Library/Frameworks/R.framework/Versions/4.4/Resources/library/RcppArmadillo/include' -pipe -Os -arch ppc -fPIC -DNOSHORTS -I../include -isystem/opt/local/include/LegacySupport -I/opt/local/include -c -o sdp.o sdp.c
/opt/local/bin/gcc-mp-13 -DDEFINE_FUNCTIONS_LAPACK_BLAS -I'/opt/local/Library/Frameworks/R.framework/Versions/4.4/Resources/library/Rcpp/include' -I'/opt/local/Library/Frameworks/R.framework/Versions/4.4/Resources/library/RcppArmadillo/include' -pipe -Os -arch ppc -fPIC -DNOSHORTS -I../include -isystem/opt/local/include/LegacySupport -I/opt/local/include -c -o op_o.o op_o.c
/opt/local/bin/gcc-mp-13 -DDEFINE_FUNCTIONS_LAPACK_BLAS -I'/opt/local/Library/Frameworks/R.framework/Versions/4.4/Resources/library/Rcpp/include' -I'/opt/local/Library/Frameworks/R.framework/Versions/4.4/Resources/library/RcppArmadillo/include' -pipe -Os -arch ppc -fPIC -DNOSHORTS -I../include -isystem/opt/local/include/LegacySupport -I/opt/local/include -c -o psd_feas.o psd_feas.c
/opt/local/bin/gcc-mp-13 -DDEFINE_FUNCTIONS_LAPACK_BLAS -I'/opt/local/Library/Frameworks/R.framework/Versions/4.4/Resources/library/Rcpp/include' -I'/opt/local/Library/Frameworks/R.framework/Versions/4.4/Resources/library/RcppArmadillo/include' -pipe -Os -arch ppc -fPIC -DNOSHORTS -I../include -isystem/opt/local/include/LegacySupport -I/opt/local/include -c -o op_a.o op_a.c
/opt/local/bin/gcc-mp-13 -DDEFINE_FUNCTIONS_LAPACK_BLAS -I'/opt/local/Library/Frameworks/R.framework/Versions/4.4/Resources/library/Rcpp/include' -I'/opt/local/Library/Frameworks/R.framework/Versions/4.4/Resources/library/RcppArmadillo/include' -pipe -Os -arch ppc -fPIC -DNOSHORTS -I../include -isystem/opt/local/include/LegacySupport -I/opt/local/include -c -o op_at.o op_at.c
/opt/local/bin/gcc-mp-13 -DDEFINE_FUNCTIONS_LAPACK_BLAS -I'/opt/local/Library/Frameworks/R.framework/Versions/4.4/Resources/library/Rcpp/include' -I'/opt/local/Library/Frameworks/R.framework/Versions/4.4/Resources/library/RcppArmadillo/include' -pipe -Os -arch ppc -fPIC -DNOSHORTS -I../include -isystem/opt/local/include/LegacySupport -I/opt/local/include -c -o Fnorm.o Fnorm.c
/opt/local/bin/gcc-mp-13 -DDEFINE_FUNCTIONS_LAPACK_BLAS -I'/opt/local/Library/Frameworks/R.framework/Versions/4.4/Resources/library/Rcpp/include' -I'/opt/local/Library/Frameworks/R.framework/Versions/4.4/Resources/library/RcppArmadillo/include' -pipe -Os -arch ppc -fPIC -DNOSHORTS -I../include -isystem/opt/local/include/LegacySupport -I/opt/local/include -c -o calc_pobj.o calc_pobj.c
/opt/local/bin/gcc-mp-13 -DDEFINE_FUNCTIONS_LAPACK_BLAS -I'/opt/local/Library/Frameworks/R.framework/Versions/4.4/Resources/library/Rcpp/include' -I'/opt/local/Library/Frameworks/R.framework/Versions/4.4/Resources/library/RcppArmadillo/include' -pipe -Os -arch ppc -fPIC -DNOSHORTS -I../include -isystem/opt/local/include/LegacySupport -I/opt/local/include -c -o calc_dobj.o calc_dobj.c
/opt/local/bin/gcc-mp-13 -DDEFINE_FUNCTIONS_LAPACK_BLAS -I'/opt/local/Library/Frameworks/R.framework/Versions/4.4/Resources/library/Rcpp/include' -I'/opt/local/Library/Frameworks/R.framework/Versions/4.4/Resources/library/RcppArmadillo/include' -pipe -Os -arch ppc -fPIC -DNOSHORTS -I../include -isystem/opt/local/include/LegacySupport -I/opt/local/include -c -o trace_prod.o trace_prod.c
/opt/local/bin/gcc-mp-13 -DDEFINE_FUNCTIONS_LAPACK_BLAS -I'/opt/local/Library/Frameworks/R.framework/Versions/4.4/Resources/library/Rcpp/include' -I'/opt/local/Library/Frameworks/R.framework/Versions/4.4/Resources/library/RcppArmadillo/include' -pipe -Os -arch ppc -fPIC -DNOSHORTS -I../include -isystem/opt/local/include/LegacySupport -I/opt/local/include -c -o zero_mat.o zero_mat.c
/opt/local/bin/gcc-mp-13 -DDEFINE_FUNCTIONS_LAPACK_BLAS -I'/opt/local/Library/Frameworks/R.framework/Versions/4.4/Resources/library/Rcpp/include' -I'/opt/local/Library/Frameworks/R.framework/Versions/4.4/Resources/library/RcppArmadillo/include' -pipe -Os -arch ppc -fPIC -DNOSHORTS -I../include -isystem/opt/local/include/LegacySupport -I/opt/local/include -c -o mat_mult.o mat_mult.c
/opt/local/bin/gcc-mp-13 -DDEFINE_FUNCTIONS_LAPACK_BLAS -I'/opt/local/Library/Frameworks/R.framework/Versions/4.4/Resources/library/Rcpp/include' -I'/opt/local/Library/Frameworks/R.framework/Versions/4.4/Resources/library/RcppArmadillo/include' -pipe -Os -arch ppc -fPIC -DNOSHORTS -I../include -isystem/opt/local/include/LegacySupport -I/opt/local/include -c -o sym_mat.o sym_mat.c
/opt/local/bin/gcc-mp-13 -DDEFINE_FUNCTIONS_LAPACK_BLAS -I'/opt/local/Library/Frameworks/R.framework/Versions/4.4/Resources/library/Rcpp/include' -I'/opt/local/Library/Frameworks/R.framework/Versions/4.4/Resources/library/RcppArmadillo/include' -pipe -Os -arch ppc -fPIC -DNOSHORTS -I../include -isystem/opt/local/include/LegacySupport -I/opt/local/include -c -o copy_mat.o copy_mat.c
/opt/local/bin/gcc-mp-13 -DDEFINE_FUNCTIONS_LAPACK_BLAS -I'/opt/local/Library/Frameworks/R.framework/Versions/4.4/Resources/library/Rcpp/include' -I'/opt/local/Library/Frameworks/R.framework/Versions/4.4/Resources/library/RcppArmadillo/include' -pipe -Os -arch ppc -fPIC -DNOSHORTS -I../include -isystem/opt/local/include/LegacySupport -I/opt/local/include -c -o addscaledmat.o addscaledmat.c
/opt/local/bin/gcc-mp-13 -DDEFINE_FUNCTIONS_LAPACK_BLAS -I'/opt/local/Library/Frameworks/R.framework/Versions/4.4/Resources/library/Rcpp/include' -I'/opt/local/Library/Frameworks/R.framework/Versions/4.4/Resources/library/RcppArmadillo/include' -pipe -Os -arch ppc -fPIC -DNOSHORTS -I../include -isystem/opt/local/include/LegacySupport -I/opt/local/include -c -o user_exit.o user_exit.c
/opt/local/bin/gcc-mp-13 -DDEFINE_FUNCTIONS_LAPACK_BLAS -I'/opt/local/Library/Frameworks/R.framework/Versions/4.4/Resources/library/Rcpp/include' -I'/opt/local/Library/Frameworks/R.framework/Versions/4.4/Resources/library/RcppArmadillo/include' -pipe -Os -arch ppc -fPIC -DNOSHORTS -I../include -isystem/opt/local/include/LegacySupport -I/opt/local/include -c -o make_i.o make_i.c
/opt/local/bin/gcc-mp-13 -DDEFINE_FUNCTIONS_LAPACK_BLAS -I'/opt/local/Library/Frameworks/R.framework/Versions/4.4/Resources/library/Rcpp/include' -I'/opt/local/Library/Frameworks/R.framework/Versions/4.4/Resources/library/RcppArmadillo/include' -pipe -Os -arch ppc -fPIC -DNOSHORTS -I../include -isystem/opt/local/include/LegacySupport -I/opt/local/include -c -o allocmat.o allocmat.c
/opt/local/bin/gcc-mp-13 -DDEFINE_FUNCTIONS_LAPACK_BLAS -I'/opt/local/Library/Frameworks/R.framework/Versions/4.4/Resources/library/Rcpp/include' -I'/opt/local/Library/Frameworks/R.framework/Versions/4.4/Resources/library/RcppArmadillo/include' -pipe -Os -arch ppc -fPIC -DNOSHORTS -I../include -isystem/opt/local/include/LegacySupport -I/opt/local/include -c -o initsoln.o initsoln.c
/opt/local/bin/gcc-mp-13 -DDEFINE_FUNCTIONS_LAPACK_BLAS -I'/opt/local/Library/Frameworks/R.framework/Versions/4.4/Resources/library/Rcpp/include' -I'/opt/local/Library/Frameworks/R.framework/Versions/4.4/Resources/library/RcppArmadillo/include' -pipe -Os -arch ppc -fPIC -DNOSHORTS -I../include -isystem/opt/local/include/LegacySupport -I/opt/local/include -c -o initparams.o initparams.c
/opt/local/bin/gcc-mp-13 -DDEFINE_FUNCTIONS_LAPACK_BLAS -I'/opt/local/Library/Frameworks/R.framework/Versions/4.4/Resources/library/Rcpp/include' -I'/opt/local/Library/Frameworks/R.framework/Versions/4.4/Resources/library/RcppArmadillo/include' -pipe -Os -arch ppc -fPIC -DNOSHORTS -I../include -isystem/opt/local/include/LegacySupport -I/opt/local/include -c -o add_mat.o add_mat.c
/opt/local/bin/gcc-mp-13 -DDEFINE_FUNCTIONS_LAPACK_BLAS -I'/opt/local/Library/Frameworks/R.framework/Versions/4.4/Resources/library/Rcpp/include' -I'/opt/local/Library/Frameworks/R.framework/Versions/4.4/Resources/library/RcppArmadillo/include' -pipe -Os -arch ppc -fPIC -DNOSHORTS -I../include -isystem/opt/local/include/LegacySupport -I/opt/local/include -c -o writesol.o writesol.c
/opt/local/bin/gcc-mp-13 -DDEFINE_FUNCTIONS_LAPACK_BLAS -I'/opt/local/Library/Frameworks/R.framework/Versions/4.4/Resources/library/Rcpp/include' -I'/opt/local/Library/Frameworks/R.framework/Versions/4.4/Resources/library/RcppArmadillo/include' -pipe -Os -arch ppc -fPIC -DNOSHORTS -I../include -isystem/opt/local/include/LegacySupport -I/opt/local/include -c -o readsol.o readsol.c
/opt/local/bin/gcc-mp-13 -DDEFINE_FUNCTIONS_LAPACK_BLAS -I'/opt/local/Library/Frameworks/R.framework/Versions/4.4/Resources/library/Rcpp/include' -I'/opt/local/Library/Frameworks/R.framework/Versions/4.4/Resources/library/RcppArmadillo/include' -pipe -Os -arch ppc -fPIC -DNOSHORTS -I../include -isystem/opt/local/include/LegacySupport -I/opt/local/include -c -o easysdp.o easysdp.c
/opt/local/bin/gcc-mp-13 -DDEFINE_FUNCTIONS_LAPACK_BLAS -I'/opt/local/Library/Frameworks/R.framework/Versions/4.4/Resources/library/Rcpp/include' -I'/opt/local/Library/Frameworks/R.framework/Versions/4.4/Resources/library/RcppArmadillo/include' -pipe -Os -arch ppc -fPIC -DNOSHORTS -I../include -isystem/opt/local/include/LegacySupport -I/opt/local/include -c -o writeprob.o writeprob.c
/opt/local/bin/gcc-mp-13 -DDEFINE_FUNCTIONS_LAPACK_BLAS -I'/opt/local/Library/Frameworks/R.framework/Versions/4.4/Resources/library/Rcpp/include' -I'/opt/local/Library/Frameworks/R.framework/Versions/4.4/Resources/library/RcppArmadillo/include' -pipe -Os -arch ppc -fPIC -DNOSHORTS -I../include -isystem/opt/local/include/LegacySupport -I/opt/local/include -c -o solvesys.o solvesys.c
/opt/local/bin/gcc-mp-13 -DDEFINE_FUNCTIONS_LAPACK_BLAS -I'/opt/local/Library/Frameworks/R.framework/Versions/4.4/Resources/library/Rcpp/include' -I'/opt/local/Library/Frameworks/R.framework/Versions/4.4/Resources/library/RcppArmadillo/include' -pipe -Os -arch ppc -fPIC -DNOSHORTS -I../include -isystem/opt/local/include/LegacySupport -I/opt/local/include -c -o makefill.o makefill.c
/opt/local/bin/gcc-mp-13 -DDEFINE_FUNCTIONS_LAPACK_BLAS -I'/opt/local/Library/Frameworks/R.framework/Versions/4.4/Resources/library/Rcpp/include' -I'/opt/local/Library/Frameworks/R.framework/Versions/4.4/Resources/library/RcppArmadillo/include' -pipe -Os -arch ppc -fPIC -DNOSHORTS -I../include -isystem/opt/local/include/LegacySupport -I/opt/local/include -c -o mat_multsp.o mat_multsp.c
/opt/local/bin/gcc-mp-13 -DDEFINE_FUNCTIONS_LAPACK_BLAS -I'/opt/local/Library/Frameworks/R.framework/Versions/4.4/Resources/library/Rcpp/include' -I'/opt/local/Library/Frameworks/R.framework/Versions/4.4/Resources/library/RcppArmadillo/include' -pipe -Os -arch ppc -fPIC -DNOSHORTS -I../include -isystem/opt/local/include/LegacySupport -I/opt/local/include -c -o norms.o norms.c
/opt/local/bin/gcc-mp-13 -DDEFINE_FUNCTIONS_LAPACK_BLAS -I'/opt/local/Library/Frameworks/R.framework/Versions/4.4/Resources/library/Rcpp/include' -I'/opt/local/Library/Frameworks/R.framework/Versions/4.4/Resources/library/RcppArmadillo/include' -pipe -Os -arch ppc -fPIC -DNOSHORTS -I../include -isystem/opt/local/include/LegacySupport -I/opt/local/include -c -o linesearch.o linesearch.c
/opt/local/bin/gcc-mp-13 -DDEFINE_FUNCTIONS_LAPACK_BLAS -I'/opt/local/Library/Frameworks/R.framework/Versions/4.4/Resources/library/Rcpp/include' -I'/opt/local/Library/Frameworks/R.framework/Versions/4.4/Resources/library/RcppArmadillo/include' -pipe -Os -arch ppc -fPIC -DNOSHORTS -I../include -isystem/opt/local/include/LegacySupport -I/opt/local/include -c -o matvec.o matvec.c
/opt/local/bin/gcc-mp-13 -DDEFINE_FUNCTIONS_LAPACK_BLAS -I'/opt/local/Library/Frameworks/R.framework/Versions/4.4/Resources/library/Rcpp/include' -I'/opt/local/Library/Frameworks/R.framework/Versions/4.4/Resources/library/RcppArmadillo/include' -pipe -Os -arch ppc -fPIC -DNOSHORTS -I../include -isystem/opt/local/include/LegacySupport -I/opt/local/include -c -o chol.o chol.c
/opt/local/bin/gcc-mp-13 -DDEFINE_FUNCTIONS_LAPACK_BLAS -I'/opt/local/Library/Frameworks/R.framework/Versions/4.4/Resources/library/Rcpp/include' -I'/opt/local/Library/Frameworks/R.framework/Versions/4.4/Resources/library/RcppArmadillo/include' -pipe -Os -arch ppc -fPIC -DNOSHORTS -I../include -isystem/opt/local/include/LegacySupport -I/opt/local/include -c -o qreig.o qreig.c
/opt/local/bin/gcc-mp-13 -DDEFINE_FUNCTIONS_LAPACK_BLAS -I'/opt/local/Library/Frameworks/R.framework/Versions/4.4/Resources/library/Rcpp/include' -I'/opt/local/Library/Frameworks/R.framework/Versions/4.4/Resources/library/RcppArmadillo/include' -pipe -Os -arch ppc -fPIC -DNOSHORTS -I../include -isystem/opt/local/include/LegacySupport -I/opt/local/include -c -o tweakgap.o tweakgap.c
/opt/local/bin/gcc-mp-13 -DDEFINE_FUNCTIONS_LAPACK_BLAS -I'/opt/local/Library/Frameworks/R.framework/Versions/4.4/Resources/library/Rcpp/include' -I'/opt/local/Library/Frameworks/R.framework/Versions/4.4/Resources/library/RcppArmadillo/include' -pipe -Os -arch ppc -fPIC -DNOSHORTS -I../include -isystem/opt/local/include/LegacySupport -I/opt/local/include -c -o freeprob.o freeprob.c
/opt/local/bin/gcc-mp-13 -DDEFINE_FUNCTIONS_LAPACK_BLAS -I'/opt/local/Library/Frameworks/R.framework/Versions/4.4/Resources/library/Rcpp/include' -I'/opt/local/Library/Frameworks/R.framework/Versions/4.4/Resources/library/RcppArmadillo/include' -pipe -Os -arch ppc -fPIC -DNOSHORTS -I../include -isystem/opt/local/include/LegacySupport -I/opt/local/include -c -o packed.o packed.c
/opt/local/bin/gcc-mp-13 -DDEFINE_FUNCTIONS_LAPACK_BLAS -I'/opt/local/Library/Frameworks/R.framework/Versions/4.4/Resources/library/Rcpp/include' -I'/opt/local/Library/Frameworks/R.framework/Versions/4.4/Resources/library/RcppArmadillo/include' -pipe -Os -arch ppc -fPIC -DNOSHORTS -I../include -isystem/opt/local/include/LegacySupport -I/opt/local/include -c -o sortentries.o sortentries.c
ar crs libsdp.a readprob.o sdp.o op_o.o psd_feas.o op_a.o op_at.o Fnorm.o calc_pobj.o calc_dobj.o trace_prod.o zero_mat.o mat_mult.o sym_mat.o copy_mat.o addscaledmat.o user_exit.o make_i.o allocmat.o initsoln.o initparams.o add_mat.o writesol.o readsol.o easysdp.o writeprob.o solvesys.o makefill.o mat_multsp.o norms.o linesearch.o matvec.o chol.o qreig.o tweakgap.o freeprob.o packed.o sortentries.o
/opt/local/bin/g++-mp-13 -std=gnu++17 -dynamiclib -Wl,-headerpad_max_install_names -undefined dynamic_lookup -single_module -multiply_defined suppress -L/opt/local/Library/Frameworks/R.framework/Resources/lib -Wl,-headerpad_max_install_names -L/opt/local/lib -lMacportsLegacySupport -Wl,-rpath,/opt/local/lib/libgcc -arch ppc -o Bayesrel.so BayesrelCpp.o LowBoundsCpp.o RcppExports.o convertCpp.o customsdpCpp.o initArma.o pfaCpp.o -LCsdp/lib -lsdp -L/opt/local/Library/Frameworks/R.framework/Resources/lib -lRlapack -L/opt/local/Library/Frameworks/R.framework/Resources/lib -lRblas -lMacportsLegacySupport -lgfortran -lef_ppc -lm -F/opt/local/Library/Frameworks/R.framework/.. -framework R -Wl,-framework -Wl,CoreFoundation
installing to /opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_R_R-Bayesrel/R-Bayesrel/work/.tmp/Rtmpejdz30/Rinstf32110e319b4/00LOCK-Bayesrel/00new/Bayesrel/libs
** R
** data
*** moving datasets to lazyload DB
** inst
** byte-compile and prepare package for lazy loading
** help
Loading required namespace: Bayesrel
Failed with error: ‘unable to load shared object '/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_R_R-Bayesrel/R-Bayesrel/work/.tmp/Rtmpejdz30/Rinstf32110e319b4/00LOCK-Bayesrel/00new/Bayesrel/libs/Bayesrel.so':
dlopen(/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_R_R-Bayesrel/R-Bayesrel/work/.tmp/Rtmpejdz30/Rinstf32110e319b4/00LOCK-Bayesrel/00new/Bayesrel/libs/Bayesrel.so, 6): Symbol not found: _alloc_mat
Referenced from: /opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_R_R-Bayesrel/R-Bayesrel/work/.tmp/Rtmpejdz30/Rinstf32110e319b4/00LOCK-Bayesrel/00new/Bayesrel/libs/Bayesrel.so
Expected in: dynamic lookup
’
Loading required namespace: Bayesrel
Failed with error: ‘unable to load shared object '/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_R_R-Bayesrel/R-Bayesrel/work/.tmp/Rtmpejdz30/Rinstf32110e319b4/00LOCK-Bayesrel/00new/Bayesrel/libs/Bayesrel.so':
dlopen(/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_R_R-Bayesrel/R-Bayesrel/work/.tmp/Rtmpejdz30/Rinstf32110e319b4/00LOCK-Bayesrel/00new/Bayesrel/libs/Bayesrel.so, 6): Symbol not found: _alloc_mat
Referenced from: /opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_R_R-Bayesrel/R-Bayesrel/work/.tmp/Rtmpejdz30/Rinstf32110e319b4/00LOCK-Bayesrel/00new/Bayesrel/libs/Bayesrel.so
Expected in: dynamic lookup
’
Loading required namespace: Bayesrel
Failed with error: ‘unable to load shared object '/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_R_R-Bayesrel/R-Bayesrel/work/.tmp/Rtmpejdz30/Rinstf32110e319b4/00LOCK-Bayesrel/00new/Bayesrel/libs/Bayesrel.so':
dlopen(/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_R_R-Bayesrel/R-Bayesrel/work/.tmp/Rtmpejdz30/Rinstf32110e319b4/00LOCK-Bayesrel/00new/Bayesrel/libs/Bayesrel.so, 6): Symbol not found: _alloc_mat
Referenced from: /opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_R_R-Bayesrel/R-Bayesrel/work/.tmp/Rtmpejdz30/Rinstf32110e319b4/00LOCK-Bayesrel/00new/Bayesrel/libs/Bayesrel.so
Expected in: dynamic lookup
’
Loading required namespace: Bayesrel
Failed with error: ‘unable to load shared object '/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_R_R-Bayesrel/R-Bayesrel/work/.tmp/Rtmpejdz30/Rinstf32110e319b4/00LOCK-Bayesrel/00new/Bayesrel/libs/Bayesrel.so':
dlopen(/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_R_R-Bayesrel/R-Bayesrel/work/.tmp/Rtmpejdz30/Rinstf32110e319b4/00LOCK-Bayesrel/00new/Bayesrel/libs/Bayesrel.so, 6): Symbol not found: _alloc_mat
Referenced from: /opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_R_R-Bayesrel/R-Bayesrel/work/.tmp/Rtmpejdz30/Rinstf32110e319b4/00LOCK-Bayesrel/00new/Bayesrel/libs/Bayesrel.so
Expected in: dynamic lookup
’
Loading required namespace: Bayesrel
Failed with error: ‘unable to load shared object '/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_R_R-Bayesrel/R-Bayesrel/work/.tmp/Rtmpejdz30/Rinstf32110e319b4/00LOCK-Bayesrel/00new/Bayesrel/libs/Bayesrel.so':
dlopen(/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_R_R-Bayesrel/R-Bayesrel/work/.tmp/Rtmpejdz30/Rinstf32110e319b4/00LOCK-Bayesrel/00new/Bayesrel/libs/Bayesrel.so, 6): Symbol not found: _alloc_mat
Referenced from: /opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_R_R-Bayesrel/R-Bayesrel/work/.tmp/Rtmpejdz30/Rinstf32110e319b4/00LOCK-Bayesrel/00new/Bayesrel/libs/Bayesrel.so
Expected in: dynamic lookup
’
Loading required namespace: Bayesrel
Failed with error: ‘unable to load shared object '/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_R_R-Bayesrel/R-Bayesrel/work/.tmp/Rtmpejdz30/Rinstf32110e319b4/00LOCK-Bayesrel/00new/Bayesrel/libs/Bayesrel.so':
dlopen(/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_R_R-Bayesrel/R-Bayesrel/work/.tmp/Rtmpejdz30/Rinstf32110e319b4/00LOCK-Bayesrel/00new/Bayesrel/libs/Bayesrel.so, 6): Symbol not found: _alloc_mat
Referenced from: /opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_R_R-Bayesrel/R-Bayesrel/work/.tmp/Rtmpejdz30/Rinstf32110e319b4/00LOCK-Bayesrel/00new/Bayesrel/libs/Bayesrel.so
Expected in: dynamic lookup
’
Loading required namespace: Bayesrel
Failed with error: ‘unable to load shared object '/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_R_R-Bayesrel/R-Bayesrel/work/.tmp/Rtmpejdz30/Rinstf32110e319b4/00LOCK-Bayesrel/00new/Bayesrel/libs/Bayesrel.so':
dlopen(/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_R_R-Bayesrel/R-Bayesrel/work/.tmp/Rtmpejdz30/Rinstf32110e319b4/00LOCK-Bayesrel/00new/Bayesrel/libs/Bayesrel.so, 6): Symbol not found: _alloc_mat
Referenced from: /opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_R_R-Bayesrel/R-Bayesrel/work/.tmp/Rtmpejdz30/Rinstf32110e319b4/00LOCK-Bayesrel/00new/Bayesrel/libs/Bayesrel.so
Expected in: dynamic lookup
’
Loading required namespace: Bayesrel
Failed with error: ‘unable to load shared object '/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_R_R-Bayesrel/R-Bayesrel/work/.tmp/Rtmpejdz30/Rinstf32110e319b4/00LOCK-Bayesrel/00new/Bayesrel/libs/Bayesrel.so':
dlopen(/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_R_R-Bayesrel/R-Bayesrel/work/.tmp/Rtmpejdz30/Rinstf32110e319b4/00LOCK-Bayesrel/00new/Bayesrel/libs/Bayesrel.so, 6): Symbol not found: _alloc_mat
Referenced from: /opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_R_R-Bayesrel/R-Bayesrel/work/.tmp/Rtmpejdz30/Rinstf32110e319b4/00LOCK-Bayesrel/00new/Bayesrel/libs/Bayesrel.so
Expected in: dynamic lookup
’
Loading required namespace: Bayesrel
Failed with error: ‘unable to load shared object '/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_R_R-Bayesrel/R-Bayesrel/work/.tmp/Rtmpejdz30/Rinstf32110e319b4/00LOCK-Bayesrel/00new/Bayesrel/libs/Bayesrel.so':
dlopen(/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_R_R-Bayesrel/R-Bayesrel/work/.tmp/Rtmpejdz30/Rinstf32110e319b4/00LOCK-Bayesrel/00new/Bayesrel/libs/Bayesrel.so, 6): Symbol not found: _alloc_mat
Referenced from: /opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_R_R-Bayesrel/R-Bayesrel/work/.tmp/Rtmpejdz30/Rinstf32110e319b4/00LOCK-Bayesrel/00new/Bayesrel/libs/Bayesrel.so
Expected in: dynamic lookup
’
Loading required namespace: Bayesrel
Failed with error: ‘unable to load shared object '/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_R_R-Bayesrel/R-Bayesrel/work/.tmp/Rtmpejdz30/Rinstf32110e319b4/00LOCK-Bayesrel/00new/Bayesrel/libs/Bayesrel.so':
dlopen(/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_R_R-Bayesrel/R-Bayesrel/work/.tmp/Rtmpejdz30/Rinstf32110e319b4/00LOCK-Bayesrel/00new/Bayesrel/libs/Bayesrel.so, 6): Symbol not found: _alloc_mat
Referenced from: /opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_R_R-Bayesrel/R-Bayesrel/work/.tmp/Rtmpejdz30/Rinstf32110e319b4/00LOCK-Bayesrel/00new/Bayesrel/libs/Bayesrel.so
Expected in: dynamic lookup
’
Loading required namespace: Bayesrel
Failed with error: ‘unable to load shared object '/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_R_R-Bayesrel/R-Bayesrel/work/.tmp/Rtmpejdz30/Rinstf32110e319b4/00LOCK-Bayesrel/00new/Bayesrel/libs/Bayesrel.so':
dlopen(/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_R_R-Bayesrel/R-Bayesrel/work/.tmp/Rtmpejdz30/Rinstf32110e319b4/00LOCK-Bayesrel/00new/Bayesrel/libs/Bayesrel.so, 6): Symbol not found: _alloc_mat
Referenced from: /opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_R_R-Bayesrel/R-Bayesrel/work/.tmp/Rtmpejdz30/Rinstf32110e319b4/00LOCK-Bayesrel/00new/Bayesrel/libs/Bayesrel.so
Expected in: dynamic lookup
’
*** installing help indices
** building package indices
** testing if installed package can be loaded from temporary location
Error: package or namespace load failed for ‘Bayesrel’ in dyn.load(file, DLLpath = DLLpath, ...):
unable to load shared object '/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_R_R-Bayesrel/R-Bayesrel/work/.tmp/Rtmpejdz30/Rinstf32110e319b4/00LOCK-Bayesrel/00new/Bayesrel/libs/Bayesrel.so':
dlopen(/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_R_R-Bayesrel/R-Bayesrel/work/.tmp/Rtmpejdz30/Rinstf32110e319b4/00LOCK-Bayesrel/00new/Bayesrel/libs/Bayesrel.so, 6): Symbol not found: _alloc_mat
Referenced from: /opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_R_R-Bayesrel/R-Bayesrel/work/.tmp/Rtmpejdz30/Rinstf32110e319b4/00LOCK-Bayesrel/00new/Bayesrel/libs/Bayesrel.so
Expected in: dynamic lookup
Error: loading failed
Execution halted
ERROR: loading failed
* removing ‘/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_R_R-Bayesrel/R-Bayesrel/work/.tmp/Rtmpejdz30/Rinstf32110e319b4/Bayesrel’
-----------------------------------
ERROR: package installation failed
Command failed: cd "/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_R_R-Bayesrel/R-Bayesrel/work/Bayesrel" && /opt/local/bin/R CMD build . --no-manual --no-build-vignettes --keep-empty-dirs
Exit code: 1
alloc_mat
is in allocmat.c
file, and I do not get why it is not found now, and why everything else is found but only this one fails.
P. S. So far every other package builds fine (I am in a process of rebuilding about 4000 R
ports, and almost completed), this is the only error of this sort I encountered. So whatever broke done on my side, it shows up only in one specific case.
The GLB is remarkably slow. Here an attempt to speed it up. If this approach looks okay to you, I'll turn it into a pull request. (unit-tests would be very convenient here to see if I didn't break anything unintentionally :) )
library(Bayesrel)
get.prob.info2 <- function(K, m) {
# block.types <- ifelse(K$type == "s", 1, 2)
block.types <- (K$type != "s") + 1L
nblocks <- length(K$type)
block.sizes <- K$size
nconstraints <- m
ret <- list(nblocks = nblocks, nconstraints = nconstraints, block.types = block.types, block.sizes = block.sizes)
return(ret)
}
write.control.file2 <- function(control) {
fileptr <- file("param.csdp", "w")
for (i in 1:length(control)) cat(names(control)[i], "=", control[[i]], "\n", sep = "", file = fileptr)
close(fileptr)
}
glbOnArray <- function(Cov) {
d <- dim(Cov)
if (length(d) == 2L) { # turn it into an array if it is a matrix
d <- c(1L, d)
dim(Cov) <- d
}
nSamples <- d[1L]
p <- d[2L]
opt <- rep.int(1L, p)
A <- vector("list", p)
for (i in seq_len(p)) {
b <- rep(0, p)
b[i] <- 1
A[[i]] <- list(diag(b), -b, b)
}
K <- list(type = c("s", "l", "l"), size = rep(p, 3))
control <- Rcsdp::csdp.control(printlevel = 0)
write.control.file2(control)
on.exit(unlink("param.csdp"))
prob.info <- get.prob.info2(K, length(b))
LoBounds <- rep(0, p)
cv <- Cov[1L, , ]
Var <- diag(cv)
C <- list(diag(Var) - cv, -Var, LoBounds)
# make the Rcsdp object once instead of each iteration
prob.data <- list(
C = Rcsdp:::blkmatrix_R2csdp(C, prob.info),
A = Rcsdp:::constraints_R2csdp(A, prob.info),
b = as.double(c(0, opt))
)
glbs <- numeric(nSamples)
for (i in seq_len(nSamples)) {
cv <- Cov[i, , ]
Var <- diag(cv)
prob.data$C$blocks[[1L]]$data <- as.double(diag(Var) - cv)
prob.data$C$blocks[[2L]]$data <- as.double(c(0, -Var))
# The two lines above are equivalent to recreating the Rcsdp object:
# C <- list(diag(Var) - cv, -Var, LoBounds)
# prob.data0 <- Rcsdp:::prepare.data(C, A, opt, prob.info)
ret <- .Call(
"csdp",
as.integer(sum(prob.info$block.sizes)),
as.integer(prob.info$nconstraints),
as.integer(prob.info$nblocks),
as.integer(c(0, prob.info$block.types)),
as.integer(c(0, prob.info$block.sizes)),
prob.data$C,
prob.data$A,
prob.data$b,
PACKAGE = "Rcsdp"
)
scv <- sum(cv)
# ret[[3L]][-1L] is equivalent to:
# ret[1:3] <- Rcsdp:::get.solution(ret[[1L]], ret[[2L]], ret[[3L]], prob.info)
# result <- structure(ret, names = c("X", "Z", "y", "pobj", "dobj", "status"))
# or
# y <- vector_csdp2R(ret[[3L]])
glbs[i] <- (scv - sum(Var) + sum(ret[[3L]][-1L])) / scv
}
return(glbs)
}
dataset <- read.csv("https://raw.githubusercontent.com/jasp-stats/jasp-desktop/development/Resources/Data%20Sets/debug.csv")
# dataset <- read.csv("../jasp-desktop/Resources/Data Sets/debug.csv")
data <- dataset[, c("contNormal", "contGamma", "contcor1", "contcor2")]
res <- strel(x = data, freq = FALSE, n.iter = 500, item.dropped = TRUE, estimates = "alpha")
covsamp <- res$bay$covsamp
e0 <- glbOnArray(covsamp)
e1 <- apply(covsamp, 1L, Bayesrel:::applyglb)
all.equal(e0, e1)
bnch <- bench::mark(
expr1 = glbOnArray(covsamp),
expr2 = apply(covsamp, 1L, Bayesrel:::applyglb),
min_iterations = 25
)
which gives about a 10 fold speed increase:
> summary(bnch, relative = TRUE)[, 1:7]
expression min mean median max `itr/sec` mem_alloc
1 expr1 1 1 1 1 10.8 1
2 expr2 3.09 10.8 4.85 25.8 1 42.7
> bnch[, 1:7]
expression min mean median max `itr/sec` mem_alloc
1 expr1 55.2ms 95.01ms 73.1ms 186.56ms 10.5 1.94KB
2 expr2 170.4ms 1.03s 355ms 4.81s 0.973 82.66KB
I am not sure if this is really an issue, but when I use data, that has a diagonal matrix as a covariance matrix, or a zero matrix, I get quite weird results for the Bayesian estimates:
d1 <- diag(5)
e1 <- Bayesrel::strel(d1, n.obs = 200)
summary(e1)
d2 <- matrix(0, 5, 5)
e2 <- Bayesrel::strel(d2, n.obs = 200)
summary(e2)
Probably it's a good idea to use testthat
for automated testing.
e.g., see:
https://testthat.r-lib.org/
http://r-pkgs.had.co.nz/tests.html
The following code errors for some reason:
d <- structure(c(0.99122228, -1.953344972, 1.576301642, 0.947933415,
-0.532552496, -1.363597632, -0.654979378, -0.751445953, 0.310181524,
-0.675270732, 0.364848251, 0.525950287, -0.954597608, -0.399043745,
-2.336742886, -0.632883125, 0.588682079, 0.391750556, -1.264009159,
1.058565048, -0.850244619, -0.359553637, 0.108920494, 0.01096381,
2.739343353, -0.59740969, -0.470163224, -1.447375559, 0.505173357,
0.307537423, -1.395443011, -0.367996707, 0.793185108, 0.596201293,
-0.556843301, 0.644058891, -0.242813433, 1.410001008, -0.342746069,
-0.618288772, -0.692689912, -1.415363942, -0.786160472, -0.840984252,
-0.999014305, 1.007309698, -0.611664173, 0.46937728, -3.023963827,
0.166778121, 0.780975715, 1.661185538, 1.176677112, 1.331417271,
1.18426484, 2.478443291, 1.529750756, 0.348246238, 0.37865767,
2.777961973, 3.977031334, 2.656664043, 0.441790033, 0.678039819,
2.530188739, 3.306006111, 1.900242487, 1.761105829, 2.29457509,
0.942826432, 2.833575102, 1.839209197, 5.078108173, 1.383094211,
0.527073852, 4.618063242, 5.157894077, 2.363390504, 2.838679609,
0.660057008, 3.930940809, 2.230799959, 1.160636689, 0.197333889,
0.676660939, 4.975727839, 2.77466792, 1.532106738, 3.959582989,
0.991611379, 0.722313192, 0.614345924, 0.483241669, 2.359102511,
1.750826816, 4.321780883, 1.195401638, 2.984005893, 0.410306148,
0.302480929, 1.7e-20, 18858693.53, 1.37e-24, 1.02e+27, 2.98e-26,
1.9e+33, 2.96e+29, 1.01e+20, 1.56e+35, 1.74e-49, 3.29e-21, 8.89e-23,
3.38e-27, 5606.730444, 3427.815043, 2.04e+25, 1.25e-32, 10641603.08,
0.042666202, 0.008650772, 2.26e-17, 7.84e+29, 2043267.37, 204310864.6,
5.37e-12, 85379971.27, 8.75e-07, 0.503955858, 1.2e+22, 6.18e-06,
0.002978766, 28940.10745, 1.61e-07, 8.58e+33, 1.67e-13, 4.17e-07,
5.22e+17, 1.19e+23, 5.37e+36, 6.68e-23, 5.87e-12, 1.16e-26, 527.1268561,
48530.464, 5.54e-13, 6.2e-06, 9.36e-22, 3.44e+57, 1.22e-17, 9.71e-10
), .Dim = c(50L, 3L), .Dimnames = list(NULL, c("XY29udE5vcm1hbA",
"XY29udEdhbW1h", "XY29udEV4cG9u")))
Bayesrel::strel(x = d, freq = FALSE, n.iter = 5e2L)
Error in HPDinterval.mcmc(res$samp$bayes.glb, prob = interval) :
obj must have nsamp > 1
In addition: There were 50 or more warnings (use warnings() to see the first 50)
Tested with the latest CRAN version
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.