carpentries / sandpaper

User Interface for The Carpentries Workbench
https://carpentries.github.io/sandpaper
Other
41 stars 24 forks source link

ERROR: dependencies ‘pkgdown’, ‘pegboard’, ‘gh’, ‘gert’, ‘usethis’ are not available for package ‘sandpaper’ #584

Closed mxochicale closed 4 months ago

mxochicale commented 4 months ago

ERROR: dependencies ‘pkgdown’, ‘pegboard’, ‘gh’, ‘gert’, ‘usethis’ are not available for package ‘sandpaper’ in R version 4.4.0 (2024-04-24) under ubuntu22.04.2LS with install.packages("sandpaper", dep =TRUE)

I am expecting to run install.packages("sandpaper", dep = TRUE) without errors. Any recommendations?

See full terminal log ``` R version 4.4.0 (2024-04-24) -- "Puppy Cup" Copyright (C) 2024 The R Foundation for Statistical Computing Platform: x86_64-pc-linux-gnu R is free software and comes with ABSOLUTELY NO WARRANTY. You are welcome to redistribute it under certain conditions. Type 'license()' or 'licence()' for distribution details. R is a collaborative project with many contributors. Type 'contributors()' for more information and 'citation()' on how to cite R or R packages in publications. Type 'demo()' for some demos, 'help()' for on-line help, or 'help.start()' for an HTML browser interface to help. Type 'q()' to quit R. [Previously saved workspace restored] > options(repos = c( carpentries = "https://carpentries.r-universe.dev/", CRAN = "https://cran.rstudio.com/" )) install.packages("sandpaper", dep =TRUE) Installing package into ‘/home/mxochicale/R/x86_64-pc-linux-gnu-library/4.4’ (as ‘lib’ is unspecified) also installing the dependencies ‘httr’, ‘tinkr’, ‘httr2’, ‘credentials’, ‘curl’, ‘pkgdown’, ‘pegboard’, ‘gh’, ‘gert’, ‘usethis’, ‘covr’, ‘xml2’, ‘xslt’ trying URL 'https://cran.rstudio.com/src/contrib/httr_1.4.7.tar.gz' Content type 'application/x-gzip' length 118500 bytes (115 KB) ================================================== downloaded 115 KB trying URL 'https://carpentries.r-universe.dev/src/contrib/tinkr_0.2.0.9000.tar.gz' Content type 'application/x-gzip' length 196451 bytes (191 KB) ================================================== downloaded 191 KB trying URL 'https://cran.rstudio.com/src/contrib/httr2_1.0.1.tar.gz' Content type 'application/x-gzip' length 214736 bytes (209 KB) ================================================== downloaded 209 KB trying URL 'https://cran.rstudio.com/src/contrib/credentials_2.0.1.tar.gz' Content type 'application/x-gzip' length 283844 bytes (277 KB) ================================================== downloaded 277 KB trying URL 'https://carpentries.r-universe.dev/src/contrib/curl_5.2.1.tar.gz' Content type 'application/x-gzip' length 307664 bytes (300 KB) ================================================== downloaded 300 KB trying URL 'https://cran.rstudio.com/src/contrib/pkgdown_2.0.9.tar.gz' Content type 'application/x-gzip' length 855137 bytes (835 KB) ================================================== downloaded 835 KB trying URL 'https://carpentries.r-universe.dev/src/contrib/pegboard_0.7.5.tar.gz' Content type 'application/x-gzip' length 538733 bytes (526 KB) ================================================== downloaded 526 KB trying URL 'https://cran.rstudio.com/src/contrib/gh_1.4.1.tar.gz' Content type 'application/x-gzip' length 46164 bytes (45 KB) ================================================== downloaded 45 KB trying URL 'https://cran.rstudio.com/src/contrib/gert_2.0.1.tar.gz' Content type 'application/x-gzip' length 122723 bytes (119 KB) ================================================== downloaded 119 KB trying URL 'https://cran.rstudio.com/src/contrib/usethis_2.2.3.tar.gz' Content type 'application/x-gzip' length 371088 bytes (362 KB) ================================================== downloaded 362 KB trying URL 'https://cran.rstudio.com/src/contrib/covr_3.6.4.tar.gz' Content type 'application/x-gzip' length 163362 bytes (159 KB) ================================================== downloaded 159 KB trying URL 'https://carpentries.r-universe.dev/src/contrib/xml2_1.3.6.tar.gz' Content type 'application/x-gzip' length 313774 bytes (306 KB) ================================================== downloaded 306 KB trying URL 'https://cran.rstudio.com/src/contrib/xslt_1.4.5.tar.gz' Content type 'application/x-gzip' length 17800 bytes (17 KB) ================================================== downloaded 17 KB trying URL 'https://carpentries.r-universe.dev/src/contrib/sandpaper_0.16.4.tar.gz' Content type 'application/x-gzip' length 690994 bytes (674 KB) ================================================== downloaded 674 KB * installing *source* package ‘curl’ ... ** using staged installation Package libcurl was not found in the pkg-config search path. Perhaps you should add the directory containing `libcurl.pc' to the PKG_CONFIG_PATH environment variable No package 'libcurl' found Package libcurl was not found in the pkg-config search path. Perhaps you should add the directory containing `libcurl.pc' to the PKG_CONFIG_PATH environment variable No package 'libcurl' found Using PKG_CFLAGS= Using PKG_LIBS=-lcurl --------------------------- [ANTICONF] -------------------------------- Configuration failed because libcurl was not found. Try installing: * deb: libcurl4-openssl-dev (Debian, Ubuntu, etc) * rpm: libcurl-devel (Fedora, CentOS, RHEL) If libcurl is already installed, check that 'pkg-config' is in your PATH and PKG_CONFIG_PATH contains a libcurl.pc file. If pkg-config is unavailable you can set INCLUDE_DIR and LIB_DIR manually via: R CMD INSTALL --configure-vars='INCLUDE_DIR=... LIB_DIR=...' -------------------------- [ERROR MESSAGE] --------------------------- :1:10: fatal error: curl/curl.h: No such file or directory compilation terminated. -------------------------------------------------------------------- ERROR: configuration failed for package ‘curl’ * removing ‘/home/mxochicale/R/x86_64-pc-linux-gnu-library/4.4/curl’ * installing *source* package ‘xml2’ ... ** using staged installation Package libxml-2.0 was not found in the pkg-config search path. Perhaps you should add the directory containing `libxml-2.0.pc' to the PKG_CONFIG_PATH environment variable No package 'libxml-2.0' found Package libxml-2.0 was not found in the pkg-config search path. Perhaps you should add the directory containing `libxml-2.0.pc' to the PKG_CONFIG_PATH environment variable No package 'libxml-2.0' found Using PKG_CFLAGS= Using PKG_LIBS=-lxml2 ------------------------- ANTICONF ERROR --------------------------- Configuration failed because libxml-2.0 was not found. Try installing: * deb: libxml2-dev (Debian, Ubuntu, etc) * rpm: libxml2-devel (Fedora, CentOS, RHEL) * csw: libxml2_dev (Solaris) If libxml-2.0 is already installed, check that 'pkg-config' is in your PATH and PKG_CONFIG_PATH contains a libxml-2.0.pc file. If pkg-config is unavailable you can set INCLUDE_DIR and LIB_DIR manually via: R CMD INSTALL --configure-vars='INCLUDE_DIR=... LIB_DIR=...' -------------------------------------------------------------------- ERROR: configuration failed for package ‘xml2’ * removing ‘/home/mxochicale/R/x86_64-pc-linux-gnu-library/4.4/xml2’ ERROR: dependency ‘curl’ is not available for package ‘httr’ * removing ‘/home/mxochicale/R/x86_64-pc-linux-gnu-library/4.4/httr’ ERROR: dependency ‘curl’ is not available for package ‘httr2’ * removing ‘/home/mxochicale/R/x86_64-pc-linux-gnu-library/4.4/httr2’ ERROR: dependency ‘curl’ is not available for package ‘credentials’ * removing ‘/home/mxochicale/R/x86_64-pc-linux-gnu-library/4.4/credentials’ ERROR: dependency ‘xml2’ is not available for package ‘xslt’ * removing ‘/home/mxochicale/R/x86_64-pc-linux-gnu-library/4.4/xslt’ ERROR: dependencies ‘xml2’, ‘xslt’ are not available for package ‘tinkr’ * removing ‘/home/mxochicale/R/x86_64-pc-linux-gnu-library/4.4/tinkr’ ERROR: dependencies ‘httr’, ‘xml2’ are not available for package ‘pkgdown’ * removing ‘/home/mxochicale/R/x86_64-pc-linux-gnu-library/4.4/pkgdown’ ERROR: dependency ‘httr2’ is not available for package ‘gh’ * removing ‘/home/mxochicale/R/x86_64-pc-linux-gnu-library/4.4/gh’ ERROR: dependency ‘credentials’ is not available for package ‘gert’ * removing ‘/home/mxochicale/R/x86_64-pc-linux-gnu-library/4.4/gert’ ERROR: dependency ‘httr’ is not available for package ‘covr’ * removing ‘/home/mxochicale/R/x86_64-pc-linux-gnu-library/4.4/covr’ ERROR: dependencies ‘tinkr’, ‘xml2’, ‘xslt’ are not available for package ‘pegboard’ * removing ‘/home/mxochicale/R/x86_64-pc-linux-gnu-library/4.4/pegboard’ ERROR: dependencies ‘curl’, ‘gert’, ‘gh’ are not available for package ‘usethis’ * removing ‘/home/mxochicale/R/x86_64-pc-linux-gnu-library/4.4/usethis’ ERROR: dependencies ‘pkgdown’, ‘pegboard’, ‘gh’, ‘gert’, ‘usethis’ are not available for package ‘sandpaper’ * removing ‘/home/mxochicale/R/x86_64-pc-linux-gnu-library/4.4/sandpaper’ The downloaded source packages are in ‘/tmp/RtmpB91BgB/downloaded_packages’ There were 14 warnings (use warnings() to see them) ```
milanmlft commented 4 months ago

Relevant part of the log:

------------------------- ANTICONF ERROR ---------------------------
Configuration failed because libxml-2.0 was not found. Try installing:
 * deb: libxml2-dev (Debian, Ubuntu, etc)
 * rpm: libxml2-devel (Fedora, CentOS, RHEL)
 * csw: libxml2_dev (Solaris)
If libxml-2.0 is already installed, check that 'pkg-config' is in your
PATH and PKG_CONFIG_PATH contains a libxml-2.0.pc file. If pkg-config
is unavailable you can set INCLUDE_DIR and LIB_DIR manually via:
R CMD INSTALL --configure-vars='INCLUDE_DIR=... LIB_DIR=...'
--------------------------------------------------------------------

You're missing the libxml external dependency. Instructions are in the log above 🙂 Make sure you restart your R session after installing libxml before retrying

mxochicale commented 4 months ago

Thanks @milanmlft , I was missing that one and these two libgit2-dev, r-cran-curl:

sudo apt-get install r-cran-xml
sudo apt-get install libxml2-dev
sudo apt install libgit2-dev
sudo apt install r-cran-curl

:tada: * DONE (sandpaper)