Remove template files to simplify distribution creation

The README templates were not useful since the replacement step
didn't have anything to replace: rename them.

Rather than creating template files for the config variants, create
mkconfig.h.in containg PACKAGE_* variables to be replaced, and have
config variant header files include it.  Note on POSIX we don't use
this, and continue to generate a single config.h.in file.

Use config.status to convert the README.in and mkconfig.h.in files
during distribution creation.

Modify all users of VERSION to use PACKAGE_VERSION instead.

* configure.ac: Use GNU Make not GNU make as the package name.
* README.in: Use GNU Make not GNU make.
* README.git: Remove references to README.W32.template.
* .gitignore: Update for new behavior.
* Basic.mk.template: Remove unused posix_SOURCES and VERSION, and
references to unshipped mk/Posix.mk
* Makefile.am: Add src/mkconfig.h as an extra dist file.
* bootstrap.bat: Rewrite mkconfig.h.in to mkconfig.h
* maintMakefile: Remove obsolete template files; add mkconfig.h.in.
* prepare_vms.com: Rewrite mkconfig.h.in to mkconfig.h
* mk/VMS.mk: Fix incorrect header file prerequisite.
* src/mkconfig.h.in: New file containing PACKAGE variables.
* src/config.ami: Include mkconfig.h.
* src/config.h.W32: Ditto.
* src/configh.dos: Ditto.
* src/config.h-vms: Ditto.
* src/version.c: Use PACKAGE_VERSION not VERSION.
This commit is contained in:
Paul Smith 2022-10-16 15:13:41 -04:00
parent b16913a67e
commit 2d943d3d2e
20 changed files with 146 additions and 170 deletions

10
.gitignore vendored
View File

@ -34,7 +34,7 @@ config.log
config.status config.status
configure configure
/mk/Posix.mk /mk/Posix.mk
stamp-h1 stamp-*
.dirstamp .dirstamp
gnulib gnulib
convert.sed convert.sed
@ -65,14 +65,8 @@ GccRel/
.check-git-HEAD .check-git-HEAD
ChangeLog ChangeLog
README README
README.DOS
README.OS2
README.W32
build.cfg build.cfg
config.ami mkconfig.h
config.h-vms
config.h.W32
configh.dos
make-[0-9]*/ make-[0-9]*/
make-[0-9]*.tar.* make-[0-9]*.tar.*
checkcfg.*.log checkcfg.*.log

View File

@ -39,7 +39,6 @@ w32_SOURCES = %w32_SOURCES%
vms_SOURCES = %vms_SOURCES% vms_SOURCES = %vms_SOURCES%
amiga_SOURCES = %amiga_SOURCES% amiga_SOURCES = %amiga_SOURCES%
posix_SOURCES = $(src)posixos.c
remote_SOURCES = $(src)remote-stub.c remote_SOURCES = $(src)remote-stub.c
OUTDIR = OUTDIR =
@ -104,9 +103,7 @@ CP.cmd = cp $1 $2
CLEANSPACE = $(call RM.cmd,$(OBJECTS) $(PROG) $(BUILT_SOURCES)) CLEANSPACE = $(call RM.cmd,$(OBJECTS) $(PROG) $(BUILT_SOURCES))
# Load overrides for the above variables. # Load overrides for the above variables.
include $(firstword $(wildcard $(SRCDIR)/mk/$(lastword $(subst -, ,$(MAKE_HOST)).mk) $(OUTDIR)mk/Posix.mk $(SRCDIR)/mk/Posix.mk)) include $(firstword $(wildcard $(SRCDIR)/mk/$(lastword $(subst -, ,$(MAKE_HOST)).mk)))
VERSION = %VERSION%
VPATH = $(SRCDIR) VPATH = $(SRCDIR)

View File

@ -112,7 +112,7 @@ test_FILES = tests/run_make_tests tests/run_make_tests.bat \
# test/scripts are added via dist-hook below. # test/scripts are added via dist-hook below.
EXTRA_DIST = ChangeLog INSTALL README build.sh build.cfg.in $(man_MANS) \ EXTRA_DIST = ChangeLog INSTALL README build.sh build.cfg.in $(man_MANS) \
README.customs README.OS2 \ src/mkconfig.h README.customs README.OS2 \
README.Amiga SCOPTIONS src/config.ami \ README.Amiga SCOPTIONS src/config.ami \
README.DOS builddos.bat src/configh.dos \ README.DOS builddos.bat src/configh.dos \
README.W32 build_w32.bat src/config.h.W32 \ README.W32 build_w32.bat src/config.h.W32 \
@ -144,7 +144,7 @@ dist-hook:
# --------------- Local CHECK Section # --------------- Local CHECK Section
check-local: check-regression check-local: check-regression
@banner=" Regression PASSED: GNU Make $(VERSION) ($(MAKE_HOST)) built with $(CC) "; \ @banner=" Regression PASSED: $(PACKAGE_STRING) ($(MAKE_HOST)) built with $(CC) "; \
dashes=`echo "$$banner" | sed s/./=/g`; \ dashes=`echo "$$banner" | sed s/./=/g`; \
echo; \ echo; \
echo "$$dashes"; \ echo "$$dashes"; \
@ -182,7 +182,7 @@ check-regression: tests/config-flags.pm
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; \
else \ else \
echo "Can't find the GNU Make test suite ($(top_srcdir)/tests)."; \ echo "Can't find the $(PACKAGE_NAME) test suite ($(top_srcdir)/tests)."; \
fi fi

View File

