Alexandre Julliard : makedep: Always open Makefile.in files from the source directory.
Alexandre Julliard
julliard at wine.codeweavers.com
Wed Nov 11 08:36:44 CST 2015
Module: wine
Branch: master
Commit: 6f8e5d4e10130de3a3d5e61aa9dc643dfa69cc61
URL: http://source.winehq.org/git/wine.git/?a=commit;h=6f8e5d4e10130de3a3d5e61aa9dc643dfa69cc61
Author: Alexandre Julliard <julliard at winehq.org>
Date: Wed Nov 11 12:05:12 2015 +0900
makedep: Always open Makefile.in files from the source directory.
Signed-off-by: Alexandre Julliard <julliard at winehq.org>
---
tools/makedep.c | 12 +++++-------
1 file changed, 5 insertions(+), 7 deletions(-)
diff --git a/tools/makedep.c b/tools/makedep.c
index f20a967..f51cd2f 100644
--- a/tools/makedep.c
+++ b/tools/makedep.c
@@ -1556,16 +1556,14 @@ static FILE *open_input_makefile( const struct makefile *make )
FILE *ret;
if (make->base_dir)
+ {
input_file_name = base_dir_path( make, input_makefile_name );
- else
- input_file_name = output_makefile_name; /* always use output name for main Makefile */
+ if (strendswith( input_makefile_name, ".in" )) input_file_name = root_dir_path( input_file_name );
+ }
+ else input_file_name = output_makefile_name; /* always use output name for main Makefile */
input_line = 0;
- if (!(ret = fopen( input_file_name, "r" )))
- {
- input_file_name = root_dir_path( input_file_name );
- if (!(ret = fopen( input_file_name, "r" ))) fatal_perror( "open" );
- }
+ if (!(ret = fopen( input_file_name, "r" ))) fatal_perror( "open" );
return ret;
}
More information about the wine-cvs
mailing list