diff options
author | Bálint Aradi <aradi@uni-bremen.de> | 2017-05-12 15:35:31 +0200 |
---|---|---|
committer | Bálint Aradi <aradi@uni-bremen.de> | 2017-05-12 15:36:38 +0200 |
commit | 37ce7f01cf4392840a8d6652a3f0ecdff5974616 (patch) | |
tree | fa1ec2c9d2850137c44131c946aacab97abd009d | |
parent | 540fd2f0e03f949842513a8fbb1ef86c33608fd8 (diff) | |
download | meson-37ce7f01cf4392840a8d6652a3f0ecdff5974616.zip meson-37ce7f01cf4392840a8d6652a3f0ecdff5974616.tar.gz meson-37ce7f01cf4392840a8d6652a3f0ecdff5974616.tar.bz2 |
Add test for fortran dependency scanning fix
-rw-r--r-- | test cases/fortran/7 generated/meson.build | 18 | ||||
-rw-r--r-- | test cases/fortran/7 generated/mod1.fpp | 6 | ||||
-rw-r--r-- | test cases/fortran/7 generated/mod2.fpp | 7 |
3 files changed, 31 insertions, 0 deletions
diff --git a/test cases/fortran/7 generated/meson.build b/test cases/fortran/7 generated/meson.build new file mode 100644 index 0000000..3ad339e --- /dev/null +++ b/test cases/fortran/7 generated/meson.build @@ -0,0 +1,18 @@ +# Tests whether fortran sources files created during configuration are properly +# scanned for dependency information + +project('generated', 'fortran') + +conf_data = configuration_data() + +sources_fortran_basenames = ['mod2', 'mod1'] +preproc_sources_fortran = [] +foreach fsource_basename : sources_fortran_basenames + infilename = '@0@.fpp'.format(fsource_basename) + outfilename = '@0@.f90'.format(fsource_basename) + outfile = configure_file( + input : infilename, output : outfilename, configuration : conf_data) + preproc_sources_fortran += [outfile] +endforeach + +mylib = static_library('mylib', preproc_sources_fortran) diff --git a/test cases/fortran/7 generated/mod1.fpp b/test cases/fortran/7 generated/mod1.fpp new file mode 100644 index 0000000..c03ef16 --- /dev/null +++ b/test cases/fortran/7 generated/mod1.fpp @@ -0,0 +1,6 @@ +module mod1 + implicit none + + integer, parameter :: modval1 = 1 + +end module mod1 diff --git a/test cases/fortran/7 generated/mod2.fpp b/test cases/fortran/7 generated/mod2.fpp new file mode 100644 index 0000000..eec931e --- /dev/null +++ b/test cases/fortran/7 generated/mod2.fpp @@ -0,0 +1,7 @@ +module mod2 + use mod1 + implicit none + + integer, parameter :: modval2 = 2 + +end module mod2 |