@ -163,17 +163,16 @@ NOTE! This method builds GNU make in "maintainer mode". Make programs built
Building From Git for Windows Building From Git for Windows
----------------------------- -----------------------------
If you have a UNIX emulation like CYGWIN you can opt to run the general If you have a UNIX emulation like CYGWIN you can opt to run the general build
build procedure above; it will work. Consult README.W32.template for procedure above; it will work. Consult README.W32 for information on options
information on options you might want to use when running ./configure. you might want to use when running ./configure.
If you can't or don't want to do that, then first run the .\bootstrap.bat If you can't or don't want to do that, then first run the .\bootstrap.bat
script to prime your Git workspace: script to "prime" your Git workspace:
> .\bootstrap.bat > .\bootstrap.bat
Next, rename the file README.W32.template to README.W32 and follow those Next, follow the instructions in the README.W32 file.
instructions.
Note, neither of these methods are tested regularly by the GNU make Note, neither of these methods are tested regularly by the GNU make
maintainers. Building for Windows from a distribution tarball IS tested maintainers. Building for Windows from a distribution tarball IS tested

View File

@ -1,4 +1,4 @@
This directory contains the %VERSION% release of GNU Make. This directory contains the @PACKAGE_VERSION@ release of @PACKAGE_NAME@.
See the file NEWS for the user-visible changes from previous releases. See the file NEWS for the user-visible changes from previous releases.
In addition, there have been bugs fixed. In addition, there have been bugs fixed.
@ -6,7 +6,7 @@ In addition, there have been bugs fixed.
Please check the system-specific notes below for any caveats related to your Please check the system-specific notes below for any caveats related to your
operating system. operating system.
If you are trying to build GNU make from a Git clone rather than a downloaded If you are trying to build GNU Make from a Git clone rather than a downloaded
source distribution, see the README.git file for instructions. source distribution, see the README.git file for instructions.
For source distribution building and installation instructions, see the file For source distribution building and installation instructions, see the file
@ -15,12 +15,12 @@ INSTALL.
If you need to build GNU Make and have no other 'make' program to use, you can If you need to build GNU Make and have no other 'make' program to use, you can
use the shell script 'build.sh' instead. To do this, first run 'configure' as use the shell script 'build.sh' instead. To do this, first run 'configure' as
described in INSTALL. Then, instead of typing 'make' to build the program, described in INSTALL. Then, instead of typing 'make' to build the program,
type 'sh build.sh'. This should compile the program in the current directory. type 'sh build.sh'. This will compile the program in the current directory.
Then you will have a Make program that you can use for './make install', or Then you will have a 'make' program that you can use for './make install', or
whatever else. whatever else.
Some systems' Make programs cannot process the Makefile for GNU Make. If you Some systems' 'make' programs cannot process the Makefile for GNU Make.
get errors from your system's Make when building GNU Make, try using If you get errors from your system's 'make' when building GNU Make, try using
'build.sh' instead. 'build.sh' instead.
@ -40,10 +40,10 @@ GNU Make can be obtained in many different ways. See a description here:
Documentation Documentation
------------- -------------
GNU make is fully documented in the GNU Make manual, which is contained GNU Make is fully documented in the GNU Make manual, which is contained in
in this distribution as the file make.texinfo. You can also find this distribution as the file make.texi. You can also find on-line and
on-line and preformatted (PostScript and DVI) versions at the FSF's web preformatted (PostScript and DVI) versions at the FSF's web site. There is
site. There is information there about ordering hardcopy documentation. information there about ordering hardcopy documentation.
https://www.gnu.org/ https://www.gnu.org/
https://www.gnu.org/doc/doc.html https://www.gnu.org/doc/doc.html
@ -69,27 +69,27 @@ this site.
Bug Reporting Bug Reporting
------------- -------------
You can send GNU make bug reports to <bug-make@gnu.org>. Please see the If you need help using GNU Make, try asking on <help-make@gnu.org>.
section of the GNU make manual entitled 'Problems and Bugs' for
information on submitting useful and complete bug reports. If you found a bug, you can send a bug reports to <bug-make@gnu.org>.
Please see the section of the GNU Make manual entitled 'Problems and Bugs'
for information on submitting useful and complete bug reports.
You do not need to subscribe to these lists first.
You can also use the online bug tracking system in the Savannah GNU Make You can also use the online bug tracking system in the Savannah GNU Make
project to submit new problem reports or search for existing ones: project to submit new problem reports or search for existing ones:
https://savannah.gnu.org/bugs/?group=make https://savannah.gnu.org/bugs/?group=make
If you need help using GNU make, try these forums: We prefer to use the bug tracking system ONLY for bugs or enhancements,
not for help requests: please use the mailing lists to get help.
help-make@gnu.org
help-utils@gnu.org
news:gnu.utils.help
news:gnu.utils.bug
Submitting Patches Submitting Patches
------------------ ------------------
If you'd like to propose a change to GNU make, you can provide a patch with If you'd like to propose a change to GNU Make, you can provide a patch with
your changes. If you are making your changes in a Git workspace you can run your changes. If you are making your changes in a Git workspace you can run
"git format-patch" to create a patch file. If not, you can use the diff(1) "git format-patch" to create a patch file. If not, you can use the diff(1)
utility to create a patch file; please use "diff -u". utility to create a patch file; please use "diff -u".
@ -102,24 +102,23 @@ Once you have a patch you can submit it in any of these ways:
* Send the patch via email to <bug-make@gnu.org>: be sure to add it as an * Send the patch via email to <bug-make@gnu.org>: be sure to add it as an
attachment to avoid interference by email processors. attachment to avoid interference by email processors.
Be aware that all non-trivial changes proposed for GNU make require FSF All non-trivial changes require FSF copyright paperwork to be completed
copyright paperwork to be completed before they can be accepted. Contact before they can be accepted. Contact <bug-make@gnu.org> for help.
<bug-make@gnu.org> for help.
Git Access Git Access
---------- ----------
The GNU make source repository is available via Git from the GNU Savannah Git The GNU Make source repository is available via Git from the GNU Savannah Git
server; look here for details: server; look here for details:
https://savannah.gnu.org/git/?group=make https://savannah.gnu.org/git/?group=make
Please note: you won't be able to build GNU make from Git without installing Please note: you won't be able to build GNU Make from Git without installing
appropriate maintainer's tools, such as GNU m4, automake, autoconf, Perl, GNU appropriate maintainer's tools, such as GNU m4, automake, autoconf, Perl, GNU
make, and GCC. make, and GCC.
See the README.git file for instructions on how to build GNU make once these See the README.git file for instructions on how to build GNU Make once these
tools are available. We make no guarantees about the contents or quality of tools are available. We make no guarantees about the contents or quality of
the latest code in the Git repository: it is not unheard of for code that is the latest code in the Git repository: it is not unheard of for code that is
known to be broken to be checked in. Use at your own risk. known to be broken to be checked in. Use at your own risk.
@ -133,7 +132,7 @@ that if you compile make with 'cc -O' on AIX 3.2, it will not work
correctly. It is said that using 'cc' without '-O' does work. correctly. It is said that using 'cc' without '-O' does work.
The standard /bin/sh on SunOS 4.1.3_U1 and 4.1.4 is broken and cannot be The standard /bin/sh on SunOS 4.1.3_U1 and 4.1.4 is broken and cannot be
used to configure GNU make. Please install a different shell such as used to configure GNU Make. Please install a different shell such as
bash or pdksh in order to run "configure". See this message for more bash or pdksh in order to run "configure". See this message for more
information: information:
https://mail.gnu.org/archive/html/bug-autoconf/2003-10/msg00190.html https://mail.gnu.org/archive/html/bug-autoconf/2003-10/msg00190.html
@ -142,7 +141,7 @@ One area that is often a problem in configuration and porting is the code
to check the system's current load average. To make it easier to test and to check the system's current load average. To make it easier to test and
debug this code, you can do 'make check-loadavg' to see if it works debug this code, you can do 'make check-loadavg' to see if it works
properly on your system. (You must run 'configure' beforehand, but you properly on your system. (You must run 'configure' beforehand, but you
need not build Make itself to run this test.) need not build 'make' itself to run this test.)
Another potential source of porting problems is the support for large Another potential source of porting problems is the support for large
files (LFS) in configure for those operating systems that provide it. files (LFS) in configure for those operating systems that provide it.
@ -151,7 +150,7 @@ difficulties, then as a workaround you should be able to disable LFS by
adding the '--disable-largefile' option to the 'configure' script. adding the '--disable-largefile' option to the 'configure' script.
On systems that support micro- and nano-second timestamp values and On systems that support micro- and nano-second timestamp values and
where stat(2) provides this information, GNU make will use it when where stat(2) provides this information, GNU Make will use it when
comparing timestamps to get the most accurate possible result. However, comparing timestamps to get the most accurate possible result. However,
note that many current implementations of tools that *set* timestamps do note that many current implementations of tools that *set* timestamps do
not preserve micro- or nano-second granularity. This means that "cp -p" not preserve micro- or nano-second granularity. This means that "cp -p"
@ -165,7 +164,7 @@ force make to treat them properly. See the manual for details.
Ports Ports
----- -----
- See README.customs for details on integrating GNU make with the - See README.customs for details on integrating GNU Make with the
Customs distributed build environment from the Pmake distribution. Customs distributed build environment from the Pmake distribution.
- See README.VMS for details about GNU Make on OpenVMS. - See README.VMS for details about GNU Make on OpenVMS.
@ -181,12 +180,12 @@ Ports
of DJGPP; see the WWW page https://www.delorie.com/djgpp/ for more of DJGPP; see the WWW page https://www.delorie.com/djgpp/ for more
information. information.
The Cygwin project maintains its own port of GNU make. That port may have The Cygwin project maintains its own port of GNU Make. That port may have
patches which are not present in this version. If you are using Cygwin patches which are not present in this version. If you are using Cygwin
you should use their version of GNU make, and if you have questions about you should use their version of GNU Make, and if you have questions about
it you should start by asking on those mailing lists and forums. it you should start by asking on those mailing lists and forums.
Please note there are two _separate_ ports of GNU make for Microsoft Please note there are two _separate_ ports of GNU Make for Microsoft
systems: a native Windows tool built with (for example) MSVC or Cygwin, systems: a native Windows tool built with (for example) MSVC or Cygwin,
and a DOS-based tool built with DJGPP. Please be sure you are looking and a DOS-based tool built with DJGPP. Please be sure you are looking
at the right README! at the right README!

