[Rcpp-devel] Ancient Rcpp for OS X on CRAN [Was: Building/linking trouble with cxxfunction()]
Simon Urbanek
simon.urbanek at r-project.org
Wed Feb 23 00:22:19 CET 2011
On Feb 22, 2011, at 5:46 PM, <Ken.Williams at thomsonreuters.com> <Ken.Williams at thomsonreuters.com> wrote:
> On 2/22/11 4:32 PM, "Dirk Eddelbuettel" <edd at debian.org> wrote:
>>
>> What boolean test for 'am I on OS X 10.5' can you suggest?
>
> You could use system("uname -r"), which on my system gives 10.6.0 (even
> though my system is 10.6.6)
uname -r (and Sys.info()['release']) shows the Darwin release, so 10.6.0 means OS X 10.6.6 since OS X versions are 10.(darwin_maj - 4).darwin_min so 10.(10 - 4).6 = 10.6.6. It would be more obvious if you didn't have exactly 10.6.6 ;)
Cheers,
Simon
> and on a 10.5.x system seems to give
> 9.something.
>
> Or if you don't mind a command that will only exist on OS X, you can do
> system("sw_vers -productVersion"), which gives the actual OS version.
>
>
> --
> Ken Williams
> Senior Research Scientist
> Thomson Reuters
> http://labs.thomsonreuters.com
>
>
>
More information about the Rcpp-devel
mailing list