I need to create a dynamic C ++ DLL to replace the old Fortran DLL, without changing the host application (so that the functions and parameters must remain unchanged).
I have a full specification of all the Fortran functions in this library, but what tools (compiler) I need to use, and what is the way to code the DLL in this situation (stdcall, cdecl, dllexport, etc.), I say a lot, I never created a DLL before).
This is an example of declaring a Fortran function in an obsolete DLL:
SUBROUTINE SetBoundaries(MaxFlow, MinFlow) cDEC$ ATTRIBUTES DLLEXPORT :: SetBoundaries cDEC$ ATTRIBUTES ALIAS: "SetBoundaries" :: SetBoundaries REAL MaxFlow REAL MinFlow
I tried to compile the VC2008 DLL but got an error:
Unhandled error in 'InitAllPublicVars' Runtime Error 453: Unable to find DLL entry point DLL in SomeLib.DLL
The source of this DLL (the defining function named DLLVersion does not help):
void __stdcall SetBoundaries( float *min , float *max ) { }
Is DLLVersion some special DLL routine or just missing from my documentation and should I create such a function?
I don't know the details about the source / compilation of the Fortran DLL file, but there is some extracted data:



source share