View File

@ -47,23 +47,30 @@ copy /Y gl\lib\*.* lib > nul
:: Create a sed script to convert templates :: Create a sed script to convert templates
if exist convert.sed del /Q convert.sed if exist convert.sed del /Q convert.sed
echo s,%%PACKAGE%%,make,g > convert.sed echo s,@PACKAGE@,make,g > convert.sed
if ERRORLEVEL 1 goto Failed if ERRORLEVEL 1 goto Failed
sed -n "s/^AC_INIT(\[GNU.make\],\[\([0-9.]*\)\].*/s,%%VERSION%%,\1,g/p" configure.ac >> convert.sed echo s,@PACKAGE_BUGREPORT@,bug-make@gnu.org,g >> convert.sed
if ERRORLEVEL 1 goto Failed
echo s,@PACKAGE_NAME@,GNU Make,g >> convert.sed
if ERRORLEVEL 1 goto Failed
echo s,@PACKAGE_TARNAME@,make,g >> convert.sed
if ERRORLEVEL 1 goto Failed
echo s,@PACKAGE_URL@,https://www.gnu.org/software/make/,g >> convert.sed
sed -n "s/^AC_INIT(\[GNU.Make\],\[\([0-9.]*\)\].*/s,@PACKAGE_VERSION@,\1,g/p" configure.ac >> convert.sed
if ERRORLEVEL 1 goto Failed if ERRORLEVEL 1 goto Failed
sed -z -e s/\\\n//g -e "s/[ \t][ \t]*/ /g" -e "s, [^ ]*\.h,,g" -e "s,src/,$(src),g" -e "s,lib/,$(lib),g" Makefile.am | sed -n "s/^\([A-Za-z0-9]*\)_SRCS *= *\(.*\)/s,%%\1_SOURCES%%,\2,/p" >> convert.sed sed -z -e s/\\\n//g -e "s/[ \t][ \t]*/ /g" -e "s, [^ ]*\.h,,g" -e "s,src/,$(src),g" -e "s,lib/,$(lib),g" Makefile.am | sed -n "s/^\([A-Za-z0-9]*\)_SRCS *= *\(.*\)/s,%%\1_SOURCES%%,\2,/p" >> convert.sed
if ERRORLEVEL 1 goto Failed if ERRORLEVEL 1 goto Failed
echo - Creating Basic.mk echo - Creating Basic.mk
call sed -f convert.sed Basic.mk.template > Basic.mk sed -f convert.sed Basic.mk.template > Basic.mk
if ERRORLEVEL 1 goto Failed if ERRORLEVEL 1 goto Failed
echo - Creating src\config.h.W32 echo - Creating src\mkconfig.h
call sed -f convert.sed src\config.h.W32.template > src\config.h.W32 sed -f convert.sed src\mkconfig.h.in > src\mkconfig.h
if ERRORLEVEL 1 goto Failed if ERRORLEVEL 1 goto Failed
echo - Creating src\gmk-default.h echo - Creating src\gmk-default.h
echo static const char *const GUILE_module_defn = ^" \ > src\gmk-default.h echo static const char *const GUILE_module_defn = ^" \ > src\gmk-default.h
call sed -e "s/;.*//" -e "/^[ \t]*$/d" -e "s/\"/\\\\\"/g" -e "s/$/ \\\/" src\gmk-default.scm >> src\gmk-default.h sed -e "s/;.*//" -e "/^[ \t]*$/d" -e "s/\"/\\\\\"/g" -e "s/$/ \\\/" src\gmk-default.scm >> src\gmk-default.h
if ERRORLEVEL 1 goto Failed if ERRORLEVEL 1 goto Failed
echo ^";>> src\gmk-default.h echo ^";>> src\gmk-default.h

