- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
PROGRAM Test
USE
IFPORTCALL
FLUSH ( 6 )STOP
END
Here's the error message:
test error LNK2019: unresolved external symbol _FLUSH@4 referenced in function _MAIN__
I (think I've) read all the appropriate documentation and can find no mention that I need to change linker settings except in the porting guide, which seems to refer to IF v7, although I tried those suggestions too. I changed from using DFPORT to IFPORT. I also tried IFLPORT, but none of the three seem to work.
Is a new porting guide going to be ready soon?
Marshall
Link Copied
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
This is exactly the same problem I was having with the COM Server example (see separate thread). This is a nice easy example so I will elaborate...
The interface for FLUSH (see IFPORT.f90) is as follows
SUBROUTINE FLUSH(LUNIT)
!DEC$ATTRIBUTES DEFAULT :: FLUSH
INTEGER(4) :: LUNIT
END SUBROUTINE
The compiler is using the Project settings for calling convention (probably CVF or STDCALL) and the explicit 'DEC$ATTRIBUTES DEFAULT...' is ignored. _FLUSH@4 is a STDCALL hash of the routine name. The Intel 'DEFAULT' is apparently 'C,REFERENCE'.
It appears to me that there is a problem in that 'DEC$ATTRIBUTES...' does not override the project settings. This will surely have wide implications for projects ported from CVF?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
The ATTRIBUTES did override the command line - but the meaning of DEFAULT changed.
As for FLUSH, I can't reproduce a problem with using it. USE DFPORT or IFPORT should work fine. If you have a sample project that shows a problem, please send it to Premier Support.
- 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
Hi,
I checked out the Calling Convention as Peter suggested and for the project that had the link problems, it was set to "CVF." It was set to "default" for the project that linked fine. I changed the problem project to "default" and it now links fine.

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