Module: wine Branch: master Commit: 74aa42a529afe216414bfeb25188ce25e47671af URL: https://source.winehq.org/git/wine.git/?a=commit;h=74aa42a529afe216414bfeb25...
Author: Alexandre Julliard julliard@winehq.org Date: Fri Dec 18 14:19:48 2020 +0100
makefiles: Make the tests also depend on the Unix library of the tested module.
Signed-off-by: Alexandre Julliard julliard@winehq.org
---
tools/makedep.c | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-)
diff --git a/tools/makedep.c b/tools/makedep.c index 0da3a6b092c..306a50eef5d 100644 --- a/tools/makedep.c +++ b/tools/makedep.c @@ -3564,7 +3564,6 @@ static void output_test_module( struct makefile *make ) struct strarray all_libs = add_import_libs( make, &dep_libs, make->imports, 0, 0 ); struct makefile *parent = get_parent_makefile( make ); const char *ext = make->is_cross ? "" : dll_ext; - const char *parent_ext = parent && parent->is_cross ? "" : dll_ext; const char *debug_file; char *output_file;
@@ -3606,7 +3605,17 @@ static void output_test_module( struct makefile *make )
output_filenames_obj_dir( make, make->ok_files ); output( ": %s%s", obj_dir_path( make, testmodule ), ext ); - if (parent) output( " %s%s", obj_dir_path( parent, make->testdll ), parent_ext ); + if (parent) + { + output_filename( parent->is_cross ? obj_dir_path( parent, make->testdll ) + : strmake( "%s%s", obj_dir_path( parent, make->testdll ), dll_ext )); + if (parent->unixobj_files.count) + { + char *ext, *unix_lib = xstrdup( parent->module ); + if ((ext = get_extension( unix_lib ))) *ext = 0; + output_filename( strmake( "%s%s", obj_dir_path( parent, unix_lib ), dll_ext )); + } + } output( "\n" ); output( "%s %s:", obj_dir_path( make, "check" ), obj_dir_path( make, "test" )); if (!make->disabled && parent && !parent->disabled) output_filenames_obj_dir( make, make->ok_files );