Hello Dirk,
thank you for your chick answer.
I tried another file and there it works. so i removed all files
which were created during of the compilation of add.c in windows
and so i could compile it under ubuntu too. During the windows
compilation there is some *.o file which is created during
From the help page:
'R CMD SHLIB' is the mechanism used by 'INSTALL' to compile source
code in packages. Please consult section 'Creating shared objects'
in the manual 'Writing R Extensions' for how to customize it (for
example to add 'cpp' flags and to add libraries to the link
Andreas Wittmann wrote:
Hello Dirk,
thank you for your chick answer.
I tried another file and there it works. so i removed all files
which were created during of the compilation of add.c in windows
and so i could compile it under ubuntu too. During the windows
compilation there is some *.o file
Dear R useRs,
on ubuntu 8.04 i try to create a shared object out of a c-file
this is
// add.c
#include Rinternals.h
SEXP addiere(SEXP a, SEXP b)
{
int i, n;
n = length(a);
for (i = 0; i n; i++)
REAL(a)[i] += REAL(b)[i];
return(a);
}
in terminal i type
R CMD SHLIB add.c
and get
gcc
On Sun, Oct 19, 2008 at 01:27:06AM +0200, Andreas Wittmann wrote:
Dear R useRs,
on ubuntu 8.04 i try to create a shared object out of a c-file
this is
// add.c
#include Rinternals.h
SEXP addiere(SEXP a, SEXP b)
{
int i, n;
n = length(a);
for (i = 0; i n; i++)
REAL(a)[i] +=
5 matches
Mail list logo