Hi all,

I have Win XP and R 2.3.1 on my notebook. I would like to write a package which includes some Fortran 95 code. Interestingly, if  I compile and link the simple file test90.f90 directly with

g95 -c test90.f90
g95 -shared -o test90.dll test90.o

then PE Viewer ( a dll viewer) shows me the right functions in the export table, hence I can use the dll in R. But as it should become part of a package I wrote the simple src/Makefile

F95=g95
prog: test90.f90
 $(F95) -shared -o test90.dll test90.o
test90.f90: test90.f90
 $(F95) -c test90.f90

which looks totally equal to the 2 commands above. If I run now 
Rcmd check --no-latex test90
Rcmd install test90

then test90.dll is made but the export table is empty and therefore in R the functions cannot be loaded.
Any idea? Can it be that Rcmd gives further flags to the compiler/linker?

Any hints appreciated
Meinhard Ploner

South Tyrol (Italy)


PS The fortran file is simply:

SUBROUTINE BLABLA(A)
!DEC$ ATTRIBUTES DLLEXPORT :: blabla    ### without this line the prob is the same :-(
IMPLICIT DOUBLE PRECISION (A-H,O-Z)
A=A+1
RETURN
END SUBROUTINE BLABLA

	[[alternative HTML version deleted]]

