[Bioc-devel] compiling C code in distributed packages

Sean Davis sdavis2 at mail.nih.gov
Tue Jul 29 00:53:58 CEST 2008


On Mon, Jul 28, 2008 at 6:23 PM, mattia pelizzola
<mattia.pelizzola at gmail.com> wrote:
> Hi,
>
> I'm new in using C code into R packages, so I apologize if my question
> looks silly.
> I'm testing a library containing C code. It works fine on the Linux
> system where I created it, and I can easily install and use it into a
> Windows system that has been set up to build packages. Rather, when I
> try to install it into a Mac, I get an error message presumably  since
> the system is lacking C/C++ compilers:
>
> * Installing *source* package 'foo' ...
> ** libs
> ** arch - i386
> /Library/Frameworks/R.framework/Resources/bin/SHLIB: line 1: make:
> command not found
> chmod: /Library/Frameworks/R.framework/Versions/2.7/Resources/library/foo/libs/i386/*:
> No such file or directory
> ** arch - ppc
> /Library/Frameworks/R.framework/Resources/bin/SHLIB: line 1: make:
> command not found
> chmod: /Library/Frameworks/R.framework/Versions/2.7/Resources/library/foo/libs/ppc/*:
> No such file or directory
> ERROR: compilation failed for package 'foo'
> ** Removing '/Library/Frameworks/R.framework/Versions/2.7/Resources/library/foo'
> ** Restoring previous
> '/Library/Frameworks/R.framework/Versions/2.7/Resources/library/foo'
> .
>
> Does this mean that additional software is always required to use R
> libraries with embedded C code ? (the Xcode that would be necessary in
> Mac is 1Gb..)
> This sounds weird to me since I know that many libraries use C code
> and I already installed them on many computers without having the
> requirement of installing developmental software.
>
> Are the packages with C code released from R or Bioconductor different
> from the one that I'm building by my self?

Yes.  To build from source, you will need to install Xcode.  The
packages you download from bioconductor and CRAN are typically built
as binary packages, so no source compiling needs to be done.

Sean



More information about the Bioc-devel mailing list