makefiles: Explicitly specify source directory in Makefile dependencies.

This commit is contained in:
Alexandre Julliard 2013-12-12 13:15:34 +01:00
parent ba1b572da2
commit be2c66d504
5 changed files with 20 additions and 14 deletions

View File

@ -32,11 +32,11 @@ all: wine
# Rules for re-running configure
config.status: configure
config.status: $(srcdir)/configure
@./config.status --recheck
include/config.h: include/stamp-h
include/stamp-h: include/config.h.in config.status
include/stamp-h: $(srcdir)/include/config.h.in config.status
@./config.status include/config.h include/stamp-h
# Rules for cleaning

11
aclocal.m4 vendored
View File

@ -219,12 +219,15 @@ wine_fn_depend_rules ()
ac_makedep="\$(MAKEDEP)"
ac_input=Make.vars.in:$ac_dir/Makefile.in
case $[1] in
*.in) ac_input=$ac_input:$[1] ;;
*) ac_makedep="$[1] $ac_makedep" ;;
*.in)
ac_input=$ac_input:$[1]
test "$srcdir" = . || ac_alldeps="$srcdir/$ac_alldeps" ;;
*)
ac_makedep="$[1] $ac_makedep" ;;
esac
wine_fn_append_rule \
"$ac_dir/Makefile: $ac_dir/Makefile.in Make.vars.in config.status $ac_alldeps \$(MAKEDEP)
"$ac_dir/Makefile: $srcdir/$ac_dir/Makefile.in $srcdir/Make.vars.in config.status $ac_alldeps \$(MAKEDEP)
@./config.status --file $ac_dir/Makefile:$ac_input && cd $ac_dir && \$(MAKE) depend
depend: $ac_dir/depend
.PHONY: $ac_dir/depend
@ -628,7 +631,7 @@ wine_fn_config_makerules ()
ac_rules=$[1]
ac_deps=$[2]
wine_fn_append_rule \
"$ac_rules: $ac_rules.in $ac_deps config.status
"$ac_rules: $srcdir/$ac_rules.in $ac_deps config.status
@./config.status $ac_rules
distclean::
\$(RM) $ac_rules"

13
configure vendored
View File

@ -16216,12 +16216,15 @@ wine_fn_depend_rules ()
ac_makedep="\$(MAKEDEP)"
ac_input=Make.vars.in:$ac_dir/Makefile.in
case $1 in
*.in) ac_input=$ac_input:$1 ;;
*) ac_makedep="$1 $ac_makedep" ;;
*.in)
ac_input=$ac_input:$1
test "$srcdir" = . || ac_alldeps="$srcdir/$ac_alldeps" ;;
*)
ac_makedep="$1 $ac_makedep" ;;
esac
wine_fn_append_rule \
"$ac_dir/Makefile: $ac_dir/Makefile.in Make.vars.in config.status $ac_alldeps \$(MAKEDEP)
"$ac_dir/Makefile: $srcdir/$ac_dir/Makefile.in $srcdir/Make.vars.in config.status $ac_alldeps \$(MAKEDEP)
@./config.status --file $ac_dir/Makefile:$ac_input && cd $ac_dir && \$(MAKE) depend
depend: $ac_dir/depend
.PHONY: $ac_dir/depend
@ -16641,7 +16644,7 @@ wine_fn_config_makerules ()
ac_rules=$1
ac_deps=$2
wine_fn_append_rule \
"$ac_rules: $ac_rules.in $ac_deps config.status
"$ac_rules: $srcdir/$ac_rules.in $ac_deps config.status
@./config.status $ac_rules
distclean::
\$(RM) $ac_rules"
@ -16677,7 +16680,7 @@ wine_fn_append_rule "
.INIT: Makefile
.MAKEFILEDEPS:
all: Makefile
Makefile: Makefile.in Make.vars.in Make.rules config.status
Makefile: $srcdir/Makefile.in $srcdir/Make.vars.in Make.rules config.status
@./config.status Make.tmp Makefile"
if test "x$enable_fonts" != xno; then

View File

@ -2667,7 +2667,7 @@ WINE_APPEND_RULE([
.INIT: Makefile
.MAKEFILEDEPS:
all: Makefile
Makefile: Makefile.in Make.vars.in Make.rules config.status
Makefile: $srcdir/Makefile.in $srcdir/Make.vars.in Make.rules config.status
@./config.status Make.tmp Makefile])
WINE_CONFIG_SYMLINK(fonts,fonts,[marlett.ttf,symbol.ttf,tahoma.ttf,tahomabd.ttf],enable_fonts)

View File

@ -1363,7 +1363,7 @@ static void output_sources(void)
if (find_src_file( "dlldata.o" ))
{
output( "dlldata.c: $(WIDL) Makefile.in\n" );
output( "dlldata.c: $(WIDL) %s\n", src_dir ? strmake("%s/Makefile.in", src_dir ) : "Makefile.in" );
column = output( "\t$(WIDL) --dlldata-only -o $@" );
LIST_FOR_EACH_ENTRY( source, &sources, struct incl_file, entry )
if (source->flags & FLAG_IDL_PROXY) output_filename( source->filename, &column );
@ -1373,7 +1373,7 @@ static void output_sources(void)
if (is_test)
{
output( "testlist.c: $(MAKECTESTS) Makefile.in\n" );
output( "testlist.c: $(MAKECTESTS) %s\n", src_dir ? strmake("%s/Makefile.in", src_dir ) : "Makefile.in" );
column = output( "\t$(MAKECTESTS) -o $@" );
LIST_FOR_EACH_ENTRY( source, &sources, struct incl_file, entry )
if (strendswith( source->name, ".c" ) && !is_generated_idl( source ))