Skip to content

Commit

Permalink
compilers/fortran: fix werror options for Intel compilers
Browse files Browse the repository at this point in the history
Unlike in the Intel C compiler, -Werror and /WX are not accepted.
  • Loading branch information
bgilbert authored and dcbaker committed Apr 27, 2024
1 parent 1684259 commit 2004b7c
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions mesonbuild/compilers/fortran.py
Original file line number Diff line number Diff line change
Expand Up @@ -300,6 +300,9 @@ def get_option_compile_args(self, options: 'KeyedOptionDictType') -> T.List[str]
def get_preprocess_only_args(self) -> T.List[str]:
return ['-cpp', '-EP']

def get_werror_args(self) -> T.List[str]:
return ['-warn', 'errors']

def language_stdlib_only_link_flags(self, env: 'Environment') -> T.List[str]:
# TODO: needs default search path added
return ['-lifcore', '-limf']
Expand Down Expand Up @@ -349,6 +352,9 @@ def get_option_compile_args(self, options: 'KeyedOptionDictType') -> T.List[str]
args.append('/stand:' + stds[std.value])
return args

def get_werror_args(self) -> T.List[str]:
return ['/warn:errors']

def get_module_outdir_args(self, path: str) -> T.List[str]:
return ['/module:' + path]

Expand Down

0 comments on commit 2004b7c

Please sign in to comment.