- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I am having trouble with mixed language calls between the .028 and .024 releases of IVF for Windows! Anybody else?
I am new to IVF, having started with the .024 package andinstalled the .028 package in an attempt to see if the ENTRY call issue (see previous post) had been resolved. I had had no trouble with mixed language calls but things went downhill with .028 even though no changes were made to the project configurationor interface statements. After I spent a few hours, I reinstalled .024 and lo! it worked again. I have again installed .028 and have the same issue. Through DUMPBIN I see that the compiler is adding @nn to the ALIAS name with /iface:cvf in .028 but not in .024 yielding a slew of the following.
sdlflib_lib.lib(SIOLIB2.obj) : error LNK2019: unresolved external symbol _isdl_siocreateandmapfile@20 referenced in function _SIO_OPEN
What am I missing? Will try any suggestions -- I have .028 back on my machine...
The interface is as follows:
INTEGER*4 FUNCTION isdl_siocreateandmapfile (lpFileName, nBytes, lpszMapName, phFile, phMap)
!DEC$ ATTRIBUTES C:: isdl_siocreateandmapfile
!DEC$ ATTRIBUTES ALIAS:"_isdl_siocreateandmapfile":: isdl_siocreateandmapfile
INTEGER*4 nBytes
CHARACTER*(*) lpszMapName
INTEGER*4 phFile
INTEGER*4 phMap
!DEC$ ATTRIBUTES REFERENCE :: lpFileName
!DEC$ ATTRIBUTES VALUE :: nBytes
!DEC$ ATTRIBUTES REFERENCE :: lpszMapName
!DEC$ ATTRIBUTES REFERENCE :: phFile
!DEC$ ATTRIBUTES REFERENCE :: phMap
END INTERFACE
The C function prototype is:
int
isdl_siocreateandmapfile(LPCSTR lpFileName, DWORD nBytes, LPSTR lpszMapName, HANDLE *phFile, HANDLE *phMap)Thanks for the help
--arvind
PS: I know I need to upgrade my style of type declarations... sigh...
Link Copied
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Why not try the following:
extern "C" {int__cdecl isdl_siocreateandmapfile(LPCSTR *lpFileName, DWORD nBytes, LPSTR *lpszMapName, HANDLE *phFile, HANDLE *phMap) };
and
INTERFACE
INTEGER*4 FUNCTION isdl_siocreateandmapfile (lpFileName, nBytes, lpszMapName, phFile, phMap)
!DEC$ ATTRIBUTES C, REFERENCE:: isdl_siocreateandmapfile
!DEC$ ATTRIBUTES ALIAS:"_isdl_siocreateandmapfile":: isdl_siocreateandmapfile
INTEGER*4 nBytes
CHARACTER*(*) lpszMapName
INTEGER*4 phFile
INTEGER*4 phMap
!DEC$ ATTRIBUTES REFERENCE :: lpFileName
!DEC$ ATTRIBUTES VALUE :: nBytes
!DEC$ ATTRIBUTES REFERENCE :: lpszMapName
!DEC$ ATTRIBUTES REFERENCE :: phFile
!DEC$ ATTRIBUTES REFERENCE :: phMap
END INTERFACE
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
That did not do it... thanks for the suggestion.
But I got it figured, I think... the .028 may be enforcing the 72 char limit while the .024 may not.
Also, it seems the .024 supported the old hack and .028 does not...
INTERFACE TO INTEGER*4 FUNCTION isdl_SioCreateAndMapFile
CHARACTER*(*) lpFileName[reference]
INTEGER*4 nBytes [value]
CHARACTER*(*) lpszMapName[reference]
INTEGER*4 phFile [reference]
INTEGER*4 phMap [reference]
END
--arvind
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Steve,I would not bet against you!But that's what it took for me to get it working.
Go to 132 column fixed (actually 80 column also worked). That got the !DEC$ ALIAS accepted. I made no changes other changes to the command line
All my interfaces were in the "old" style and that worked for me that way for 10 years or so! Since I saw no documentation supporting that form I changed the one I presented earlier. Once Igot that one going then it was a matter of changing the rest of them. The "old" ones did not work.
I did not have to make these adjustments for the previous package! The project came out of CVF and I used the extract tool to separate out the C and Fortran. I had no issues with .024 but somehow .028 required me to make the changes I mentioned.
I went back and tried again == same result!
regards
--arvind

- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page