I am having trouble to build a dummy testing package for R on windows.
for testing purpose,in R terminal, I input:
a=rnorm(10)
package.skeleton("pkgtest")
then I run R CMD check pkgtest on this dummy package and got error like
* using R version 2.12.0 (2010-10-15)
* using platform: i386-pc-mingw32 (32-bit)
* using session charset: ISO8859-1
* checking for file 'pkgtest/DESCRIPTION' ... OK
* checking extension type ... Package
* this is package 'pkgtest' version '1.0'
* checking package dependencies ... OK
* checking if this is a source package ... OK
* checking for executable files ... OK
* checking whether package 'pkgtest' can be installed ... ERROR Installation failed.
EDIT,The full log file:
* installing *source* package 'pkgtest' ...
** libs
cygwin warning:
MS-DOS style path detected: C:/R/R-212~1.0/etc/i386/Makeconf
Preferred POSIX equivalent is: /cygdrive/c/R/R-212~1.0/etc/i386/Makeconf
CYGWIN environment variable option "nodosfilewarning" turns off this warning.
Consult the user's guide for more details about POSIX paths:
http://cygwin.com/cygwin-ug-net/using.html#using-pathnames
ERROR: compilation failed for package 'pkgtest'
`* removing 'C:/DOCUME~1/xxxx'`
That is all. I have a data a in the data folder, so it is not empty. The Rd file can actually compile to pdf by Rcmd rd2pdf, its title is not empty.
did I missing something very basic for this error? I Have Rtools2.12 installed. I even have package inline and Rcpp intalled and running examples fine.
To test my R environment setup, I downloaded Rcpp source package and did a R cmd check on Rcpp, it went fine.
Yes, a lot if all you did were the steps documented above.
Firstly, did you do as the output from
package.skeletonasks you to?:In particular the last line.
You don’t quote the full CHECK log, I get:
So you should go and check the contents of the
.outfile it mentions. I have the following in that file:Which is fairly self-explanatory, once you look at the package source.
You needed at least:
And then you should note that you do have to edit the Rd files. It is a design feature that
prompt()andpackage.skeleton()do not create valid Rd files to get package authors to write the minimum documentation for their packages.