------- Comment #7 from burnus at gcc dot gnu dot org 2008-10-15 09:29 ------- Patch does not work - the "." causes problems as a "include" (not "#include") does not work anymore: The "." is not included. Still there is the issue about the order "." should be searched before the "-I" paths and it is not needed to be added for "#include" but only for "include".
The latter can be solved by calling in this case in "gfc_add_include_path" only "add_path_to_list (&include_dirs" and not "gfc_cpp_add_include_path" but I fear that also the order for include_dirs has to be changed as well as OPT_I / -I<dir> come before the filename processing in gfc_post_options. -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=37821