Skip to content

Commit

Permalink
makedep: Allow two versions of same file
Browse files Browse the repository at this point in the history
- @marshallward reported that FMS2 has multiple versions of the same
  file int he search path. To avoid fatal errors, we are now allowing
  an ambiguous outcome and simple throwing out a warning that two
  files of the same name were encountered.

Co-authored-by: Marshall Ward <[email protected]>
  • Loading branch information
adcroft and marshallward committed Jul 8, 2022
1 parent 2581118 commit 9ecf1a6
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion ac/makedep
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ def create_deps(src_dirs, makefile, debug, exec_target, fc_rule, link_externals,
a = []
for f in all_files:
if os.path.basename(f) in a:
raise ValueError('File %s was found twice!'%(os.path.basename(f)))
print('Warning: File %s was found twice! One is being ignored but which is undefined.'%(os.path.basename(f)))
a.append( os.path.basename(f) )

# maps object file to F90 source
Expand Down

0 comments on commit 9ecf1a6

Please sign in to comment.