From iago.mosqueira at gmail.com  Tue Nov 11 17:50:27 2008
From: iago.mosqueira at gmail.com (Iago Mosqueira)
Date: Tue, 11 Nov 2008 17:50:27 +0100
Subject: [Rd] Linking to headers and shared library in another package
Message-ID: <4919B7D3.8050105@gmail.com>

Hi,

A package with some C code needs to use the headers and shared library
in another package during installation/compilation. The first one is
achieved through the LinkingTo option in DESCRIPTION. For the second a
Makevars file with

PKG_LIBS=$(R_HOME)/library/firstPkg/libs/firstPkg.so

was being used. Problem this is not portable if the firstPkg package is
not installed in the library folder inside R_HOME but lives somewhere else.

What is the best way for Makevars or configure to find where a package
lives? Or is there any other way to make sure the linking step finds
where the shared library is located?

Apologies if I missed something in the extensions manual, but my limited
experience with autoconf might have made me not notice it.

Many thanks,


Iago



[Rd] Linking to headers and shared library in another package
Iago Mosqueira