View File

@ -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.3.91],[bug-make@gnu.org]) AC_INIT([GNU Make],[4.3.91],[bug-make@gnu.org])
AC_PREREQ([2.69]) AC_PREREQ([2.69])
@ -509,8 +509,8 @@ AM_CONDITIONAL([KNOWN_PREFIX],
-o "x$prefix" = x/usr/gnu -o "x$prefix" = x/usr]) -o "x$prefix" = x/usr/gnu -o "x$prefix" = x/usr])
# Specify what files are to be created. # Specify what files are to be created.
AC_CONFIG_FILES([Makefile build.cfg lib/Makefile po/Makefile.in doc/Makefile \ AC_CONFIG_FILES([build.cfg tests/config-flags.pm \
tests/config-flags.pm]) Makefile lib/Makefile doc/Makefile po/Makefile.in])
# We don't need this: the standard automake output suffices for POSIX systems. # We don't need this: the standard automake output suffices for POSIX systems.
#mk/Posix.mk #mk/Posix.mk

View File

@ -43,31 +43,28 @@ GUILE_CFLAGS := $(patsubst -I%,-isystem %,$(GUILE_CFLAGS))
MAKE_MAINTAINER_MODE := -DMAKE_MAINTAINER_MODE MAKE_MAINTAINER_MODE := -DMAKE_MAINTAINER_MODE
AM_CPPFLAGS += $(MAKE_MAINTAINER_MODE) AM_CPPFLAGS += $(MAKE_MAINTAINER_MODE)
TEMPLATES = README README.DOS README.W32 README.OS2 \
src/config.ami src/configh.dos src/config.h.W32 src/config.h-vms
all: $(TEMPLATES)
# Create preprocessor output files--GCC specific! # Create preprocessor output files--GCC specific!
%.i : %.c %.i : %.c
$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) -E -dD -o $@ $< $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) -E -dD -o $@ $<
# General rule for turning a .template into a regular file. # Create the mkconfig.h file for non-POSIX config headers
#
$(TEMPLATES) : % : %.template Makefile all: src/mkconfig.h
rm -f $@ src/mkconfig.h: src/mkconfig.h.in config.status
sed -e 's@%VERSION%@$(VERSION)@g' \ ./config.status --header=$@
-e 's@%PACKAGE%@$(PACKAGE)@g' \
$< > $@ # Build the README
chmod a-w $@
all: README
README : README.in config.status
./config.status --file=$@
# Construct Makefiles by adding on dependencies, etc. # Construct Makefiles by adding on dependencies, etc.
# #
cvt = $(patsubst $1/%,$$($1)%,$(filter %.c,$2)) cvt = $(patsubst $1/%,$$($1)%,$(filter %.c,$2))
Basic.mk: Basic.mk.template .dep_segment Makefile Basic.mk: Basic.mk.template .dep_segment Makefile
rm -f $@ rm -f $@
sed -e 's@%VERSION%@$(VERSION)@g' \ sed -e 's@%make_SOURCES%@$(call cvt,src,$(make_SRCS))@g' \
-e 's@%make_SOURCES%@$(call cvt,src,$(make_SRCS))@g' \
-e 's@%w32_SOURCES%@$(call cvt,src,$(w32_SRCS))@g' \ -e 's@%w32_SOURCES%@$(call cvt,src,$(w32_SRCS))@g' \
-e 's@%vms_SOURCES%@$(call cvt,src,$(vms_SRCS))@g' \ -e 's@%vms_SOURCES%@$(call cvt,src,$(vms_SRCS))@g' \
-e 's@%amiga_SOURCES%@$(call cvt,src,$(amiga_SRCS))@g' \ -e 's@%amiga_SOURCES%@$(call cvt,src,$(amiga_SRCS))@g' \
@ -76,6 +73,7 @@ Basic.mk: Basic.mk.template .dep_segment Makefile
-e 's@%glob_SOURCES%@$(call cvt,lib,$(glob_SRCS))@g' \ -e 's@%glob_SOURCES%@$(call cvt,lib,$(glob_SRCS))@g' \
$< > $@ $< > $@
echo >>$@; echo '# --------------- DEPENDENCIES' >>$@; echo '#' >>$@; \ echo >>$@; echo '# --------------- DEPENDENCIES' >>$@; echo '#' >>$@; \
echo >>$@; echo '$$(OBJECTS): $$(SRCDIR)/src/mkconfig.h' >>$@; \
sed -e 's@^\([^ ]*\)\.o:@$$(OUTDIR)\1.$$(OBJEXT):@' \ sed -e 's@^\([^ ]*\)\.o:@$$(OUTDIR)\1.$$(OBJEXT):@' \
-e 's@\([^ ]*\.[ch]\)@$$(SRCDIR)/\1@g' \ -e 's@\([^ ]*\.[ch]\)@$$(SRCDIR)/\1@g' \
-e 's@$$(SRCDIR)/src/config.h@$$(OUTDIR)src/config.h@g' \ -e 's@$$(SRCDIR)/src/config.h@$$(OUTDIR)src/config.h@g' \
@ -176,7 +174,7 @@ po_sync = translationproject.org::tp/latest/$(PACKAGE)/
.PHONY: do-po-update po-update .PHONY: do-po-update po-update
do-po-update: do-po-update:
tmppo="/tmp/po-$(PACKAGE)-$(VERSION).$$$$" \ tmppo="/tmp/po-$(PACKAGE)-$(PACKAGE_VERSION).$$$$" \
&& rm -rf "$$tmppo" \ && rm -rf "$$tmppo" \
&& mkdir "$$tmppo" \ && mkdir "$$tmppo" \
&& $(RSYNC) $(po_sync) "$$tmppo" \ && $(RSYNC) $(po_sync) "$$tmppo" \
@ -238,7 +236,7 @@ export TAR_OPTIONS := --mode=u+w,go-w --owner=0 --group=0 --numeric-owner --sort
# When I released 4.3 somehow the INSTALL file was missing. # When I released 4.3 somehow the INSTALL file was missing.
# When I tried to build it again, it was there. I have no idea what happened # When I tried to build it again, it was there. I have no idea what happened
# but add a new check to be sure it doesn't happen again. # but add a new check to be sure it doesn't happen again.
mk_dist_files = AUTHORS ChangeLog COPYING INSTALL README mk_dist_files = AUTHORS ChangeLog COPYING INSTALL README src/mkconfig.h
dist: mk-distcheck dist: mk-distcheck
@ -363,10 +361,10 @@ local-check: po-check changelog-check
# copyright-check writable-files # copyright-check writable-files
changelog-check: changelog-check:
if head $(top_srcdir)/ChangeLog | grep 'Version $(VERSION)' >/dev/null; then \ if head $(top_srcdir)/ChangeLog | grep 'Version $(PACKAGE_VERSION)' >/dev/null; then \
:; \ :; \
else \ else \
echo "$(VERSION) not in ChangeLog" 1>&2; \ echo "$(PACKAGE_VERSION) not in ChangeLog" 1>&2; \
exit 1; \ exit 1; \
fi fi
@ -413,7 +411,7 @@ gendocs: update-gnuweb update-makeweb
cd doc \ cd doc \
&& rm -rf doc/manual \ && rm -rf doc/manual \
&& $(GNULIBDIR)/build-aux/gendocs.sh --email '$(BUGLIST)' \ && $(GNULIBDIR)/build-aux/gendocs.sh --email '$(BUGLIST)' \
make 'GNU Make Manual' make '$(PACKAGE_NAME) Manual'
find '$(MAKEWEBDIR)'/manual \( -name CVS -prune \) -o \( -name '[!.]*' -type f -exec rm -f '{}' \; \) find '$(MAKEWEBDIR)'/manual \( -name CVS -prune \) -o \( -name '[!.]*' -type f -exec rm -f '{}' \; \)
cp -r doc/manual '$(MAKEWEBDIR)' cp -r doc/manual '$(MAKEWEBDIR)'
@echo 'Status of $(MAKEWEBDIR) repo:' && cd '$(MAKEWEBDIR)' \ @echo 'Status of $(MAKEWEBDIR) repo:' && cd '$(MAKEWEBDIR)' \
@ -421,7 +419,7 @@ gendocs: update-gnuweb update-makeweb
@echo '- cvs add <new files>' \ @echo '- cvs add <new files>' \
&& echo '- cvs remove <deleted files>' \ && echo '- cvs remove <deleted files>' \
&& echo '- cvs commit' \ && echo '- cvs commit' \
&& echo '- cvs tag make-$(subst .,-,$(VERSION))' && echo '- cvs tag make-$(subst .,-,$(PACKAGE_VERSION))'
## --------------------------------------------- ## ## --------------------------------------------- ##
@ -459,15 +457,15 @@ $(COV_BUILD_FILE)-submitted: $(COV_BUILD_FILE)
@test -n "$(COVERITY_TOKEN)" || { echo 'COVERITY_TOKEN not set'; exit 1; } @test -n "$(COVERITY_TOKEN)" || { echo 'COVERITY_TOKEN not set'; exit 1; }
@test -n "$(COVERITY_EMAIL)" || { echo 'COVERITY_EMAIL not set'; exit 1; } @test -n "$(COVERITY_EMAIL)" || { echo 'COVERITY_EMAIL not set'; exit 1; }
rm -f '$@' rm -f '$@'
case '$(VERSION)' in \ case '$(PACKAGE_VERSION)' in \
(*.*.9*) type="daily build"; ext=".$$(date +%Y%m%d)" ;; \ (*.*.9*) type="daily build"; ext=".$$(date +%Y%m%d)" ;; \
(*) type="release"; ext= ;; \ (*) type="release"; ext= ;; \
esac; \ esac; \
curl --form token='$(COVERITY_TOKEN)' \ curl --form token='$(COVERITY_TOKEN)' \
--form email='$(COVERITY_EMAIL)' \ --form email='$(COVERITY_EMAIL)' \
--form file='@$<' \ --form file='@$<' \
--form version="$(VERSION)$$ext" \ --form version="$(PACKAGE_VERSION)$$ext" \
--form description="GNU make $$type" \ --form description="$(PACKAGE_NAME) $$type" \
'https://scan.coverity.com/builds?project=gmake' 'https://scan.coverity.com/builds?project=gmake'
cp '$<' '$@' cp '$<' '$@'
@ -478,11 +476,11 @@ $(COV_BUILD_FILE)-submitted: $(COV_BUILD_FILE)
.PHONY: tag-release .PHONY: tag-release
tag-release: tag-release:
case '$(VERSION)' in \ case '$(PACKAGE_VERSION)' in \
(*.*.9*) message=" candidate" ;; \ (*.*.9*) message=" candidate" ;; \
(*) message= ;; \ (*) message= ;; \
esac; \ esac; \
$(GIT) tag -m "GNU Make release$$message $(VERSION)" -u '$(GPG_KEYID)' '$(VERSION)' $(GIT) tag -m "$(PACKAGE_NAME) release$$message $(PACKAGE_VERSION)" -u '$(GPG_KEYID)' '$(PACKAGE_VERSION)'
## ------------------------- ## ## ------------------------- ##
@ -513,7 +511,7 @@ distsign: $(DIST_ARCHIVES_SIG) $(DIST_ARCHIVES_DIRECTIVE)
echo 'version: 1.2'; \ echo 'version: 1.2'; \
echo 'directory: make'; \ echo 'directory: make'; \
echo 'filename: $*'; \ echo 'filename: $*'; \
echo 'comment: Official upload of GNU make version $(VERSION)'; \ echo 'comment: Official upload of $(PACKAGE_NAME) version $(PACKAGE_VERSION)'; \
) > "$*.directive" ) > "$*.directive"
$(GPG) $(GPGFLAGS) -o "$@" --clearsign "$*.directive" $(GPG) $(GPGFLAGS) -o "$@" --clearsign "$*.directive"
@rm -f "$*.directive" @rm -f "$*.directive"

