On Fri, 4 Mar 2022 08:23:43 -0500 Brian Lunergan <ff809 at ncf.ca> wrote:> Running R 4.1.2 on Linux Mint 19.3.> g++ -std=gnu++11 -I"/usr/share/R/include" -DNDEBUG -I../inst/include > -I'/home/brian/R/x86_64-pc-linux-gnu-library/4.1/testthat/include' > -fpic -g -O2 -fdebug-prefix-map=/build/r-base-J7pprH/r-base-4.1.2=. > -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time > -D_FORTIFY_SOURCE=2 -g -c test-runner.cpp -o test-runner.o > g++ -std=gnu++11 -shared -L/usr/lib/R/lib -Wl,-Bsymbolic-functions > -Wl,-z,relro -o nloptr.so init_nloptr.o nloptr.o test-C-API.o > test-runner.o -llapack -lblas -lgfortran -lm -lquadmath -Lnlopt/lib > -lnlopt -L/usr/lib/R/lib -lR > /usr/bin/ld: cannot find -lnlopt > collect2: error: ld returned 1 exit statusTypically, when an R package wraps a third-party library, you need a development version of it installed in order to install that package from source. If you're running R from the Linux Mint repos, try to install r-cran-nloptr from Linux Mint repositories. If you don't, or have some trouble installing the package, install the libnlopt-dev Linux Mint package before trying to install the nloptr R package. -- Best regards, Ivan
On 2022-03-04 8:34 a.m., Ivan Krylov wrote:> Typically, when an R package wraps a third-party library, you need a > development version of it installed in order to install that package > from source. > > If you're running R from the Linux Mint repos, try to install > r-cran-nloptr from Linux Mint repositories. If you don't, or have some > trouble installing the package, install the libnlopt-dev Linux Mint > package before trying to install the nloptr R package. >libnlopt-dev installed okay, but when I tried pulling in the r-cran package I got this: brian at brian-Aspire-ES1-511:~$ sudo apt-get install r-cran-nloptr Reading package lists... Done Building dependency tree Reading state information... Done Some packages could not be installed. This may mean that you have requested an impossible situation or if you are using the unstable distribution that some required packages have not yet been created or been moved out of Incoming. The following information may help resolve the situation: The following packages have unmet dependencies: r-cran-nloptr : Depends: r-api-3.4 E: Unable to correct problems, you have held broken packages. I'll try the R site, but I'm open to other ideas.:-( -- Brian Lunergan Russell, ON Canada -------------- next part -------------- A non-text attachment was scrubbed... Name: OpenPGP_signature Type: application/pgp-signature Size: 665 bytes Desc: OpenPGP digital signature URL: <https://stat.ethz.ch/pipermail/r-help/attachments/20220304/7e3cc72a/attachment.sig>