Skip to content
Prev 21044 / 63424 Next

about integration of a library into package creation

Nicolas Turenne wrote:
I think you are doing too much! 

1.  You should not use "useDynLib" for the DLL from another package.  
Let the other package load its own DLL.

2.  If you declare that your package Depends on the other packages, then 
they will be loaded and attached, and the importFrom lines will not be 
needed. 

"Import"ing and "Depend"ing are similar but not identical concepts.  
Routines that are imported are available to your package *before* the 
global environment (i.e. user workspace).  Routines that are in packages 
attached by Depends come after the global environment, so there's a 
possibility that the user could create a routine named e.g. "mstree", 
and your code would use that version, rather than the one from ade4.  So 
normally "Imports" is better than "Depends".

However, it appears that you can only import packages that have a 
namespace.  (I was unaware of this restriction; perhaps it's not really 
true, and the error message means something else.)

So you can probably get rid of the error message by using only Depends, 
but you may want to keep the Imports from packages other than quadprog.

Duncan Murdoch

Thread (19 messages)

Nicolas Turenne about integration of a library into package creation Jun 12 Duncan Murdoch about integration of a library into package creation Jun 12 Nicolas Turenne about integration of a library into package creation Jun 12 Brian Ripley about integration of a library into package creation Jun 12 Nicolas Turenne about integration of a library into package creation Jun 12 Duncan Murdoch about integration of a library into package creation Jun 12 Nicolas Turenne about integration of a library into package creation Jun 12 Uwe Ligges about integration of a library into package creation Jun 12 Martin Maechler about integration of a library into package creation Jun 12 Nicolas Turenne about integration of a library into package creation Jun 13 Uwe Ligges about integration of a library into package creation Jun 13 Duncan Murdoch about integration of a library into package creation Jun 13 Nicolas Turenne about integration of a library into package creation Jun 13 Duncan Murdoch about integration of a library into package creation Jun 13 Nicolas Turenne about integration of a library into package creation Jun 13 Duncan Murdoch about integration of a library into package creation Jun 13 Nicolas Turenne about integration of a library into package creation Jun 13 Brian Ripley about integration of a library into package creation Jun 13 Nicolas Turenne about integration of a library into package creation Jun 14