public inbox for libstdc++-cvs@sourceware.org
help / color / mirror / Atom feed
From: Jonathan Wakely <redi@gcc.gnu.org>
To: gcc-cvs@gcc.gnu.org, libstdc++-cvs@gcc.gnu.org
Subject: [gcc r14-9549] libstdc++: Regenerate <bits/version.h> in maintainer mode
Date: Tue, 19 Mar 2024 15:34:15 +0000 (GMT)	[thread overview]
Message-ID: <20240319153416.09A9F3858CD1@sourceware.org> (raw)

https://gcc.gnu.org/g:90788dd722346560d410fe9a5c2d543811027336

commit r14-9549-g90788dd722346560d410fe9a5c2d543811027336
Author: Jonathan Wakely <jwakely@redhat.com>
Date:   Fri Mar 1 11:20:51 2024 +0000

    libstdc++: Regenerate <bits/version.h> in maintainer mode
    
    This is a generated header but regenerating it requires the manual step
    of running 'make -C include update-version' in the libstdc++ build dir.
    Make it regenerate automatically when --enable-maintainer-mode is used.
    
    libstdc++-v3/ChangeLog:
    
            * include/Makefile.am [MAINTAINER_MODE]: Add target to
            automatically update <bits/version.h>.
            * include/Makefile.in: Regenerate.
    
    gcc/ChangeLog:
    
            * doc/install.texi (Prerequisites): Document use of autogen for
            libstdc++.

Diff:
---
 gcc/doc/install.texi             | 2 ++
 libstdc++-v3/include/Makefile.am | 6 ++++++
 libstdc++-v3/include/Makefile.in | 4 ++++
 3 files changed, 12 insertions(+)

diff --git a/gcc/doc/install.texi b/gcc/doc/install.texi
index e3650e0c4f4..014ca25aa62 100644
--- a/gcc/doc/install.texi
+++ b/gcc/doc/install.texi
@@ -545,6 +545,8 @@ Necessary to run @samp{make check} for @file{fixinc}.
 Necessary to regenerate the top level @file{Makefile.in} file from
 @file{Makefile.tpl} and @file{Makefile.def}.
 
+Necessary to regenerate the @file{bits/version.h} header for libstdc++.
+
 @item Flex version 2.5.4 (or later)
 
 Necessary when modifying @file{*.l} files.
diff --git a/libstdc++-v3/include/Makefile.am b/libstdc++-v3/include/Makefile.am
index 64152351ed0..cb902de36ae 100644
--- a/libstdc++-v3/include/Makefile.am
+++ b/libstdc++-v3/include/Makefile.am
@@ -1480,6 +1480,12 @@ update-version:
 	cd ${bits_srcdir} && \
 	autogen version.def
 
+if MAINTAINER_MODE
+# Regenerate it automatically in maintainer mode.
+${bits_srcdir}/version.h: ${bits_srcdir}/version.def ${bits_srcdir}/version.tpl
+	$(MAKE) update-version
+endif
+
 # The real deal.
 install-data-local: install-headers
 install-headers:
diff --git a/libstdc++-v3/include/Makefile.in b/libstdc++-v3/include/Makefile.in
index 5a965c8e03b..9357087acb4 100644
--- a/libstdc++-v3/include/Makefile.in
+++ b/libstdc++-v3/include/Makefile.in
@@ -1954,6 +1954,10 @@ update-version:
 	cd ${bits_srcdir} && \
 	autogen version.def
 
+# Regenerate it automatically in maintainer mode.
+@MAINTAINER_MODE_TRUE@${bits_srcdir}/version.h: ${bits_srcdir}/version.def ${bits_srcdir}/version.tpl
+@MAINTAINER_MODE_TRUE@	$(MAKE) update-version
+
 # The real deal.
 install-data-local: install-headers
 install-headers:

                 reply	other threads:[~2024-03-19 15:34 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20240319153416.09A9F3858CD1@sourceware.org \
    --to=redi@gcc.gnu.org \
    --cc=gcc-cvs@gcc.gnu.org \
    --cc=libstdc++-cvs@gcc.gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).