Silverfrost Forums

Welcome to our forums

Creating dlls

2 May 2017 9:05 #19527

I am trying to create a dll using slink64. As known from slink (32 bit) I tried to use

dll

as the first command for slink64 to specify that a DLL was to be built. However, slink64 complains displaying '***dll - unknown command.' Command 'archive' is unkwown to slink64, as well.

How would I create a dll and an archive for the 64 bit environment?

Regards, Dietmar

2 May 2017 10:12 #19529

If the source code for your DLL already has the relevant !FTN95 DLLEXPORT directives, you can link the DLL exactly as you would an EXE. The linker will output an EXE or DLL, as the case may be, based on the file extension in the /out:<filename> argument.

To link a program that calls the DLL, simply specify the DLL name with the extension in the SLINK command. You do not need a stub static library in the way that the MS build system, which is used by other Fortran compilers on Windows, does.

2 May 2017 10:46 #19531

The SLINK64 default is to export all routines regardless.

3 May 2017 4:52 #19540

Respect to compiler directives !FTN95$OPTIONS(directive). Specifically directives FREE and FIXED

Is it considered as a big crime against Standard to mix free and fixed format source code in the same file using such directives?

3 May 2017 6:27 #19541

Have you tried it? I don't think that it can be done using FTN95.

Please login to reply.