From murdoch at stats.uwo.ca  Tue Dec 27 22:57:40 2005
From: murdoch at stats.uwo.ca (Duncan Murdoch)
Date: Tue, 27 Dec 2005 16:57:40 -0500
Subject: [Rd] Portability and Memory Issues for R-package
In-Reply-To: <5A0AA3EF31FA5545B010F180E03F929A042E11AF@UNISMSX02.internal.imsglobal.com>
References: <5A0AA3EF31FA5545B010F180E03F929A042E11AF@UNISMSX02.internal.imsglobal.com>
Message-ID: <43B1B8D4.5080005@stats.uwo.ca>

On 12/27/2005 3:44 PM, KNygren at us.imshealth.com wrote:
> My guess is that the key step for a user to be able to use my package still would be to install the gsl library first so it can be accessed during the build. I am not sure if Robin has a set of instructions for platform specific installation of his package (which would likely include the pre-installation of the gsl library).

This is not necessary on Windows, where most users install binary builds 
of packages, because Brian Ripley has done the work to put together a 
binary build that includes the necessary GSL routines.  I would expect 
that if you require users to install GSL and compile your package 
themselves, you'll get almost no Windows users.  I don't know what is 
involved in installing the package on other platforms.

Duncan Murdoch

> I may follow up with him in regards to this and to see if it makes sense to link to his library. I will also look into the possibility of adding a configure script (as per Jan's suggestion). I know that the use of the gsl library is not ideal, and may eventually try to replace the gsl dependent code, perhaps by making use of the R matrix package (though I don't know if it has all the features I am currently using).    
> 
> 
> Kjell Nygren 
>  
> 
>>I. Portability-
>>
>>Since I make extensive use of the gsl library in my C code, I have the gsl library installed (within the MinGw directory so it is included in the path) on my local machine. Within the package, I am then including a Makevars file with the following code in order to link to the gsl library:
>>
>>PKG_LIBS=-lgsl -lgslcblas
>>
>>I also know that there is an R package (gsl) making use of some gsl functions which contains a Makevars.win file with the following code:
> 
> 
> This package requires manual handling to build for Windows, and probably 
> for some other platforms if they don't come with gsl by default.
> 
> My recommendation would be to work with its author (Robin Hankin, see 
> the DESCRIPTION file for contact information) to add whatever functions 
> are not already there, and then just make your package depend on the R 
> package, rather than on the GSL library directly.
> 
> This will mean that all the manual work that has been done to get gsl to 
> build will not need to be repeated by anyone who wants to install your 
> package.
> 
> Duncan Murdoch
> 
> ______________________________________________
> R-devel at r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/r-devel



[Rd] Portability and Memory Issues for R-package
Duncan Murdoch