makefiles: Generate all makefiles at once.

Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
Alexandre Julliard 2016-01-11 16:05:51 +09:00
parent fad6dc66df
commit 8f57dfedf8
5 changed files with 107 additions and 84 deletions

View File

@ -72,6 +72,7 @@ ICOTOOL = @ICOTOOL@
MSGFMT = @MSGFMT@ MSGFMT = @MSGFMT@
CROSSTARGET = @CROSSTARGET@ CROSSTARGET = @CROSSTARGET@
LINGUAS = @LINGUAS@ LINGUAS = @LINGUAS@
SUBDIRS = @SUBDIRS@
RUNTESTFLAGS = -q -P wine RUNTESTFLAGS = -q -P wine
MAKEDEP = $(TOOLSDIR)/tools/makedep$(TOOLSEXT) MAKEDEP = $(TOOLSDIR)/tools/makedep$(TOOLSEXT)
WINEBUILD = $(TOOLSDIR)/tools/winebuild/winebuild$(TOOLSEXT) WINEBUILD = $(TOOLSDIR)/tools/winebuild/winebuild$(TOOLSEXT)

57
aclocal.m4 vendored
View File

@ -201,6 +201,7 @@ AC_DEFUN([WINE_CONFIG_HELPERS],
rm -f $wine_rules_file rm -f $wine_rules_file
ALL_POT_FILES="" ALL_POT_FILES=""
GITIGNORE="# Automatically generated by configure; DO NOT EDIT!!" GITIGNORE="# Automatically generated by configure; DO NOT EDIT!!"
AC_SUBST(SUBDIRS,"")
AC_SUBST(ALL_TEST_RESOURCES,"") AC_SUBST(ALL_TEST_RESOURCES,"")
wine_fn_append_file () wine_fn_append_file ()
@ -229,13 +230,9 @@ wine_fn_has_flag ()
wine_fn_depend_rules () wine_fn_depend_rules ()
{ {
wine_fn_append_file SUBDIRS $ac_dir
wine_fn_append_rule \ wine_fn_append_rule \
"$ac_dir/Makefile: $srcdir/$ac_dir/Makefile.in Makefile \$(MAKEDEP) "Makefile: $srcdir/$ac_dir/Makefile.in"
\$(MAKEDEP) $ac_dir
depend: $ac_dir/depend
.PHONY: $ac_dir/depend
$ac_dir/depend: \$(MAKEDEP) dummy
\$(MAKEDEP) $ac_dir"
} }
wine_fn_pot_rules () wine_fn_pot_rules ()
@ -246,7 +243,7 @@ wine_fn_pot_rules ()
then then
wine_fn_append_file ALL_POT_FILES $ac_dir/msg.pot wine_fn_append_file ALL_POT_FILES $ac_dir/msg.pot
wine_fn_append_rule \ wine_fn_append_rule \
"$ac_dir/msg.pot: $ac_dir/Makefile dummy "$ac_dir/msg.pot: dummy
@cd $ac_dir && \$(MAKE) msg.pot @cd $ac_dir && \$(MAKE) msg.pot
$ac_dir/msg.pot: tools/wmc include" $ac_dir/msg.pot: tools/wmc include"
fi fi
@ -254,7 +251,7 @@ $ac_dir/msg.pot: tools/wmc include"
then then
wine_fn_append_file ALL_POT_FILES $ac_dir/rsrc.pot wine_fn_append_file ALL_POT_FILES $ac_dir/rsrc.pot
wine_fn_append_rule \ wine_fn_append_rule \
"$ac_dir/rsrc.pot: $ac_dir/Makefile dummy "$ac_dir/rsrc.pot: dummy
@cd $ac_dir && \$(MAKE) rsrc.pot @cd $ac_dir && \$(MAKE) rsrc.pot
$ac_dir/rsrc.pot: tools/wrc include" $ac_dir/rsrc.pot: tools/wrc include"
fi fi
@ -266,7 +263,7 @@ wine_fn_all_rules ()
wine_fn_append_rule \ wine_fn_append_rule \
"all: $ac_dir "all: $ac_dir
.PHONY: $ac_dir .PHONY: $ac_dir
$ac_dir: $ac_dir/Makefile dummy $ac_dir: dummy
@cd $ac_dir && \$(MAKE)" @cd $ac_dir && \$(MAKE)"
} }
@ -278,7 +275,7 @@ wine_fn_install_rules ()
".PHONY: $ac_dir/install $ac_dir/uninstall ".PHONY: $ac_dir/install $ac_dir/uninstall
$ac_dir/install:: $ac_dir $ac_dir/install:: $ac_dir
@cd $ac_dir && \$(MAKE) install @cd $ac_dir && \$(MAKE) install
$ac_dir/uninstall:: $ac_dir/Makefile $ac_dir/uninstall::
@cd $ac_dir && \$(MAKE) uninstall @cd $ac_dir && \$(MAKE) uninstall
install:: $ac_dir/install install:: $ac_dir/install
__uninstall__: $ac_dir/uninstall" __uninstall__: $ac_dir/uninstall"
@ -314,18 +311,18 @@ wine_fn_clean_rules ()
if wine_fn_has_flag clean if wine_fn_has_flag clean
then then
wine_fn_append_rule \ wine_fn_append_rule \
"__clean__: $ac_dir/clean "$ac_dir/clean: dummy
.PHONY: $ac_dir/clean @cd $ac_dir && \$(MAKE) clean"
$ac_dir/clean: $ac_dir/Makefile
@cd $ac_dir && \$(MAKE) clean
\$(RM) $ac_extraclean"
else else
wine_fn_append_rule \ wine_fn_append_rule \
"$ac_dir/clean: dummy
\$(RM) \$(CLEAN_FILES:%=$ac_dir/%) $ac_clean"
fi
wine_fn_append_rule \
"__clean__: $ac_dir/clean "__clean__: $ac_dir/clean
.PHONY: $ac_dir/clean .PHONY: $ac_dir/clean
$ac_dir/clean: dummy distclean::
\$(RM) \$(CLEAN_FILES:%=$ac_dir/%) $ac_clean $ac_extraclean" \$(RM) $ac_extraclean"
fi
} }
wine_fn_disabled_rules () wine_fn_disabled_rules ()
@ -338,7 +335,9 @@ wine_fn_disabled_rules ()
"__clean__: $ac_dir/clean "__clean__: $ac_dir/clean
.PHONY: $ac_dir/clean .PHONY: $ac_dir/clean
$ac_dir/clean: dummy $ac_dir/clean: dummy
\$(RM) \$(CLEAN_FILES:%=$ac_dir/%) $ac_clean $ac_extraclean" \$(RM) \$(CLEAN_FILES:%=$ac_dir/%) $ac_clean
distclean::
\$(RM) $ac_extraclean"
} }
wine_fn_config_makefile () wine_fn_config_makefile ()
@ -417,7 +416,7 @@ wine_fn_config_dll ()
wine_fn_clean_rules $ac_clean wine_fn_clean_rules $ac_clean
wine_fn_append_rule \ wine_fn_append_rule \
"$ac_dir: __builddeps__ "$ac_dir: __builddeps__
manpages htmlpages sgmlpages xmlpages:: $ac_dir/Makefile manpages htmlpages sgmlpages xmlpages::
@cd $ac_dir && \$(MAKE) \$[@] @cd $ac_dir && \$(MAKE) \$[@]
.PHONY: $ac_dir/install-lib $ac_dir/uninstall .PHONY: $ac_dir/install-lib $ac_dir/uninstall
install install-lib:: $ac_dir/install-lib install install-lib:: $ac_dir/install-lib
@ -445,9 +444,9 @@ $ac_dir/uninstall::
wine_fn_append_rule \ wine_fn_append_rule \
"__builddeps__: $ac_file.$IMPLIBEXT $ac_file.$STATIC_IMPLIBEXT "__builddeps__: $ac_file.$IMPLIBEXT $ac_file.$STATIC_IMPLIBEXT
$ac_file.$IMPLIBEXT $ac_file.$STATIC_IMPLIBEXT $ac_file.cross.a: $ac_deps $ac_file.$IMPLIBEXT $ac_file.$STATIC_IMPLIBEXT $ac_file.cross.a: $ac_deps
$ac_file.def: $srcdir/$ac_dir/$ac_name.spec $ac_dir/Makefile \$(WINEBUILD) $ac_file.def: $srcdir/$ac_dir/$ac_name.spec \$(WINEBUILD)
\$(WINEBUILD) \$(TARGETFLAGS)$ac_implibflags -w --def -o \$[@] --export $srcdir/$ac_dir/$ac_name.spec \$(WINEBUILD) \$(TARGETFLAGS)$ac_implibflags -w --def -o \$[@] --export $srcdir/$ac_dir/$ac_name.spec
$ac_file.$STATIC_IMPLIBEXT: $ac_dir/Makefile dummy $ac_file.$STATIC_IMPLIBEXT: dummy
@cd $ac_dir && \$(MAKE) lib$ac_implib.$STATIC_IMPLIBEXT @cd $ac_dir && \$(MAKE) lib$ac_implib.$STATIC_IMPLIBEXT
.PHONY: $ac_dir/install-dev $ac_dir/uninstall .PHONY: $ac_dir/install-dev $ac_dir/uninstall
$ac_dir/install-dev:: $ac_file.$IMPLIBEXT $ac_dir/install-dev:: $ac_file.$IMPLIBEXT
@ -470,7 +469,7 @@ $ac_dir/uninstall::
then then
wine_fn_append_rule \ wine_fn_append_rule \
"__builddeps__: $ac_file.cross.a "__builddeps__: $ac_file.cross.a
$ac_file.cross.a: $ac_dir/Makefile dummy $ac_file.cross.a: dummy
@cd $ac_dir && \$(MAKE) lib$ac_implib.cross.a" @cd $ac_dir && \$(MAKE) lib$ac_implib.cross.a"
fi fi
@ -478,9 +477,9 @@ $ac_file.cross.a: $ac_dir/Makefile dummy
then then
wine_fn_append_rule \ wine_fn_append_rule \
"__builddeps__: $ac_file.$IMPLIBEXT "__builddeps__: $ac_file.$IMPLIBEXT
$ac_file.def: $srcdir/$ac_dir/$ac_name.spec $ac_dir/Makefile \$(WINEBUILD) $ac_file.def: $srcdir/$ac_dir/$ac_name.spec \$(WINEBUILD)
\$(WINEBUILD) \$(TARGETFLAGS)$ac_implibflags -w --def -o \$[@] --export $srcdir/$ac_dir/$ac_name.spec \$(WINEBUILD) \$(TARGETFLAGS)$ac_implibflags -w --def -o \$[@] --export $srcdir/$ac_dir/$ac_name.spec
$ac_file.a: $srcdir/$ac_dir/$ac_name.spec $ac_dir/Makefile \$(WINEBUILD) $ac_file.a: $srcdir/$ac_dir/$ac_name.spec \$(WINEBUILD)
\$(WINEBUILD) \$(TARGETFLAGS)$ac_implibflags -w --implib -o \$[@] --export $srcdir/$ac_dir/$ac_name.spec \$(WINEBUILD) \$(TARGETFLAGS)$ac_implibflags -w --implib -o \$[@] --export $srcdir/$ac_dir/$ac_name.spec
.PHONY: $ac_dir/install-dev $ac_dir/uninstall .PHONY: $ac_dir/install-dev $ac_dir/uninstall
$ac_dir/install-dev:: $ac_file.$IMPLIBEXT $ac_dir/install-dev:: $ac_file.$IMPLIBEXT
@ -493,7 +492,7 @@ __uninstall__: $ac_dir/uninstall"
then then
wine_fn_append_rule \ wine_fn_append_rule \
"__builddeps__: $ac_file.cross.a "__builddeps__: $ac_file.cross.a
$ac_file.cross.a: $srcdir/$ac_dir/$ac_name.spec $ac_dir/Makefile \$(WINEBUILD) $ac_file.cross.a: $srcdir/$ac_dir/$ac_name.spec \$(WINEBUILD)
\$(WINEBUILD) \$(CROSSTARGET:%=-b %)$ac_implibflags -w --implib -o \$[@] --export $srcdir/$ac_dir/$ac_name.spec" \$(WINEBUILD) \$(CROSSTARGET:%=-b %)$ac_implibflags -w --implib -o \$[@] --export $srcdir/$ac_dir/$ac_name.spec"
fi fi
@ -604,7 +603,7 @@ wine_fn_config_test ()
wine_fn_clean_rules $ac_clean wine_fn_clean_rules $ac_clean
wine_fn_append_rule \ wine_fn_append_rule \
"$ac_dir: programs/winetest/Makefile __builddeps__ "$ac_dir: __builddeps__
programs/winetest: $ac_dir programs/winetest: $ac_dir
check test: $ac_dir/test check test: $ac_dir/test
.PHONY: $ac_dir/test .PHONY: $ac_dir/test
@ -618,7 +617,7 @@ testclean::
wine_fn_append_rule \ wine_fn_append_rule \
"crosstest: $ac_dir/crosstest "crosstest: $ac_dir/crosstest
.PHONY: $ac_dir/crosstest .PHONY: $ac_dir/crosstest
$ac_dir/crosstest: $ac_dir/Makefile __builddeps__ dummy $ac_dir/crosstest: __builddeps__ dummy
@cd $ac_dir && \$(MAKE) crosstest" @cd $ac_dir && \$(MAKE) crosstest"
fi fi
} }
@ -656,7 +655,7 @@ distclean::
\$(RM) $ac_links" \$(RM) $ac_links"
for f in $ac_links; do wine_fn_ignore_file $f; done for f in $ac_links; do wine_fn_ignore_file $f; done
test -n "$ac_linkdir" || return test -n "$ac_linkdir" || return
wine_fn_append_rule "$ac_linkdir/Makefile $ac_linkdir/depend: $ac_links" wine_fn_append_rule "$ac_linkdir/depend: $ac_links"
}]) }])
dnl **** Define helper function to append a file to a makefile file list **** dnl **** Define helper function to append a file to a makefile file list ****

