R CMD build
Rd ファイルに含まれているかどうかにかかわらず、動作が異なります\PR{}
。マクロの詳細については、R拡張機能の記述を参照してください。
Rd ファイルに が含まれていない場合の例\PR{}
:
$ R CMD build test
* checking for file 'test/DESCRIPTION' ... OK
* preparing 'test':
* checking DESCRIPTION meta-information ... OK
* installing the package to process help pages
* saving partial Rd database
* checking for LF line-endings in source and make files and shell scripts
* checking for empty or unneeded directories
* building 'test_0.1.tar.gz'
Rd ファイルに次のものが含まれている場合の例\PR{}
:
$ R CMD build test
* checking for file 'test/DESCRIPTION' ... OK
* preparing 'test':
* checking DESCRIPTION meta-information ... OK
* installing the package to process help pages
* saving partial Rd database
* building the PDF package manual # <- this
Hmm ... looks like a package # <- this
Converting Rd files to LaTeX # <- this
Creating pdf output from LaTeX ... # <- this
Saving output to 'xxx/test.pdf' ... # <- this
Done # <- this
* checking for LF line-endings in source and make files and shell scripts
* checking for empty or unneeded directories
* building 'test_0.1.tar.gz'
追加の段階 (つまりbuilding the PDF package manual
、古いコンピューターでは非常に遅くなる可能性があります...) は、.build_packages (行 619-625)の..Rd2pdfへの呼び出しによるものです。しかし、何がこの段階を引き起こすのかわかりません。さらに、やなどの他のマクロに対してのみトリガーされ、トリガーされません。\PR{}
\CRANpkg{}
\doi{}
誰かが何が起こったのか、そしてその理由を追跡できますか? 質問は基本R関数のみです。などのヘルパーは使用しませんdevtools
。
最小限のテスト パッケージ
パッケージ構造
test
test/man
test/man/one.Rd
test/R
test/R/one.R
test/DESCRIPTION
test/NAMESPACE
test/man/one.Rd
\name{one}
\alias{one}
\title{Get One}
\description{
Rd file containing or not the PR macro:
\PR{1} % comment/uncomment this line as needed
but containing other macros:
\CRANpkg{ggplot2} and \doi{10.1002/wics.147}
}
\usage{
one()
}
test/R/one.R
one <- function() 1
test/DESCRIPTION
Package: test
Version: 0.1
Title: Test
Author: Nobody
Maintainer: Nobody <no@body.org>
Description: Test.
License: GPL-3
test/NAMESPACE
export(one)
以下を使用してビルド、チェック、およびインストールします。
$ R CMD build test
$ R CMD check test_0.1.tar.gz
$ R CMD INSTALL test_0.1.tar.gz