View File

@ -20,7 +20,7 @@
# Very little is needed here since the default Basic.mk assumes POSIX # Very little is needed here since the default Basic.mk assumes POSIX
prog_SOURCES += $(posix_SOURCES) prog_SOURCES += $(src)/posixos.c
extra_CPPFLAGS += @GUILE_CFLAGS@ extra_CPPFLAGS += @GUILE_CFLAGS@
extra_LDFLAGS += @AM_LDFLAGS@ extra_LDFLAGS += @AM_LDFLAGS@

View File

@ -93,5 +93,5 @@ define CLEANSPACE
endef endef
$(OUTDIR)$(src)config.h: $(SRCDIR)$(src)config.h.W32 $(OUTDIR)$(src)config.h: $(SRCDIR)$(src)config.h-vms
$(call CP.cmd,$<,$@) $(call CP.cmd,$<,$@)

View File

@ -4,28 +4,27 @@ $!
$! This is used for building off the master instead of a release tarball. $! This is used for building off the master instead of a release tarball.
$! $!
$! $!
$!
$! First try ODS-5, Pathworks V6 or UNZIP name. $! First try ODS-5, Pathworks V6 or UNZIP name.
$! $!
$ config_template = f$search("sys$disk:[]config*h-vms.template") $ config_template = f$search("sys$disk:[.src]mkconfig*h.in")
$ if config_template .eqs. "" $ if config_template .eqs. ""
$ then $ then
$! $!
$! Try NFS, VMStar, or Pathworks V5 ODS-2 encoded name. $! Try NFS, VMStar, or Pathworks V5 ODS-2 encoded name.
$! $!
$ config_template = f$search("sys$disk:[]config.h-vms*template") $ config_template = f$search("sys$disk:[.src]mkconfig.h*in")
$ if config_template .eqs. "" $ if config_template .eqs. ""
$ then $ then
$ write sys$output "Could not find config.h-vms*template!" $ write sys$output "Could not find mkconfig.h.in!"
$ exit 44 $ exit 44
$ endif $ endif
$ endif $ endif
$ config_template_file = f$parse(config_template,,,"name") $ config_template_file = f$parse(config_template,,,"name")
$ config_template_type = f$parse(config_template,,,"type") $ config_template_type = f$parse(config_template,,,"type")
$ config_template = "sys$disk:[]" + config_template_file + config_template_type $ config_template = "sys$disk:[.src]" + config_template_file + config_template_type
$! $!
$! $!
$! Pull the package and version from configure.ac $! Pull the version from configure.ac
$! $!
$ open/read ac_file sys$disk:[]configure.ac $ open/read ac_file sys$disk:[]configure.ac
$ac_read_loop: $ac_read_loop:
@ -39,21 +38,26 @@ $ version = f$element (0,"]",version)
$ac_read_loop_end: $ac_read_loop_end:
$ close ac_file $ close ac_file
$! $!
$ if (package .eqs. "") .or. (version .eqs. "") $ if (version .eqs. "")
$ then $ then
$ write sys$output "Unable to determine package and/or version!" $ write sys$output "Unable to determine version!"
$ exit 44 $ exit 44
$ endif $ endif
$! $!
$! $!
$ outfile = "sys$disk:[]config.h-vms" $ outfile = "sys$disk:[.src]mkconfig.h"
$! $!
$! Note the pipe command is close to the length of 255, which is the $! Note the pipe command is close to the length of 255, which is the
$! maximum token length prior to VMS V8.2: $! maximum token length prior to VMS V8.2:
$! %DCL-W-TKNOVF, command element is too long - shorten $! %DCL-W-TKNOVF, command element is too long - shorten
$ pipe (write sys$output "sub/%PACKAGE%/''package'/WHOLE/NOTYPE" ;- $! PDS: Blown out; someone else will have to figure this out
write sys$output "sub/%VERSION%/''version'/WHOLE/NOTYPE" ;- $ pipe (write sys$output "sub,@PACKAGE@,make,WHOLE/NOTYPE" ;-
write sys$output "sub,@PACKAGE_BUGREPORT@,bug-make@gnu.org,WHOLE/NOTYPE" ;-
write sys$output "sub,@PACKAGE_NAME@,GNU Make,WHOLE/NOTYPE" ;-
write sys$output "sub,@PACKAGE_TARNAME@,make,WHOLE/NOTYPE" ;-
write sys$output "sub,@PACKAGE_URL@,https://www.gnu.org/software/make/,WHOLE/NOTYPE" ;-
write sys$output "sub,@PACKAGE_VERSION@,''version',WHOLE/NOTYPE" ;-
write sys$output "exit") |- write sys$output "exit") |-
edit/edt 'config_template'/out='outfile'/command=sys$pipe >nla0: edit/edt 'config_template'/out='outfile'/command=sys$pipe >nla0:
$! $!
$ write sys$output package, ", version: ", version, " prepared for VMS" $ write sys$output "GNU Make version: ", version, " prepared for VMS"

