- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Good Day,
I get the following errors when trying to compile a gateway mex file and I'm not sure why. Any help is appreciated:
aerocalc.f90(8): error #5082: Syntax error, found IDENTIFIER 'PLHS' when expecting one of: ( % [ : . = =>
mwpointer plhs(*), prhs(*)
----------^
aerocalc.f90(14): error #5082: Syntax error, found IDENTIFIER 'MXCREATEDOUBLEMATRIX' when expecting one of: ( % [ : . = =>
mwpointer mxcreatedoublematrix, mxgetpr
----------^
aerocalc.f90(15): error #5082: Syntax error, found IDENTIFIER 'MXGETM' when expecting one of: ( % [ : . = =>
mwpointer mxgetm, mxgetn
----------^
aerocalc.f90(17): error #5082: Syntax error, found IDENTIFIER 'TURBINECOMPONENTS_PR' when expecting one of: ( % [ : . = =>
mwpointer turbinecomponents_pr, y_pr
----------^
aerocalc.f90(20): error #5082: Syntax error, found IDENTIFIER 'M' when expecting one of: ( % [ : . = =>
mwpointer m, n
----------^
aerocalc.f90(21): error #5082: Syntax error, found IDENTIFIER 'SIZE' when expecting one of: ( % [ : . = =>
mwsize size
-------^
I get the following errors when trying to compile a gateway mex file and I'm not sure why. Any help is appreciated:
aerocalc.f90(8): error #5082: Syntax error, found IDENTIFIER 'PLHS' when expecting one of: ( % [ : . = =>
mwpointer plhs(*), prhs(*)
----------^
aerocalc.f90(14): error #5082: Syntax error, found IDENTIFIER 'MXCREATEDOUBLEMATRIX' when expecting one of: ( % [ : . = =>
mwpointer mxcreatedoublematrix, mxgetpr
----------^
aerocalc.f90(15): error #5082: Syntax error, found IDENTIFIER 'MXGETM' when expecting one of: ( % [ : . = =>
mwpointer mxgetm, mxgetn
----------^
aerocalc.f90(17): error #5082: Syntax error, found IDENTIFIER 'TURBINECOMPONENTS_PR' when expecting one of: ( % [ : . = =>
mwpointer turbinecomponents_pr, y_pr
----------^
aerocalc.f90(20): error #5082: Syntax error, found IDENTIFIER 'M' when expecting one of: ( % [ : . = =>
mwpointer m, n
----------^
aerocalc.f90(21): error #5082: Syntax error, found IDENTIFIER 'SIZE' when expecting one of: ( % [ : . = =>
mwsize size
-------^
1 Solution
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
You probably did not add
include 'fintrf.h'
to your source file or, if you are using C style includes, did not specify that the C preprocessor shoud be used.
By themselves (i.e., without the header file defining 'mwpointer') the lines that you show are not valid Fortran declarations.
include 'fintrf.h'
to your source file or, if you are using C style includes, did not specify that the C preprocessor shoud be used.
By themselves (i.e., without the header file defining 'mwpointer') the lines that you show are not valid Fortran declarations.
Link Copied
3 Replies
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
You probably did not add
include 'fintrf.h'
to your source file or, if you are using C style includes, did not specify that the C preprocessor shoud be used.
By themselves (i.e., without the header file defining 'mwpointer') the lines that you show are not valid Fortran declarations.
include 'fintrf.h'
to your source file or, if you are using C style includes, did not specify that the C preprocessor shoud be used.
By themselves (i.e., without the header file defining 'mwpointer') the lines that you show are not valid Fortran declarations.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
try replacing mwpointer and mwsize with INTEGER(INT_PTR_KIND())
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
It worked. I forgot about including that tag. Thanks

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