65
configure vendored
View File

@ -714,6 +714,7 @@ SOCKET_LIBS
DLLTOOL DLLTOOL
WINELOADER_PROGRAMS WINELOADER_PROGRAMS
ALL_TEST_RESOURCES ALL_TEST_RESOURCES
SUBDIRS
READELF READELF
OTOOL OTOOL
LDD LDD
@ -7393,6 +7394,8 @@ wine_rules_file=conf$$rules.make
rm -f $wine_rules_file rm -f $wine_rules_file
ALL_POT_FILES="" ALL_POT_FILES=""
GITIGNORE="# Automatically generated by configure; DO NOT EDIT!!" GITIGNORE="# Automatically generated by configure; DO NOT EDIT!!"
SUBDIRS=""
ALL_TEST_RESOURCES="" ALL_TEST_RESOURCES=""
@ -7422,13 +7425,9 @@ wine_fn_has_flag ()
wine_fn_depend_rules () wine_fn_depend_rules ()
{ {
wine_fn_append_file SUBDIRS $ac_dir
wine_fn_append_rule \ wine_fn_append_rule \
"$ac_dir/Makefile: $srcdir/$ac_dir/Makefile.in Makefile \$(MAKEDEP) "Makefile: $srcdir/$ac_dir/Makefile.in"
\$(MAKEDEP) $ac_dir
depend: $ac_dir/depend
.PHONY: $ac_dir/depend
$ac_dir/depend: \$(MAKEDEP) dummy
\$(MAKEDEP) $ac_dir"
} }
wine_fn_pot_rules () wine_fn_pot_rules ()
@ -7439,7 +7438,7 @@ wine_fn_pot_rules ()
then then
wine_fn_append_file ALL_POT_FILES $ac_dir/msg.pot wine_fn_append_file ALL_POT_FILES $ac_dir/msg.pot
wine_fn_append_rule \ wine_fn_append_rule \
"$ac_dir/msg.pot: $ac_dir/Makefile dummy "$ac_dir/msg.pot: dummy
@cd $ac_dir && \$(MAKE) msg.pot @cd $ac_dir && \$(MAKE) msg.pot
$ac_dir/msg.pot: tools/wmc include" $ac_dir/msg.pot: tools/wmc include"
fi fi
@ -7447,7 +7446,7 @@ $ac_dir/msg.pot: tools/wmc include"
then then
wine_fn_append_file ALL_POT_FILES $ac_dir/rsrc.pot wine_fn_append_file ALL_POT_FILES $ac_dir/rsrc.pot
wine_fn_append_rule \ wine_fn_append_rule \
"$ac_dir/rsrc.pot: $ac_dir/Makefile dummy "$ac_dir/rsrc.pot: dummy
@cd $ac_dir && \$(MAKE) rsrc.pot @cd $ac_dir && \$(MAKE) rsrc.pot
$ac_dir/rsrc.pot: tools/wrc include" $ac_dir/rsrc.pot: tools/wrc include"
fi fi
@ -7459,7 +7458,7 @@ wine_fn_all_rules ()
wine_fn_append_rule \ wine_fn_append_rule \
"all: $ac_dir "all: $ac_dir
.PHONY: $ac_dir .PHONY: $ac_dir
$ac_dir: $ac_dir/Makefile dummy $ac_dir: dummy
@cd $ac_dir && \$(MAKE)" @cd $ac_dir && \$(MAKE)"
} }
@ -7471,7 +7470,7 @@ wine_fn_install_rules ()
".PHONY: $ac_dir/install $ac_dir/uninstall ".PHONY: $ac_dir/install $ac_dir/uninstall
$ac_dir/install:: $ac_dir $ac_dir/install:: $ac_dir
@cd $ac_dir && \$(MAKE) install @cd $ac_dir && \$(MAKE) install
$ac_dir/uninstall:: $ac_dir/Makefile $ac_dir/uninstall::
@cd $ac_dir && \$(MAKE) uninstall @cd $ac_dir && \$(MAKE) uninstall
install:: $ac_dir/install install:: $ac_dir/install
__uninstall__: $ac_dir/uninstall" __uninstall__: $ac_dir/uninstall"
@ -7507,18 +7506,18 @@ wine_fn_clean_rules ()
if wine_fn_has_flag clean if wine_fn_has_flag clean
then then
wine_fn_append_rule \ wine_fn_append_rule \
"__clean__: $ac_dir/clean "$ac_dir/clean: dummy
.PHONY: $ac_dir/clean @cd $ac_dir && \$(MAKE) clean"
$ac_dir/clean: $ac_dir/Makefile
@cd $ac_dir && \$(MAKE) clean
\$(RM) $ac_extraclean"
else else
wine_fn_append_rule \ wine_fn_append_rule \
"$ac_dir/clean: dummy
\$(RM) \$(CLEAN_FILES:%=$ac_dir/%) $ac_clean"
fi
wine_fn_append_rule \
"__clean__: $ac_dir/clean "__clean__: $ac_dir/clean
.PHONY: $ac_dir/clean .PHONY: $ac_dir/clean
$ac_dir/clean: dummy distclean::
\$(RM) \$(CLEAN_FILES:%=$ac_dir/%) $ac_clean $ac_extraclean" \$(RM) $ac_extraclean"
fi
} }
wine_fn_disabled_rules () wine_fn_disabled_rules ()
@ -7531,7 +7530,9 @@ wine_fn_disabled_rules ()
"__clean__: $ac_dir/clean "__clean__: $ac_dir/clean
.PHONY: $ac_dir/clean .PHONY: $ac_dir/clean
$ac_dir/clean: dummy $ac_dir/clean: dummy
\$(RM) \$(CLEAN_FILES:%=$ac_dir/%) $ac_clean $ac_extraclean" \$(RM) \$(CLEAN_FILES:%=$ac_dir/%) $ac_clean
distclean::
\$(RM) $ac_extraclean"
} }
wine_fn_config_makefile () wine_fn_config_makefile ()
@ -7619,7 +7620,7 @@ else
wine_fn_clean_rules $ac_clean wine_fn_clean_rules $ac_clean
wine_fn_append_rule \ wine_fn_append_rule \
"$ac_dir: __builddeps__ "$ac_dir: __builddeps__
manpages htmlpages sgmlpages xmlpages:: $ac_dir/Makefile manpages htmlpages sgmlpages xmlpages::
@cd $ac_dir && \$(MAKE) \$@ @cd $ac_dir && \$(MAKE) \$@
.PHONY: $ac_dir/install-lib $ac_dir/uninstall .PHONY: $ac_dir/install-lib $ac_dir/uninstall
install install-lib:: $ac_dir/install-lib install install-lib:: $ac_dir/install-lib
@ -7648,9 +7649,9 @@ fi
wine_fn_append_rule \ wine_fn_append_rule \
"__builddeps__: $ac_file.$IMPLIBEXT $ac_file.$STATIC_IMPLIBEXT "__builddeps__: $ac_file.$IMPLIBEXT $ac_file.$STATIC_IMPLIBEXT
$ac_file.$IMPLIBEXT $ac_file.$STATIC_IMPLIBEXT $ac_file.cross.a: $ac_deps $ac_file.$IMPLIBEXT $ac_file.$STATIC_IMPLIBEXT $ac_file.cross.a: $ac_deps
$ac_file.def: $srcdir/$ac_dir/$ac_name.spec $ac_dir/Makefile \$(WINEBUILD) $ac_file.def: $srcdir/$ac_dir/$ac_name.spec \$(WINEBUILD)
\$(WINEBUILD) \$(TARGETFLAGS)$ac_implibflags -w --def -o \$@ --export $srcdir/$ac_dir/$ac_name.spec \$(WINEBUILD) \$(TARGETFLAGS)$ac_implibflags -w --def -o \$@ --export $srcdir/$ac_dir/$ac_name.spec
$ac_file.$STATIC_IMPLIBEXT: $ac_dir/Makefile dummy $ac_file.$STATIC_IMPLIBEXT: dummy
@cd $ac_dir && \$(MAKE) lib$ac_implib.$STATIC_IMPLIBEXT @cd $ac_dir && \$(MAKE) lib$ac_implib.$STATIC_IMPLIBEXT
.PHONY: $ac_dir/install-dev $ac_dir/uninstall .PHONY: $ac_dir/install-dev $ac_dir/uninstall
$ac_dir/install-dev:: $ac_file.$IMPLIBEXT $ac_dir/install-dev:: $ac_file.$IMPLIBEXT
@ -7673,7 +7674,7 @@ $ac_dir/uninstall::
then then
wine_fn_append_rule \ wine_fn_append_rule \
"__builddeps__: $ac_file.cross.a "__builddeps__: $ac_file.cross.a
$ac_file.cross.a: $ac_dir/Makefile dummy $ac_file.cross.a: dummy
@cd $ac_dir && \$(MAKE) lib$ac_implib.cross.a" @cd $ac_dir && \$(MAKE) lib$ac_implib.cross.a"
fi fi
@ -7681,9 +7682,9 @@ $ac_file.cross.a: $ac_dir/Makefile dummy
then then
wine_fn_append_rule \ wine_fn_append_rule \
"__builddeps__: $ac_file.$IMPLIBEXT "__builddeps__: $ac_file.$IMPLIBEXT
$ac_file.def: $srcdir/$ac_dir/$ac_name.spec $ac_dir/Makefile \$(WINEBUILD) $ac_file.def: $srcdir/$ac_dir/$ac_name.spec \$(WINEBUILD)
\$(WINEBUILD) \$(TARGETFLAGS)$ac_implibflags -w --def -o \$@ --export $srcdir/$ac_dir/$ac_name.spec \$(WINEBUILD) \$(TARGETFLAGS)$ac_implibflags -w --def -o \$@ --export $srcdir/$ac_dir/$ac_name.spec
$ac_file.a: $srcdir/$ac_dir/$ac_name.spec $ac_dir/Makefile \$(WINEBUILD) $ac_file.a: $srcdir/$ac_dir/$ac_name.spec \$(WINEBUILD)
\$(WINEBUILD) \$(TARGETFLAGS)$ac_implibflags -w --implib -o \$@ --export $srcdir/$ac_dir/$ac_name.spec \$(WINEBUILD) \$(TARGETFLAGS)$ac_implibflags -w --implib -o \$@ --export $srcdir/$ac_dir/$ac_name.spec
.PHONY: $ac_dir/install-dev $ac_dir/uninstall .PHONY: $ac_dir/install-dev $ac_dir/uninstall
$ac_dir/install-dev:: $ac_file.$IMPLIBEXT $ac_dir/install-dev:: $ac_file.$IMPLIBEXT
@ -7696,7 +7697,7 @@ __uninstall__: $ac_dir/uninstall"
then then
wine_fn_append_rule \ wine_fn_append_rule \
"__builddeps__: $ac_file.cross.a "__builddeps__: $ac_file.cross.a
$ac_file.cross.a: $srcdir/$ac_dir/$ac_name.spec $ac_dir/Makefile \$(WINEBUILD) $ac_file.cross.a: $srcdir/$ac_dir/$ac_name.spec \$(WINEBUILD)
\$(WINEBUILD) \$(CROSSTARGET:%=-b %)$ac_implibflags -w --implib -o \$@ --export $srcdir/$ac_dir/$ac_name.spec" \$(WINEBUILD) \$(CROSSTARGET:%=-b %)$ac_implibflags -w --implib -o \$@ --export $srcdir/$ac_dir/$ac_name.spec"
fi fi
@ -7811,7 +7812,7 @@ fi
wine_fn_clean_rules $ac_clean wine_fn_clean_rules $ac_clean
wine_fn_append_rule \ wine_fn_append_rule \
"$ac_dir: programs/winetest/Makefile __builddeps__ "$ac_dir: __builddeps__
programs/winetest: $ac_dir programs/winetest: $ac_dir
check test: $ac_dir/test check test: $ac_dir/test
.PHONY: $ac_dir/test .PHONY: $ac_dir/test
@ -7825,7 +7826,7 @@ testclean::
wine_fn_append_rule \ wine_fn_append_rule \
"crosstest: $ac_dir/crosstest "crosstest: $ac_dir/crosstest
.PHONY: $ac_dir/crosstest .PHONY: $ac_dir/crosstest
$ac_dir/crosstest: $ac_dir/Makefile __builddeps__ dummy $ac_dir/crosstest: __builddeps__ dummy
@cd $ac_dir && \$(MAKE) crosstest" @cd $ac_dir && \$(MAKE) crosstest"
fi fi
} }
@ -7865,7 +7866,7 @@ distclean::
\$(RM) $ac_links" \$(RM) $ac_links"
for f in $ac_links; do wine_fn_ignore_file $f; done for f in $ac_links; do wine_fn_ignore_file $f; done
test -n "$ac_linkdir" || return test -n "$ac_linkdir" || return
wine_fn_append_rule "$ac_linkdir/Makefile $ac_linkdir/depend: $ac_links" wine_fn_append_rule "$ac_linkdir/depend: $ac_links"
} }
wine_binary="wine" wine_binary="wine"
@ -17230,7 +17231,9 @@ CLEAN_FILES = *.o *.a *.so *.res *.fake *.ok *.tab.[ch] *.yy.c
.MAKEFILEDEPS: .MAKEFILEDEPS:
all: Makefile all: Makefile
Makefile: $srcdir/Makefile.in config.status \$(MAKEDEP) Makefile: $srcdir/Makefile.in config.status \$(MAKEDEP)
@./config.status Make.tmp Makefile" @./config.status Make.tmp Makefile
depend: \$(MAKEDEP) dummy
\$(MAKEDEP)"
test "$srcdir" = . && wine_fn_append_rule "all: .gitignore test "$srcdir" = . && wine_fn_append_rule "all: .gitignore
.gitignore: config.status .gitignore: config.status
@ -19026,7 +19029,7 @@ wine_fn_output_makedep ()
} }
wine_fn_output_makefile () wine_fn_output_makefile ()
{ {
cat Make.tmp - <<\_WINE_EOF >\$tmp/makefile && mv -f \$tmp/makefile \$1 && rm -f Make.tmp && "$wine_makedep" . && return cat Make.tmp - <<\_WINE_EOF >\$tmp/makefile && mv -f \$tmp/makefile \$1 && rm -f Make.tmp && "$wine_makedep" && return
`cat $wine_rules_file` `cat $wine_rules_file`
_WINE_EOF _WINE_EOF
as_fn_error $? "could not create Makefile" "$LINENO" 5 as_fn_error $? "could not create Makefile" "$LINENO" 5

View File

@ -2573,7 +2573,9 @@ CLEAN_FILES = *.o *.a *.so *.res *.fake *.ok *.tab.[[ch]] *.yy.c
.MAKEFILEDEPS: .MAKEFILEDEPS:
all: Makefile all: Makefile
Makefile: $srcdir/Makefile.in config.status \$(MAKEDEP) Makefile: $srcdir/Makefile.in config.status \$(MAKEDEP)
@./config.status Make.tmp Makefile]) @./config.status Make.tmp Makefile
depend: \$(MAKEDEP) dummy
\$(MAKEDEP)])
test "$srcdir" = . && WINE_APPEND_RULE( test "$srcdir" = . && WINE_APPEND_RULE(
[all: .gitignore [all: .gitignore
@ -3575,7 +3577,7 @@ fi
AC_CONFIG_COMMANDS([Makefile], [wine_fn_output_makefile Makefile], AC_CONFIG_COMMANDS([Makefile], [wine_fn_output_makefile Makefile],
[wine_fn_output_makefile () [wine_fn_output_makefile ()
{ {
cat Make.tmp - <<\_WINE_EOF >\$tmp/makefile && mv -f \$tmp/makefile \$[]1 && rm -f Make.tmp && "$wine_makedep" . && return cat Make.tmp - <<\_WINE_EOF >\$tmp/makefile && mv -f \$tmp/makefile \$[]1 && rm -f Make.tmp && "$wine_makedep" && return
`cat $wine_rules_file` `cat $wine_rules_file`
_WINE_EOF _WINE_EOF
AS_ERROR([could not create Makefile]) AS_ERROR([could not create Makefile])

View File

@ -156,6 +156,7 @@ struct makefile
struct strarray scripts; struct strarray scripts;
struct strarray appmode; struct strarray appmode;
struct strarray imports; struct strarray imports;
struct strarray subdirs;
struct strarray delayimports; struct strarray delayimports;
struct strarray extradllflags; struct strarray extradllflags;
struct strarray install_lib; struct strarray install_lib;
@ -175,6 +176,7 @@ struct makefile
const char *importlib; const char *importlib;
int use_msvcrt; int use_msvcrt;
int is_win16; int is_win16;
struct makefile **submakes;
}; };
static struct makefile *top_makefile; static struct makefile *top_makefile;
@ -189,7 +191,7 @@ static int output_column;
static FILE *output_file; static FILE *output_file;
static const char Usage[] = static const char Usage[] =
"Usage: makedep [options] directories\n" "Usage: makedep [options] [directories]\n"
"Options:\n" "Options:\n"
" -R from to Compute the relative path between two directories\n" " -R from to Compute the relative path between two directories\n"
" -fxxx Store output in file 'xxx' (default: Makefile)\n"; " -fxxx Store output in file 'xxx' (default: Makefile)\n";
@ -2842,13 +2844,6 @@ static struct strarray output_sources( const struct makefile *make, struct strar
strarray_add( &phony_targets, obj_dir_path( make, "clean" )); strarray_add( &phony_targets, obj_dir_path( make, "clean" ));
} }
if (make->top_obj_dir)
{
output( "depend:\n" );
output( "\t@cd %s && $(MAKE) %s\n", make->top_obj_dir, base_dir_path( make, "depend" ));
strarray_add( &phony_targets, "depend" );
}
if (phony_targets.count) if (phony_targets.count)
{ {
output( ".PHONY:" ); output( ".PHONY:" );
@ -3013,7 +3008,10 @@ static void output_top_variables( const struct makefile *make )
output( "# Automatically generated by make depend; DO NOT EDIT!!\n\n" ); output( "# Automatically generated by make depend; DO NOT EDIT!!\n\n" );
output( "all:\n\n" ); output( "all:\n\n" );
for (i = 0; i < vars->count; i += 2) for (i = 0; i < vars->count; i += 2)
{
if (!strcmp( vars->str[i], "SUBDIRS" )) continue; /* not inherited */
output( "%s = %s\n", vars->str[i], get_make_variable( make, vars->str[i] )); output( "%s = %s\n", vars->str[i], get_make_variable( make, vars->str[i] ));
}
output( "\n" ); output( "\n" );
} }
@ -3023,9 +3021,11 @@ static void output_top_variables( const struct makefile *make )
*/ */
static void output_dependencies( const struct makefile *make ) static void output_dependencies( const struct makefile *make )
{ {
static const char separator[] = "### Dependencies";
struct strarray targets, testlist_files = empty_strarray, ignore_files = empty_strarray; struct strarray targets, testlist_files = empty_strarray, ignore_files = empty_strarray;
char buffer[1024]; char buffer[1024];
FILE *src_file; FILE *src_file;
int found = 0;
output_file_name = base_dir_path( make, output_makefile_name ); output_file_name = base_dir_path( make, output_makefile_name );
output_file = create_temp_file( output_file_name ); output_file = create_temp_file( output_file_name );
@ -3033,11 +3033,15 @@ static void output_dependencies( const struct makefile *make )
/* copy the contents of the source makefile */ /* copy the contents of the source makefile */
src_file = open_input_makefile( make ); src_file = open_input_makefile( make );
while (fgets( buffer, sizeof(buffer), src_file )) while (fgets( buffer, sizeof(buffer), src_file ) && !found)
{
if (fwrite( buffer, 1, strlen(buffer), output_file ) != strlen(buffer)) fatal_perror( "write" ); if (fwrite( buffer, 1, strlen(buffer), output_file ) != strlen(buffer)) fatal_perror( "write" );
found = !strncmp( buffer, separator, strlen(separator) );
}
if (fclose( src_file )) fatal_perror( "close" ); if (fclose( src_file )) fatal_perror( "close" );
input_file_name = NULL; input_file_name = NULL;
if (!found) output( "\n%s (everything below this line is auto-generated; DO NOT EDIT!!)\n", separator );
targets = output_sources( make, &testlist_files ); targets = output_sources( make, &testlist_files );
fclose( output_file ); fclose( output_file );
@ -3059,9 +3063,9 @@ static void output_dependencies( const struct makefile *make )
/******************************************************************* /*******************************************************************
* update_makefile * load_sources
*/ */
static void update_makefile( const char *path ) static void load_sources( struct makefile *make )
{ {
static const char *source_vars[] = static const char *source_vars[] =
{ {
@ -3084,9 +3088,6 @@ static void update_makefile( const char *path )
unsigned int i; unsigned int i;
struct strarray value; struct strarray value;
struct incl_file *file; struct incl_file *file;
struct makefile *make;
make = parse_makefile( path, NULL );
if (root_src_dir) if (root_src_dir)
{ {
@ -3161,8 +3162,6 @@ static void update_makefile( const char *path )
} }
LIST_FOR_EACH_ENTRY( file, &make->includes, struct incl_file, entry ) parse_file( make, file, 0 ); LIST_FOR_EACH_ENTRY( file, &make->includes, struct incl_file, entry ) parse_file( make, file, 0 );
output_dependencies( make );
} }
@ -3250,11 +3249,6 @@ int main( int argc, char *argv[] )
exit( 0 ); exit( 0 );
} }
if (argc <= 1)
{
fprintf( stderr, "%s", Usage );
exit( 1 );
}
atexit( cleanup_files ); atexit( cleanup_files );
signal( SIGTERM, exit_on_signal ); signal( SIGTERM, exit_on_signal );
signal( SIGINT, exit_on_signal ); signal( SIGINT, exit_on_signal );
@ -3294,6 +3288,30 @@ int main( int argc, char *argv[] )
if (!tools_ext) tools_ext = ""; if (!tools_ext) tools_ext = "";
if (!man_ext) man_ext = "3w"; if (!man_ext) man_ext = "3w";
for (i = 1; i < argc; i++) update_makefile( argv[i] ); if (argc == 1)
{
top_makefile->subdirs = get_expanded_make_var_array( top_makefile, "SUBDIRS" );
top_makefile->submakes = xmalloc( top_makefile->subdirs.count * sizeof(*top_makefile->submakes) );
for (i = 0; i < top_makefile->subdirs.count; i++)
top_makefile->submakes[i] = parse_makefile( top_makefile->subdirs.str[i], NULL );
load_sources( top_makefile );
for (i = 0; i < top_makefile->subdirs.count; i++)
load_sources( top_makefile->submakes[i] );
for (i = 0; i < top_makefile->subdirs.count; i++)
output_dependencies( top_makefile->submakes[i] );
output_dependencies( top_makefile );
return 0;
}
for (i = 1; i < argc; i++)
{
struct makefile *make = parse_makefile( argv[i], NULL );
load_sources( make );
output_dependencies( make );
}
return 0; return 0;
} }