View File

@ -14,6 +14,8 @@ A PARTICULAR PURPOSE. See the GNU General Public License for more details.
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/>. */
#include "mkconfig.h"
/* Define if on AIX 3. /* Define if on AIX 3.
System headers sometimes define this. System headers sometimes define this.
We just want to avoid a redefinition error message. */ We just want to avoid a redefinition error message. */
@ -166,12 +168,6 @@ this program. If not, see <http://www.gnu.org/licenses/>. */
instead of <sys/cpustats.h>. */ instead of <sys/cpustats.h>. */
/* #undef UMAX4_3 */ /* #undef UMAX4_3 */
/* Name of this package (needed by automake) */
#define PACKAGE "%PACKAGE%"
/* Version of this package (needed by automake) */
#define VERSION "%VERSION%"
/* Define to the name of the SCCS 'get' command. */ /* Define to the name of the SCCS 'get' command. */
#define SCCS_GET "get" #define SCCS_GET "get"

View File

@ -15,8 +15,7 @@ A PARTICULAR PURPOSE. See the GNU General Public License for more details.
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/>. */
/* config.h. Generated automatically by configure. */ #include "mkconfig.h"
/* config.h.in. Generated automatically from configure.ac by autoheader. */
/* Pull in types.h here to get __CRTL_VER defined for old versions of the /* Pull in types.h here to get __CRTL_VER defined for old versions of the
compiler which don't define it. */ compiler which don't define it. */
@ -206,24 +205,6 @@ this program. If not, see <http://www.gnu.org/licenses/>. */
instead of <sys/cpustats.h>. */ instead of <sys/cpustats.h>. */
/* #undef UMAX4_3 */ /* #undef UMAX4_3 */
/* Name of this package (needed by automake) */
#define PACKAGE "%PACKAGE%"
/* Define to the address where bug reports for this package should be sent. */
#define PACKAGE_BUGREPORT "bug-make@gnu.org"
/* Define to the full name of this package. */
#define PACKAGE_NAME "GNU make"
/* Define to the home page for this package. */
#define PACKAGE_URL "https://www.gnu.org/software/make/"
/* Define to the version of this package. */
#define PACKAGE_VERSION "%VERSION%"
/* Version of this package (needed by automake) */
#define VERSION "%VERSION%"
/* Define to the name of the SCCS 'get' command. */ /* Define to the name of the SCCS 'get' command. */
/* #undef SCCS_GET */ /* #undef SCCS_GET */

