From ripley at stats.ox.ac.uk  Thu Aug 11 18:39:08 2011
From: ripley at stats.ox.ac.uk (Prof Brian Ripley)
Date: Thu, 11 Aug 2011 17:39:08 +0100 (BST)
Subject: [Rd] autogenerated namespaces not initialized correctly
In-Reply-To: <CAOQ5Nyf=4O8RZUakZ4NPpD80VFnfTnyjy9AmyhHjHnV38ER7GQ@mail.gmail.com>
References: <CAOQ5Nyf=4O8RZUakZ4NPpD80VFnfTnyjy9AmyhHjHnV38ER7GQ@mail.gmail.com>
Message-ID: <alpine.LFD.2.02.1108111735240.10826@gannet.stats.ox.ac.uk>

On Thu, 11 Aug 2011, Michael Lawrence wrote:

> Hi guys,
>
> This probably isn't news, but when a package is given an autogenerated
> namespace, its .First.lib, if any, is no longer called.

Please do read the NEWS file: .First.lib *is* called as either .onLoad 
or .onAttach.

> This causes problems, e.g., when a package is loading a dynamic 
> library. Probably no good solution here. The initialization routines 
> could be made to call .First.lib, code could be rewritten on the 
> fly, a useDynlib() could be added for a package that has one, etc. 
> Nothing too appealing.

But actually it works well enough in 97% of the cases on CRAN.

>
> Thanks,
> Michael
>
> 	[[alternative HTML version deleted]]

Please do follow the posting guide!

> _____________________________________________
> R-devel at r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/r-devel
>

-- 
Brian D. Ripley,                  ripley at stats.ox.ac.uk
Professor of Applied Statistics,  http://www.stats.ox.ac.uk/~ripley/
University of Oxford,             Tel:  +44 1865 272861 (self)
1 South Parks Road,                     +44 1865 272866 (PA)
Oxford OX1 3TG, UK                Fax:  +44 1865 272595



[Rd] autogenerated namespaces not initialized correctly
Prof Brian Ripley