Jon Olav Skoien wrote: > Hi, > > I want to cross-reference from the documentation of pkg1 to pkg2, which > is imported in the NAMESPACE of pkg1, and under Depends in DESCRIPTION > of pkg1. According to "Writing R extensions", this can be done by: > \code{\link{foo}} > when foo is an aliased function in the documentation of pkg2. This works > as it should when I install the package, but when I run R CMD check > pgk1, I get a warning: > > * checking Rd cross-references ... WARNING > Missing link(s) in documentation object 'fooPkg1.Rd' > foo > > I have tried to change the link to > \code{\link[pkg2]{foo}} > \code{\link[pkg:pkg2]{foo}}
Hi Jon -- I think the current requirement is \link[pkg2;foo_Rd_file_name]{foo} where foo_Rd_file_name is the name (without the .Rd extension) of the FILE in which foo is documented. This would appear not to be foo.Rd, because you say \link[pkg2]{foo} fails. This is as documented in Writing R extensions. > None of these works, the first gives a link that leads to an error page, > and the second one gives a link that does not work at all. I assume this > is as it should be; foo.Rd does not exist. However, R CMD check does not > complain about any of these links... Try building with R-devel, where the error messages are more detailed. > Why does R CMD check warn me against links that work? I think pkg2 is I think the idea is that the cross-package links as you originally specified work for some help formats, but not for others (e.g., pdf). Martin > not on the search path when looking for cross-references, but why? R CMD > check continues to run after the warning without any complaints, and all > tests rely on pkg2. I am quite sure there is something simple that I > have overlooked, but cannot figure out what it is. > > Best wishes, > Jon > > Platform etc: > XP SP3, R 2.9-2, Rtools210 (the problem was also there before upgrading > from R 2.9-1 and Rtools29 ) > > ______________________________________________ > R-help@r-project.org mailing list > https://stat.ethz.ch/mailman/listinfo/r-help > PLEASE do read the posting guide > http://www.R-project.org/posting-guide.html > and provide commented, minimal, self-contained, reproducible code. ______________________________________________ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code.