View File

@ -15,6 +15,8 @@ A PARTICULAR PURPOSE. See the GNU General Public License for more details.
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/>. */
#include "mkconfig.h"
/* Suppress some Visual C++ warnings. /* Suppress some Visual C++ warnings.
Maybe after the code cleanup for ISO C we can remove some/all of these. */ Maybe after the code cleanup for ISO C we can remove some/all of these. */
#if _MSC_VER > 1000 #if _MSC_VER > 1000
@ -461,21 +463,6 @@ char *ttyname (int);
/* Define to 1 if your C compiler doesn't accept -c and -o together. */ /* Define to 1 if your C compiler doesn't accept -c and -o together. */
/* #undef NO_MINUS_C_MINUS_O */ /* #undef NO_MINUS_C_MINUS_O */
/* Name of this package (needed by automake) */
#define PACKAGE "%PACKAGE%"
/* Define to the address where bug reports for this package should be sent. */
#define PACKAGE_BUGREPORT "bug-make@gnu.org"
/* Define to the full name of this package. */
#define PACKAGE_NAME "GNU make"
/* Define to the home page for this package. */
#define PACKAGE_URL "https://www.gnu.org/software/make/"
/* Define to the version of this package. */
#define PACKAGE_VERSION "%VERSION%"
/* Define to the character that separates directories in PATH. */ /* Define to the character that separates directories in PATH. */
#define PATH_SEPARATOR_CHAR ';' #define PATH_SEPARATOR_CHAR ';'
@ -512,9 +499,6 @@ char *ttyname (int);
<sys/cpustats.h>. */ <sys/cpustats.h>. */
/* #undef UMAX4_3 */ /* #undef UMAX4_3 */
/* Version number of package */
#define VERSION "%VERSION%"
/* Define if using the dmalloc debugging malloc package */ /* Define if using the dmalloc debugging malloc package */
/* #undef WITH_DMALLOC */ /* #undef WITH_DMALLOC */

