There is no rule that says one DLL can't make use of another. Therefore,
you might want to make one master dll in the language of your choice (one
that can be directly linked/loaded by S-Plus) and a second in the other
language that is only called by the first DLL. The master DLL will have to
take care of ensuring that the second DLL gets loaded. You could debug this
combination without solving the S-Plus interfacing problem (by compiling and
running your DLL as a stand-alone program, or by creating a separate test
program that links to the master DLL)
If you are having trouble getting any DLL to work with S-Plus, you should
start by working on a fairly simple example and make sure that you can get
all parts of that process to work properly before moving on to more
difficult or obscure cases. I found that a good first example problem is to
simply make sure that you can pass various kinds of arguments to a DLL, then
process them a little to see if you are able to correctly receive and return
single values and vectors over the DLL/S-Plus interface. For instance, you
might try formatting a floating number as a character variable and
returning that, or simply returning some constant values from your DLL.
Once you are able to pass character data from your DLL back to S-Plus, you
have a convenient way to debug the operation of your DLL when it is linked
to S-Plus (by making up and returning progress and variable-value messages
as the DLL operates on your problem). I have also made use of MessageBoxes
initiated by the DLL as an early-stage debugging aide.
----- Original Message -----
From: "Urs Wagner" <wagner@itp.phys.ethz.ch>
To: <s-news@lists.biostat.wustl.edu>
Sent: Thursday, October 21, 2004 10:24 AM
Subject: [S] S.dll with Fortran and C code
Hello
SPLUS 6.2 on WinXP
I have troubles build the S.dll. The problem is I need combine Fortran
and C objects
into the same DLL.
Has anyone an idea how to combine it?
Urs
--------------------------------------------------------------------
This message was distributed by s-news@lists.biostat.wustl.edu. To
unsubscribe send e-mail to s-news-request@lists.biostat.wustl.edu with
the BODY of the message: unsubscribe s-news