RStudio 和 Travis CI 构建检查不匹配 (libudunits2.so)
RStudio and Travis CI build check do NOT match (libudunits2.so)
Travis CI 检测到 RStudio
中 Build > Check
没有为我的 lares
库找到的问题(在 Github 中发现为 laresbernardo/lares).根据 Travis CI 的说法,我最后一次 "Passed" 提交实际上是一个拼写错误更改,因此库的代码不应该是问题所在;因此,当我 运行 devtools::check()
访问库时,我收到了很好的 R CMD check succeeded
消息,其中包含 0 个错误、警告或注释。
我已经尝试了消息建议的内容和其他内容:
- 运行
brew install udunits
在终端 (macOS)
- 使用
install.packages(units)
通过 CRAN 安装库
- 并通过 Github (dev) 与
devtools::install_github("r-quantities/units", args="--configure-args='--with-udunits2-lib=/usr/local/lib'")
- 和
devtools::install_github("r-quantities/units", args="--configure-args='--with-udunits2-include=/usr/include/udunits2'")
这是 Travis CI 日志的结尾,也可以在这里找到:https://travis-ci.org/laresbernardo/lares
(...)
checking for ut_read_xml in -ludunits2... no
configure: error: in `/tmp/RtmpITNXhh/R.INSTALL3d3b9a0f951/units':
configure: error:
--------------------------------------------------------------------------------
Configuration failed because libudunits2.so was not found. Try installing:
* deb: libudunits2-dev (Debian, Ubuntu, ...)
* rpm: udunits2-devel (Fedora, EPEL, ...)
* brew: udunits (OSX)
If udunits2 is already installed in a non-standard location, use:
--configure-args='--with-udunits2-lib=/usr/local/lib'
if the library was not found, and/or:
--configure-args='--with-udunits2-include=/usr/include/udunits2'
if the header was not found, replacing paths with appropriate values.
You can alternatively set UDUNITS2_INCLUDE and UDUNITS2_LIBS manually.
--------------------------------------------------------------------------------
See `config.log' for more details
ERROR: configuration failed for package ‘units’
* removing ‘/home/travis/R/Library/units’
Error in i.p(...) :
(converted from warning) installation of package ‘units’ had non-zero exit status
Calls: <Anonymous> ... with_rprofile_user -> with_envvar -> force -> force -> i.p
Execution halted
The command "Rscript -e 'deps <- devtools::dev_package_deps(dependencies = NA);devtools::install_deps(dependencies = TRUE);if (!all(deps$package %in% installed.packages())) { message("missing: ", paste(setdiff(deps$package, installed.packages()), collapse=", ")); q(status = 1, save = "no")}'" failed and exited with 1 during .
Your build has been stopped.
我没主意了。它是 stringi
或 units
库中的更改吗?还是 Travis CI 问题?或者我的图书馆中的某些东西设置不同?
已解决将以下内容添加到 .travis.yml
文件!我必须指定需要安装此库。
addons:
apt:
packages:
- libudunits2-dev
感谢 units
库的开发者 Iñaki Ucar 提供了非常有用的答案。
Travis CI 检测到 RStudio
中 Build > Check
没有为我的 lares
库找到的问题(在 Github 中发现为 laresbernardo/lares).根据 Travis CI 的说法,我最后一次 "Passed" 提交实际上是一个拼写错误更改,因此库的代码不应该是问题所在;因此,当我 运行 devtools::check()
访问库时,我收到了很好的 R CMD check succeeded
消息,其中包含 0 个错误、警告或注释。
我已经尝试了消息建议的内容和其他内容:
- 运行
brew install udunits
在终端 (macOS) - 使用
install.packages(units)
通过 CRAN 安装库
- 并通过 Github (dev) 与
devtools::install_github("r-quantities/units", args="--configure-args='--with-udunits2-lib=/usr/local/lib'")
- 和
devtools::install_github("r-quantities/units", args="--configure-args='--with-udunits2-include=/usr/include/udunits2'")
这是 Travis CI 日志的结尾,也可以在这里找到:https://travis-ci.org/laresbernardo/lares
(...)
checking for ut_read_xml in -ludunits2... no
configure: error: in `/tmp/RtmpITNXhh/R.INSTALL3d3b9a0f951/units':
configure: error:
--------------------------------------------------------------------------------
Configuration failed because libudunits2.so was not found. Try installing:
* deb: libudunits2-dev (Debian, Ubuntu, ...)
* rpm: udunits2-devel (Fedora, EPEL, ...)
* brew: udunits (OSX)
If udunits2 is already installed in a non-standard location, use:
--configure-args='--with-udunits2-lib=/usr/local/lib'
if the library was not found, and/or:
--configure-args='--with-udunits2-include=/usr/include/udunits2'
if the header was not found, replacing paths with appropriate values.
You can alternatively set UDUNITS2_INCLUDE and UDUNITS2_LIBS manually.
--------------------------------------------------------------------------------
See `config.log' for more details
ERROR: configuration failed for package ‘units’
* removing ‘/home/travis/R/Library/units’
Error in i.p(...) :
(converted from warning) installation of package ‘units’ had non-zero exit status
Calls: <Anonymous> ... with_rprofile_user -> with_envvar -> force -> force -> i.p
Execution halted
The command "Rscript -e 'deps <- devtools::dev_package_deps(dependencies = NA);devtools::install_deps(dependencies = TRUE);if (!all(deps$package %in% installed.packages())) { message("missing: ", paste(setdiff(deps$package, installed.packages()), collapse=", ")); q(status = 1, save = "no")}'" failed and exited with 1 during .
Your build has been stopped.
我没主意了。它是 stringi
或 units
库中的更改吗?还是 Travis CI 问题?或者我的图书馆中的某些东西设置不同?
已解决将以下内容添加到 .travis.yml
文件!我必须指定需要安装此库。
addons:
apt:
packages:
- libudunits2-dev
感谢 units
库的开发者 Iñaki Ucar 提供了非常有用的答案。