View File

@ -15,6 +15,8 @@ A PARTICULAR PURPOSE. See the GNU General Public License for more details.
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/>. */
#include "mkconfig.h"
/* Include this header to make __DJGPP_MINOR__ available because DJGPP ports /* Include this header to make __DJGPP_MINOR__ available because DJGPP ports
of GCC 4.3.0 and later no longer do it automatically. */ of GCC 4.3.0 and later no longer do it automatically. */
#include <sys/version.h> #include <sys/version.h>
@ -81,30 +83,9 @@ this program. If not, see <http://www.gnu.org/licenses/>. */
/* Define to 1 if you have the `strtoll' function. */ /* Define to 1 if you have the `strtoll' function. */
#define HAVE_STRTOLL 1 #define HAVE_STRTOLL 1
/* Name of the package */
#define PACKAGE "%PACKAGE%"
/* Define to the address where bug reports for this package should be sent. */
#define PACKAGE_BUGREPORT "bug-%PACKAGE%@gnu.org"
/* Define to the full name of this package. */
#define PACKAGE_NAME "GNU %PACKAGE%"
/* Define to the full name and version of this package. */
#define PACKAGE_STRING "GNU %PACKAGE% %VERSION%"
/* Define to the one symbol short name of this package. */
#define PACKAGE_TARNAME "%PACKAGE%"
/* Define to the version of this package. */
#define PACKAGE_VERSION "%VERSION%"
/* Output sync support */ /* Output sync support */
#define NO_OUTPUT_SYNC 1 #define NO_OUTPUT_SYNC 1
/* Version number of package */
#define VERSION "%VERSION%"
/* Build host information. */ /* Build host information. */
#define MAKE_HOST "i386-pc-msdosdjgpp" #define MAKE_HOST "i386-pc-msdosdjgpp"

36
src/mkconfig.h.in Normal file
View File

@ -0,0 +1,36 @@
/* Autoconf values for use on non-POSIX systems.
Copyright (C) 2022 Free Software Foundation, Inc.
This file is part of GNU Make.
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
Foundation; either version 3 of the License, or (at your option) any later
version.
GNU Make is distributed in the hope that it will be useful, but WITHOUT ANY
WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR
A PARTICULAR PURPOSE. See the GNU General Public License for more details.
You should have received a copy of the GNU General Public License along with
this program. If not, see <http://www.gnu.org/licenses/>. */
/* Name of package */
#define PACKAGE "@PACKAGE@"
/* Define to the address where bug reports for this package should be sent. */
#define PACKAGE_BUGREPORT "@PACKAGE_BUGREPORT@"
/* Define to the full name of this package. */
#define PACKAGE_NAME "@PACKAGE_NAME@"
/* Define to the full name and version of this package. */
#define PACKAGE_STRING "@PACKAGE_NAME@ @PACKAGE_VERSION@"
/* Define to the one symbol short name of this package. */
#define PACKAGE_TARNAME "@PACKAGE_TARNAME@"
/* Define to the home page for this package. */
#define PACKAGE_URL "@PACKAGE_URL@"
/* Define to the version of this package. */
#define PACKAGE_VERSION "@PACKAGE_VERSION@"

View File

@ -23,7 +23,7 @@ this program. If not, see <http://www.gnu.org/licenses/>. */
# define MAKE_HOST "unknown" # define MAKE_HOST "unknown"
#endif #endif
const char *version_string = VERSION; const char *version_string = PACKAGE_VERSION;
const char *make_host = MAKE_HOST; const char *make_host = MAKE_HOST;
/* /*