Module: wine Branch: master Commit: 4303bd4450e5e8982852852c3be1433cbf26a26d URL: https://gitlab.winehq.org/wine/wine/-/commit/4303bd4450e5e8982852852c3be1433...
Author: Alexandre Julliard julliard@winehq.org Date: Wed Jun 26 11:32:20 2024 +0200
makedep: Generate rules for make depend.
---
configure | 17 +++-------------- configure.ac | 18 +++++------------- tools/makedep.c | 16 ++++++++++++++-- 3 files changed, 22 insertions(+), 29 deletions(-)
diff --git a/configure b/configure index 2373cf89da8..e27f98a8a67 100755 --- a/configure +++ b/configure @@ -809,7 +809,6 @@ BISON FLEX SED_CMD RUNTESTFLAGS -MAKEDEP toolsdir x86_64_DISABLED_SUBDIRS x86_64_DELAYLOADFLAG @@ -6464,8 +6463,6 @@ else fi toolsdir=$wine_cv_toolsdir
-MAKEDEP=$wine_makedep - RUNTESTFLAGS="-q -P wine"
SED_CMD="LC_ALL=C sed -e 's,@bindir@,${bindir},g' -e 's,@PACKAGE_STRING@,$PACKAGE_STRING,g' -e 's,@PACKAGE_VERSION@,$PACKAGE_VERSION,g'" @@ -23116,19 +23113,12 @@ ac_config_commands="$ac_config_commands Makefile" SHELL=/bin/sh
+ as_fn_append wine_rules " all: wine @echo "Wine build complete." -.INIT: Makefile -.MAKEFILEDEPS: -all: Makefile -Makefile: config.status $(MAKEDEP) +Makefile: config.status @./config.status Makefile -depend: $(MAKEDEP) - $(MAKEDEP)$makedep_flags" - - -as_fn_append wine_rules " config.status: ${wine_srcdir}configure @./config.status --recheck include/config.h: include/stamp-h @@ -23220,7 +23210,7 @@ tags ctags: rm -f tags (test -d .git && git ls-files || find -L $srcdir -name '*.[ch]' -print) | xargs ctags -a $(TAGSFLAGS) dummy: -.PHONY: depend dummy install-manpages" +.PHONY: dummy"
printf "%s\n" " done" >&6 cat >confcache <<_ACEOF @@ -24023,7 +24013,6 @@ x86_64_TARGET = $x86_64_TARGET x86_64_DELAYLOADFLAG = $x86_64_DELAYLOADFLAG x86_64_DISABLED_SUBDIRS = $x86_64_DISABLED_SUBDIRS toolsdir = $toolsdir -MAKEDEP = $MAKEDEP RUNTESTFLAGS = $RUNTESTFLAGS SED_CMD = $SED_CMD FLEX = $FLEX diff --git a/configure.ac b/configure.ac index 43bba37a39b..798ed738d97 100644 --- a/configure.ac +++ b/configure.ac @@ -193,7 +193,6 @@ else AC_MSG_ERROR([could not find Wine tools in $wine_cv_toolsdir]) fi AC_SUBST(toolsdir,[$wine_cv_toolsdir]) -AC_SUBST(MAKEDEP,[$wine_makedep]) AC_SUBST(RUNTESTFLAGS,["-q -P wine"]) AC_SUBST(SED_CMD,["LC_ALL=C sed -e 's,@bindir@,${bindir},g' -e 's,@PACKAGE_STRING@,$PACKAGE_STRING,g' -e 's,@PACKAGE_VERSION@,$PACKAGE_VERSION,g'"])
@@ -3625,21 +3624,14 @@ dnl Main makefile
AC_SUBST(SHELL,[/bin/sh])
+dnl Rules for re-running configure + WINE_APPEND_RULE( [all: wine @echo "Wine build complete." -.INIT: Makefile -.MAKEFILEDEPS: -all: Makefile -Makefile: config.status $(MAKEDEP) +Makefile: config.status @./config.status Makefile -depend: $(MAKEDEP) - $(MAKEDEP)$makedep_flags]) - -dnl Rules for re-running configure - -WINE_APPEND_RULE( -[config.status: ${wine_srcdir}configure +config.status: ${wine_srcdir}configure @./config.status --recheck include/config.h: include/stamp-h include/stamp-h: ${wine_srcdir}include/config.h.in config.status @@ -3734,7 +3726,7 @@ tags ctags: rm -f tags (test -d .git && git ls-files || find -L $srcdir -name '*.[[ch]]' -print) | xargs ctags -a $(TAGSFLAGS) dummy: -.PHONY: depend dummy install-manpages]) +.PHONY: dummy])
AS_ECHO(" done") >&AS_MESSAGE_FD AC_OUTPUT diff --git a/tools/makedep.c b/tools/makedep.c index a1534e8e9da..25ddb92f7fa 100644 --- a/tools/makedep.c +++ b/tools/makedep.c @@ -4189,6 +4189,7 @@ static void output_top_makefile( struct makefile *make ) FILE *src_file; unsigned int i; int found = 0; + const char *makedep;
output_file_name = obj_dir_path( make, output_makefile_name ); output_file = create_temp_file( output_file_name ); @@ -4206,10 +4207,21 @@ static void output_top_makefile( struct makefile *make ) if (!found) output( "\n%s (everything below this line is auto-generated; DO NOT EDIT!!)\n", separator );
if (silent_rules) output_silent_rules(); + + /* add special targets for makefile and dependencies */ + + output( ".INIT: Makefile\n" ); + output( ".MAKEFILEDEPS:\n" ); + output( ".SUFFIXES:\n" ); + makedep = strmake( "%s%s",tools_dir_path( make, "makedep" ), tools_ext ); + output( "Makefile: %s\n", makedep ); + output( "depend: %s\n", makedep ); + output( "\t%s%s\n", makedep, + silent_rules ? " -S" : "" ); + strarray_add( &make->phony_targets, "depend" ); + for (i = 0; i < subdirs.count; i++) output_sources( submakes[i] ); output_sources( make ); - /* disable implicit rules */ - output( ".SUFFIXES:\n" );
fclose( output_file ); output_file = NULL;