mirror of
https://github.com/mirror/make.git
synced 2026-08-31 03:38:03 +08:00
Compare commits
52 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
f430a65ccb | ||
|
|
c30da63fd2 | ||
|
|
3fb7312e9f | ||
|
|
dd6adfa454 | ||
|
|
3b5e47b2e2 | ||
|
|
4e277f6fbd | ||
|
|
ec946d7e21 | ||
|
|
16d06006a4 | ||
|
|
b774aebffa | ||
|
|
06de697268 | ||
|
|
fdfe0446b6 | ||
|
|
12b14f0484 | ||
|
|
4e12a5fa45 | ||
|
|
e56243fe57 | ||
|
|
7449abfe1b | ||
|
|
53b9770b40 | ||
|
|
766baeef0a | ||
|
|
ee204c78f2 | ||
|
|
e64674b718 | ||
|
|
564fb212a7 | ||
|
|
30cc10093b | ||
|
|
69c5a2128b | ||
|
|
577dd1ff6d | ||
|
|
86f2f8bcb5 | ||
|
|
c72205b28b | ||
|
|
057e33d6b5 | ||
|
|
e4499a1fb5 | ||
|
|
57b043c7fb | ||
|
|
f389aabde6 | ||
|
|
acbef3f612 | ||
|
|
3822f77c1d | ||
|
|
1cf3932a39 | ||
|
|
33bda40086 | ||
|
|
e666a6a021 | ||
|
|
5920d6d2b3 | ||
|
|
2e6468c811 | ||
|
|
393d2a2d4a | ||
|
|
bd7d03f8cd | ||
|
|
a4a173928f | ||
|
|
0e113897f7 | ||
|
|
b0eab8ecb9 | ||
|
|
f84821b249 | ||
|
|
99d1423059 | ||
|
|
7fbd58cd6b | ||
|
|
3ede0b96ac | ||
|
|
1d289b424a | ||
|
|
96285f875b | ||
|
|
bd4ce86785 | ||
|
|
e1c072aa7e | ||
|
|
af0074547d | ||
|
|
4a7a8278e8 | ||
|
|
00fa3ca3a5 |
1
.gitignore
vendored
1
.gitignore
vendored
@@ -30,6 +30,7 @@ configure
|
|||||||
/mk/Posix.mk
|
/mk/Posix.mk
|
||||||
stamp-h1
|
stamp-h1
|
||||||
.dirstamp
|
.dirstamp
|
||||||
|
gnulib
|
||||||
|
|
||||||
# Build artifacts
|
# Build artifacts
|
||||||
.deps/
|
.deps/
|
||||||
|
|||||||
3
AUTHORS
3
AUTHORS
@@ -68,12 +68,13 @@ Other contributors:
|
|||||||
David Boyce <dsb@boyski.com>
|
David Boyce <dsb@boyski.com>
|
||||||
Frank Heckenbach <f.heckenbach@fh-soft.de>
|
Frank Heckenbach <f.heckenbach@fh-soft.de>
|
||||||
Kaz Kylheku <kaz@kylheku.com>
|
Kaz Kylheku <kaz@kylheku.com>
|
||||||
|
Christof Warlich <cwarlich@gmx.de>
|
||||||
|
|
||||||
With suggestions/comments/bug reports from a cast of ... well ...
|
With suggestions/comments/bug reports from a cast of ... well ...
|
||||||
hundreds, anyway :)
|
hundreds, anyway :)
|
||||||
|
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
Copyright (C) 1997-2019 Free Software Foundation, Inc.
|
Copyright (C) 1997-2020 Free Software Foundation, Inc.
|
||||||
This file is part of GNU Make.
|
This file is part of GNU Make.
|
||||||
|
|
||||||
GNU Make is free software; you can redistribute it and/or modify it under the
|
GNU Make is free software; you can redistribute it and/or modify it under the
|
||||||
|
|||||||
@@ -10,7 +10,7 @@
|
|||||||
#
|
#
|
||||||
# make.exe -f Basic.mk
|
# make.exe -f Basic.mk
|
||||||
#
|
#
|
||||||
# Copyright (C) 2017-2019 Free Software Foundation, Inc.
|
# Copyright (C) 2017-2020 Free Software Foundation, Inc.
|
||||||
# This file is part of GNU Make.
|
# This file is part of GNU Make.
|
||||||
#
|
#
|
||||||
# GNU Make is free software; you can redistribute it and/or modify it under
|
# GNU Make is free software; you can redistribute it and/or modify it under
|
||||||
|
|||||||
11
Makefile.am
11
Makefile.am
@@ -1,6 +1,6 @@
|
|||||||
# This is a -*-Makefile-*-, or close enough
|
# This is a -*-Makefile-*-, or close enough
|
||||||
#
|
#
|
||||||
# Copyright (C) 1997-2019 Free Software Foundation, Inc.
|
# Copyright (C) 1997-2020 Free Software Foundation, Inc.
|
||||||
# This file is part of GNU Make.
|
# This file is part of GNU Make.
|
||||||
#
|
#
|
||||||
# GNU Make is free software; you can redistribute it and/or modify it under
|
# GNU Make is free software; you can redistribute it and/or modify it under
|
||||||
@@ -16,7 +16,7 @@
|
|||||||
# You should have received a copy of the GNU General Public License along with
|
# You should have received a copy of the GNU General Public License along with
|
||||||
# this program. If not, see <http://www.gnu.org/licenses/>.
|
# this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
|
|
||||||
AUTOMAKE_OPTIONS = dist-bzip2 silent-rules std-options subdir-objects nostdinc
|
AUTOMAKE_OPTIONS = dist-lzip silent-rules std-options subdir-objects nostdinc
|
||||||
ACLOCAL_AMFLAGS = -I m4
|
ACLOCAL_AMFLAGS = -I m4
|
||||||
|
|
||||||
MAKE_HOST = @MAKE_HOST@
|
MAKE_HOST = @MAKE_HOST@
|
||||||
@@ -94,7 +94,8 @@ m4_FILES = m4/gnulib-cache.m4
|
|||||||
test_FILES = tests/run_make_tests tests/run_make_tests.bat \
|
test_FILES = tests/run_make_tests tests/run_make_tests.bat \
|
||||||
tests/run_make_tests.pl tests/test_driver.pl \
|
tests/run_make_tests.pl tests/test_driver.pl \
|
||||||
tests/config-flags.pm.in tests/config_flags_pm.com \
|
tests/config-flags.pm.in tests/config_flags_pm.com \
|
||||||
tests/mkshadow tests/jhelp.pl tests/guile.supp tests/README
|
tests/config-flags.pm.W32 \
|
||||||
|
tests/mkshadow tests/thelp.pl tests/guile.supp tests/README
|
||||||
# test/scripts are added via dist-hook below.
|
# test/scripts are added via dist-hook below.
|
||||||
|
|
||||||
EXTRA_DIST = ChangeLog README build.sh build.cfg.in $(man_MANS) \
|
EXTRA_DIST = ChangeLog README build.sh build.cfg.in $(man_MANS) \
|
||||||
@@ -160,8 +161,8 @@ check-regression: tests/config-flags.pm
|
|||||||
rm -f tests/$$f; ln -s ../srctests/$$f tests; \
|
rm -f tests/$$f; ln -s ../srctests/$$f tests; \
|
||||||
done; fi ;; \
|
done; fi ;; \
|
||||||
esac; \
|
esac; \
|
||||||
echo "cd tests && $(PERL) ./run_make_tests.pl -srcdir $(abs_top_srcdir) -make ../make$(EXEEXT) $(MAKETESTFLAGS)"; \
|
echo "cd tests && $(PERL) $(PERLFLAGS) ./run_make_tests.pl -srcdir $(abs_top_srcdir) -make ../make$(EXEEXT) $(MAKETESTFLAGS)"; \
|
||||||
cd tests && $(PERL) ./run_make_tests.pl -srcdir '$(abs_top_srcdir)' -make '../make$(EXEEXT)' $(MAKETESTFLAGS); \
|
cd tests && $(PERL) $(PERLFLAGS) ./run_make_tests.pl -srcdir '$(abs_top_srcdir)' -make '../make$(EXEEXT)' $(MAKETESTFLAGS); \
|
||||||
else \
|
else \
|
||||||
echo "Can't find a working Perl ($(PERL)); the test suite requires Perl."; \
|
echo "Can't find a working Perl ($(PERL)); the test suite requires Perl."; \
|
||||||
fi; \
|
fi; \
|
||||||
|
|||||||
60
NEWS
60
NEWS
@@ -1,6 +1,6 @@
|
|||||||
GNU make NEWS -*-indented-text-*-
|
GNU make NEWS -*-indented-text-*-
|
||||||
History of user-visible changes.
|
History of user-visible changes.
|
||||||
16 September 2019
|
19 January 2020
|
||||||
|
|
||||||
See the end of this file for copyrights and conditions.
|
See the end of this file for copyrights and conditions.
|
||||||
|
|
||||||
@@ -9,11 +9,11 @@ which is contained in this distribution as the file doc/make.texi.
|
|||||||
See the README file and the GNU make manual for instructions for
|
See the README file and the GNU make manual for instructions for
|
||||||
reporting bugs.
|
reporting bugs.
|
||||||
|
|
||||||
Version 4.2.91 (16 Sep 2019)
|
Version 4.3 (19 Jan 2020)
|
||||||
|
|
||||||
A complete list of bugs fixed in this version is available here:
|
A complete list of bugs fixed in this version is available here:
|
||||||
|
|
||||||
http://sv.gnu.org/bugs/index.php?group=make&report_id=111&fix_release_id=108&set=custom
|
https://sv.gnu.org/bugs/index.php?group=make&report_id=111&fix_release_id=108&set=custom
|
||||||
|
|
||||||
* WARNING: Backward-incompatibility!
|
* WARNING: Backward-incompatibility!
|
||||||
Number signs (#) appearing inside a macro reference or function invocation
|
Number signs (#) appearing inside a macro reference or function invocation
|
||||||
@@ -35,18 +35,18 @@ http://sv.gnu.org/bugs/index.php?group=make&report_id=111&fix_release_id=108&set
|
|||||||
already contains some value. Similarly, appending an empty string does not
|
already contains some value. Similarly, appending an empty string does not
|
||||||
add a trailing space.
|
add a trailing space.
|
||||||
|
|
||||||
* WARNING: Backward-incompatibility!
|
* NOTE: Deprecated behavior.
|
||||||
On Linux, and any other systems that provide a /proc/loadavg with similar
|
Contrary to the documentation, suffix rules with prerequisites are being
|
||||||
syntax, the -l/--load-average option will consult that file to determine how
|
treated BOTH as simple targets AND as pattern rules. Further, the
|
||||||
many CPUs are busy at that moment and compare that value to the load value
|
prerequisites are ignored by the pattern rules. POSIX specifies that in
|
||||||
requested. This allows usage such as "-j -lN" for N-processor systems
|
order to be a suffix rule there can be no prerequisites defined. In this
|
||||||
without fear of overload during initial startup.
|
release if POSIX mode is enabled then rules with prerequisites cannot be
|
||||||
Patch provided by Sven C. Dack <sven.c.dack@sky.com>
|
suffix rules. If POSIX mode is not enabled then the previous behavior is
|
||||||
|
preserved (a pattern rule with no extra prerequisites is created) AND a
|
||||||
* WARNING: Backward-incompatibility!
|
warning about this behavior is generated:
|
||||||
Contrary to the documentation, suffix rules with prerequisites were being
|
warning: ignoring prerequisites on suffix rule definition
|
||||||
treated BOTH as simple targets AND as pattern rules. Behavior now matches
|
The POSIX behavior will be adopted as the only behavior in a future release
|
||||||
the documentation, and pattern rules are no longer created in this case.
|
of GNU make so please resolve any warnings.
|
||||||
|
|
||||||
* New feature: Grouped explicit targets
|
* New feature: Grouped explicit targets
|
||||||
Pattern rules have always had the ability to generate multiple targets with
|
Pattern rules have always had the ability to generate multiple targets with
|
||||||
@@ -56,13 +56,21 @@ http://sv.gnu.org/bugs/index.php?group=make&report_id=111&fix_release_id=108&set
|
|||||||
search for 'grouped-target' in the .FEATURES special variable.
|
search for 'grouped-target' in the .FEATURES special variable.
|
||||||
Implementation contributed by Kaz Kylheku <kaz@kylheku.com>
|
Implementation contributed by Kaz Kylheku <kaz@kylheku.com>
|
||||||
|
|
||||||
|
* New feature: .EXTRA_PREREQS variable
|
||||||
|
Words in this variable are considered prerequisites of targets but they are
|
||||||
|
not added to any of the automatic variable values when expanding the
|
||||||
|
recipe. This variable can either be global (applies to all targets) or
|
||||||
|
a target-specific variable. To detect this feature search for 'extra-prereqs'
|
||||||
|
in the .FEATURES special variable.
|
||||||
|
Implementation contributed by Christof Warlich <cwarlich@gmx.de>
|
||||||
|
|
||||||
* Makefiles can now specify the '-j' option in their MAKEFLAGS variable and
|
* Makefiles can now specify the '-j' option in their MAKEFLAGS variable and
|
||||||
this will cause make to enable that parallelism mode.
|
this will cause make to enable that parallelism mode.
|
||||||
|
|
||||||
* GNU make will now use posix_spawn() on systems where it is available.
|
* GNU make will now use posix_spawn() on systems where it is available.
|
||||||
If you prefer to use fork/exec even on systems where posix_spawn() is
|
If you prefer to use fork/exec even on systems where posix_spawn() is
|
||||||
present, you can use the --disable-posix-spawn option to configure. Aron
|
present, you can use the --disable-posix-spawn option to configure.
|
||||||
Barath <baratharon@caesar.elte.hu> provided the basic implementation.
|
Implementation contributed by Aron Barath <baratharon@caesar.elte.hu>
|
||||||
|
|
||||||
* Error messages printed when invoking non-existent commands have been cleaned
|
* Error messages printed when invoking non-existent commands have been cleaned
|
||||||
up and made consistent.
|
up and made consistent.
|
||||||
@@ -100,7 +108,7 @@ Version 4.2.1 (10 Jun 2016)
|
|||||||
|
|
||||||
A complete list of bugs fixed in this version is available here:
|
A complete list of bugs fixed in this version is available here:
|
||||||
|
|
||||||
http://sv.gnu.org/bugs/index.php?group=make&report_id=111&fix_release_id=107&set=custom
|
https://sv.gnu.org/bugs/index.php?group=make&report_id=111&fix_release_id=107&set=custom
|
||||||
|
|
||||||
This release is a bug-fix release.
|
This release is a bug-fix release.
|
||||||
|
|
||||||
@@ -109,7 +117,7 @@ Version 4.2 (22 May 2016)
|
|||||||
|
|
||||||
A complete list of bugs fixed in this version is available here:
|
A complete list of bugs fixed in this version is available here:
|
||||||
|
|
||||||
http://sv.gnu.org/bugs/index.php?group=make&report_id=111&fix_release_id=106&set=custom
|
https://sv.gnu.org/bugs/index.php?group=make&report_id=111&fix_release_id=106&set=custom
|
||||||
|
|
||||||
* New variable: $(.SHELLSTATUS) is set to the exit status of the last != or
|
* New variable: $(.SHELLSTATUS) is set to the exit status of the last != or
|
||||||
$(shell ...) function invoked in this instance of make. This will be "0" if
|
$(shell ...) function invoked in this instance of make. This will be "0" if
|
||||||
@@ -148,7 +156,7 @@ Version 4.1 (05 Oct 2014)
|
|||||||
|
|
||||||
A complete list of bugs fixed in this version is available here:
|
A complete list of bugs fixed in this version is available here:
|
||||||
|
|
||||||
http://sv.gnu.org/bugs/index.php?group=make&report_id=111&fix_release_id=105&set=custom
|
https://sv.gnu.org/bugs/index.php?group=make&report_id=111&fix_release_id=105&set=custom
|
||||||
|
|
||||||
* New variables: $(MAKE_TERMOUT) and $(MAKE_TERMERR) are set to non-empty
|
* New variables: $(MAKE_TERMOUT) and $(MAKE_TERMERR) are set to non-empty
|
||||||
values if stdout or stderr, respectively, are believed to be writing to a
|
values if stdout or stderr, respectively, are believed to be writing to a
|
||||||
@@ -196,7 +204,7 @@ Version 4.0 (09 Oct 2013)
|
|||||||
|
|
||||||
A complete list of bugs fixed in this version is available here:
|
A complete list of bugs fixed in this version is available here:
|
||||||
|
|
||||||
http://sv.gnu.org/bugs/index.php?group=make&report_id=111&fix_release_id=101&set=custom
|
https://sv.gnu.org/bugs/index.php?group=make&report_id=111&fix_release_id=101&set=custom
|
||||||
|
|
||||||
* WARNING: Backward-incompatibility!
|
* WARNING: Backward-incompatibility!
|
||||||
If .POSIX is specified, then make adheres to the POSIX backslash/newline
|
If .POSIX is specified, then make adheres to the POSIX backslash/newline
|
||||||
@@ -300,7 +308,7 @@ Version 3.82 (28 Jul 2010)
|
|||||||
|
|
||||||
A complete list of bugs fixed in this version is available here:
|
A complete list of bugs fixed in this version is available here:
|
||||||
|
|
||||||
http://sv.gnu.org/bugs/index.php?group=make&report_id=111&fix_release_id=104&set=custom
|
https://sv.gnu.org/bugs/index.php?group=make&report_id=111&fix_release_id=104&set=custom
|
||||||
|
|
||||||
* Compiling GNU make now requires a conforming ISO C 1989 compiler and
|
* Compiling GNU make now requires a conforming ISO C 1989 compiler and
|
||||||
standard runtime library.
|
standard runtime library.
|
||||||
@@ -465,7 +473,7 @@ Version 3.81 (01 Apr 2006)
|
|||||||
might have caused the target to rebuild. Starting with the _next_
|
might have caused the target to rebuild. Starting with the _next_
|
||||||
release of GNU make, '$?' will contain all prerequisites that caused
|
release of GNU make, '$?' will contain all prerequisites that caused
|
||||||
the target to be considered out of date.
|
the target to be considered out of date.
|
||||||
See http://savannah.gnu.org/bugs/?16051
|
See https://savannah.gnu.org/bugs/?16051
|
||||||
|
|
||||||
* WARNING: Backward-incompatibility!
|
* WARNING: Backward-incompatibility!
|
||||||
GNU make now implements a generic "second expansion" feature on the
|
GNU make now implements a generic "second expansion" feature on the
|
||||||
@@ -589,7 +597,7 @@ Version 3.81 (01 Apr 2006)
|
|||||||
|
|
||||||
A complete list of bugs fixed in this version is available here:
|
A complete list of bugs fixed in this version is available here:
|
||||||
|
|
||||||
http://savannah.gnu.org/bugs/index.php?group=make&report_id=111&fix_release_id=103
|
https://savannah.gnu.org/bugs/index.php?group=make&report_id=111&fix_release_id=103
|
||||||
|
|
||||||
|
|
||||||
Version 3.80 (03 Oct 2002)
|
Version 3.80 (03 Oct 2002)
|
||||||
@@ -707,7 +715,7 @@ Version 3.80 (03 Oct 2002)
|
|||||||
|
|
||||||
A complete list of bugs fixed in this version is available here:
|
A complete list of bugs fixed in this version is available here:
|
||||||
|
|
||||||
http://savannah.gnu.org/bugs/index.php?group=make&report_id=111&fix_release_id=102
|
https://savannah.gnu.org/bugs/index.php?group=make&report_id=111&fix_release_id=102
|
||||||
|
|
||||||
|
|
||||||
Version 3.79.1 (23 Jun 2000)
|
Version 3.79.1 (23 Jun 2000)
|
||||||
@@ -1611,7 +1619,7 @@ Version 3.05
|
|||||||
(Changes from versions 1 through 3.05 were never recorded. Sorry.)
|
(Changes from versions 1 through 3.05 were never recorded. Sorry.)
|
||||||
|
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
Copyright (C) 1988-2019 Free Software Foundation, Inc.
|
Copyright (C) 1988-2020 Free Software Foundation, Inc.
|
||||||
This file is part of GNU Make.
|
This file is part of GNU Make.
|
||||||
|
|
||||||
GNU Make is free software; you can redistribute it and/or modify it under the
|
GNU Make is free software; you can redistribute it and/or modify it under the
|
||||||
|
|||||||
@@ -64,7 +64,7 @@ If you plan to use recursive makes, install make resident:
|
|||||||
|
|
||||||
|
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
Copyright (C) 1995-2019 Free Software Foundation, Inc.
|
Copyright (C) 1995-2020 Free Software Foundation, Inc.
|
||||||
This file is part of GNU Make.
|
This file is part of GNU Make.
|
||||||
|
|
||||||
GNU Make is free software; you can redistribute it and/or modify it under the
|
GNU Make is free software; you can redistribute it and/or modify it under the
|
||||||
|
|||||||
@@ -280,7 +280,7 @@ Bug reports:
|
|||||||
|
|
||||||
|
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
Copyright (C) 1996-2019 Free Software Foundation, Inc.
|
Copyright (C) 1996-2020 Free Software Foundation, Inc.
|
||||||
This file is part of GNU Make.
|
This file is part of GNU Make.
|
||||||
|
|
||||||
GNU Make is free software; you can redistribute it and/or modify it under the
|
GNU Make is free software; you can redistribute it and/or modify it under the
|
||||||
|
|||||||
@@ -160,7 +160,7 @@ from the make source tree.
|
|||||||
|
|
||||||
|
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
Copyright (C) 2003-2019 Free Software Foundation, Inc.
|
Copyright (C) 2003-2020 Free Software Foundation, Inc.
|
||||||
This file is part of GNU Make.
|
This file is part of GNU Make.
|
||||||
|
|
||||||
GNU Make is free software; you can redistribute it and/or modify it under the
|
GNU Make is free software; you can redistribute it and/or modify it under the
|
||||||
|
|||||||
@@ -345,7 +345,7 @@ Bug reports:
|
|||||||
is described in the GNU make manual and the base README.
|
is described in the GNU make manual and the base README.
|
||||||
|
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
Copyright (C) 1996-2019 Free Software Foundation, Inc.
|
Copyright (C) 1996-2020 Free Software Foundation, Inc.
|
||||||
This file is part of GNU Make.
|
This file is part of GNU Make.
|
||||||
|
|
||||||
GNU Make is free software; you can redistribute it and/or modify it under the
|
GNU Make is free software; you can redistribute it and/or modify it under the
|
||||||
|
|||||||
@@ -96,7 +96,7 @@ SunOS 4.1.x:
|
|||||||
|
|
||||||
|
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
Copyright (C) 1998-2019 Free Software Foundation, Inc.
|
Copyright (C) 1998-2020 Free Software Foundation, Inc.
|
||||||
This file is part of GNU Make.
|
This file is part of GNU Make.
|
||||||
|
|
||||||
GNU Make is free software; you can redistribute it and/or modify it under the
|
GNU Make is free software; you can redistribute it and/or modify it under the
|
||||||
|
|||||||
18
README.git
18
README.git
@@ -1,7 +1,7 @@
|
|||||||
-*-text-*-
|
-*-text-*-
|
||||||
|
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
Copyright (C) 2002-2019 Free Software Foundation, Inc.
|
Copyright (C) 2002-2020 Free Software Foundation, Inc.
|
||||||
This file is part of GNU Make.
|
This file is part of GNU Make.
|
||||||
|
|
||||||
GNU Make is free software; you can redistribute it and/or modify it under the
|
GNU Make is free software; you can redistribute it and/or modify it under the
|
||||||
@@ -88,7 +88,11 @@ need to install the following extra software:
|
|||||||
* GCC (Clang's GCC emulation is not sufficient)
|
* GCC (Clang's GCC emulation is not sufficient)
|
||||||
* GNU make (POSIX make is not sufficient)
|
* GNU make (POSIX make is not sufficient)
|
||||||
|
|
||||||
And any tools that those utilities require (GNU m4, Perl, etc.)
|
And any tools that those utilities require (GNU m4, etc.)
|
||||||
|
|
||||||
|
To run the tests you must install Perl.
|
||||||
|
|
||||||
|
To build a release you'll need to install lzip.
|
||||||
|
|
||||||
GNU make requires gnulib to provide some facilities. If you want to maintain
|
GNU make requires gnulib to provide some facilities. If you want to maintain
|
||||||
a local installation of gnulib you can set GNULIB_SRCDIR to point to it.
|
a local installation of gnulib you can set GNULIB_SRCDIR to point to it.
|
||||||
@@ -166,16 +170,16 @@ run:
|
|||||||
|
|
||||||
and, if you like:
|
and, if you like:
|
||||||
|
|
||||||
$ make dist-bzip2
|
$ make dist-lzip
|
||||||
|
|
||||||
Even better, you should run this:
|
Even better, you should run this:
|
||||||
|
|
||||||
$ make distcheck
|
$ make distcheck
|
||||||
|
|
||||||
Which will build both .gz and .bz2 package files, then unpack them into
|
Which will build both .gz and .lz package files, then unpack one into a
|
||||||
a temporary location, try to build them, and repack them, verifying that
|
temporary location, try to build it and repack it, then verifying that
|
||||||
everything works, you get the same results, _and_ no extraneous files
|
everything works, you get the same results, _and_ no extraneous files are
|
||||||
are left over after the "distclean" rule.
|
left over after the "distclean" rule.
|
||||||
|
|
||||||
This package can be unpacked and built to give a "normal" (non-maintainer
|
This package can be unpacked and built to give a "normal" (non-maintainer
|
||||||
mode) result.
|
mode) result.
|
||||||
|
|||||||
@@ -172,7 +172,7 @@ at the right README!
|
|||||||
|
|
||||||
|
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
Copyright (C) 1988-2019 Free Software Foundation, Inc.
|
Copyright (C) 1988-2020 Free Software Foundation, Inc.
|
||||||
This file is part of GNU Make.
|
This file is part of GNU Make.
|
||||||
|
|
||||||
GNU Make is free software; you can redistribute it and/or modify it under the
|
GNU Make is free software; you can redistribute it and/or modify it under the
|
||||||
|
|||||||
@@ -101,7 +101,7 @@ The Rest of the List
|
|||||||
|
|
||||||
|
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
Copyright (C) 1997-2019 Free Software Foundation, Inc.
|
Copyright (C) 1997-2020 Free Software Foundation, Inc.
|
||||||
This file is part of GNU Make.
|
This file is part of GNU Make.
|
||||||
|
|
||||||
GNU Make is free software; you can redistribute it and/or modify it under the
|
GNU Make is free software; you can redistribute it and/or modify it under the
|
||||||
|
|||||||
22
bootstrap
22
bootstrap
@@ -4,7 +4,7 @@ scriptversion=2019-01-04.17; # UTC
|
|||||||
|
|
||||||
# Bootstrap this package from checked-out sources.
|
# Bootstrap this package from checked-out sources.
|
||||||
|
|
||||||
# Copyright (C) 2003-2019 Free Software Foundation, Inc.
|
# Copyright (C) 2003-2020 Free Software Foundation, Inc.
|
||||||
|
|
||||||
# This program is free software: you can redistribute it and/or modify
|
# This program is free software: you can redistribute it and/or modify
|
||||||
# it under the terms of the GNU General Public License as published by
|
# it under the terms of the GNU General Public License as published by
|
||||||
@@ -162,18 +162,11 @@ bootstrap_post_import_hook() { :; }
|
|||||||
# Override it via your own definition in bootstrap.conf.
|
# Override it via your own definition in bootstrap.conf.
|
||||||
bootstrap_epilogue() { :; }
|
bootstrap_epilogue() { :; }
|
||||||
|
|
||||||
# The command to download all .po files for a specified domain into
|
# The command to download all .po files for a specified domain into a
|
||||||
# a specified directory. Fill in the first %s is the domain name, and
|
# specified directory. Fill in the first %s with the destination
|
||||||
# the second with the destination directory. Use rsync's -L and -r
|
# directory and the second with the domain name.
|
||||||
# options because the latest/%s directory and the .po files within are
|
|
||||||
# all symlinks.
|
|
||||||
po_download_command_format=\
|
po_download_command_format=\
|
||||||
"rsync --delete --exclude '*.s1' -Lrtvz \
|
"wget --mirror --level=1 -nd -nv -A.po -P '%s' \
|
||||||
'translationproject.org::tp/latest/%s/' '%s'"
|
|
||||||
|
|
||||||
# Fallback for downloading .po files (if rsync fails).
|
|
||||||
po_download_command_format2=\
|
|
||||||
"wget --mirror -nd -q -np -A.po -P '%s' \
|
|
||||||
https://translationproject.org/latest/%s/"
|
https://translationproject.org/latest/%s/"
|
||||||
|
|
||||||
# Prefer a non-empty tarname (4th argument of AC_INIT if given), else
|
# Prefer a non-empty tarname (4th argument of AC_INIT if given), else
|
||||||
@@ -741,10 +734,7 @@ download_po_files() {
|
|||||||
subdir=$1
|
subdir=$1
|
||||||
domain=$2
|
domain=$2
|
||||||
echo "$me: getting translations into $subdir for $domain..."
|
echo "$me: getting translations into $subdir for $domain..."
|
||||||
cmd=$(printf "$po_download_command_format" "$domain" "$subdir")
|
cmd=$(printf "$po_download_command_format" "$subdir" "$domain")
|
||||||
eval "$cmd" && return
|
|
||||||
# Fallback to HTTPS.
|
|
||||||
cmd=$(printf "$po_download_command_format2" "$subdir" "$domain")
|
|
||||||
eval "$cmd"
|
eval "$cmd"
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
@echo off
|
@echo off
|
||||||
:: Copyright (C) 2018-2019 Free Software Foundation, Inc.
|
:: Copyright (C) 2018-2020 Free Software Foundation, Inc.
|
||||||
:: This file is part of GNU Make.
|
:: This file is part of GNU Make.
|
||||||
::
|
::
|
||||||
:: GNU Make is free software; you can redistribute it and/or modify it under
|
:: GNU Make is free software; you can redistribute it and/or modify it under
|
||||||
@@ -30,5 +30,5 @@ if ERRORLEVEL 1 exit /b 1
|
|||||||
goto :EOF
|
goto :EOF
|
||||||
|
|
||||||
:Done
|
:Done
|
||||||
echo Done. Run buld_w32.bat to build GNU make.
|
echo Done. Run build_w32.bat to build GNU make.
|
||||||
goto :EOF
|
goto :EOF
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
# Bootstrap configuration. -*-shell-script-*-
|
# Bootstrap configuration. -*-shell-script-*-
|
||||||
|
|
||||||
# Copyright (C) 2018-2019 Free Software Foundation, Inc.
|
# Copyright (C) 2018-2020 Free Software Foundation, Inc.
|
||||||
|
|
||||||
# GNU Make is free software: you can redistribute it and/or modify it under
|
# GNU Make is free software: you can redistribute it and/or modify it under
|
||||||
# the terms of the GNU General Public License as published by the Free
|
# the terms of the GNU General Public License as published by the Free
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
# Configuration for building GNU Make in the absence of any 'make' program.
|
# Configuration for building GNU Make in the absence of any 'make' program.
|
||||||
# @configure_input@
|
# @configure_input@
|
||||||
|
|
||||||
# Copyright (C) 1993-2019 Free Software Foundation, Inc.
|
# Copyright (C) 1993-2020 Free Software Foundation, Inc.
|
||||||
# This file is part of GNU Make.
|
# This file is part of GNU Make.
|
||||||
#
|
#
|
||||||
# GNU Make is free software; you can redistribute it and/or modify it under
|
# GNU Make is free software; you can redistribute it and/or modify it under
|
||||||
|
|||||||
2
build.sh
2
build.sh
@@ -1,7 +1,7 @@
|
|||||||
#!/bin/sh
|
#!/bin/sh
|
||||||
# Shell script to build GNU Make in the absence of any 'make' program.
|
# Shell script to build GNU Make in the absence of any 'make' program.
|
||||||
|
|
||||||
# Copyright (C) 1993-2019 Free Software Foundation, Inc.
|
# Copyright (C) 1993-2020 Free Software Foundation, Inc.
|
||||||
# This file is part of GNU Make.
|
# This file is part of GNU Make.
|
||||||
#
|
#
|
||||||
# GNU Make is free software; you can redistribute it and/or modify it under
|
# GNU Make is free software; you can redistribute it and/or modify it under
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
@echo off
|
@echo off
|
||||||
:: Copyright (C) 1996-2019 Free Software Foundation, Inc.
|
:: Copyright (C) 1996-2020 Free Software Foundation, Inc.
|
||||||
:: This file is part of GNU Make.
|
:: This file is part of GNU Make.
|
||||||
::
|
::
|
||||||
:: GNU Make is free software; you can redistribute it and/or modify it under
|
:: GNU Make is free software; you can redistribute it and/or modify it under
|
||||||
@@ -258,6 +258,7 @@ exit 1
|
|||||||
:Success
|
:Success
|
||||||
echo %OUTDIR% build succeeded.
|
echo %OUTDIR% build succeeded.
|
||||||
if exist Basic.mk copy /Y Basic.mk Makefile
|
if exist Basic.mk copy /Y Basic.mk Makefile
|
||||||
|
if not exist tests\config-flags.pm copy /Y tests\config-flags.pm.W32 tests\config-flags.pm
|
||||||
call :Reset
|
call :Reset
|
||||||
goto :EOF
|
goto :EOF
|
||||||
|
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
@echo off
|
@echo off
|
||||||
rem Copyright (C) 1998-2019 Free Software Foundation, Inc.
|
rem Copyright (C) 1998-2020 Free Software Foundation, Inc.
|
||||||
rem This file is part of GNU Make.
|
rem This file is part of GNU Make.
|
||||||
rem
|
rem
|
||||||
rem GNU Make is free software; you can redistribute it and/or modify it under
|
rem GNU Make is free software; you can redistribute it and/or modify it under
|
||||||
|
|||||||
53
configure.ac
53
configure.ac
@@ -1,6 +1,6 @@
|
|||||||
# Process this file with autoconf to produce a configure script.
|
# Process this file with autoconf to produce a configure script.
|
||||||
#
|
#
|
||||||
# Copyright (C) 1993-2019 Free Software Foundation, Inc.
|
# Copyright (C) 1993-2020 Free Software Foundation, Inc.
|
||||||
# This file is part of GNU Make.
|
# This file is part of GNU Make.
|
||||||
#
|
#
|
||||||
# GNU Make is free software; you can redistribute it and/or modify it under
|
# GNU Make is free software; you can redistribute it and/or modify it under
|
||||||
@@ -16,7 +16,7 @@
|
|||||||
# You should have received a copy of the GNU General Public License along with
|
# You should have received a copy of the GNU General Public License along with
|
||||||
# this program. If not, see <http://www.gnu.org/licenses/>.
|
# this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
|
|
||||||
AC_INIT([GNU make],[4.2.91],[bug-make@gnu.org])
|
AC_INIT([GNU make],[4.3],[bug-make@gnu.org])
|
||||||
|
|
||||||
AC_PREREQ([2.69])
|
AC_PREREQ([2.69])
|
||||||
|
|
||||||
@@ -127,8 +127,8 @@ AC_CACHE_CHECK([for standard gettimeofday], [ac_cv_func_gettimeofday],
|
|||||||
int main ()
|
int main ()
|
||||||
{
|
{
|
||||||
struct timeval t; t.tv_sec = -1; t.tv_usec = -1;
|
struct timeval t; t.tv_sec = -1; t.tv_usec = -1;
|
||||||
exit (gettimeofday (&t, 0) != 0
|
return gettimeofday (&t, 0) != 0
|
||||||
|| t.tv_sec < 0 || t.tv_usec < 0);
|
|| t.tv_sec < 0 || t.tv_usec < 0;
|
||||||
}]])],
|
}]])],
|
||||||
[ac_cv_func_gettimeofday=yes],
|
[ac_cv_func_gettimeofday=yes],
|
||||||
[ac_cv_func_gettimeofday=no],
|
[ac_cv_func_gettimeofday=no],
|
||||||
@@ -138,7 +138,7 @@ AS_IF([test "$ac_cv_func_gettimeofday" = yes],
|
|||||||
[Define to 1 if you have a standard gettimeofday function])
|
[Define to 1 if you have a standard gettimeofday function])
|
||||||
])
|
])
|
||||||
|
|
||||||
AC_CHECK_FUNCS([strdup strndup umask mkstemp mktemp fdopen \
|
AC_CHECK_FUNCS([strdup strndup memrchr umask mkstemp mktemp fdopen \
|
||||||
dup dup2 getcwd realpath sigsetmask sigaction \
|
dup dup2 getcwd realpath sigsetmask sigaction \
|
||||||
getgroups seteuid setegid setlinebuf setreuid setregid \
|
getgroups seteuid setegid setlinebuf setreuid setregid \
|
||||||
getrlimit setrlimit setvbuf pipe strsignal \
|
getrlimit setrlimit setvbuf pipe strsignal \
|
||||||
@@ -176,7 +176,7 @@ AC_ARG_WITH([guile], [AS_HELP_STRING([--with-guile],
|
|||||||
PKG_PROG_PKG_CONFIG
|
PKG_PROG_PKG_CONFIG
|
||||||
|
|
||||||
AS_IF([test "x$with_guile" != xno],
|
AS_IF([test "x$with_guile" != xno],
|
||||||
[ guile_versions="2.2 2.0 1.8"
|
[ guile_versions="3.0 2.2 2.0 1.8"
|
||||||
guile_version=no
|
guile_version=no
|
||||||
have_guile=no
|
have_guile=no
|
||||||
AC_MSG_CHECKING([for GNU Guile])
|
AC_MSG_CHECKING([for GNU Guile])
|
||||||
@@ -184,13 +184,21 @@ AS_IF([test "x$with_guile" != xno],
|
|||||||
PKG_CHECK_EXISTS([guile-$v], [guile_version=$v; have_guile=yes; break], [])
|
PKG_CHECK_EXISTS([guile-$v], [guile_version=$v; have_guile=yes; break], [])
|
||||||
done
|
done
|
||||||
AC_MSG_RESULT([$guile_version])
|
AC_MSG_RESULT([$guile_version])
|
||||||
if test "$have_guile" = yes; then
|
AS_IF([test "$have_guile" = yes],
|
||||||
PKG_CHECK_MODULES(GUILE, [guile-$guile_version])
|
[ PKG_CHECK_MODULES(GUILE, [guile-$guile_version])
|
||||||
AC_DEFINE([HAVE_GUILE], [1], [Embed GNU Guile support])
|
# Unfortunately Guile requires a C99 compiler but GNU make doesn't, so
|
||||||
fi
|
# verify we can actually compile the header.
|
||||||
|
keep_CPPFLAGS="$CPPFLAGS"
|
||||||
|
CPPFLAGS="$CPPFLAGS $pkg_cv_GUILE_CFLAGS"
|
||||||
|
AC_CHECK_HEADER([libguile.h],
|
||||||
|
[AC_DEFINE([HAVE_GUILE], [1], [Embed GNU Guile support])],
|
||||||
|
[have_guile=no],
|
||||||
|
[/* Avoid configuration error warnings. */])
|
||||||
|
CPPFLAGS="$keep_CPPFLAGS"
|
||||||
|
])
|
||||||
])
|
])
|
||||||
|
|
||||||
AM_CONDITIONAL([HAVE_GUILE], [test "$have_guile" = yes])
|
AM_CONDITIONAL([HAVE_GUILE], [test "$have_guile" = "yes"])
|
||||||
|
|
||||||
AC_CHECK_DECLS([sys_siglist, _sys_siglist, __sys_siglist], , ,
|
AC_CHECK_DECLS([sys_siglist, _sys_siglist, __sys_siglist], , ,
|
||||||
[AC_INCLUDES_DEFAULT
|
[AC_INCLUDES_DEFAULT
|
||||||
@@ -371,7 +379,28 @@ AC_ARG_ENABLE([posix-spawn],
|
|||||||
AS_CASE([/$ac_cv_header_spawn/$ac_cv_func_posix_spawn/],
|
AS_CASE([/$ac_cv_header_spawn/$ac_cv_func_posix_spawn/],
|
||||||
[*/no/*], [make_cv_posix_spawn=no])
|
[*/no/*], [make_cv_posix_spawn=no])
|
||||||
|
|
||||||
AS_CASE([/$make_cv_posix_spawn/$user_posix_spawn/],
|
AS_IF([test "$make_cv_posix_spawn" = yes],
|
||||||
|
AC_CACHE_CHECK([for posix_spawn that fails synchronously],
|
||||||
|
[make_cv_synchronous_posix_spawn],
|
||||||
|
[make_cv_synchronous_posix_spawn=no
|
||||||
|
AC_RUN_IFELSE([AC_LANG_SOURCE([[
|
||||||
|
#include <spawn.h>
|
||||||
|
#include <string.h>
|
||||||
|
|
||||||
|
extern char **environ;
|
||||||
|
|
||||||
|
int main() {
|
||||||
|
char* path = strdup("./non-existent");
|
||||||
|
char *argv[[2]];
|
||||||
|
argv[[0]] = path;
|
||||||
|
argv[[1]] = 0;
|
||||||
|
return posix_spawn(0, path, 0, 0, argv, environ);
|
||||||
|
}]])],
|
||||||
|
[make_cv_synchronous_posix_spawn=no],
|
||||||
|
[make_cv_synchronous_posix_spawn=yes],
|
||||||
|
[make_cv_synchronous_posix_spawn="no (cross-compiling)"])]))
|
||||||
|
|
||||||
|
AS_CASE([/$user_posix_spawn/$make_cv_posix_spawn/$make_cv_synchronous_posix_spawn/],
|
||||||
[*/no/*], [make_cv_posix_spawn=no],
|
[*/no/*], [make_cv_posix_spawn=no],
|
||||||
[AC_DEFINE(USE_POSIX_SPAWN, 1, [Define to 1 to use posix_spawn().])
|
[AC_DEFINE(USE_POSIX_SPAWN, 1, [Define to 1 to use posix_spawn().])
|
||||||
])
|
])
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
# -*-Makefile-*-, or close enough
|
# -*-Makefile-*-, or close enough
|
||||||
# Copyright (C) 2000-2019 Free Software Foundation, Inc.
|
# Copyright (C) 2000-2020 Free Software Foundation, Inc.
|
||||||
# This file is part of GNU Make.
|
# This file is part of GNU Make.
|
||||||
#
|
#
|
||||||
# GNU Make is free software; you can redistribute it and/or modify it under
|
# GNU Make is free software; you can redistribute it and/or modify it under
|
||||||
|
|||||||
@@ -361,7 +361,7 @@ This manual page contributed by Dennis Morse of Stanford University.
|
|||||||
Further updates contributed by Mike Frysinger. It has been reworked by Roland
|
Further updates contributed by Mike Frysinger. It has been reworked by Roland
|
||||||
McGrath. Maintained by Paul Smith.
|
McGrath. Maintained by Paul Smith.
|
||||||
.SH "COPYRIGHT"
|
.SH "COPYRIGHT"
|
||||||
Copyright \(co 1992-1993, 1996-2019 Free Software Foundation, Inc.
|
Copyright \(co 1992-1993, 1996-2020 Free Software Foundation, Inc.
|
||||||
This file is part of
|
This file is part of
|
||||||
.IR "GNU make" .
|
.IR "GNU make" .
|
||||||
.LP
|
.LP
|
||||||
|
|||||||
156
doc/make.texi
156
doc/make.texi
@@ -3,7 +3,7 @@
|
|||||||
@setfilename make.info
|
@setfilename make.info
|
||||||
|
|
||||||
@include version.texi
|
@include version.texi
|
||||||
@set EDITION 0.74
|
@set EDITION 0.75
|
||||||
|
|
||||||
@settitle GNU @code{make}
|
@settitle GNU @code{make}
|
||||||
@setchapternewpage odd
|
@setchapternewpage odd
|
||||||
@@ -26,8 +26,8 @@ of @cite{The GNU Make Manual}, for GNU @code{make} version @value{VERSION}.
|
|||||||
|
|
||||||
Copyright @copyright{} 1988, 1989, 1990, 1991, 1992, 1993, 1994, 1995,
|
Copyright @copyright{} 1988, 1989, 1990, 1991, 1992, 1993, 1994, 1995,
|
||||||
1996, 1997, 1998, 1999, 2000, 2002, 2003, 2004, 2005, 2006, 2007,
|
1996, 1997, 1998, 1999, 2000, 2002, 2003, 2004, 2005, 2006, 2007,
|
||||||
2008, 2009, 2010, 2011, 2012, 2013, 2014, 2015, 2016, 2017, 2018, 2019
|
2008, 2009, 2010, 2011, 2012, 2013, 2014, 2015, 2016, 2017, 2018, 2019,
|
||||||
Free Software Foundation, Inc.
|
2020 Free Software Foundation, Inc.
|
||||||
|
|
||||||
@quotation
|
@quotation
|
||||||
Permission is granted to copy, distribute and/or modify this document
|
Permission is granted to copy, distribute and/or modify this document
|
||||||
@@ -1469,25 +1469,27 @@ build it---otherwise it would apply the same match-anything rule to
|
|||||||
@cindex reading makefiles
|
@cindex reading makefiles
|
||||||
@cindex makefile, reading
|
@cindex makefile, reading
|
||||||
|
|
||||||
GNU @code{make} does its work in two distinct phases. During the first
|
GNU @code{make} does its work in two distinct phases. During the
|
||||||
phase it reads all the makefiles, included makefiles, etc. and
|
first phase it reads all the makefiles, included makefiles, etc. and
|
||||||
internalizes all the variables and their values, implicit and explicit
|
internalizes all the variables and their values and implicit and
|
||||||
rules, and constructs a dependency graph of all the targets and their
|
explicit rules, and builds a dependency graph of all the targets and
|
||||||
prerequisites. During the second phase, @code{make} uses these internal
|
their prerequisites. During the second phase, @code{make} uses this
|
||||||
structures to determine what targets will need to be rebuilt and to
|
internalized data to determine which targets need to be updated and
|
||||||
invoke the rules necessary to do so.
|
run the recipes necessary to update them.
|
||||||
|
|
||||||
It's important to understand this two-phase approach because it has a
|
It's important to understand this two-phase approach because it has a
|
||||||
direct impact on how variable and function expansion happens; this is
|
direct impact on how variable and function expansion happens; this is
|
||||||
often a source of some confusion when writing makefiles. Here we will
|
often a source of some confusion when writing makefiles. Below is a
|
||||||
present a summary of the phases in which expansion happens for different
|
summary of the different constructs that can be found in a makefile,
|
||||||
constructs within the makefile. We say that expansion is
|
and the phase in which expansion happens for each part of the
|
||||||
@dfn{immediate} if it happens during the first phase: in this case
|
construct.
|
||||||
@code{make} will expand any variables or functions in that section of a
|
|
||||||
construct as the makefile is parsed. We say that expansion is
|
We say that expansion is @dfn{immediate} if it happens during the
|
||||||
@dfn{deferred} if expansion is not performed immediately. Expansion of
|
first phase: @code{make} will expand that part of the construct as the
|
||||||
a deferred construct is not performed until either the construct appears
|
makefile is parsed. We say that expansion is @dfn{deferred} if it is
|
||||||
later in an immediate context, or until the second phase.
|
not immediate. Expansion of a deferred construct part is delayed
|
||||||
|
until the expansion is used: either when it is referenced in an
|
||||||
|
immediate context, or when it is needed during the second phase.
|
||||||
|
|
||||||
You may not be familiar with some of these constructs yet. You can
|
You may not be familiar with some of these constructs yet. You can
|
||||||
reference this section as you become familiar with them, in later
|
reference this section as you become familiar with them, in later
|
||||||
@@ -1540,14 +1542,14 @@ define @var{immediate} !=
|
|||||||
endef
|
endef
|
||||||
@end example
|
@end example
|
||||||
|
|
||||||
For the append operator, @samp{+=}, the right-hand side is considered
|
For the append operator @samp{+=}, the right-hand side is considered
|
||||||
immediate if the variable was previously set as a simple variable
|
immediate if the variable was previously set as a simple variable
|
||||||
(@samp{:=} or @samp{::=}), and deferred otherwise.
|
(@samp{:=} or @samp{::=}), and deferred otherwise.
|
||||||
|
|
||||||
For the shell assignment operator, @samp{!=}, the right-hand side is
|
For the shell assignment operator @samp{!=}, the right-hand side is
|
||||||
evaluated immediately and handed to the shell. The result is stored in the
|
evaluated immediately and handed to the shell. The result is stored
|
||||||
variable named on the left, and that variable becomes a simple variable
|
in the variable named on the left, and that variable becomes a simple
|
||||||
(and will thus be re-evaluated on each reference).
|
variable (and will thus be re-evaluated on each reference).
|
||||||
|
|
||||||
@subheading Conditional Directives
|
@subheading Conditional Directives
|
||||||
@cindex ifdef, expansion
|
@cindex ifdef, expansion
|
||||||
@@ -1576,10 +1578,10 @@ A rule is always expanded the same way, regardless of the form:
|
|||||||
@var{deferred}
|
@var{deferred}
|
||||||
@end example
|
@end example
|
||||||
|
|
||||||
That is, the target and prerequisite sections are expanded immediately,
|
That is, the target and prerequisite sections are expanded
|
||||||
and the recipe used to construct the target is always deferred. This
|
immediately, and the recipe used to build the target is always
|
||||||
general rule is true for explicit rules, pattern rules, suffix rules,
|
deferred. This is true for explicit rules, pattern rules, suffix
|
||||||
static pattern rules, and simple prerequisite definitions.
|
rules, static pattern rules, and simple prerequisite definitions.
|
||||||
|
|
||||||
@node Parsing Makefiles, Secondary Expansion, Reading Makefiles, Makefiles
|
@node Parsing Makefiles, Secondary Expansion, Reading Makefiles, Makefiles
|
||||||
@section How Makefiles Are Parsed
|
@section How Makefiles Are Parsed
|
||||||
@@ -1930,8 +1932,8 @@ more recent than it.
|
|||||||
@item
|
@item
|
||||||
How to update the file @file{foo.o}: by running @code{cc} as stated.
|
How to update the file @file{foo.o}: by running @code{cc} as stated.
|
||||||
The recipe does not explicitly mention @file{defs.h}, but we presume
|
The recipe does not explicitly mention @file{defs.h}, but we presume
|
||||||
that @file{foo.c} includes it, and that that is why @file{defs.h} was
|
that @file{foo.c} includes it, and that is why @file{defs.h} was added
|
||||||
added to the prerequisites.
|
to the prerequisites.
|
||||||
@end itemize
|
@end itemize
|
||||||
@end ifnottex
|
@end ifnottex
|
||||||
|
|
||||||
@@ -4531,6 +4533,19 @@ target is updated in some atomic fashion, or exists only to record a
|
|||||||
modification-time (its contents do not matter), or must exist at all
|
modification-time (its contents do not matter), or must exist at all
|
||||||
times to prevent other sorts of trouble.
|
times to prevent other sorts of trouble.
|
||||||
|
|
||||||
|
Although @code{make} does its best to clean up there are certain situations
|
||||||
|
in which cleanup is impossible. For example, @code{make} may be killed by
|
||||||
|
an uncatchable signal. Or, one of the programs make invokes may be killed
|
||||||
|
or crash, leaving behind an up-to-date but corrupt target file: @code{make}
|
||||||
|
will not realize that this failure requires the target to be cleaned. Or
|
||||||
|
@code{make} itself may encounter a bug and crash.
|
||||||
|
|
||||||
|
For these reasons it's best to write @emph{defensive recipes}, which won't
|
||||||
|
leave behind corrupted targets even if they fail. Most commonly these
|
||||||
|
recipes create temporary files rather than updating the target directly,
|
||||||
|
then rename the temporary file to the final target name. Some compilers
|
||||||
|
already behave this way, so that you don't need to write a defensive recipe.
|
||||||
|
|
||||||
@node Recursion, Canned Recipes, Interrupts, Recipes
|
@node Recursion, Canned Recipes, Interrupts, Recipes
|
||||||
@section Recursive Use of @code{make}
|
@section Recursive Use of @code{make}
|
||||||
@cindex recursion
|
@cindex recursion
|
||||||
@@ -6629,6 +6644,57 @@ Supports dynamically loadable objects for creating custom extensions.
|
|||||||
Expands to a list of directories that @code{make} searches for
|
Expands to a list of directories that @code{make} searches for
|
||||||
included makefiles (@pxref{Include, , Including Other Makefiles}).
|
included makefiles (@pxref{Include, , Including Other Makefiles}).
|
||||||
|
|
||||||
|
@vindex .EXTRA_PREREQS @r{(prerequisites not added to automatic variables)}
|
||||||
|
@item .EXTRA_PREREQS
|
||||||
|
Each word in this variable is a new prerequisite which is added to
|
||||||
|
targets for which it is set. These prerequisites differ from normal
|
||||||
|
prerequisites in that they do not appear in any of the automatic
|
||||||
|
variables (@pxref{Automatic Variables}). This allows prerequisites to
|
||||||
|
be defined which do not impact the recipe.
|
||||||
|
|
||||||
|
Consider a rule to link a program:
|
||||||
|
|
||||||
|
@example
|
||||||
|
myprog: myprog.o file1.o file2.o
|
||||||
|
$(CC) $(CFLAGS) $(LDFLAGS) -o $@@ $^ $(LDLIBS)
|
||||||
|
@end example
|
||||||
|
|
||||||
|
Now suppose you want to enhance this makefile to ensure that updates
|
||||||
|
to the compiler cause the program to be re-linked. You can add the
|
||||||
|
compiler as a prerequisite, but you must ensure that it's not passed
|
||||||
|
as an argument to link command. You'll need something like this:
|
||||||
|
|
||||||
|
@example
|
||||||
|
myprog: myprog.o file1.o file2.o $(CC)
|
||||||
|
$(CC) $(CFLAGS) $(LDFLAGS) -o $@@ $(filter-out $(CC),$^) $(LDLIBS)
|
||||||
|
@end example
|
||||||
|
|
||||||
|
Then consider having multiple extra prerequisites: they would all have
|
||||||
|
to be filtered out. Using @code{.EXTRA_PREREQS} and target-specific
|
||||||
|
variables provides a simpler solution:
|
||||||
|
|
||||||
|
@example
|
||||||
|
myprog: myprog.o file1.o file2.o
|
||||||
|
$(CC) $(CFLAGS) $(LDFLAGS) -o $@@ $^ $(LDLIBS)
|
||||||
|
myprog: .EXTRA_PREREQS = $(CC)
|
||||||
|
@end example
|
||||||
|
|
||||||
|
This feature can also be useful if you want to add prerequisites to a
|
||||||
|
makefile you cannot easily modify: you can create a new file such as
|
||||||
|
@file{extra.mk}:
|
||||||
|
|
||||||
|
@example
|
||||||
|
myprog: .EXTRA_PREREQS = $(CC)
|
||||||
|
@end example
|
||||||
|
|
||||||
|
then invoke @code{make -f extra.mk -f Makefile}.
|
||||||
|
|
||||||
|
Setting @code{.EXTRA_PREREQS} globally will cause those prerequisites
|
||||||
|
to be added to all targets (which did not themselves override it with
|
||||||
|
a target-specific value). Note @code{make} is smart enough not to add
|
||||||
|
a prerequisite listed in @code{.EXTRA_PREREQS} as a prerequisite to
|
||||||
|
itself.
|
||||||
|
|
||||||
@end table
|
@end table
|
||||||
|
|
||||||
@node Conditionals, Functions, Using Variables, Top
|
@node Conditionals, Functions, Using Variables, Top
|
||||||
@@ -9865,6 +9931,10 @@ and linking with a single @code{cc} command. The optimized rule is used in
|
|||||||
preference to the step-by-step chain because it comes earlier in the
|
preference to the step-by-step chain because it comes earlier in the
|
||||||
ordering of rules.
|
ordering of rules.
|
||||||
|
|
||||||
|
Finally, for performance reasons @code{make} will not consider non-terminal
|
||||||
|
match-anything rules (i.e., @samp{%:}) when searching for a rule to
|
||||||
|
build a prerequisite of an implicit rule (@pxref{Match-Anything Rules}).
|
||||||
|
|
||||||
@node Pattern Rules, Last Resort, Chained Rules, Implicit Rules
|
@node Pattern Rules, Last Resort, Chained Rules, Implicit Rules
|
||||||
@section Defining and Redefining Pattern Rules
|
@section Defining and Redefining Pattern Rules
|
||||||
|
|
||||||
@@ -10354,9 +10424,10 @@ remade from any other files; therefore, @code{make} can save time by not
|
|||||||
looking for ways to remake them.@refill
|
looking for ways to remake them.@refill
|
||||||
|
|
||||||
If you do not mark the match-anything rule as terminal, then it is
|
If you do not mark the match-anything rule as terminal, then it is
|
||||||
non-terminal. A non-terminal match-anything rule cannot apply to a file name
|
non-terminal. A non-terminal match-anything rule cannot apply to a
|
||||||
that indicates a specific type of data. A file name indicates a specific
|
prerequisite of an implicit rule, or to a file name that indicates a
|
||||||
type of data if some non-match-anything implicit rule target matches it.
|
specific type of data. A file name indicates a specific type of data
|
||||||
|
if some non-match-anything implicit rule target matches it.
|
||||||
|
|
||||||
For example, the file name @file{foo.c} matches the target for the pattern
|
For example, the file name @file{foo.c} matches the target for the pattern
|
||||||
rule @samp{%.c : %.y} (the rule to run Yacc). Regardless of whether this
|
rule @samp{%.c : %.y} (the rule to run Yacc). Regardless of whether this
|
||||||
@@ -10593,8 +10664,9 @@ Make a list of all the pattern rules one of whose targets matches
|
|||||||
matched against @var{t}; otherwise, against @var{n}.
|
matched against @var{t}; otherwise, against @var{n}.
|
||||||
|
|
||||||
@item
|
@item
|
||||||
If any rule in that list is @emph{not} a match-anything rule, then
|
If any rule in that list is @emph{not} a match-anything rule, or if
|
||||||
remove all non-terminal match-anything rules from the list.
|
@var{t} is a prerequisite of an implicit rule, then remove all
|
||||||
|
non-terminal match-anything rules from the list.
|
||||||
|
|
||||||
@item
|
@item
|
||||||
Remove from the list all rules with no recipe.
|
Remove from the list all rules with no recipe.
|
||||||
@@ -12678,6 +12750,18 @@ receive only part of the information necessary. In this case, the child
|
|||||||
will generate this warning message and proceed with its build in a
|
will generate this warning message and proceed with its build in a
|
||||||
sequential manner.
|
sequential manner.
|
||||||
|
|
||||||
|
@item warning: ignoring prerequisites on suffix rule definition
|
||||||
|
According to POSIX, a suffix rule cannot contain prerequisites. If a rule
|
||||||
|
that could be a suffix rule has prerequisites it is interpreted as a simple
|
||||||
|
explicit rule, with an odd target name. This requirement is obeyed when
|
||||||
|
POSIX-conforming mode is enabled (the @code{.POSIX} target is defined). In
|
||||||
|
versions of GNU @code{make} prior to 4.3, no warning was emitted and a
|
||||||
|
suffix rule was created, however all prerequisites were ignored and were not
|
||||||
|
part of the suffix rule. Starting with GNU @code{make} 4.3 the behavior is
|
||||||
|
the same, and in addition this warning is generated. In a future version
|
||||||
|
the POSIX-conforming behavior will be the only behavior: no rule with a
|
||||||
|
prerequisite can be suffix rule and this warning will be removed.
|
||||||
|
|
||||||
@end table
|
@end table
|
||||||
|
|
||||||
@node Complex Makefile, GNU Free Documentation License, Error Messages, Top
|
@node Complex Makefile, GNU Free Documentation License, Error Messages, Top
|
||||||
@@ -12960,7 +13044,7 @@ tar.zoo: $(SRCS) $(AUX)
|
|||||||
@end example
|
@end example
|
||||||
|
|
||||||
@node GNU Free Documentation License, Concept Index, Complex Makefile, Top
|
@node GNU Free Documentation License, Concept Index, Complex Makefile, Top
|
||||||
@appendixsec GNU Free Documentation License
|
@appendix GNU Free Documentation License
|
||||||
@cindex FDL, GNU Free Documentation License
|
@cindex FDL, GNU Free Documentation License
|
||||||
@include fdl.texi
|
@include fdl.texi
|
||||||
|
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
dnl acinclude.m4 -- Extra macros needed for GNU make.
|
dnl acinclude.m4 -- Extra macros needed for GNU make.
|
||||||
dnl
|
dnl
|
||||||
dnl Automake will incorporate this into its generated aclocal.m4.
|
dnl Automake will incorporate this into its generated aclocal.m4.
|
||||||
dnl Copyright (C) 1998-2019 Free Software Foundation, Inc.
|
dnl Copyright (C) 1998-2020 Free Software Foundation, Inc.
|
||||||
dnl This file is part of GNU Make.
|
dnl This file is part of GNU Make.
|
||||||
dnl
|
dnl
|
||||||
dnl GNU Make is free software; you can redistribute it and/or modify it under
|
dnl GNU Make is free software; you can redistribute it and/or modify it under
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
# Test if the system uses DOS-style pathnames (drive specs and backslashes)
|
# Test if the system uses DOS-style pathnames (drive specs and backslashes)
|
||||||
# By Paul Smith <psmith@gnu.org>. Based on dos.m4 by Jim Meyering.
|
# By Paul Smith <psmith@gnu.org>. Based on dos.m4 by Jim Meyering.
|
||||||
#
|
#
|
||||||
# Copyright (C) 1993-2019 Free Software Foundation, Inc.
|
# Copyright (C) 1993-2020 Free Software Foundation, Inc.
|
||||||
# This file is part of GNU Make.
|
# This file is part of GNU Make.
|
||||||
#
|
#
|
||||||
# GNU Make is free software; you can redistribute it and/or modify it under
|
# GNU Make is free software; you can redistribute it and/or modify it under
|
||||||
|
|||||||
@@ -26,6 +26,9 @@ GNUWEBDIR ?= $(SRCROOTDIR)/gnu-www
|
|||||||
# Where to put the CVS checkout of the GNU make web repository
|
# Where to put the CVS checkout of the GNU make web repository
|
||||||
MAKEWEBDIR ?= $(SRCROOTDIR)/make/make-web
|
MAKEWEBDIR ?= $(SRCROOTDIR)/make/make-web
|
||||||
|
|
||||||
|
# Enable Perl warnings for the test suite
|
||||||
|
PERLFLAGS := -w
|
||||||
|
|
||||||
# We like mondo-warnings!
|
# We like mondo-warnings!
|
||||||
# Also force comments to be preserved. This helps when using ccache, in
|
# Also force comments to be preserved. This helps when using ccache, in
|
||||||
# combination with GCC 7's implicit-fallthrough warning.
|
# combination with GCC 7's implicit-fallthrough warning.
|
||||||
@@ -228,15 +231,36 @@ get-doc/make-stds.texi get-doc/fdl.texi:
|
|||||||
# Alternative configuration checks. #
|
# Alternative configuration checks. #
|
||||||
# ---------------------------------- #
|
# ---------------------------------- #
|
||||||
|
|
||||||
|
CFGCHECK_CONFIGFLAGS =
|
||||||
|
CFGCHECK_BUILDFLAGS =
|
||||||
|
CFGCHECK_MAKEFLAGS = CFLAGS='$(AM_CFLAGS)'
|
||||||
|
|
||||||
|
checkcfg.strict-c90: CFGCHECK_CONFIGFLAGS = CFLAGS='-std=c90 -pedantic'
|
||||||
|
checkcfg.strict-c90: CFGCHECK_MAKEFLAGS =
|
||||||
|
|
||||||
|
checkcfg.no-jobserver:CFGCHECK_CONFIGFLAGS = --disable-job-server
|
||||||
|
checkcfg.no-load: CFGCHECK_CONFIGFLAGS = --disable-load
|
||||||
|
checkcfg.no-guile: CFGCHECK_CONFIGFLAGS = --without-guile
|
||||||
|
checkcfg.no-spawn: CFGCHECK_CONFIGFLAGS = --disable-posix-spawn
|
||||||
|
checkcfg.no-sysglob: CFGCHECK_CONFIGFLAGS = make_cv_sys_gnu_glob=no
|
||||||
|
checkcfg.no-loadavg: CFGCHECK_CONFIGFLAGS = ac_cv_func_getloadavg=no \
|
||||||
|
ac_cv_have_decl_getloadavg=no \
|
||||||
|
gl_cv_have_raw_decl_getloadavg=no \
|
||||||
|
ac_cv_lib_util_getloadavg=no \
|
||||||
|
ac_cv_lib_getloadavg_getloadavg=no
|
||||||
|
checkcfg.no-sync: CFGCHECK_CONFIGFLAGS = CPPFLAGS=-DNO_OUTPUT_SYNC
|
||||||
|
checkcfg.no-archives: CFGCHECK_CONFIGFLAGS = CPPFLAGS=-DNO_ARCHIVES
|
||||||
|
|
||||||
CONFIG_CHECKS := \
|
CONFIG_CHECKS := \
|
||||||
checkcfg.--disable-job-server \
|
checkcfg.strict-c90 \
|
||||||
checkcfg.--disable-load \
|
checkcfg.no-jobserver \
|
||||||
checkcfg.--without-guile \
|
checkcfg.no-load \
|
||||||
checkcfg.--disable-posix-spawn \
|
checkcfg.no-guile \
|
||||||
checkcfg.make_cv_sys_gnu_glob^no \
|
checkcfg.no-spawn \
|
||||||
checkcfg.ac_cv_func_getloadavg^no+ac_cv_have_decl_getloadavg^no+gl_cv_have_raw_decl_getloadavg^no+ac_cv_lib_util_getloadavg^no+ac_cv_lib_getloadavg_getloadavg^no \
|
checkcfg.no-sysglob \
|
||||||
checkcfg.CPPFLAGS^-DNO_OUTPUT_SYNC \
|
checkcfg.no-loadavg \
|
||||||
checkcfg.CPPFLAGS^-DNO_ARCHIVES
|
checkcfg.no-sync \
|
||||||
|
checkcfg.no-archives
|
||||||
|
|
||||||
.PHONY: check-alt-config
|
.PHONY: check-alt-config
|
||||||
check-alt-config: $(CONFIG_CHECKS)
|
check-alt-config: $(CONFIG_CHECKS)
|
||||||
@@ -248,20 +272,20 @@ NR_MAKE = $(MAKE)
|
|||||||
$(CONFIG_CHECKS): checkcfg.%: distdir
|
$(CONFIG_CHECKS): checkcfg.%: distdir
|
||||||
@echo "Building $@ (output in checkcfg.$*.log)"
|
@echo "Building $@ (output in checkcfg.$*.log)"
|
||||||
exec >'checkcfg.$*.log' 2>&1; \
|
exec >'checkcfg.$*.log' 2>&1; \
|
||||||
echo "Testing configure with $(subst ^,=,$(subst +, ,$*))"; set -x; \
|
echo "Testing configure with $(CFGCHECK_CONFIGFLAGS)"; set -x; \
|
||||||
rm -rf $(distdir)/_build \
|
rm -rf $(distdir)/_build \
|
||||||
&& mkdir $(distdir)/_build \
|
&& mkdir $(distdir)/_build \
|
||||||
&& cd $(distdir)/_build \
|
&& cd $(distdir)/_build \
|
||||||
&& ../configure --srcdir=.. $(subst ^,=,$(subst +, ,$*)) \
|
&& ../configure --srcdir=.. $(CFGCHECK_CONFIGFLAGS) \
|
||||||
$(AM_DISTCHECK_CONFIGURE_FLAGS) $(DISTCHECK_CONFIGURE_FLAGS)
|
$(AM_DISTCHECK_CONFIGURE_FLAGS) $(DISTCHECK_CONFIGURE_FLAGS)
|
||||||
exec >>'checkcfg.$*.log' 2>&1; set -x; \
|
exec >>'checkcfg.$*.log' 2>&1; set -x; \
|
||||||
cd $(distdir)/_build \
|
cd $(distdir)/_build \
|
||||||
&& OUTDIR=_bld ../build.sh \
|
&& OUTDIR=_bld ../build.sh $(CFGCHECK_BUILD_FLAGS) \
|
||||||
&& _bld/make $(AM_MAKEFLAGS) check-local \
|
&& _bld/make $(AM_MAKEFLAGS) check-local \
|
||||||
&& _bld/make $(AM_MAKEFLAGS) clean
|
&& _bld/make $(AM_MAKEFLAGS) clean
|
||||||
exec >>'checkcfg.$*.log' 2>&1; set -x; \
|
exec >>'checkcfg.$*.log' 2>&1; set -x; \
|
||||||
cd $(distdir)/_build \
|
cd $(distdir)/_build \
|
||||||
&& $(NR_MAKE) $(AM_MAKEFLAGS) CFLAGS='$(AM_CFLAGS)' \
|
&& $(NR_MAKE) $(AM_MAKEFLAGS) $(CFGCHECK_MAKEFLAGS) \
|
||||||
&& ./make $(AM_MAKEFLAGS) check \
|
&& ./make $(AM_MAKEFLAGS) check \
|
||||||
&& ./make $(AM_MAKEFLAGS) clean
|
&& ./make $(AM_MAKEFLAGS) clean
|
||||||
|
|
||||||
@@ -480,7 +504,7 @@ $(UPLOADS): $(DIST_ARCHIVES) $(DIST_ARCHIVES_SIG) $(DIST_ARCHIVES_DIRECTIVE)
|
|||||||
# Rebuild Makefile.in if this file is modifed.
|
# Rebuild Makefile.in if this file is modifed.
|
||||||
Makefile.in: maintMakefile
|
Makefile.in: maintMakefile
|
||||||
|
|
||||||
# Copyright (C) 1997-2019 Free Software Foundation, Inc.
|
# Copyright (C) 1997-2020 Free Software Foundation, Inc.
|
||||||
# This file is part of GNU Make.
|
# This file is part of GNU Make.
|
||||||
#
|
#
|
||||||
# GNU Make is free software; you can redistribute it and/or modify it under
|
# GNU Make is free software; you can redistribute it and/or modify it under
|
||||||
|
|||||||
@@ -154,7 +154,7 @@ $ exit
|
|||||||
$ endsubroutine : compileit
|
$ endsubroutine : compileit
|
||||||
$!
|
$!
|
||||||
$!-----------------------------------------------------------------------------
|
$!-----------------------------------------------------------------------------
|
||||||
$!Copyright (C) 1996-2019 Free Software Foundation, Inc.
|
$!Copyright (C) 1996-2020 Free Software Foundation, Inc.
|
||||||
$!This file is part of GNU Make.
|
$!This file is part of GNU Make.
|
||||||
$!
|
$!
|
||||||
$!GNU Make is free software; you can redistribute it and/or modify it under
|
$!GNU Make is free software; you can redistribute it and/or modify it under
|
||||||
|
|||||||
@@ -2,7 +2,7 @@
|
|||||||
#
|
#
|
||||||
# Amiga overrides for use with Basic.mk.
|
# Amiga overrides for use with Basic.mk.
|
||||||
#
|
#
|
||||||
# Copyright (C) 2017-2019 Free Software Foundation, Inc.
|
# Copyright (C) 2017-2020 Free Software Foundation, Inc.
|
||||||
# This file is part of GNU Make.
|
# This file is part of GNU Make.
|
||||||
#
|
#
|
||||||
# GNU Make is free software; you can redistribute it and/or modify it under
|
# GNU Make is free software; you can redistribute it and/or modify it under
|
||||||
|
|||||||
@@ -2,7 +2,7 @@
|
|||||||
#
|
#
|
||||||
# POSIX overrides for use with Basic.mk.
|
# POSIX overrides for use with Basic.mk.
|
||||||
#
|
#
|
||||||
# Copyright (C) 2017-2019 Free Software Foundation, Inc.
|
# Copyright (C) 2017-2020 Free Software Foundation, Inc.
|
||||||
# This file is part of GNU Make.
|
# This file is part of GNU Make.
|
||||||
#
|
#
|
||||||
# GNU Make is free software; you can redistribute it and/or modify it under
|
# GNU Make is free software; you can redistribute it and/or modify it under
|
||||||
|
|||||||
@@ -2,7 +2,7 @@
|
|||||||
#
|
#
|
||||||
# VMS overrides for use with Basic.mk.
|
# VMS overrides for use with Basic.mk.
|
||||||
#
|
#
|
||||||
# Copyright (C) 2017-2019 Free Software Foundation, Inc.
|
# Copyright (C) 2017-2020 Free Software Foundation, Inc.
|
||||||
# This file is part of GNU Make.
|
# This file is part of GNU Make.
|
||||||
#
|
#
|
||||||
# GNU Make is free software; you can redistribute it and/or modify it under
|
# GNU Make is free software; you can redistribute it and/or modify it under
|
||||||
|
|||||||
@@ -2,7 +2,7 @@
|
|||||||
#
|
#
|
||||||
# Windows overrides for use with Basic.mk.
|
# Windows overrides for use with Basic.mk.
|
||||||
#
|
#
|
||||||
# Copyright (C) 2017-2019 Free Software Foundation, Inc.
|
# Copyright (C) 2017-2020 Free Software Foundation, Inc.
|
||||||
# This file is part of GNU Make.
|
# This file is part of GNU Make.
|
||||||
#
|
#
|
||||||
# GNU Make is free software; you can redistribute it and/or modify it under
|
# GNU Make is free software; you can redistribute it and/or modify it under
|
||||||
|
|||||||
@@ -2,7 +2,7 @@
|
|||||||
#
|
#
|
||||||
# MS-DOS overrides for use with Basic.mk.
|
# MS-DOS overrides for use with Basic.mk.
|
||||||
#
|
#
|
||||||
# Copyright (C) 2017-2019 Free Software Foundation, Inc.
|
# Copyright (C) 2017-2020 Free Software Foundation, Inc.
|
||||||
# This file is part of GNU Make.
|
# This file is part of GNU Make.
|
||||||
#
|
#
|
||||||
# GNU Make is free software; you can redistribute it and/or modify it under
|
# GNU Make is free software; you can redistribute it and/or modify it under
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
# List of source files containing translatable strings.
|
# List of source files containing translatable strings.
|
||||||
# Copyright (C) 2000-2019 Free Software Foundation, Inc.
|
# Copyright (C) 2000-2020 Free Software Foundation, Inc.
|
||||||
# This file is part of GNU Make.
|
# This file is part of GNU Make.
|
||||||
#
|
#
|
||||||
# GNU Make is free software; you can redistribute it and/or modify it under
|
# GNU Make is free software; you can redistribute it and/or modify it under
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
#!/bin/sh
|
#!/bin/sh
|
||||||
#
|
#
|
||||||
# Copyright (C) 2014-2019 Free Software Foundation, Inc.
|
# Copyright (C) 2014-2020 Free Software Foundation, Inc.
|
||||||
# This file is part of GNU Make.
|
# This file is part of GNU Make.
|
||||||
#
|
#
|
||||||
# Update GNU make copyrights using gnulib update-copyright
|
# Update GNU make copyrights using gnulib update-copyright
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
/* Running commands on Amiga
|
/* Running commands on Amiga
|
||||||
Copyright (C) 1995-2019 Free Software Foundation, Inc.
|
Copyright (C) 1995-2020 Free Software Foundation, Inc.
|
||||||
This file is part of GNU Make.
|
This file is part of GNU Make.
|
||||||
|
|
||||||
GNU Make is free software; you can redistribute it and/or modify it under the
|
GNU Make is free software; you can redistribute it and/or modify it under the
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
/* Definitions for amiga specific things
|
/* Definitions for amiga specific things
|
||||||
Copyright (C) 1995-2019 Free Software Foundation, Inc.
|
Copyright (C) 1995-2020 Free Software Foundation, Inc.
|
||||||
This file is part of GNU Make.
|
This file is part of GNU Make.
|
||||||
|
|
||||||
GNU Make is free software; you can redistribute it and/or modify it under the
|
GNU Make is free software; you can redistribute it and/or modify it under the
|
||||||
|
|||||||
2
src/ar.c
2
src/ar.c
@@ -1,5 +1,5 @@
|
|||||||
/* Interface to 'ar' archives for GNU Make.
|
/* Interface to 'ar' archives for GNU Make.
|
||||||
Copyright (C) 1988-2019 Free Software Foundation, Inc.
|
Copyright (C) 1988-2020 Free Software Foundation, Inc.
|
||||||
|
|
||||||
This file is part of GNU Make.
|
This file is part of GNU Make.
|
||||||
|
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
/* Library function for scanning an archive file.
|
/* Library function for scanning an archive file.
|
||||||
Copyright (C) 1987-2019 Free Software Foundation, Inc.
|
Copyright (C) 1987-2020 Free Software Foundation, Inc.
|
||||||
This file is part of GNU Make.
|
This file is part of GNU Make.
|
||||||
|
|
||||||
GNU Make is free software; you can redistribute it and/or modify it under the
|
GNU Make is free software; you can redistribute it and/or modify it under the
|
||||||
@@ -703,7 +703,7 @@ ar_scan (const char *archive, ar_member_func_t function, const void *arg)
|
|||||||
}
|
}
|
||||||
|
|
||||||
#ifndef M_XENIX
|
#ifndef M_XENIX
|
||||||
sscanf (TOCHAR (member_header.ar_mode), "%o", &eltmode);
|
sscanf (TOCHAR (member_header.ar_mode), "%8o", &eltmode);
|
||||||
eltsize = atol (TOCHAR (member_header.ar_size));
|
eltsize = atol (TOCHAR (member_header.ar_size));
|
||||||
#else /* Xenix. */
|
#else /* Xenix. */
|
||||||
eltmode = (unsigned short int) member_header.ar_mode;
|
eltmode = (unsigned short int) member_header.ar_mode;
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
/* Command processing for GNU Make.
|
/* Command processing for GNU Make.
|
||||||
Copyright (C) 1988-2019 Free Software Foundation, Inc.
|
Copyright (C) 1988-2020 Free Software Foundation, Inc.
|
||||||
This file is part of GNU Make.
|
This file is part of GNU Make.
|
||||||
|
|
||||||
GNU Make is free software; you can redistribute it and/or modify it under the
|
GNU Make is free software; you can redistribute it and/or modify it under the
|
||||||
@@ -133,7 +133,7 @@ set_file_variables (struct file *file)
|
|||||||
/* $< is the first not order-only dependency. */
|
/* $< is the first not order-only dependency. */
|
||||||
less = "";
|
less = "";
|
||||||
for (d = file->deps; d != 0; d = d->next)
|
for (d = file->deps; d != 0; d = d->next)
|
||||||
if (!d->ignore_mtime)
|
if (!d->ignore_mtime && !d->ignore_automatic_vars)
|
||||||
{
|
{
|
||||||
if (!d->need_2nd_expansion)
|
if (!d->need_2nd_expansion)
|
||||||
less = dep_name (d);
|
less = dep_name (d);
|
||||||
@@ -178,7 +178,7 @@ set_file_variables (struct file *file)
|
|||||||
bar_len = 0;
|
bar_len = 0;
|
||||||
for (d = file->deps; d != 0; d = d->next)
|
for (d = file->deps; d != 0; d = d->next)
|
||||||
{
|
{
|
||||||
if (!d->need_2nd_expansion)
|
if (!d->need_2nd_expansion && !d->ignore_automatic_vars)
|
||||||
{
|
{
|
||||||
if (d->ignore_mtime)
|
if (d->ignore_mtime)
|
||||||
bar_len += strlen (dep_name (d)) + 1;
|
bar_len += strlen (dep_name (d)) + 1;
|
||||||
@@ -200,7 +200,7 @@ set_file_variables (struct file *file)
|
|||||||
|
|
||||||
qmark_len = plus_len + 1; /* Will be this or less. */
|
qmark_len = plus_len + 1; /* Will be this or less. */
|
||||||
for (d = file->deps; d != 0; d = d->next)
|
for (d = file->deps; d != 0; d = d->next)
|
||||||
if (! d->ignore_mtime && ! d->need_2nd_expansion)
|
if (! d->ignore_mtime && ! d->need_2nd_expansion && ! d->ignore_automatic_vars)
|
||||||
{
|
{
|
||||||
const char *c = dep_name (d);
|
const char *c = dep_name (d);
|
||||||
|
|
||||||
@@ -247,7 +247,7 @@ set_file_variables (struct file *file)
|
|||||||
|
|
||||||
for (d = file->deps; d != 0; d = d->next)
|
for (d = file->deps; d != 0; d = d->next)
|
||||||
{
|
{
|
||||||
if (d->need_2nd_expansion)
|
if (d->need_2nd_expansion || d->ignore_automatic_vars)
|
||||||
continue;
|
continue;
|
||||||
|
|
||||||
slot = hash_find_slot (&dep_hash, d);
|
slot = hash_find_slot (&dep_hash, d);
|
||||||
@@ -269,7 +269,7 @@ set_file_variables (struct file *file)
|
|||||||
{
|
{
|
||||||
const char *c;
|
const char *c;
|
||||||
|
|
||||||
if (d->need_2nd_expansion || hash_find_item (&dep_hash, d) != d)
|
if (d->need_2nd_expansion || d->ignore_automatic_vars || hash_find_item (&dep_hash, d) != d)
|
||||||
continue;
|
continue;
|
||||||
|
|
||||||
c = dep_name (d);
|
c = dep_name (d);
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
/* Definition of data structures describing shell commands for GNU Make.
|
/* Definition of data structures describing shell commands for GNU Make.
|
||||||
Copyright (C) 1988-2019 Free Software Foundation, Inc.
|
Copyright (C) 1988-2020 Free Software Foundation, Inc.
|
||||||
This file is part of GNU Make.
|
This file is part of GNU Make.
|
||||||
|
|
||||||
GNU Make is free software; you can redistribute it and/or modify it under the
|
GNU Make is free software; you can redistribute it and/or modify it under the
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
/* config.h -- hand-massaged for Amiga -*-C-*-
|
/* config.h -- hand-massaged for Amiga -*-C-*-
|
||||||
Copyright (C) 1995-2019 Free Software Foundation, Inc.
|
Copyright (C) 1995-2020 Free Software Foundation, Inc.
|
||||||
This file is part of GNU Make.
|
This file is part of GNU Make.
|
||||||
|
|
||||||
GNU Make is free software; you can redistribute it and/or modify it under the
|
GNU Make is free software; you can redistribute it and/or modify it under the
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
/* config.h-vms. Generated by hand by Klaus Kämpf <kkaempf@rmi.de> -*-C-*-
|
/* config.h-vms. Generated by hand by Klaus Kämpf <kkaempf@rmi.de> -*-C-*-
|
||||||
|
|
||||||
Copyright (C) 1996-2019 Free Software Foundation, Inc.
|
Copyright (C) 1996-2020 Free Software Foundation, Inc.
|
||||||
This file is part of GNU Make.
|
This file is part of GNU Make.
|
||||||
|
|
||||||
GNU Make is free software; you can redistribute it and/or modify it under the
|
GNU Make is free software; you can redistribute it and/or modify it under the
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
/* config.h.W32 -- hand-massaged config.h file for Windows builds -*-C-*-
|
/* config.h.W32 -- hand-massaged config.h file for Windows builds -*-C-*-
|
||||||
|
|
||||||
Copyright (C) 1996-2019 Free Software Foundation, Inc.
|
Copyright (C) 1996-2020 Free Software Foundation, Inc.
|
||||||
This file is part of GNU Make.
|
This file is part of GNU Make.
|
||||||
|
|
||||||
GNU Make is free software; you can redistribute it and/or modify it under the
|
GNU Make is free software; you can redistribute it and/or modify it under the
|
||||||
@@ -292,7 +292,10 @@ this program. If not, see <http://www.gnu.org/licenses/>. */
|
|||||||
/* #undef HAVE_STRSIGNAL */
|
/* #undef HAVE_STRSIGNAL */
|
||||||
|
|
||||||
/* Define to 1 if `d_type' is a member of `struct dirent'. */
|
/* Define to 1 if `d_type' is a member of `struct dirent'. */
|
||||||
|
/* SV 57152: MinGW64 version of dirent doesn't support d_type. */
|
||||||
|
#ifndef __MINGW64__
|
||||||
# define HAVE_STRUCT_DIRENT_D_TYPE 1
|
# define HAVE_STRUCT_DIRENT_D_TYPE 1
|
||||||
|
#endif
|
||||||
|
|
||||||
/* Define to 1 if you have the `isatty' function. */
|
/* Define to 1 if you have the `isatty' function. */
|
||||||
#define HAVE_ISATTY 1
|
#define HAVE_ISATTY 1
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
/* configh.dos -- hand-massaged config.h file for MS-DOS builds -*-C-*-
|
/* configh.dos -- hand-massaged config.h file for MS-DOS builds -*-C-*-
|
||||||
|
|
||||||
Copyright (C) 1994-2019 Free Software Foundation, Inc.
|
Copyright (C) 1994-2020 Free Software Foundation, Inc.
|
||||||
This file is part of GNU Make.
|
This file is part of GNU Make.
|
||||||
|
|
||||||
GNU Make is free software; you can redistribute it and/or modify it under the
|
GNU Make is free software; you can redistribute it and/or modify it under the
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
/* Debugging macros and interface.
|
/* Debugging macros and interface.
|
||||||
Copyright (C) 1999-2019 Free Software Foundation, Inc.
|
Copyright (C) 1999-2020 Free Software Foundation, Inc.
|
||||||
This file is part of GNU Make.
|
This file is part of GNU Make.
|
||||||
|
|
||||||
GNU Make is free software; you can redistribute it and/or modify it under the
|
GNU Make is free software; you can redistribute it and/or modify it under the
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
/* Data base of default implicit rules for GNU Make.
|
/* Data base of default implicit rules for GNU Make.
|
||||||
Copyright (C) 1988-2019 Free Software Foundation, Inc.
|
Copyright (C) 1988-2020 Free Software Foundation, Inc.
|
||||||
This file is part of GNU Make.
|
This file is part of GNU Make.
|
||||||
|
|
||||||
GNU Make is free software; you can redistribute it and/or modify it under the
|
GNU Make is free software; you can redistribute it and/or modify it under the
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
/* Definitions of dependency data structures for GNU Make.
|
/* Definitions of dependency data structures for GNU Make.
|
||||||
Copyright (C) 1988-2019 Free Software Foundation, Inc.
|
Copyright (C) 1988-2020 Free Software Foundation, Inc.
|
||||||
This file is part of GNU Make.
|
This file is part of GNU Make.
|
||||||
|
|
||||||
GNU Make is free software; you can redistribute it and/or modify it under the
|
GNU Make is free software; you can redistribute it and/or modify it under the
|
||||||
@@ -48,7 +48,8 @@ struct nameseq
|
|||||||
unsigned int changed : 1; \
|
unsigned int changed : 1; \
|
||||||
unsigned int ignore_mtime : 1; \
|
unsigned int ignore_mtime : 1; \
|
||||||
unsigned int staticpattern : 1; \
|
unsigned int staticpattern : 1; \
|
||||||
unsigned int need_2nd_expansion : 1
|
unsigned int need_2nd_expansion : 1; \
|
||||||
|
unsigned int ignore_automatic_vars : 1
|
||||||
|
|
||||||
struct dep
|
struct dep
|
||||||
{
|
{
|
||||||
@@ -74,6 +75,7 @@ struct goaldep
|
|||||||
#define PARSEFS_NOGLOB 0x0004
|
#define PARSEFS_NOGLOB 0x0004
|
||||||
#define PARSEFS_EXISTS 0x0008
|
#define PARSEFS_EXISTS 0x0008
|
||||||
#define PARSEFS_NOCACHE 0x0010
|
#define PARSEFS_NOCACHE 0x0010
|
||||||
|
#define PARSEFS_ONEWORD 0x0020
|
||||||
|
|
||||||
#define PARSE_FILE_SEQ(_s,_t,_c,_p,_f) \
|
#define PARSE_FILE_SEQ(_s,_t,_c,_p,_f) \
|
||||||
(_t *)parse_file_seq ((_s),sizeof (_t),(_c),(_p),(_f))
|
(_t *)parse_file_seq ((_s),sizeof (_t),(_c),(_p),(_f))
|
||||||
@@ -98,7 +100,7 @@ struct nameseq *ar_glob (const char *arname, const char *member_pattern, size_t
|
|||||||
#define alloc_seq_elt(_t) xcalloc (sizeof (_t))
|
#define alloc_seq_elt(_t) xcalloc (sizeof (_t))
|
||||||
void free_ns_chain (struct nameseq *n);
|
void free_ns_chain (struct nameseq *n);
|
||||||
|
|
||||||
#if defined(MAKE_MAINTAINER_MODE) && defined(__GNUC__)
|
#if defined(MAKE_MAINTAINER_MODE) && defined(__GNUC__) && !defined(__STRICT_ANSI__)
|
||||||
/* Use inline to get real type-checking. */
|
/* Use inline to get real type-checking. */
|
||||||
#define SI static inline
|
#define SI static inline
|
||||||
SI struct nameseq *alloc_ns() { return alloc_seq_elt (struct nameseq); }
|
SI struct nameseq *alloc_ns() { return alloc_seq_elt (struct nameseq); }
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
/* Directory hashing for GNU Make.
|
/* Directory hashing for GNU Make.
|
||||||
Copyright (C) 1988-2019 Free Software Foundation, Inc.
|
Copyright (C) 1988-2020 Free Software Foundation, Inc.
|
||||||
This file is part of GNU Make.
|
This file is part of GNU Make.
|
||||||
|
|
||||||
GNU Make is free software; you can redistribute it and/or modify it under the
|
GNU Make is free software; you can redistribute it and/or modify it under the
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
/* Variable expansion functions for GNU Make.
|
/* Variable expansion functions for GNU Make.
|
||||||
Copyright (C) 1988-2019 Free Software Foundation, Inc.
|
Copyright (C) 1988-2020 Free Software Foundation, Inc.
|
||||||
This file is part of GNU Make.
|
This file is part of GNU Make.
|
||||||
|
|
||||||
GNU Make is free software; you can redistribute it and/or modify it under the
|
GNU Make is free software; you can redistribute it and/or modify it under the
|
||||||
|
|||||||
87
src/file.c
87
src/file.c
@@ -1,5 +1,5 @@
|
|||||||
/* Target file management for GNU Make.
|
/* Target file management for GNU Make.
|
||||||
Copyright (C) 1988-2019 Free Software Foundation, Inc.
|
Copyright (C) 1988-2020 Free Software Foundation, Inc.
|
||||||
This file is part of GNU Make.
|
This file is part of GNU Make.
|
||||||
|
|
||||||
GNU Make is free software; you can redistribute it and/or modify it under the
|
GNU Make is free software; you can redistribute it and/or modify it under the
|
||||||
@@ -550,15 +550,6 @@ enter_prereqs (struct dep *deps, const char *stem)
|
|||||||
return deps;
|
return deps;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Set the intermediate flag. */
|
|
||||||
|
|
||||||
static void
|
|
||||||
set_intermediate (const void *item)
|
|
||||||
{
|
|
||||||
struct file *f = (struct file *) item;
|
|
||||||
f->intermediate = 1;
|
|
||||||
}
|
|
||||||
|
|
||||||
/* Expand and parse each dependency line. */
|
/* Expand and parse each dependency line. */
|
||||||
static void
|
static void
|
||||||
expand_deps (struct file *f)
|
expand_deps (struct file *f)
|
||||||
@@ -644,13 +635,70 @@ expand_deps (struct file *f)
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Reset the updating flag. */
|
/* Add extra prereqs to the file in question. */
|
||||||
|
|
||||||
|
struct dep *
|
||||||
|
expand_extra_prereqs (const struct variable *extra)
|
||||||
|
{
|
||||||
|
struct dep *d;
|
||||||
|
struct dep *prereqs = extra ? split_prereqs (variable_expand (extra->value)) : NULL;
|
||||||
|
|
||||||
|
for (d = prereqs; d; d = d->next)
|
||||||
|
{
|
||||||
|
d->file = lookup_file (d->name);
|
||||||
|
if (!d->file)
|
||||||
|
d->file = enter_file (d->name);
|
||||||
|
d->name = NULL;
|
||||||
|
d->ignore_automatic_vars = 1;
|
||||||
|
}
|
||||||
|
|
||||||
|
return prereqs;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* Perform per-file snap operations. */
|
||||||
|
|
||||||
static void
|
static void
|
||||||
reset_updating (const void *item)
|
snap_file (const void *item, void *arg)
|
||||||
{
|
{
|
||||||
struct file *f = (struct file*)item;
|
struct file *f = (struct file*)item;
|
||||||
|
struct dep *prereqs = NULL;
|
||||||
|
|
||||||
|
/* If we're not doing second expansion then reset updating. */
|
||||||
|
if (!second_expansion)
|
||||||
f->updating = 0;
|
f->updating = 0;
|
||||||
|
|
||||||
|
/* If .SECONDARY is set with no deps, mark all targets as intermediate. */
|
||||||
|
if (all_secondary)
|
||||||
|
f->intermediate = 1;
|
||||||
|
|
||||||
|
/* If .EXTRA_PREREQS is set, add them as ignored by automatic variables. */
|
||||||
|
if (f->variables)
|
||||||
|
prereqs = expand_extra_prereqs (lookup_variable_in_set (STRING_SIZE_TUPLE(".EXTRA_PREREQS"), f->variables->set));
|
||||||
|
|
||||||
|
else if (f->is_target)
|
||||||
|
prereqs = copy_dep_chain (arg);
|
||||||
|
|
||||||
|
if (prereqs)
|
||||||
|
{
|
||||||
|
struct dep *d;
|
||||||
|
for (d = prereqs; d; d = d->next)
|
||||||
|
if (streq (f->name, dep_name (d)))
|
||||||
|
/* Skip circular dependencies. */
|
||||||
|
break;
|
||||||
|
|
||||||
|
if (d)
|
||||||
|
/* We broke early: must have found a circular dependency. */
|
||||||
|
free_dep_chain (prereqs);
|
||||||
|
else if (!f->deps)
|
||||||
|
f->deps = prereqs;
|
||||||
|
else
|
||||||
|
{
|
||||||
|
d = f->deps;
|
||||||
|
while (d->next)
|
||||||
|
d = d->next;
|
||||||
|
d->next = prereqs;
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/* For each dependency of each file, make the 'struct dep' point
|
/* For each dependency of each file, make the 'struct dep' point
|
||||||
@@ -700,9 +748,6 @@ snap_deps (void)
|
|||||||
expand_deps (f);
|
expand_deps (f);
|
||||||
free (file_slot_0);
|
free (file_slot_0);
|
||||||
}
|
}
|
||||||
else
|
|
||||||
/* We're not doing second expansion, so reset updating. */
|
|
||||||
hash_map (&files, reset_updating);
|
|
||||||
|
|
||||||
/* Now manage all the special targets. */
|
/* Now manage all the special targets. */
|
||||||
|
|
||||||
@@ -744,10 +789,7 @@ snap_deps (void)
|
|||||||
f2->intermediate = f2->secondary = 1;
|
f2->intermediate = f2->secondary = 1;
|
||||||
/* .SECONDARY with no deps listed marks *all* files that way. */
|
/* .SECONDARY with no deps listed marks *all* files that way. */
|
||||||
else
|
else
|
||||||
{
|
|
||||||
all_secondary = 1;
|
all_secondary = 1;
|
||||||
hash_map (&files, set_intermediate);
|
|
||||||
}
|
|
||||||
|
|
||||||
f = lookup_file (".EXPORT_ALL_VARIABLES");
|
f = lookup_file (".EXPORT_ALL_VARIABLES");
|
||||||
if (f != 0 && f->is_target)
|
if (f != 0 && f->is_target)
|
||||||
@@ -779,6 +821,15 @@ snap_deps (void)
|
|||||||
if (f != 0 && f->is_target)
|
if (f != 0 && f->is_target)
|
||||||
not_parallel = 1;
|
not_parallel = 1;
|
||||||
|
|
||||||
|
{
|
||||||
|
struct dep *prereqs = expand_extra_prereqs (lookup_variable (STRING_SIZE_TUPLE(".EXTRA_PREREQS")));
|
||||||
|
|
||||||
|
/* Perform per-file snap operations. */
|
||||||
|
hash_map_arg(&files, snap_file, prereqs);
|
||||||
|
|
||||||
|
free_dep_chain (prereqs);
|
||||||
|
}
|
||||||
|
|
||||||
#ifndef NO_MINUS_C_MINUS_O
|
#ifndef NO_MINUS_C_MINUS_O
|
||||||
/* If .POSIX was defined, remove OUTPUT_OPTION to comply. */
|
/* If .POSIX was defined, remove OUTPUT_OPTION to comply. */
|
||||||
/* This needs more work: what if the user sets this in the makefile?
|
/* This needs more work: what if the user sets this in the makefile?
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
/* Definition of target file data structures for GNU Make.
|
/* Definition of target file data structures for GNU Make.
|
||||||
Copyright (C) 1988-2019 Free Software Foundation, Inc.
|
Copyright (C) 1988-2020 Free Software Foundation, Inc.
|
||||||
This file is part of GNU Make.
|
This file is part of GNU Make.
|
||||||
|
|
||||||
GNU Make is free software; you can redistribute it and/or modify it under the
|
GNU Make is free software; you can redistribute it and/or modify it under the
|
||||||
@@ -21,6 +21,11 @@ this program. If not, see <http://www.gnu.org/licenses/>. */
|
|||||||
|
|
||||||
#include "hash.h"
|
#include "hash.h"
|
||||||
|
|
||||||
|
struct commands;
|
||||||
|
struct dep;
|
||||||
|
struct variable;
|
||||||
|
struct variable_set_list;
|
||||||
|
|
||||||
struct file
|
struct file
|
||||||
{
|
{
|
||||||
const char *name;
|
const char *name;
|
||||||
@@ -110,6 +115,7 @@ struct file *lookup_file (const char *name);
|
|||||||
struct file *enter_file (const char *name);
|
struct file *enter_file (const char *name);
|
||||||
struct dep *split_prereqs (char *prereqstr);
|
struct dep *split_prereqs (char *prereqstr);
|
||||||
struct dep *enter_prereqs (struct dep *prereqs, const char *stem);
|
struct dep *enter_prereqs (struct dep *prereqs, const char *stem);
|
||||||
|
struct dep *expand_extra_prereqs (const struct variable *extra);
|
||||||
void remove_intermediates (int sig);
|
void remove_intermediates (int sig);
|
||||||
void snap_deps (void);
|
void snap_deps (void);
|
||||||
void rename_file (struct file *file, const char *name);
|
void rename_file (struct file *file, const char *name);
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
/* Builtin function expansion for GNU Make.
|
/* Builtin function expansion for GNU Make.
|
||||||
Copyright (C) 1988-2019 Free Software Foundation, Inc.
|
Copyright (C) 1988-2020 Free Software Foundation, Inc.
|
||||||
This file is part of GNU Make.
|
This file is part of GNU Make.
|
||||||
|
|
||||||
GNU Make is free software; you can redistribute it and/or modify it under the
|
GNU Make is free software; you can redistribute it and/or modify it under the
|
||||||
@@ -2173,6 +2173,15 @@ func_realpath (char *o, char **argv, const char *funcname UNUSED)
|
|||||||
|
|
||||||
#ifdef HAVE_REALPATH
|
#ifdef HAVE_REALPATH
|
||||||
ENULLLOOP (rp, realpath (in, out));
|
ENULLLOOP (rp, realpath (in, out));
|
||||||
|
# if defined _AIX
|
||||||
|
/* AIX realpath() doesn't remove trailing slashes correctly. */
|
||||||
|
if (rp)
|
||||||
|
{
|
||||||
|
char *ep = rp + strlen (rp) - 1;
|
||||||
|
while (ep > rp && ep[0] == '/')
|
||||||
|
*(ep--) = '\0';
|
||||||
|
}
|
||||||
|
# endif
|
||||||
#else
|
#else
|
||||||
rp = abspath (in, out);
|
rp = abspath (in, out);
|
||||||
#endif
|
#endif
|
||||||
|
|||||||
@@ -3,7 +3,7 @@ NOTE: getopt is now part of the C library, so if you don't know what
|
|||||||
"Keep this file name-space clean" means, talk to drepper@gnu.org
|
"Keep this file name-space clean" means, talk to drepper@gnu.org
|
||||||
before changing it!
|
before changing it!
|
||||||
|
|
||||||
Copyright (C) 1987-2019 Free Software Foundation, Inc.
|
Copyright (C) 1987-2020 Free Software Foundation, Inc.
|
||||||
|
|
||||||
NOTE: The canonical source of this file is maintained with the GNU C Library.
|
NOTE: The canonical source of this file is maintained with the GNU C Library.
|
||||||
Bugs can be reported to bug-glibc@gnu.org.
|
Bugs can be reported to bug-glibc@gnu.org.
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
/* Declarations for getopt.
|
/* Declarations for getopt.
|
||||||
Copyright (C) 1989-2019 Free Software Foundation, Inc.
|
Copyright (C) 1989-2020 Free Software Foundation, Inc.
|
||||||
|
|
||||||
NOTE: The canonical source of this file is maintained with the GNU C Library.
|
NOTE: The canonical source of this file is maintained with the GNU C Library.
|
||||||
Bugs can be reported to bug-glibc@gnu.org.
|
Bugs can be reported to bug-glibc@gnu.org.
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
/* getopt_long and getopt_long_only entry points for GNU getopt.
|
/* getopt_long and getopt_long_only entry points for GNU getopt.
|
||||||
Copyright (C) 1987-1994, 1996-2019 Free Software Foundation, Inc.
|
Copyright (C) 1987-1994, 1996-2020 Free Software Foundation, Inc.
|
||||||
|
|
||||||
NOTE: The canonical source of this file is maintained with the GNU C Library.
|
NOTE: The canonical source of this file is maintained with the GNU C Library.
|
||||||
Bugs can be reported to bug-glibc@gnu.org.
|
Bugs can be reported to bug-glibc@gnu.org.
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
/* Convenience header for conditional use of GNU <libintl.h>.
|
/* Convenience header for conditional use of GNU <libintl.h>.
|
||||||
Copyright (C) 1995-2019 Free Software Foundation, Inc.
|
Copyright (C) 1995-2020 Free Software Foundation, Inc.
|
||||||
This file is part of GNU Make.
|
This file is part of GNU Make.
|
||||||
|
|
||||||
GNU Make is free software; you can redistribute it and/or modify it under the
|
GNU Make is free software; you can redistribute it and/or modify it under the
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
;; Contents of the (gnu make) Guile module
|
;; Contents of the (gnu make) Guile module
|
||||||
;; Copyright (C) 2011-2019 Free Software Foundation, Inc.
|
;; Copyright (C) 2011-2020 Free Software Foundation, Inc.
|
||||||
;; This file is part of GNU Make.
|
;; This file is part of GNU Make.
|
||||||
;;
|
;;
|
||||||
;; GNU Make is free software; you can redistribute it and/or modify it under
|
;; GNU Make is free software; you can redistribute it and/or modify it under
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
/* External interfaces usable by dynamic objects loaded into GNU Make.
|
/* External interfaces usable by dynamic objects loaded into GNU Make.
|
||||||
--THIS API IS A "TECHNOLOGY PREVIEW" ONLY. IT IS NOT A STABLE INTERFACE--
|
--THIS API IS A "TECHNOLOGY PREVIEW" ONLY. IT IS NOT A STABLE INTERFACE--
|
||||||
|
|
||||||
Copyright (C) 2013-2019 Free Software Foundation, Inc.
|
Copyright (C) 2013-2020 Free Software Foundation, Inc.
|
||||||
This file is part of GNU Make.
|
This file is part of GNU Make.
|
||||||
|
|
||||||
GNU Make is free software; you can redistribute it and/or modify it under the
|
GNU Make is free software; you can redistribute it and/or modify it under the
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
/* GNU Guile interface for GNU Make.
|
/* GNU Guile interface for GNU Make.
|
||||||
Copyright (C) 2011-2019 Free Software Foundation, Inc.
|
Copyright (C) 2011-2020 Free Software Foundation, Inc.
|
||||||
This file is part of GNU Make.
|
This file is part of GNU Make.
|
||||||
|
|
||||||
GNU Make is free software; you can redistribute it and/or modify it under the
|
GNU Make is free software; you can redistribute it and/or modify it under the
|
||||||
|
|||||||
67
src/hash.c
67
src/hash.c
@@ -16,6 +16,7 @@ this program. If not, see <http://www.gnu.org/licenses/>. */
|
|||||||
|
|
||||||
#include "makeint.h"
|
#include "makeint.h"
|
||||||
#include "hash.h"
|
#include "hash.h"
|
||||||
|
#include <assert.h>
|
||||||
|
|
||||||
#define CALLOC(t, n) ((t *) xcalloc (sizeof (t) * (n)))
|
#define CALLOC(t, n) ((t *) xcalloc (sizeof (t) * (n)))
|
||||||
#define MALLOC(t, n) ((t *) xmalloc (sizeof (t) * (n)))
|
#define MALLOC(t, n) ((t *) xmalloc (sizeof (t) * (n)))
|
||||||
@@ -364,7 +365,8 @@ round_up_2 (unsigned long n)
|
|||||||
r += val; \
|
r += val; \
|
||||||
} while(0);
|
} while(0);
|
||||||
|
|
||||||
unsigned jhash(unsigned const char *k, int length)
|
unsigned int
|
||||||
|
jhash(unsigned const char *k, int length)
|
||||||
{
|
{
|
||||||
unsigned int a, b, c;
|
unsigned int a, b, c;
|
||||||
|
|
||||||
@@ -408,12 +410,16 @@ unsigned jhash(unsigned const char *k, int length)
|
|||||||
return c;
|
return c;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#define UINTSZ sizeof (unsigned int)
|
||||||
|
|
||||||
#ifdef WORDS_BIGENDIAN
|
#ifdef WORDS_BIGENDIAN
|
||||||
/* The ifs are ordered from the first byte in memory to the last. */
|
/* The ifs are ordered from the first byte in memory to the last. */
|
||||||
#define sum_up_to_nul(r, p, flag) \
|
#define sum_up_to_nul(r, p, plen, flag) \
|
||||||
do { \
|
do { \
|
||||||
unsigned int val; \
|
unsigned int val = 0; \
|
||||||
memcpy(&val, (p), 4); \
|
size_t pn = (plen); \
|
||||||
|
size_t n = pn < UINTSZ ? pn : UINTSZ; \
|
||||||
|
memcpy (&val, (p), n); \
|
||||||
if ((val & 0xFF000000) == 0) \
|
if ((val & 0xFF000000) == 0) \
|
||||||
flag = 1; \
|
flag = 1; \
|
||||||
else if ((val & 0xFF0000) == 0) \
|
else if ((val & 0xFF0000) == 0) \
|
||||||
@@ -427,51 +433,60 @@ unsigned jhash(unsigned const char *k, int length)
|
|||||||
/* First detect the presence of zeroes. If there is none, we can
|
/* First detect the presence of zeroes. If there is none, we can
|
||||||
sum the 4 bytes directly. Otherwise, the ifs are ordered as in the
|
sum the 4 bytes directly. Otherwise, the ifs are ordered as in the
|
||||||
big endian case, from the first byte in memory to the last. */
|
big endian case, from the first byte in memory to the last. */
|
||||||
#define sum_up_to_nul(r, p, flag) \
|
#define sum_up_to_nul(r, p, plen, flag) \
|
||||||
do { \
|
do { \
|
||||||
unsigned int val; \
|
unsigned int val = 0; \
|
||||||
unsigned int zeroes; \
|
size_t pn = (plen); \
|
||||||
memcpy(&val, (p), 4); \
|
size_t n = pn < UINTSZ ? pn : UINTSZ; \
|
||||||
zeroes = ((val - 0x01010101) & ~val); \
|
memcpy (&val, (p), n); \
|
||||||
if (!(zeroes & 0x80808080)) \
|
flag = ((val - 0x01010101) & ~val) & 0x80808080; \
|
||||||
|
if (!flag) \
|
||||||
r += val; \
|
r += val; \
|
||||||
else if ((val & 0xFF) == 0) \
|
else if (val & 0xFF) \
|
||||||
flag = 1; \
|
{ \
|
||||||
else if ((val & 0xFF00) == 0) \
|
if ((val & 0xFF00) == 0) \
|
||||||
r += val & 0xFF, flag = 1; \
|
r += val & 0xFF; \
|
||||||
else if ((val & 0xFF0000) == 0) \
|
else if ((val & 0xFF0000) == 0) \
|
||||||
r += val & 0xFFFF, flag = 1; \
|
r += val & 0xFFFF; \
|
||||||
else \
|
else \
|
||||||
r += val, flag = 1; \
|
r += val; \
|
||||||
|
} \
|
||||||
} while (0)
|
} while (0)
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
/* This function performs magic which is correct but causes ASAN heartburn
|
unsigned int
|
||||||
when we pass in a global constant string (at least). */
|
jhash_string(unsigned const char *k)
|
||||||
__attribute__((no_sanitize_address))
|
|
||||||
unsigned jhash_string(unsigned const char *k)
|
|
||||||
{
|
{
|
||||||
unsigned int a, b, c;
|
unsigned int a, b, c;
|
||||||
unsigned int have_nul = 0;
|
unsigned int have_nul = 0;
|
||||||
unsigned const char *start = k;
|
unsigned const char *start = k;
|
||||||
|
size_t klen = strlen ((const char*)k);
|
||||||
|
|
||||||
/* Set up the internal state */
|
/* Set up the internal state */
|
||||||
a = b = c = JHASH_INITVAL;
|
a = b = c = JHASH_INITVAL;
|
||||||
|
|
||||||
/* All but the last block: affect some 32 bits of (a,b,c) */
|
/* All but the last block: affect some 32 bits of (a,b,c) */
|
||||||
for (;;) {
|
for (;;) {
|
||||||
sum_up_to_nul(a, k, have_nul);
|
sum_up_to_nul(a, k, klen, have_nul);
|
||||||
if (have_nul)
|
if (have_nul)
|
||||||
break;
|
break;
|
||||||
k += 4;
|
k += UINTSZ;
|
||||||
sum_up_to_nul(b, k, have_nul);
|
assert (klen >= UINTSZ);
|
||||||
|
klen -= UINTSZ;
|
||||||
|
|
||||||
|
sum_up_to_nul(b, k, klen, have_nul);
|
||||||
if (have_nul)
|
if (have_nul)
|
||||||
break;
|
break;
|
||||||
k += 4;
|
k += UINTSZ;
|
||||||
sum_up_to_nul(c, k, have_nul);
|
assert (klen >= UINTSZ);
|
||||||
|
klen -= UINTSZ;
|
||||||
|
|
||||||
|
sum_up_to_nul(c, k, klen, have_nul);
|
||||||
if (have_nul)
|
if (have_nul)
|
||||||
break;
|
break;
|
||||||
k += 4;
|
k += UINTSZ;
|
||||||
|
assert (klen >= UINTSZ);
|
||||||
|
klen -= UINTSZ;
|
||||||
jhash_mix(a, b, c);
|
jhash_mix(a, b, c);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
/* Implicit rule searching for GNU Make.
|
/* Implicit rule searching for GNU Make.
|
||||||
Copyright (C) 1988-2019 Free Software Foundation, Inc.
|
Copyright (C) 1988-2020 Free Software Foundation, Inc.
|
||||||
This file is part of GNU Make.
|
This file is part of GNU Make.
|
||||||
|
|
||||||
GNU Make is free software; you can redistribute it and/or modify it under the
|
GNU Make is free software; you can redistribute it and/or modify it under the
|
||||||
@@ -152,6 +152,7 @@ struct patdeps
|
|||||||
const char *pattern;
|
const char *pattern;
|
||||||
struct file *file;
|
struct file *file;
|
||||||
unsigned int ignore_mtime : 1;
|
unsigned int ignore_mtime : 1;
|
||||||
|
unsigned int ignore_automatic_vars : 1;
|
||||||
};
|
};
|
||||||
|
|
||||||
/* This structure stores information about pattern rules that we need
|
/* This structure stores information about pattern rules that we need
|
||||||
@@ -220,8 +221,9 @@ pattern_search (struct file *file, int archive,
|
|||||||
struct patdeps *deplist = xmalloc (max_deps * sizeof (struct patdeps));
|
struct patdeps *deplist = xmalloc (max_deps * sizeof (struct patdeps));
|
||||||
struct patdeps *pat = deplist;
|
struct patdeps *pat = deplist;
|
||||||
|
|
||||||
/* Names of possible dependencies are constructed in this buffer. */
|
/* Names of possible dependencies are constructed in this buffer.
|
||||||
char *depname = alloca (namelen + max_pattern_dep_length);
|
We may replace % by $(*F) for second expansion, increasing the length. */
|
||||||
|
char *depname = alloca (namelen + max_pattern_dep_length + 4);
|
||||||
|
|
||||||
/* The start and length of the stem of FILENAME for the current rule. */
|
/* The start and length of the stem of FILENAME for the current rule. */
|
||||||
const char *stem = 0;
|
const char *stem = 0;
|
||||||
@@ -265,7 +267,7 @@ pattern_search (struct file *file, int archive,
|
|||||||
/* Set LASTSLASH to point at the last slash in FILENAME
|
/* Set LASTSLASH to point at the last slash in FILENAME
|
||||||
but not counting any slash at the end. (foo/bar/ counts as
|
but not counting any slash at the end. (foo/bar/ counts as
|
||||||
bar/ in directory foo/, not empty in directory foo/bar/.) */
|
bar/ in directory foo/, not empty in directory foo/bar/.) */
|
||||||
lastslash = strrchr (filename, '/');
|
lastslash = memrchr (filename, '/', namelen - 1);
|
||||||
#ifdef VMS
|
#ifdef VMS
|
||||||
if (lastslash == NULL)
|
if (lastslash == NULL)
|
||||||
lastslash = strrchr (filename, ']');
|
lastslash = strrchr (filename, ']');
|
||||||
@@ -278,18 +280,16 @@ pattern_search (struct file *file, int archive,
|
|||||||
/* Handle backslashes (possibly mixed with forward slashes)
|
/* Handle backslashes (possibly mixed with forward slashes)
|
||||||
and the case of "d:file". */
|
and the case of "d:file". */
|
||||||
{
|
{
|
||||||
char *bslash = strrchr (filename, '\\');
|
char *bslash = memrchr (filename, '\\', namelen - 1);
|
||||||
if (lastslash == 0 || bslash > lastslash)
|
if (lastslash == 0 || bslash > lastslash)
|
||||||
lastslash = bslash;
|
lastslash = bslash;
|
||||||
if (lastslash == 0 && filename[0] && filename[1] == ':')
|
if (lastslash == 0 && filename[0] && filename[1] == ':')
|
||||||
lastslash = filename + 1;
|
lastslash = filename + 1;
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
if (lastslash != 0 && lastslash[1] == '\0')
|
|
||||||
lastslash = 0;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
pathlen = lastslash - filename + 1;
|
pathlen = lastslash ? lastslash - filename + 1 : 0;
|
||||||
|
|
||||||
/* First see which pattern rules match this target and may be considered.
|
/* First see which pattern rules match this target and may be considered.
|
||||||
Put them in TRYRULES. */
|
Put them in TRYRULES. */
|
||||||
@@ -443,7 +443,6 @@ pattern_search (struct file *file, int archive,
|
|||||||
unsigned int deps_found = 0;
|
unsigned int deps_found = 0;
|
||||||
/* NPTR points to the part of the prereq we haven't processed. */
|
/* NPTR points to the part of the prereq we haven't processed. */
|
||||||
const char *nptr = 0;
|
const char *nptr = 0;
|
||||||
const char *dir = NULL;
|
|
||||||
int order_only = 0;
|
int order_only = 0;
|
||||||
unsigned int matches;
|
unsigned int matches;
|
||||||
|
|
||||||
@@ -478,12 +477,12 @@ pattern_search (struct file *file, int archive,
|
|||||||
memcpy (pathdir, filename, pathlen);
|
memcpy (pathdir, filename, pathlen);
|
||||||
pathdir[pathlen] = '\0';
|
pathdir[pathlen] = '\0';
|
||||||
}
|
}
|
||||||
dir = pathdir;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
if (stemlen > GET_PATH_MAX)
|
if (stemlen + (check_lastslash ? pathlen : 0) > GET_PATH_MAX)
|
||||||
{
|
{
|
||||||
DBS (DB_IMPLICIT, (_("Stem too long: '%.*s'.\n"),
|
DBS (DB_IMPLICIT, (_("Stem too long: '%s%.*s'.\n"),
|
||||||
|
check_lastslash ? pathdir : "",
|
||||||
(int) stemlen, stem));
|
(int) stemlen, stem));
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
@@ -491,8 +490,19 @@ pattern_search (struct file *file, int archive,
|
|||||||
DBS (DB_IMPLICIT, (_("Trying pattern rule with stem '%.*s'.\n"),
|
DBS (DB_IMPLICIT, (_("Trying pattern rule with stem '%.*s'.\n"),
|
||||||
(int) stemlen, stem));
|
(int) stemlen, stem));
|
||||||
|
|
||||||
strncpy (stem_str, stem, stemlen);
|
if (!check_lastslash)
|
||||||
|
{
|
||||||
|
memcpy (stem_str, stem, stemlen);
|
||||||
stem_str[stemlen] = '\0';
|
stem_str[stemlen] = '\0';
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
/* We want to prepend the directory from
|
||||||
|
the original FILENAME onto the stem. */
|
||||||
|
memcpy (stem_str, filename, pathlen);
|
||||||
|
memcpy (stem_str + pathlen, stem, stemlen);
|
||||||
|
stem_str[pathlen + stemlen] = '\0';
|
||||||
|
}
|
||||||
|
|
||||||
/* If there are no prerequisites, then this rule matches. */
|
/* If there are no prerequisites, then this rule matches. */
|
||||||
if (rule->deps == 0)
|
if (rule->deps == 0)
|
||||||
@@ -543,18 +553,19 @@ pattern_search (struct file *file, int archive,
|
|||||||
}
|
}
|
||||||
memcpy (o, nptr, p - nptr);
|
memcpy (o, nptr, p - nptr);
|
||||||
o += p - nptr;
|
o += p - nptr;
|
||||||
memcpy (o, stem_str, stemlen);
|
memcpy (o, stem, stemlen);
|
||||||
o += stemlen;
|
o += stemlen;
|
||||||
strcpy (o, p + 1);
|
strcpy (o, p + 1);
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Parse the expanded string. It might have wildcards. */
|
/* Parse the expanded string. It might have wildcards. */
|
||||||
p = depname;
|
p = depname;
|
||||||
dl = PARSE_SIMPLE_SEQ (&p, struct dep);
|
dl = PARSE_FILE_SEQ (&p, struct dep, MAP_NUL, NULL, PARSEFS_ONEWORD);
|
||||||
for (d = dl; d != NULL; d = d->next)
|
for (d = dl; d != NULL; d = d->next)
|
||||||
{
|
{
|
||||||
++deps_found;
|
++deps_found;
|
||||||
d->ignore_mtime = dep->ignore_mtime;
|
d->ignore_mtime = dep->ignore_mtime;
|
||||||
|
d->ignore_automatic_vars = dep->ignore_automatic_vars;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* We've used up this dep, so next time get a new one. */
|
/* We've used up this dep, so next time get a new one. */
|
||||||
@@ -594,10 +605,10 @@ pattern_search (struct file *file, int archive,
|
|||||||
again. This is not good if you have certain characters
|
again. This is not good if you have certain characters
|
||||||
in your stem (like $).
|
in your stem (like $).
|
||||||
|
|
||||||
Instead, we will replace % with $* and allow the second
|
Instead, we will replace % with $* or $(*F) and allow the
|
||||||
expansion to take care of it for us. This way (since $*
|
second expansion to take care of it for us. This way
|
||||||
is a simple variable) there won't be additional
|
(since $* and $(*F) are simple variables) there won't be
|
||||||
re-expansion of the stem. */
|
additional re-expansion of the stem. */
|
||||||
|
|
||||||
p = lindex (nptr, nptr + len, '%');
|
p = lindex (nptr, nptr + len, '%');
|
||||||
if (p == 0)
|
if (p == 0)
|
||||||
@@ -608,13 +619,22 @@ pattern_search (struct file *file, int archive,
|
|||||||
else
|
else
|
||||||
{
|
{
|
||||||
size_t i = p - nptr;
|
size_t i = p - nptr;
|
||||||
memcpy (depname, nptr, i);
|
char *o = depname;
|
||||||
memcpy (depname + i, "$*", 2);
|
memcpy (o, nptr, i);
|
||||||
memcpy (depname + i + 2, p + 1, len - i - 1);
|
o += i;
|
||||||
depname[len + 2 - 1] = '\0';
|
|
||||||
|
|
||||||
if (check_lastslash)
|
if (check_lastslash)
|
||||||
|
{
|
||||||
add_dir = 1;
|
add_dir = 1;
|
||||||
|
memcpy (o, "$(*F)", 5);
|
||||||
|
o += 5;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
memcpy (o, "$*", 2);
|
||||||
|
o += 2;
|
||||||
|
}
|
||||||
|
memcpy (o, p + 1, len - i - 1);
|
||||||
|
o[len - i - 1] = '\0';
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Set up for the next word. */
|
/* Set up for the next word. */
|
||||||
@@ -646,7 +666,7 @@ pattern_search (struct file *file, int archive,
|
|||||||
/* Parse the expanded string. */
|
/* Parse the expanded string. */
|
||||||
struct dep *dp = PARSE_FILE_SEQ (&p, struct dep,
|
struct dep *dp = PARSE_FILE_SEQ (&p, struct dep,
|
||||||
order_only ? MAP_NUL : MAP_PIPE,
|
order_only ? MAP_NUL : MAP_PIPE,
|
||||||
add_dir ? dir : NULL, PARSEFS_NONE);
|
add_dir ? pathdir : NULL, PARSEFS_NONE);
|
||||||
*dptr = dp;
|
*dptr = dp;
|
||||||
|
|
||||||
for (d = dp; d != NULL; d = d->next)
|
for (d = dp; d != NULL; d = d->next)
|
||||||
@@ -705,6 +725,7 @@ pattern_search (struct file *file, int archive,
|
|||||||
|
|
||||||
memset (pat, '\0', sizeof (struct patdeps));
|
memset (pat, '\0', sizeof (struct patdeps));
|
||||||
pat->ignore_mtime = d->ignore_mtime;
|
pat->ignore_mtime = d->ignore_mtime;
|
||||||
|
pat->ignore_automatic_vars = d->ignore_automatic_vars;
|
||||||
|
|
||||||
DBS (DB_IMPLICIT,
|
DBS (DB_IMPLICIT,
|
||||||
(is_rule
|
(is_rule
|
||||||
@@ -895,6 +916,7 @@ pattern_search (struct file *file, int archive,
|
|||||||
|
|
||||||
dep = alloc_dep ();
|
dep = alloc_dep ();
|
||||||
dep->ignore_mtime = pat->ignore_mtime;
|
dep->ignore_mtime = pat->ignore_mtime;
|
||||||
|
dep->ignore_automatic_vars = pat->ignore_automatic_vars;
|
||||||
s = strcache_add (pat->name);
|
s = strcache_add (pat->name);
|
||||||
if (recursions)
|
if (recursions)
|
||||||
dep->name = s;
|
dep->name = s;
|
||||||
@@ -931,17 +953,13 @@ pattern_search (struct file *file, int archive,
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
size_t dirlen = (lastslash + 1) - filename;
|
|
||||||
char *sp;
|
|
||||||
|
|
||||||
/* We want to prepend the directory from
|
/* We want to prepend the directory from
|
||||||
the original FILENAME onto the stem. */
|
the original FILENAME onto the stem. */
|
||||||
fullstemlen = dirlen + stemlen;
|
fullstemlen = pathlen + stemlen;
|
||||||
sp = alloca (fullstemlen + 1);
|
memcpy (stem_str, filename, pathlen);
|
||||||
memcpy (sp, filename, dirlen);
|
memcpy (stem_str + pathlen, stem, stemlen);
|
||||||
memcpy (sp + dirlen, stem, stemlen);
|
stem_str[fullstemlen] = '\0';
|
||||||
sp[fullstemlen] = '\0';
|
file->stem = strcache_add (stem_str);
|
||||||
file->stem = strcache_add (sp);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
file->cmds = rule->cmds;
|
file->cmds = rule->cmds;
|
||||||
|
|||||||
35
src/job.c
35
src/job.c
@@ -1,5 +1,5 @@
|
|||||||
/* Job execution and handling for GNU Make.
|
/* Job execution and handling for GNU Make.
|
||||||
Copyright (C) 1988-2019 Free Software Foundation, Inc.
|
Copyright (C) 1988-2020 Free Software Foundation, Inc.
|
||||||
This file is part of GNU Make.
|
This file is part of GNU Make.
|
||||||
|
|
||||||
GNU Make is free software; you can redistribute it and/or modify it under the
|
GNU Make is free software; you can redistribute it and/or modify it under the
|
||||||
@@ -557,11 +557,8 @@ child_error (struct child *child,
|
|||||||
nm = _("<builtin>");
|
nm = _("<builtin>");
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
/* We can't use the standard <FILE>:<LINENO> syntax here because
|
|
||||||
Emacs misinterprets it and matches a bogus filename in the compile
|
|
||||||
buffer. */
|
|
||||||
char *a = alloca (strlen (flocp->filenm) + 6 + INTSTR_LENGTH + 1);
|
char *a = alloca (strlen (flocp->filenm) + 6 + INTSTR_LENGTH + 1);
|
||||||
sprintf (a, "%s;%lu", flocp->filenm, flocp->lineno + flocp->offset);
|
sprintf (a, "%s:%lu", flocp->filenm, flocp->lineno + flocp->offset);
|
||||||
nm = a;
|
nm = a;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -1073,11 +1070,11 @@ reap_children (int block, int err)
|
|||||||
{
|
{
|
||||||
DB (DB_JOBS, (_("Removing child %p PID %s%s from chain.\n"),
|
DB (DB_JOBS, (_("Removing child %p PID %s%s from chain.\n"),
|
||||||
c, pid2str (c->pid), c->remote ? _(" (remote)") : ""));
|
c, pid2str (c->pid), c->remote ? _(" (remote)") : ""));
|
||||||
|
}
|
||||||
|
|
||||||
/* There is now another slot open. */
|
/* There is now another slot open. */
|
||||||
if (job_slots_used > 0)
|
if (job_slots_used > 0)
|
||||||
--job_slots_used;
|
job_slots_used -= c->jobslot;
|
||||||
}
|
|
||||||
|
|
||||||
/* Remove the child from the chain and free it. */
|
/* Remove the child from the chain and free it. */
|
||||||
if (lastc == 0)
|
if (lastc == 0)
|
||||||
@@ -1647,6 +1644,8 @@ start_waiting_job (struct child *c)
|
|||||||
c->remote ? _(" (remote)") : ""));
|
c->remote ? _(" (remote)") : ""));
|
||||||
/* One more job slot is in use. */
|
/* One more job slot is in use. */
|
||||||
++job_slots_used;
|
++job_slots_used;
|
||||||
|
assert (c->jobslot == 0);
|
||||||
|
c->jobslot = 1;
|
||||||
}
|
}
|
||||||
children = c;
|
children = c;
|
||||||
unblock_sigs ();
|
unblock_sigs ();
|
||||||
@@ -2009,7 +2008,18 @@ load_too_high (void)
|
|||||||
#else
|
#else
|
||||||
static double last_sec;
|
static double last_sec;
|
||||||
static time_t last_now;
|
static time_t last_now;
|
||||||
static int proc_fd = -2;
|
|
||||||
|
/* This is disabled by default for now, because it will behave badly if the
|
||||||
|
user gives a value > the number of cores; in that situation the load will
|
||||||
|
never be exceeded, this function always returns false, and we'll start
|
||||||
|
all the jobs. Also, it's not quite right to limit jobs to the number of
|
||||||
|
cores not busy since a job takes some time to start etc. Maybe that's
|
||||||
|
OK, I'm not sure exactly how to handle that, but for sure we need to
|
||||||
|
clamp this value at the number of cores before this can be enabled.
|
||||||
|
*/
|
||||||
|
#define PROC_FD_INIT -1
|
||||||
|
static int proc_fd = PROC_FD_INIT;
|
||||||
|
|
||||||
double load, guess;
|
double load, guess;
|
||||||
time_t now;
|
time_t now;
|
||||||
|
|
||||||
@@ -2397,7 +2407,7 @@ child_execute_job (struct childbase *child, int good_stdin, char **argv)
|
|||||||
for (pp = argv; *pp != NULL; ++pp)
|
for (pp = argv; *pp != NULL; ++pp)
|
||||||
++l;
|
++l;
|
||||||
|
|
||||||
nargv = xmalloc (sizeof (char *) * (l + 2));
|
nargv = xmalloc (sizeof (char *) * (l + 3));
|
||||||
nargv[0] = (char *)default_shell;
|
nargv[0] = (char *)default_shell;
|
||||||
nargv[1] = cmd;
|
nargv[1] = cmd;
|
||||||
memcpy (&nargv[2], &argv[1], sizeof (char *) * l);
|
memcpy (&nargv[2], &argv[1], sizeof (char *) * l);
|
||||||
@@ -2775,9 +2785,10 @@ construct_command_argv_internal (char *line, char **restp, const char *shell,
|
|||||||
#else /* must be UNIX-ish */
|
#else /* must be UNIX-ish */
|
||||||
static const char *sh_chars = "#;\"*?[]&|<>(){}$`^~!";
|
static const char *sh_chars = "#;\"*?[]&|<>(){}$`^~!";
|
||||||
static const char *sh_cmds[] =
|
static const char *sh_cmds[] =
|
||||||
{ ".", ":", "break", "case", "cd", "command", "continue", "eval", "exec",
|
{ ".", ":", "alias", "bg", "break", "case", "cd", "command", "continue",
|
||||||
"exit", "export", "for", "if", "login", "logout", "read", "readonly",
|
"eval", "exec", "exit", "export", "fc", "fg", "for", "getopts", "hash",
|
||||||
"set", "shift", "switch", "test", "times", "trap", "ulimit", "umask",
|
"if", "jobs", "login", "logout", "read", "readonly", "return", "set",
|
||||||
|
"shift", "test", "times", "trap", "type", "ulimit", "umask", "unalias",
|
||||||
"unset", "wait", "while", 0 };
|
"unset", "wait", "while", 0 };
|
||||||
|
|
||||||
# ifdef HAVE_DOS_PATHS
|
# ifdef HAVE_DOS_PATHS
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
/* Definitions for managing subprocesses in GNU Make.
|
/* Definitions for managing subprocesses in GNU Make.
|
||||||
Copyright (C) 1992-2019 Free Software Foundation, Inc.
|
Copyright (C) 1992-2020 Free Software Foundation, Inc.
|
||||||
This file is part of GNU Make.
|
This file is part of GNU Make.
|
||||||
|
|
||||||
GNU Make is free software; you can redistribute it and/or modify it under the
|
GNU Make is free software; you can redistribute it and/or modify it under the
|
||||||
@@ -61,6 +61,7 @@ struct child
|
|||||||
unsigned int good_stdin:1; /* Nonzero if this child has a good stdin. */
|
unsigned int good_stdin:1; /* Nonzero if this child has a good stdin. */
|
||||||
unsigned int deleted:1; /* Nonzero if targets have been deleted. */
|
unsigned int deleted:1; /* Nonzero if targets have been deleted. */
|
||||||
unsigned int recursive:1; /* Nonzero for recursive command ('+' etc.) */
|
unsigned int recursive:1; /* Nonzero for recursive command ('+' etc.) */
|
||||||
|
unsigned int jobslot:1; /* Nonzero if it's reserved a job slot. */
|
||||||
unsigned int dontcare:1; /* Saved dontcare flag. */
|
unsigned int dontcare:1; /* Saved dontcare flag. */
|
||||||
};
|
};
|
||||||
|
|
||||||
@@ -79,11 +80,11 @@ char **construct_command_argv (char *line, char **restp, struct file *file,
|
|||||||
pid_t child_execute_job (struct childbase *child, int good_stdin, char **argv);
|
pid_t child_execute_job (struct childbase *child, int good_stdin, char **argv);
|
||||||
|
|
||||||
#ifdef _AMIGA
|
#ifdef _AMIGA
|
||||||
void exec_command (char **argv) __attribute__ ((noreturn));
|
void exec_command (char **argv) NORETURN;
|
||||||
#elif defined(__EMX__)
|
#elif defined(__EMX__)
|
||||||
int exec_command (char **argv, char **envp);
|
int exec_command (char **argv, char **envp);
|
||||||
#else
|
#else
|
||||||
void exec_command (char **argv, char **envp) __attribute__ ((noreturn));
|
void exec_command (char **argv, char **envp) NORETURN;
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
void unblock_all_sigs (void);
|
void unblock_all_sigs (void);
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
/* Loading dynamic objects for GNU Make.
|
/* Loading dynamic objects for GNU Make.
|
||||||
Copyright (C) 2012-2019 Free Software Foundation, Inc.
|
Copyright (C) 2012-2020 Free Software Foundation, Inc.
|
||||||
This file is part of GNU Make.
|
This file is part of GNU Make.
|
||||||
|
|
||||||
GNU Make is free software; you can redistribute it and/or modify it under the
|
GNU Make is free software; you can redistribute it and/or modify it under the
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
/* API for GNU Make dynamic objects.
|
/* API for GNU Make dynamic objects.
|
||||||
Copyright (C) 2013-2019 Free Software Foundation, Inc.
|
Copyright (C) 2013-2020 Free Software Foundation, Inc.
|
||||||
This file is part of GNU Make.
|
This file is part of GNU Make.
|
||||||
|
|
||||||
GNU Make is free software; you can redistribute it and/or modify it under the
|
GNU Make is free software; you can redistribute it and/or modify it under the
|
||||||
|
|||||||
12
src/main.c
12
src/main.c
@@ -1,5 +1,5 @@
|
|||||||
/* Argument parsing and main program of GNU Make.
|
/* Argument parsing and main program of GNU Make.
|
||||||
Copyright (C) 1988-2019 Free Software Foundation, Inc.
|
Copyright (C) 1988-2020 Free Software Foundation, Inc.
|
||||||
This file is part of GNU Make.
|
This file is part of GNU Make.
|
||||||
|
|
||||||
GNU Make is free software; you can redistribute it and/or modify it under the
|
GNU Make is free software; you can redistribute it and/or modify it under the
|
||||||
@@ -96,7 +96,7 @@ int chdir ();
|
|||||||
#endif
|
#endif
|
||||||
#ifndef STDC_HEADERS
|
#ifndef STDC_HEADERS
|
||||||
# ifndef sun /* Sun has an incorrect decl in a header. */
|
# ifndef sun /* Sun has an incorrect decl in a header. */
|
||||||
void exit (int) __attribute__ ((noreturn));
|
void exit (int) NORETURN;
|
||||||
# endif
|
# endif
|
||||||
double atof ();
|
double atof ();
|
||||||
#endif
|
#endif
|
||||||
@@ -1313,7 +1313,7 @@ main (int argc, char **argv, char **envp)
|
|||||||
{
|
{
|
||||||
const char *features = "target-specific order-only second-expansion"
|
const char *features = "target-specific order-only second-expansion"
|
||||||
" else-if shortest-stem undefine oneshell nocomment"
|
" else-if shortest-stem undefine oneshell nocomment"
|
||||||
" grouped-target"
|
" grouped-target extra-prereqs"
|
||||||
#ifndef NO_ARCHIVES
|
#ifndef NO_ARCHIVES
|
||||||
" archives"
|
" archives"
|
||||||
#endif
|
#endif
|
||||||
@@ -2134,9 +2134,9 @@ main (int argc, char **argv, char **envp)
|
|||||||
|
|
||||||
install_default_implicit_rules ();
|
install_default_implicit_rules ();
|
||||||
|
|
||||||
/* Compute implicit rule limits. */
|
/* Compute implicit rule limits and do magic for pattern rules. */
|
||||||
|
|
||||||
count_implicit_rule_limits ();
|
snap_implicit_rules ();
|
||||||
|
|
||||||
/* Construct the listings of directories in VPATH lists. */
|
/* Construct the listings of directories in VPATH lists. */
|
||||||
|
|
||||||
@@ -3370,7 +3370,7 @@ print_version (void)
|
|||||||
year, and none of the rest of it should be translated (including the
|
year, and none of the rest of it should be translated (including the
|
||||||
word "Copyright"), so it hardly seems worth it. */
|
word "Copyright"), so it hardly seems worth it. */
|
||||||
|
|
||||||
printf ("%sCopyright (C) 1988-2019 Free Software Foundation, Inc.\n",
|
printf ("%sCopyright (C) 1988-2020 Free Software Foundation, Inc.\n",
|
||||||
precede);
|
precede);
|
||||||
|
|
||||||
printf (_("%sLicense GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>\n\
|
printf (_("%sLicense GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>\n\
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
/* Miscellaneous global declarations and portability cruft for GNU Make.
|
/* Miscellaneous global declarations and portability cruft for GNU Make.
|
||||||
Copyright (C) 1988-2019 Free Software Foundation, Inc.
|
Copyright (C) 1988-2020 Free Software Foundation, Inc.
|
||||||
This file is part of GNU Make.
|
This file is part of GNU Make.
|
||||||
|
|
||||||
GNU Make is free software; you can redistribute it and/or modify it under the
|
GNU Make is free software; you can redistribute it and/or modify it under the
|
||||||
@@ -220,19 +220,22 @@ extern int vms_legacy_behavior;
|
|||||||
extern int vms_unix_simulation;
|
extern int vms_unix_simulation;
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#ifndef __attribute__
|
#if !defined(__attribute__) && (__GNUC__ < 2 || (__GNUC__ == 2 && __GNUC_MINOR__ < 5) || __STRICT_ANSI__)
|
||||||
/* This feature is available in gcc versions 2.5 and later. */
|
/* Don't use __attribute__ if it's not supported. */
|
||||||
# if __GNUC__ < 2 || (__GNUC__ == 2 && __GNUC_MINOR__ < 5) || __STRICT_ANSI__
|
# define ATTRIBUTE(x)
|
||||||
# define __attribute__(x)
|
#else
|
||||||
|
# define ATTRIBUTE(x) __attribute__ (x)
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
/* The __-protected variants of 'format' and 'printf' attributes
|
/* The __-protected variants of 'format' and 'printf' attributes
|
||||||
are accepted by gcc versions 2.6.4 (effectively 2.7) and later. */
|
are accepted by gcc versions 2.6.4 (effectively 2.7) and later. */
|
||||||
#if __GNUC__ < 2 || (__GNUC__ == 2 && __GNUC_MINOR__ < 7)
|
#if __GNUC__ < 2 || (__GNUC__ == 2 && __GNUC_MINOR__ < 7)
|
||||||
# define __format__ format
|
# define __format__ format
|
||||||
# define __printf__ printf
|
# define __printf__ printf
|
||||||
#endif
|
#endif
|
||||||
#endif
|
|
||||||
#define UNUSED __attribute__ ((unused))
|
#define UNUSED ATTRIBUTE ((unused))
|
||||||
|
#define NORETURN ATTRIBUTE ((noreturn))
|
||||||
|
|
||||||
#if defined (STDC_HEADERS) || defined (__GNU_LIBRARY__)
|
#if defined (STDC_HEADERS) || defined (__GNU_LIBRARY__)
|
||||||
# include <stdlib.h>
|
# include <stdlib.h>
|
||||||
@@ -255,8 +258,8 @@ void *malloc (int);
|
|||||||
void *realloc (void *, int);
|
void *realloc (void *, int);
|
||||||
void free (void *);
|
void free (void *);
|
||||||
|
|
||||||
void abort (void) __attribute__ ((noreturn));
|
void abort (void) NORETURN;
|
||||||
void exit (int) __attribute__ ((noreturn));
|
void exit (int) NORETURN;
|
||||||
# endif /* HAVE_STDLIB_H. */
|
# endif /* HAVE_STDLIB_H. */
|
||||||
|
|
||||||
#endif /* Standard headers. */
|
#endif /* Standard headers. */
|
||||||
@@ -327,7 +330,7 @@ extern mode_t umask (mode_t);
|
|||||||
|
|
||||||
#define strneq(a, b, l) (strncmp ((a), (b), (l)) == 0)
|
#define strneq(a, b, l) (strncmp ((a), (b), (l)) == 0)
|
||||||
|
|
||||||
#if defined(__GNUC__) || defined(ENUM_BITFIELDS)
|
#if defined(ENUM_BITFIELDS) || (defined(__GNUC__) && !defined(__STRICT_ANSI__))
|
||||||
# define ENUM_BITFIELD(bits) :bits
|
# define ENUM_BITFIELD(bits) :bits
|
||||||
#else
|
#else
|
||||||
# define ENUM_BITFIELD(bits)
|
# define ENUM_BITFIELD(bits)
|
||||||
@@ -486,12 +489,12 @@ typedef struct
|
|||||||
|
|
||||||
const char *concat (unsigned int, ...);
|
const char *concat (unsigned int, ...);
|
||||||
void message (int prefix, size_t length, const char *fmt, ...)
|
void message (int prefix, size_t length, const char *fmt, ...)
|
||||||
__attribute__ ((__format__ (__printf__, 3, 4)));
|
ATTRIBUTE ((__format__ (__printf__, 3, 4)));
|
||||||
void error (const floc *flocp, size_t length, const char *fmt, ...)
|
void error (const floc *flocp, size_t length, const char *fmt, ...)
|
||||||
__attribute__ ((__format__ (__printf__, 3, 4)));
|
ATTRIBUTE ((__format__ (__printf__, 3, 4)));
|
||||||
void fatal (const floc *flocp, size_t length, const char *fmt, ...)
|
void fatal (const floc *flocp, size_t length, const char *fmt, ...)
|
||||||
__attribute__ ((noreturn, __format__ (__printf__, 3, 4)));
|
ATTRIBUTE ((noreturn, __format__ (__printf__, 3, 4)));
|
||||||
void out_of_memory () __attribute__((noreturn));
|
void out_of_memory () NORETURN;
|
||||||
|
|
||||||
/* When adding macros to this list be sure to update the value of
|
/* When adding macros to this list be sure to update the value of
|
||||||
XGETTEXT_OPTIONS in the po/Makevars file. */
|
XGETTEXT_OPTIONS in the po/Makevars file. */
|
||||||
@@ -509,8 +512,8 @@ void out_of_memory () __attribute__((noreturn));
|
|||||||
#define ONS(_t,_a,_f,_n,_s) _t((_a), INTSTR_LENGTH + strlen (_s), \
|
#define ONS(_t,_a,_f,_n,_s) _t((_a), INTSTR_LENGTH + strlen (_s), \
|
||||||
(_f), (_n), (_s))
|
(_f), (_n), (_s))
|
||||||
|
|
||||||
void die (int) __attribute__ ((noreturn));
|
void die (int) NORETURN;
|
||||||
void pfatal_with_name (const char *) __attribute__ ((noreturn));
|
void pfatal_with_name (const char *) NORETURN;
|
||||||
void perror_with_name (const char *, const char *);
|
void perror_with_name (const char *, const char *);
|
||||||
#define xstrlen(_s) ((_s)==NULL ? 0 : strlen (_s))
|
#define xstrlen(_s) ((_s)==NULL ? 0 : strlen (_s))
|
||||||
void *xmalloc (size_t);
|
void *xmalloc (size_t);
|
||||||
@@ -531,6 +534,10 @@ FILE *get_tmpfile (char **, const char *);
|
|||||||
ssize_t writebuf (int, const void *, size_t);
|
ssize_t writebuf (int, const void *, size_t);
|
||||||
ssize_t readbuf (int, void *, size_t);
|
ssize_t readbuf (int, void *, size_t);
|
||||||
|
|
||||||
|
#ifndef HAVE_MEMRCHR
|
||||||
|
void *memrchr(const void *, int, size_t);
|
||||||
|
#endif
|
||||||
|
|
||||||
#ifndef NO_ARCHIVES
|
#ifndef NO_ARCHIVES
|
||||||
int ar_name (const char *);
|
int ar_name (const char *);
|
||||||
void ar_parse_name (const char *, char **, char **);
|
void ar_parse_name (const char *, char **, char **);
|
||||||
|
|||||||
34
src/misc.c
34
src/misc.c
@@ -1,5 +1,5 @@
|
|||||||
/* Miscellaneous generic support functions for GNU Make.
|
/* Miscellaneous generic support functions for GNU Make.
|
||||||
Copyright (C) 1988-2019 Free Software Foundation, Inc.
|
Copyright (C) 1988-2020 Free Software Foundation, Inc.
|
||||||
This file is part of GNU Make.
|
This file is part of GNU Make.
|
||||||
|
|
||||||
GNU Make is free software; you can redistribute it and/or modify it under the
|
GNU Make is free software; you can redistribute it and/or modify it under the
|
||||||
@@ -24,6 +24,7 @@ this program. If not, see <http://www.gnu.org/licenses/>. */
|
|||||||
#include <stdarg.h>
|
#include <stdarg.h>
|
||||||
|
|
||||||
#ifdef WINDOWS32
|
#ifdef WINDOWS32
|
||||||
|
# include <windows.h>
|
||||||
# include <io.h>
|
# include <io.h>
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
@@ -260,6 +261,30 @@ xstrndup (const char *str, size_t length)
|
|||||||
|
|
||||||
return result;
|
return result;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#ifndef HAVE_MEMRCHR
|
||||||
|
void *
|
||||||
|
memrchr(const void* str, int ch, size_t len)
|
||||||
|
{
|
||||||
|
const char* sp = str;
|
||||||
|
const char* cp = sp;
|
||||||
|
|
||||||
|
if (len == 0)
|
||||||
|
return NULL;
|
||||||
|
|
||||||
|
cp += len - 1;
|
||||||
|
|
||||||
|
while (cp[0] != ch)
|
||||||
|
{
|
||||||
|
if (cp == sp)
|
||||||
|
return NULL;
|
||||||
|
--cp;
|
||||||
|
}
|
||||||
|
|
||||||
|
return (void*)cp;
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
/* Limited INDEX:
|
/* Limited INDEX:
|
||||||
@@ -407,7 +432,8 @@ free_ns_chain (struct nameseq *ns)
|
|||||||
|
|
||||||
#ifdef MAKE_MAINTAINER_MODE
|
#ifdef MAKE_MAINTAINER_MODE
|
||||||
|
|
||||||
void spin(const char* type)
|
void
|
||||||
|
spin (const char* type)
|
||||||
{
|
{
|
||||||
char filenm[256];
|
char filenm[256];
|
||||||
struct stat dummy;
|
struct stat dummy;
|
||||||
@@ -418,7 +444,11 @@ void spin(const char* type)
|
|||||||
{
|
{
|
||||||
fprintf (stderr, "SPIN on %s\n", filenm);
|
fprintf (stderr, "SPIN on %s\n", filenm);
|
||||||
do
|
do
|
||||||
|
#ifdef WINDOWS32
|
||||||
|
Sleep (1000);
|
||||||
|
#else
|
||||||
sleep (1);
|
sleep (1);
|
||||||
|
#endif
|
||||||
while (stat (filenm, &dummy) == 0);
|
while (stat (filenm, &dummy) == 0);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
2
src/os.h
2
src/os.h
@@ -1,5 +1,5 @@
|
|||||||
/* Declarations for operating system interfaces for GNU Make.
|
/* Declarations for operating system interfaces for GNU Make.
|
||||||
Copyright (C) 2016-2019 Free Software Foundation, Inc.
|
Copyright (C) 2016-2020 Free Software Foundation, Inc.
|
||||||
This file is part of GNU Make.
|
This file is part of GNU Make.
|
||||||
|
|
||||||
GNU Make is free software; you can redistribute it and/or modify it under the
|
GNU Make is free software; you can redistribute it and/or modify it under the
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
/* Output to stdout / stderr for GNU make
|
/* Output to stdout / stderr for GNU make
|
||||||
Copyright (C) 2013-2019 Free Software Foundation, Inc.
|
Copyright (C) 2013-2020 Free Software Foundation, Inc.
|
||||||
This file is part of GNU Make.
|
This file is part of GNU Make.
|
||||||
|
|
||||||
GNU Make is free software; you can redistribute it and/or modify it under the
|
GNU Make is free software; you can redistribute it and/or modify it under the
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
/* Output to stdout / stderr for GNU make
|
/* Output to stdout / stderr for GNU make
|
||||||
Copyright (C) 2013-2019 Free Software Foundation, Inc.
|
Copyright (C) 2013-2020 Free Software Foundation, Inc.
|
||||||
This file is part of GNU Make.
|
This file is part of GNU Make.
|
||||||
|
|
||||||
GNU Make is free software; you can redistribute it and/or modify it under the
|
GNU Make is free software; you can redistribute it and/or modify it under the
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
/* POSIX-based operating system interface for GNU Make.
|
/* POSIX-based operating system interface for GNU Make.
|
||||||
Copyright (C) 2016-2019 Free Software Foundation, Inc.
|
Copyright (C) 2016-2020 Free Software Foundation, Inc.
|
||||||
This file is part of GNU Make.
|
This file is part of GNU Make.
|
||||||
|
|
||||||
GNU Make is free software; you can redistribute it and/or modify it under the
|
GNU Make is free software; you can redistribute it and/or modify it under the
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
/* Reading and parsing of makefiles for GNU Make.
|
/* Reading and parsing of makefiles for GNU Make.
|
||||||
Copyright (C) 1988-2019 Free Software Foundation, Inc.
|
Copyright (C) 1988-2020 Free Software Foundation, Inc.
|
||||||
This file is part of GNU Make.
|
This file is part of GNU Make.
|
||||||
|
|
||||||
GNU Make is free software; you can redistribute it and/or modify it under the
|
GNU Make is free software; you can redistribute it and/or modify it under the
|
||||||
@@ -3138,7 +3138,10 @@ parse_file_seq (char **stringp, size_t size, int stopmap,
|
|||||||
char *p;
|
char *p;
|
||||||
glob_t gl;
|
glob_t gl;
|
||||||
char *tp;
|
char *tp;
|
||||||
int findmap = stopmap|MAP_VMSCOMMA|MAP_BLANK|MAP_NUL;
|
int findmap = stopmap|MAP_VMSCOMMA|MAP_NUL;
|
||||||
|
|
||||||
|
if (NONE_SET (flags, PARSEFS_ONEWORD))
|
||||||
|
findmap |= MAP_BLANK;
|
||||||
|
|
||||||
/* Always stop on NUL. */
|
/* Always stop on NUL. */
|
||||||
stopmap |= MAP_NUL;
|
stopmap |= MAP_NUL;
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
/* Basic dependency engine for GNU Make.
|
/* Basic dependency engine for GNU Make.
|
||||||
Copyright (C) 1988-2019 Free Software Foundation, Inc.
|
Copyright (C) 1988-2020 Free Software Foundation, Inc.
|
||||||
This file is part of GNU Make.
|
This file is part of GNU Make.
|
||||||
|
|
||||||
GNU Make is free software; you can redistribute it and/or modify it under the
|
GNU Make is free software; you can redistribute it and/or modify it under the
|
||||||
|
|||||||
@@ -3,7 +3,7 @@
|
|||||||
Please do not send bug reports or questions about it to
|
Please do not send bug reports or questions about it to
|
||||||
the Make maintainers.
|
the Make maintainers.
|
||||||
|
|
||||||
Copyright (C) 1988-2019 Free Software Foundation, Inc.
|
Copyright (C) 1988-2020 Free Software Foundation, Inc.
|
||||||
This file is part of GNU Make.
|
This file is part of GNU Make.
|
||||||
|
|
||||||
GNU Make is free software; you can redistribute it and/or modify it under the
|
GNU Make is free software; you can redistribute it and/or modify it under the
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
/* Template for the remote job exportation interface to GNU Make.
|
/* Template for the remote job exportation interface to GNU Make.
|
||||||
Copyright (C) 1988-2019 Free Software Foundation, Inc.
|
Copyright (C) 1988-2020 Free Software Foundation, Inc.
|
||||||
This file is part of GNU Make.
|
This file is part of GNU Make.
|
||||||
|
|
||||||
GNU Make is free software; you can redistribute it and/or modify it under the
|
GNU Make is free software; you can redistribute it and/or modify it under the
|
||||||
|
|||||||
79
src/rule.c
79
src/rule.c
@@ -1,5 +1,5 @@
|
|||||||
/* Pattern and suffix rule internals for GNU Make.
|
/* Pattern and suffix rule internals for GNU Make.
|
||||||
Copyright (C) 1988-2019 Free Software Foundation, Inc.
|
Copyright (C) 1988-2020 Free Software Foundation, Inc.
|
||||||
This file is part of GNU Make.
|
This file is part of GNU Make.
|
||||||
|
|
||||||
GNU Make is free software; you can redistribute it and/or modify it under the
|
GNU Make is free software; you can redistribute it and/or modify it under the
|
||||||
@@ -60,29 +60,38 @@ struct file *suffix_file;
|
|||||||
|
|
||||||
static size_t maxsuffix;
|
static size_t maxsuffix;
|
||||||
|
|
||||||
/* Compute the maximum dependency length and maximum number of
|
/* Compute the maximum dependency length and maximum number of dependencies of
|
||||||
dependencies of all implicit rules. Also sets the subdir
|
all implicit rules. Also sets the subdir flag for a rule when appropriate,
|
||||||
flag for a rule when appropriate, possibly removing the rule
|
possibly removing the rule completely when appropriate.
|
||||||
completely when appropriate. */
|
|
||||||
|
Add any global EXTRA_PREREQS here as well. */
|
||||||
|
|
||||||
void
|
void
|
||||||
count_implicit_rule_limits (void)
|
snap_implicit_rules (void)
|
||||||
{
|
{
|
||||||
char *name;
|
char *name = NULL;
|
||||||
size_t namelen;
|
size_t namelen = 0;
|
||||||
struct rule *rule;
|
struct rule *rule;
|
||||||
|
struct dep *dep;
|
||||||
|
struct dep *prereqs = expand_extra_prereqs (lookup_variable (STRING_SIZE_TUPLE(".EXTRA_PREREQS")));
|
||||||
|
unsigned int pre_deps = 0;
|
||||||
|
|
||||||
num_pattern_rules = max_pattern_targets = max_pattern_deps = 0;
|
|
||||||
max_pattern_dep_length = 0;
|
max_pattern_dep_length = 0;
|
||||||
|
|
||||||
name = 0;
|
for (dep = prereqs; dep; dep = dep->next)
|
||||||
namelen = 0;
|
|
||||||
rule = pattern_rules;
|
|
||||||
while (rule != 0)
|
|
||||||
{
|
{
|
||||||
unsigned int ndeps = 0;
|
size_t l = strlen (dep_name (dep));
|
||||||
struct dep *dep;
|
if (l > max_pattern_dep_length)
|
||||||
struct rule *next = rule->next;
|
max_pattern_dep_length = l;
|
||||||
|
++pre_deps;
|
||||||
|
}
|
||||||
|
|
||||||
|
num_pattern_rules = max_pattern_targets = max_pattern_deps = 0;
|
||||||
|
|
||||||
|
for (rule = pattern_rules; rule; rule = rule->next)
|
||||||
|
{
|
||||||
|
unsigned int ndeps = pre_deps;
|
||||||
|
struct dep *lastdep = NULL;
|
||||||
|
|
||||||
++num_pattern_rules;
|
++num_pattern_rules;
|
||||||
|
|
||||||
@@ -99,17 +108,20 @@ count_implicit_rule_limits (void)
|
|||||||
const char *p2;
|
const char *p2;
|
||||||
if (p == 0)
|
if (p == 0)
|
||||||
p = strrchr (dname, ':');
|
p = strrchr (dname, ':');
|
||||||
p2 = p != 0 ? strchr (dname, '%') : 0;
|
p2 = p ? strchr (p, '%') : 0;
|
||||||
#else
|
#else
|
||||||
const char *p = strrchr (dname, '/');
|
const char *p = strrchr (dname, '/');
|
||||||
const char *p2 = p != 0 ? strchr (dname, '%') : 0;
|
const char *p2 = p ? strchr (p, '%') : 0;
|
||||||
#endif
|
#endif
|
||||||
ndeps++;
|
ndeps++;
|
||||||
|
|
||||||
if (len > max_pattern_dep_length)
|
if (len > max_pattern_dep_length)
|
||||||
max_pattern_dep_length = len;
|
max_pattern_dep_length = len;
|
||||||
|
|
||||||
if (p != 0 && p2 > p)
|
if (!dep->next)
|
||||||
|
lastdep = dep;
|
||||||
|
|
||||||
|
if (p2)
|
||||||
{
|
{
|
||||||
/* There is a slash before the % in the dep name.
|
/* There is a slash before the % in the dep name.
|
||||||
Extract the directory name. */
|
Extract the directory name. */
|
||||||
@@ -134,13 +146,20 @@ count_implicit_rule_limits (void)
|
|||||||
dep->changed = 0;
|
dep->changed = 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (prereqs)
|
||||||
|
{
|
||||||
|
if (lastdep)
|
||||||
|
lastdep->next = copy_dep_chain (prereqs);
|
||||||
|
else
|
||||||
|
rule->deps = copy_dep_chain (prereqs);
|
||||||
|
}
|
||||||
|
|
||||||
if (ndeps > max_pattern_deps)
|
if (ndeps > max_pattern_deps)
|
||||||
max_pattern_deps = ndeps;
|
max_pattern_deps = ndeps;
|
||||||
|
|
||||||
rule = next;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
free (name);
|
free (name);
|
||||||
|
free_dep_chain (prereqs);
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Create a pattern rule from a suffix rule.
|
/* Create a pattern rule from a suffix rule.
|
||||||
@@ -253,11 +272,23 @@ convert_to_pattern (void)
|
|||||||
memcpy (rulename + slen, dep_name (d2), s2len + 1);
|
memcpy (rulename + slen, dep_name (d2), s2len + 1);
|
||||||
f = lookup_file (rulename);
|
f = lookup_file (rulename);
|
||||||
|
|
||||||
/* No target, or no commands, or it has deps: it can't be a
|
/* No target, or no commands: it can't be a suffix rule. */
|
||||||
suffix rule. */
|
if (f == 0 || f->cmds == 0)
|
||||||
if (f == 0 || f->cmds == 0 || f->deps != 0)
|
|
||||||
continue;
|
continue;
|
||||||
|
|
||||||
|
/* POSIX says that suffix rules can't have prerequisites.
|
||||||
|
In POSIX mode, don't make this a suffix rule. Previous versions
|
||||||
|
of GNU make did treat this as a suffix rule and ignored the
|
||||||
|
prerequisites, which is bad. In the future we'll do the same as
|
||||||
|
POSIX, but for now preserve the old behavior and warn about it. */
|
||||||
|
if (f->deps != 0)
|
||||||
|
{
|
||||||
|
if (posix_pedantic)
|
||||||
|
continue;
|
||||||
|
error (&f->cmds->fileinfo, 0,
|
||||||
|
_("warning: ignoring prerequisites on suffix rule definition"));
|
||||||
|
}
|
||||||
|
|
||||||
if (s2len == 2 && rulename[slen] == '.' && rulename[slen + 1] == 'a')
|
if (s2len == 2 && rulename[slen] == '.' && rulename[slen + 1] == 'a')
|
||||||
/* A suffix rule '.X.a:' generates the pattern rule '(%.o): %.X'.
|
/* A suffix rule '.X.a:' generates the pattern rule '(%.o): %.X'.
|
||||||
It also generates a normal '%.a: %.X' rule below. */
|
It also generates a normal '%.a: %.X' rule below. */
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
/* Definitions for using pattern rules in GNU Make.
|
/* Definitions for using pattern rules in GNU Make.
|
||||||
Copyright (C) 1988-2019 Free Software Foundation, Inc.
|
Copyright (C) 1988-2020 Free Software Foundation, Inc.
|
||||||
This file is part of GNU Make.
|
This file is part of GNU Make.
|
||||||
|
|
||||||
GNU Make is free software; you can redistribute it and/or modify it under the
|
GNU Make is free software; you can redistribute it and/or modify it under the
|
||||||
@@ -48,7 +48,7 @@ extern size_t max_pattern_dep_length;
|
|||||||
extern struct file *suffix_file;
|
extern struct file *suffix_file;
|
||||||
|
|
||||||
|
|
||||||
void count_implicit_rule_limits (void);
|
void snap_implicit_rules (void);
|
||||||
void convert_to_pattern (void);
|
void convert_to_pattern (void);
|
||||||
void install_pattern_rule (struct pspec *p, int terminal);
|
void install_pattern_rule (struct pspec *p, int terminal);
|
||||||
void create_pattern_rule (const char **targets, const char **target_percents,
|
void create_pattern_rule (const char **targets, const char **target_percents,
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
/* Convert between signal names and numbers.
|
/* Convert between signal names and numbers.
|
||||||
Copyright (C) 1990-2019 Free Software Foundation, Inc.
|
Copyright (C) 1990-2020 Free Software Foundation, Inc.
|
||||||
This file is part of GNU Make.
|
This file is part of GNU Make.
|
||||||
|
|
||||||
GNU Make is free software; you can redistribute it and/or modify it under the
|
GNU Make is free software; you can redistribute it and/or modify it under the
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
/* Constant string caching for GNU Make.
|
/* Constant string caching for GNU Make.
|
||||||
Copyright (C) 2006-2019 Free Software Foundation, Inc.
|
Copyright (C) 2006-2020 Free Software Foundation, Inc.
|
||||||
This file is part of GNU Make.
|
This file is part of GNU Make.
|
||||||
|
|
||||||
GNU Make is free software; you can redistribute it and/or modify it under the
|
GNU Make is free software; you can redistribute it and/or modify it under the
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
/* Internals of variables for GNU Make.
|
/* Internals of variables for GNU Make.
|
||||||
Copyright (C) 1988-2019 Free Software Foundation, Inc.
|
Copyright (C) 1988-2020 Free Software Foundation, Inc.
|
||||||
This file is part of GNU Make.
|
This file is part of GNU Make.
|
||||||
|
|
||||||
GNU Make is free software; you can redistribute it and/or modify it under the
|
GNU Make is free software; you can redistribute it and/or modify it under the
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
/* Definitions for using variables in GNU Make.
|
/* Definitions for using variables in GNU Make.
|
||||||
Copyright (C) 1988-2019 Free Software Foundation, Inc.
|
Copyright (C) 1988-2020 Free Software Foundation, Inc.
|
||||||
This file is part of GNU Make.
|
This file is part of GNU Make.
|
||||||
|
|
||||||
GNU Make is free software; you can redistribute it and/or modify it under the
|
GNU Make is free software; you can redistribute it and/or modify it under the
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
/* Record version and build host architecture for GNU make.
|
/* Record version and build host architecture for GNU make.
|
||||||
Copyright (C) 1988-2019 Free Software Foundation, Inc.
|
Copyright (C) 1988-2020 Free Software Foundation, Inc.
|
||||||
This file is part of GNU Make.
|
This file is part of GNU Make.
|
||||||
|
|
||||||
GNU Make is free software; you can redistribute it and/or modify it under the
|
GNU Make is free software; you can redistribute it and/or modify it under the
|
||||||
|
|||||||
@@ -7,7 +7,7 @@
|
|||||||
* Author: John E. Malmberg
|
* Author: John E. Malmberg
|
||||||
*/
|
*/
|
||||||
|
|
||||||
/* Copyright (C) 2014-2019 Free Software Foundation, Inc.
|
/* Copyright (C) 2014-2020 Free Software Foundation, Inc.
|
||||||
|
|
||||||
GNU Make is free software; you can redistribute it and/or modify it under the
|
GNU Make is free software; you can redistribute it and/or modify it under the
|
||||||
terms of the GNU General Public License as published by the Free Software
|
terms of the GNU General Public License as published by the Free Software
|
||||||
|
|||||||
@@ -4,7 +4,7 @@
|
|||||||
* DCL symbols.
|
* DCL symbols.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
/* Copyright (C) 2014-2019 Free Software Foundation, Inc.
|
/* Copyright (C) 2014-2020 Free Software Foundation, Inc.
|
||||||
|
|
||||||
GNU Make is free software; you can redistribute it and/or modify it under the
|
GNU Make is free software; you can redistribute it and/or modify it under the
|
||||||
terms of the GNU General Public License as published by the Free Software
|
terms of the GNU General Public License as published by the Free Software
|
||||||
|
|||||||
@@ -36,7 +36,7 @@
|
|||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
|
|
||||||
/* Copyright (C) 2014-2019 Free Software Foundation, Inc.
|
/* Copyright (C) 2014-2020 Free Software Foundation, Inc.
|
||||||
|
|
||||||
GNU Make is free software; you can redistribute it and/or modify it under the
|
GNU Make is free software; you can redistribute it and/or modify it under the
|
||||||
terms of the GNU General Public License as published by the Free Software
|
terms of the GNU General Public License as published by the Free Software
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
/* dirent.h for vms
|
/* dirent.h for vms
|
||||||
Copyright (C) 1996-2019 Free Software Foundation, Inc.
|
Copyright (C) 1996-2020 Free Software Foundation, Inc.
|
||||||
This file is part of GNU Make.
|
This file is part of GNU Make.
|
||||||
|
|
||||||
GNU Make is free software; you can redistribute it and/or modify it under the
|
GNU Make is free software; you can redistribute it and/or modify it under the
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
/* VMS functions
|
/* VMS functions
|
||||||
Copyright (C) 1996-2019 Free Software Foundation, Inc.
|
Copyright (C) 1996-2020 Free Software Foundation, Inc.
|
||||||
This file is part of GNU Make.
|
This file is part of GNU Make.
|
||||||
|
|
||||||
GNU Make is free software; you can redistribute it and/or modify it under the
|
GNU Make is free software; you can redistribute it and/or modify it under the
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
/* vmsify.c -- Module for vms <-> unix file name conversion
|
/* vmsify.c -- Module for vms <-> unix file name conversion
|
||||||
Copyright (C) 1996-2019 Free Software Foundation, Inc.
|
Copyright (C) 1996-2020 Free Software Foundation, Inc.
|
||||||
This file is part of GNU Make.
|
This file is part of GNU Make.
|
||||||
|
|
||||||
GNU Make is free software; you can redistribute it and/or modify it under the
|
GNU Make is free software; you can redistribute it and/or modify it under the
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
/* --------------- Moved here from job.c ---------------
|
/* --------------- Moved here from job.c ---------------
|
||||||
This file must be #included in job.c, as it accesses static functions.
|
This file must be #included in job.c, as it accesses static functions.
|
||||||
|
|
||||||
Copyright (C) 1996-2019 Free Software Foundation, Inc.
|
Copyright (C) 1996-2020 Free Software Foundation, Inc.
|
||||||
This file is part of GNU Make.
|
This file is part of GNU Make.
|
||||||
|
|
||||||
GNU Make is free software; you can redistribute it and/or modify it under the
|
GNU Make is free software; you can redistribute it and/or modify it under the
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
/* Implementation of pattern-matching file search paths for GNU Make.
|
/* Implementation of pattern-matching file search paths for GNU Make.
|
||||||
Copyright (C) 1988-2019 Free Software Foundation, Inc.
|
Copyright (C) 1988-2020 Free Software Foundation, Inc.
|
||||||
This file is part of GNU Make.
|
This file is part of GNU Make.
|
||||||
|
|
||||||
GNU Make is free software; you can redistribute it and/or modify it under the
|
GNU Make is free software; you can redistribute it and/or modify it under the
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
/* Directory entry code for Window platforms.
|
/* Directory entry code for Window platforms.
|
||||||
Copyright (C) 1996-2019 Free Software Foundation, Inc.
|
Copyright (C) 1996-2020 Free Software Foundation, Inc.
|
||||||
This file is part of GNU Make.
|
This file is part of GNU Make.
|
||||||
|
|
||||||
GNU Make is free software; you can redistribute it and/or modify it under the
|
GNU Make is free software; you can redistribute it and/or modify it under the
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
/* Replacements for Posix functions and Posix functionality for MS-Windows.
|
/* Replacements for Posix functions and Posix functionality for MS-Windows.
|
||||||
|
|
||||||
Copyright (C) 2013-2019 Free Software Foundation, Inc.
|
Copyright (C) 2013-2020 Free Software Foundation, Inc.
|
||||||
This file is part of GNU Make.
|
This file is part of GNU Make.
|
||||||
|
|
||||||
GNU Make is free software; you can redistribute it and/or modify it under the
|
GNU Make is free software; you can redistribute it and/or modify it under the
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
/* Windows version of dirent.h
|
/* Windows version of dirent.h
|
||||||
Copyright (C) 1996-2019 Free Software Foundation, Inc.
|
Copyright (C) 1996-2020 Free Software Foundation, Inc.
|
||||||
This file is part of GNU Make.
|
This file is part of GNU Make.
|
||||||
|
|
||||||
GNU Make is free software; you can redistribute it and/or modify it under the
|
GNU Make is free software; you can redistribute it and/or modify it under the
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
/* dlfcn.h replacement for MS-Windows build.
|
/* dlfcn.h replacement for MS-Windows build.
|
||||||
Copyright (C) 2013-2019 Free Software Foundation, Inc.
|
Copyright (C) 2013-2020 Free Software Foundation, Inc.
|
||||||
This file is part of GNU Make.
|
This file is part of GNU Make.
|
||||||
|
|
||||||
GNU Make is free software; you can redistribute it and/or modify it under the
|
GNU Make is free software; you can redistribute it and/or modify it under the
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
/* Definitions for Windows path manipulation.
|
/* Definitions for Windows path manipulation.
|
||||||
Copyright (C) 1996-2019 Free Software Foundation, Inc.
|
Copyright (C) 1996-2020 Free Software Foundation, Inc.
|
||||||
This file is part of GNU Make.
|
This file is part of GNU Make.
|
||||||
|
|
||||||
GNU Make is free software; you can redistribute it and/or modify it under the
|
GNU Make is free software; you can redistribute it and/or modify it under the
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
/* Definitions for Windows process invocation.
|
/* Definitions for Windows process invocation.
|
||||||
Copyright (C) 1996-2019 Free Software Foundation, Inc.
|
Copyright (C) 1996-2020 Free Software Foundation, Inc.
|
||||||
This file is part of GNU Make.
|
This file is part of GNU Make.
|
||||||
|
|
||||||
GNU Make is free software; you can redistribute it and/or modify it under the
|
GNU Make is free software; you can redistribute it and/or modify it under the
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
/* Definitions for Windows error handling.
|
/* Definitions for Windows error handling.
|
||||||
Copyright (C) 1996-2019 Free Software Foundation, Inc.
|
Copyright (C) 1996-2020 Free Software Foundation, Inc.
|
||||||
This file is part of GNU Make.
|
This file is part of GNU Make.
|
||||||
|
|
||||||
GNU Make is free software; you can redistribute it and/or modify it under the
|
GNU Make is free software; you can redistribute it and/or modify it under the
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
/* Path conversion for Windows pathnames.
|
/* Path conversion for Windows pathnames.
|
||||||
Copyright (C) 1996-2019 Free Software Foundation, Inc.
|
Copyright (C) 1996-2020 Free Software Foundation, Inc.
|
||||||
This file is part of GNU Make.
|
This file is part of GNU Make.
|
||||||
|
|
||||||
GNU Make is free software; you can redistribute it and/or modify it under the
|
GNU Make is free software; you can redistribute it and/or modify it under the
|
||||||
|
|||||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user