public inbox for gcc-patches@gcc.gnu.org
 help / color / mirror / Atom feed
* [PATCH v1] libstdc++-v3: Update VTV vars for libtool link commands [PR99172]
@ 2021-03-11  4:50 Caroline Tice
  2021-03-11 15:31 ` Caroline Tice
  0 siblings, 1 reply; 8+ messages in thread
From: Caroline Tice @ 2021-03-11  4:50 UTC (permalink / raw)
  To: GCC Patches

[-- Attachment #1: Type: text/plain, Size: 1887 bytes --]

This patch is to fix PR 99172.

Currently when GCC is configured with --enable-vtable-verify, the
libstdc++-v3 Makefiles add "-fvtable-verify=std
-Wl,-u_vtable_map_vars_start,-u_vtable_map_vars_end" to libtool link
commands. The "-fvtable-verify=std" piece causes alternate versions of
libtool (such as slibtool) to fail, unable to find "-lvtv" (GNU
libtool just removes that piece).

This patch updates the libstdc++-v3 Makefiles to not pass
"-fvtable-verify=std" to the libtool link commands, while continuing
to pass the rest of the VTV  flags (which are necessary for VTV to
work).

I tested this by configuring with --enable-vtable-verify, boostrapping
the compiler, and running all the regression testsuites (including
libvtv & libstdc++) without any regressions.  I only ran it on a linux
system, on an x86_64 machine.

I also gave a copy of the patch to the person who reported the bug,
and they verified that the patch fixes their issue.

Is this ok to commit?

-- Caroline Tice
cmtice@google.com

libstdc++-v3/ChangeLog

2021-03-10  Caroline Tice  <cmtice@google.com>

        PR libstdc++/99172
        * Makefile.in: Regenerate.
        * acinclude.m4: Add definitions for VTV_CXXFLAGS_LT.
        * configure: Regenerate.
        * doc/Makefile.in: Regenerate.
        * include/Maefile.in: Regenerate.
        * libsupc++/Makefile.in: Regenerate.
        * po/Makefile.in: Regenerate.
        * python/Makefile.in: Regenerate.
        * src/Makefile.am (AM_CXXFLAGS_LT): New definition.
        (CXXLINK): Update to use AM_CXXFLAGS_LT instead of AM_CXXFLAGS.
        * src/Makefile.in: Regenerate.
        * src/c++11/Makefile.in: Regenerate.
        * src/c++17/Makefile.in: Regenerate.
        * src/c++20/Makefile.in: Regenerate.
        * src/c++98/Makefile.in: Regenerate.
        * src/filesystem/Makefile.in: Regenerate.
        * testsuite/Makefile.in: Regenerate.

[-- Attachment #2: v1-0001-libstdc-v3-Update-VTV-vars-for-libtool-link-comma.patch --]
[-- Type: application/octet-stream, Size: 16597 bytes --]

From 962f67696c0423de81d86d6285f47a00b4ee321c Mon Sep 17 00:00:00 2001
From: Caroline Tice <cmtice@google.com>
Date: Tue, 9 Mar 2021 15:51:15 -0800
Subject: [PATCH v1] libstdc++-v3: Update VTV vars for libtool link commands
 [PR99172]

This fixes PR 99172

Currently when GCC is configured with --enable-vtable-verify, the
libstdc++-v3 Makefiles add "-fvtable-verify=std
-Wl,-u_vtable_map_vars_start,-u_vtable_map_vars_end" to libtool link
commands. The "-fvtable-verify=std" piece causes alternate versions of
libtool (such as slibtool) to fail, unable to find "-lvtv" (GNU
libtool just removes that piece).

This patch updates the libstdc++-v3 Makefiles to not pass
"-fvtable-verify=std" to the libtool link commands.
---
 libstdc++-v3/Makefile.in                |  1 +
 libstdc++-v3/acinclude.m4               |  6 ++++
 libstdc++-v3/configure                  | 37 ++++++++++++-------------
 libstdc++-v3/doc/Makefile.in            |  1 +
 libstdc++-v3/include/Makefile.in        |  1 +
 libstdc++-v3/libsupc++/Makefile.in      |  1 +
 libstdc++-v3/po/Makefile.in             |  1 +
 libstdc++-v3/python/Makefile.in         |  1 +
 libstdc++-v3/src/Makefile.am            | 10 ++++++-
 libstdc++-v3/src/Makefile.in            | 12 +++++++-
 libstdc++-v3/src/c++11/Makefile.in      |  1 +
 libstdc++-v3/src/c++17/Makefile.in      |  1 +
 libstdc++-v3/src/c++20/Makefile.in      |  1 +
 libstdc++-v3/src/c++98/Makefile.in      |  1 +
 libstdc++-v3/src/filesystem/Makefile.in |  1 +
 libstdc++-v3/testsuite/Makefile.in      |  1 +
 16 files changed, 55 insertions(+), 22 deletions(-)

diff --git a/libstdc++-v3/Makefile.in b/libstdc++-v3/Makefile.in
index a1955dddd15..2906d91d4c5 100644
--- a/libstdc++-v3/Makefile.in
+++ b/libstdc++-v3/Makefile.in
@@ -295,6 +295,7 @@ TOPLEVEL_INCLUDES = @TOPLEVEL_INCLUDES@
 USE_NLS = @USE_NLS@
 VERSION = @VERSION@
 VTV_CXXFLAGS = @VTV_CXXFLAGS@
+VTV_CXXFLAGS_LT = @VTV_CXXFLAGS_LT@
 VTV_CXXLINKFLAGS = @VTV_CXXLINKFLAGS@
 VTV_PCH_CXXFLAGS = @VTV_PCH_CXXFLAGS@
 WARN_FLAGS = @WARN_FLAGS@
diff --git a/libstdc++-v3/acinclude.m4 b/libstdc++-v3/acinclude.m4
index e4175ea3e64..64e23c178fe 100644
--- a/libstdc++-v3/acinclude.m4
+++ b/libstdc++-v3/acinclude.m4
@@ -2786,30 +2786,36 @@ AC_DEFUN([GLIBCXX_ENABLE_VTABLE_VERIFY], [
     case ${target_os} in
       cygwin*|mingw32*)
         VTV_CXXFLAGS="-fvtable-verify=std -Wl,-lvtv,-u_vtable_map_vars_start,-u_vtable_map_vars_end"
+        VTV_CXXFLAGS_LT="-Wl,-u_vtable_map_vars_start,-u_vtable_map_vars_end"
         VTV_CXXLINKFLAGS="-L${toplevel_builddir}/libvtv/.libs -Wl,--rpath -Wl,${toplevel_builddir}/libvtv/.libs"
         vtv_cygmin=yes
         ;;
       darwin*)
         VTV_CXXFLAGS="-fvtable-verify=std -Wl,-u,_vtable_map_vars_start -Wl,-u,_vtable_map_vars_end"
+        VTV_CXXFLAGS_LT="-Wl,-u_vtable_map_vars_start,-u_vtable_map_vars_end"
         VTV_CXXLINKFLAGS="-L${toplevel_builddir}/libvtv/.libs -Wl,-rpath,${toplevel_builddir}/libvtv/.libs"
         ;;
       solaris2*)
         VTV_CXXFLAGS="-fvtable-verify=std -Wl,-u_vtable_map_vars_start,-u_vtable_map_vars_end"
+        VTV_CXXFLAGS_LT="-Wl,-u_vtable_map_vars_start,-u_vtable_map_vars_end"
         VTV_CXXLINKFLAGS="-L${toplevel_builddir}/libvtv/.libs -Wl,-R -Wl,${toplevel_builddir}/libvtv/.libs"
         ;;
       *)
         VTV_CXXFLAGS="-fvtable-verify=std -Wl,-u_vtable_map_vars_start,-u_vtable_map_vars_end"
+        VTV_CXXFLAGS_LT="-Wl,-u_vtable_map_vars_start,-u_vtable_map_vars_end"
         VTV_CXXLINKFLAGS="-L${toplevel_builddir}/libvtv/.libs -Wl,--rpath -Wl,${toplevel_builddir}/libvtv/.libs"
         ;;
     esac
     VTV_PCH_CXXFLAGS="-fvtable-verify=std"
   else
     VTV_CXXFLAGS=
+    VTV_CXXFLAGS_LT=
     VTV_PCH_CXXFLAGS=
     VTV_CXXLINKFLAGS=
   fi
 
   AC_SUBST(VTV_CXXFLAGS)
+  AC_SUBST(VTV_CXXFLAGS_LT)
   AC_SUBST(VTV_PCH_CXXFLAGS)
   AC_SUBST(VTV_CXXLINKFLAGS)
   AM_CONDITIONAL(VTV_CYGMIN, test x$vtv_cygmin = xyes)
diff --git a/libstdc++-v3/configure b/libstdc++-v3/configure
index a310e9feb6c..e689f63afec 100755
--- a/libstdc++-v3/configure
+++ b/libstdc++-v3/configure
@@ -719,6 +719,7 @@ VTV_CYGMIN_FALSE
 VTV_CYGMIN_TRUE
 VTV_CXXLINKFLAGS
 VTV_PCH_CXXFLAGS
+VTV_CXXFLAGS_LT
 VTV_CXXFLAGS
 ENABLE_WERROR_FALSE
 ENABLE_WERROR_TRUE
@@ -12130,7 +12131,7 @@ else
   lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
   lt_status=$lt_dlunknown
   cat > conftest.$ac_ext <<_LT_EOF
-#line 12143 "configure"
+#line 12134 "configure"
 #include "confdefs.h"
 
 #if HAVE_DLFCN_H
@@ -12236,7 +12237,7 @@ else
   lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
   lt_status=$lt_dlunknown
   cat > conftest.$ac_ext <<_LT_EOF
-#line 12249 "configure"
+#line 12240 "configure"
 #include "confdefs.h"
 
 #if HAVE_DLFCN_H
@@ -14981,16 +14982,6 @@ freebsd* | dragonfly*)
   esac
   ;;
 
-gnu*)
-  version_type=linux
-  need_lib_prefix=no
-  need_version=no
-  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}'
-  soname_spec='${libname}${release}${shared_ext}$major'
-  shlibpath_var=LD_LIBRARY_PATH
-  hardcode_into_libs=yes
-  ;;
-
 haiku*)
   version_type=linux
   need_lib_prefix=no
@@ -15112,7 +15103,7 @@ linux*oldld* | linux*aout* | linux*coff*)
 # project, but have not yet been accepted: they are GCC-local changes
 # for the time being.  (See
 # https://lists.gnu.org/archive/html/libtool-patches/2018-05/msg00000.html)
-linux* | k*bsd*-gnu | kopensolaris*-gnu | uclinuxfdpiceabi)
+linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu* | uclinuxfdpiceabi)
   version_type=linux
   need_lib_prefix=no
   need_version=no
@@ -15928,7 +15919,7 @@ $as_echo "$glibcxx_cv_atomic_long_long" >&6; }
   # Fake what AC_TRY_COMPILE does.
 
     cat > conftest.$ac_ext << EOF
-#line 15941 "configure"
+#line 15922 "configure"
 int main()
 {
   typedef bool atomic_type;
@@ -15963,7 +15954,7 @@ $as_echo "$glibcxx_cv_atomic_bool" >&6; }
     rm -f conftest*
 
     cat > conftest.$ac_ext << EOF
-#line 15976 "configure"
+#line 15957 "configure"
 int main()
 {
   typedef short atomic_type;
@@ -15998,7 +15989,7 @@ $as_echo "$glibcxx_cv_atomic_short" >&6; }
     rm -f conftest*
 
     cat > conftest.$ac_ext << EOF
-#line 16011 "configure"
+#line 15992 "configure"
 int main()
 {
   // NB: _Atomic_word not necessarily int.
@@ -16034,7 +16025,7 @@ $as_echo "$glibcxx_cv_atomic_int" >&6; }
     rm -f conftest*
 
     cat > conftest.$ac_ext << EOF
-#line 16047 "configure"
+#line 16028 "configure"
 int main()
 {
   typedef long long atomic_type;
@@ -16187,7 +16178,7 @@ $as_echo "mutex" >&6; }
   # unnecessary for this test.
 
     cat > conftest.$ac_ext << EOF
-#line 16200 "configure"
+#line 16181 "configure"
 int main()
 {
   _Decimal32 d1;
@@ -16229,7 +16220,7 @@ ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
   # unnecessary for this test.
 
     cat > conftest.$ac_ext << EOF
-#line 16242 "configure"
+#line 16223 "configure"
 template<typename T1, typename T2>
   struct same
   { typedef T2 type; };
@@ -16263,7 +16254,7 @@ $as_echo "$enable_int128" >&6; }
     rm -f conftest*
 
     cat > conftest.$ac_ext << EOF
-#line 16276 "configure"
+#line 16257 "configure"
 template<typename T1, typename T2>
   struct same
   { typedef T2 type; };
@@ -18771,25 +18762,30 @@ $as_echo "$enable_vtable_verify" >&6; }
     case ${target_os} in
       cygwin*|mingw32*)
         VTV_CXXFLAGS="-fvtable-verify=std -Wl,-lvtv,-u_vtable_map_vars_start,-u_vtable_map_vars_end"
+        VTV_CXXFLAGS_LT="-Wl,-u_vtable_map_vars_start,-u_vtable_map_vars_end"
         VTV_CXXLINKFLAGS="-L${toplevel_builddir}/libvtv/.libs -Wl,--rpath -Wl,${toplevel_builddir}/libvtv/.libs"
         vtv_cygmin=yes
         ;;
       darwin*)
         VTV_CXXFLAGS="-fvtable-verify=std -Wl,-u,_vtable_map_vars_start -Wl,-u,_vtable_map_vars_end"
+        VTV_CXXFLAGS_LT="-Wl,-u_vtable_map_vars_start,-u_vtable_map_vars_end"
         VTV_CXXLINKFLAGS="-L${toplevel_builddir}/libvtv/.libs -Wl,-rpath,${toplevel_builddir}/libvtv/.libs"
         ;;
       solaris2*)
         VTV_CXXFLAGS="-fvtable-verify=std -Wl,-u_vtable_map_vars_start,-u_vtable_map_vars_end"
+        VTV_CXXFLAGS_LT="-Wl,-u_vtable_map_vars_start,-u_vtable_map_vars_end"
         VTV_CXXLINKFLAGS="-L${toplevel_builddir}/libvtv/.libs -Wl,-R -Wl,${toplevel_builddir}/libvtv/.libs"
         ;;
       *)
         VTV_CXXFLAGS="-fvtable-verify=std -Wl,-u_vtable_map_vars_start,-u_vtable_map_vars_end"
+        VTV_CXXFLAGS_LT="-Wl,-u_vtable_map_vars_start,-u_vtable_map_vars_end"
         VTV_CXXLINKFLAGS="-L${toplevel_builddir}/libvtv/.libs -Wl,--rpath -Wl,${toplevel_builddir}/libvtv/.libs"
         ;;
     esac
     VTV_PCH_CXXFLAGS="-fvtable-verify=std"
   else
     VTV_CXXFLAGS=
+    VTV_CXXFLAGS_LT=
     VTV_PCH_CXXFLAGS=
     VTV_CXXLINKFLAGS=
   fi
@@ -18797,6 +18793,7 @@ $as_echo "$enable_vtable_verify" >&6; }
 
 
 
+
    if test x$vtv_cygmin = xyes; then
   VTV_CYGMIN_TRUE=
   VTV_CYGMIN_FALSE='#'
diff --git a/libstdc++-v3/doc/Makefile.in b/libstdc++-v3/doc/Makefile.in
index 7681908103a..eafbc29afec 100644
--- a/libstdc++-v3/doc/Makefile.in
+++ b/libstdc++-v3/doc/Makefile.in
@@ -254,6 +254,7 @@ TOPLEVEL_INCLUDES = @TOPLEVEL_INCLUDES@
 USE_NLS = @USE_NLS@
 VERSION = @VERSION@
 VTV_CXXFLAGS = @VTV_CXXFLAGS@
+VTV_CXXFLAGS_LT = @VTV_CXXFLAGS_LT@
 VTV_CXXLINKFLAGS = @VTV_CXXLINKFLAGS@
 VTV_PCH_CXXFLAGS = @VTV_PCH_CXXFLAGS@
 WARN_FLAGS = @WARN_FLAGS@
diff --git a/libstdc++-v3/include/Makefile.in b/libstdc++-v3/include/Makefile.in
index 12c63400706..de0abd36e96 100644
--- a/libstdc++-v3/include/Makefile.in
+++ b/libstdc++-v3/include/Makefile.in
@@ -254,6 +254,7 @@ TOPLEVEL_INCLUDES = @TOPLEVEL_INCLUDES@
 USE_NLS = @USE_NLS@
 VERSION = @VERSION@
 VTV_CXXFLAGS = @VTV_CXXFLAGS@
+VTV_CXXFLAGS_LT = @VTV_CXXFLAGS_LT@
 VTV_CXXLINKFLAGS = @VTV_CXXLINKFLAGS@
 VTV_PCH_CXXFLAGS = @VTV_PCH_CXXFLAGS@
 WARN_FLAGS = @WARN_FLAGS@
diff --git a/libstdc++-v3/libsupc++/Makefile.in b/libstdc++-v3/libsupc++/Makefile.in
index 831f3ed0ad3..64820a5f4ee 100644
--- a/libstdc++-v3/libsupc++/Makefile.in
+++ b/libstdc++-v3/libsupc++/Makefile.in
@@ -363,6 +363,7 @@ TOPLEVEL_INCLUDES = @TOPLEVEL_INCLUDES@
 USE_NLS = @USE_NLS@
 VERSION = @VERSION@
 VTV_CXXFLAGS = @VTV_CXXFLAGS@
+VTV_CXXFLAGS_LT = @VTV_CXXFLAGS_LT@
 VTV_CXXLINKFLAGS = @VTV_CXXLINKFLAGS@
 VTV_PCH_CXXFLAGS = @VTV_PCH_CXXFLAGS@
 WARN_FLAGS = @WARN_FLAGS@
diff --git a/libstdc++-v3/po/Makefile.in b/libstdc++-v3/po/Makefile.in
index 8edd2e05639..14887b52ec3 100644
--- a/libstdc++-v3/po/Makefile.in
+++ b/libstdc++-v3/po/Makefile.in
@@ -254,6 +254,7 @@ TOPLEVEL_INCLUDES = @TOPLEVEL_INCLUDES@
 USE_NLS = @USE_NLS@
 VERSION = @VERSION@
 VTV_CXXFLAGS = @VTV_CXXFLAGS@
+VTV_CXXFLAGS_LT = @VTV_CXXFLAGS_LT@
 VTV_CXXLINKFLAGS = @VTV_CXXLINKFLAGS@
 VTV_PCH_CXXFLAGS = @VTV_PCH_CXXFLAGS@
 WARN_FLAGS = @WARN_FLAGS@
diff --git a/libstdc++-v3/python/Makefile.in b/libstdc++-v3/python/Makefile.in
index c35dbe55961..adb76570c32 100644
--- a/libstdc++-v3/python/Makefile.in
+++ b/libstdc++-v3/python/Makefile.in
@@ -284,6 +284,7 @@ TOPLEVEL_INCLUDES = @TOPLEVEL_INCLUDES@
 USE_NLS = @USE_NLS@
 VERSION = @VERSION@
 VTV_CXXFLAGS = @VTV_CXXFLAGS@
+VTV_CXXFLAGS_LT = @VTV_CXXFLAGS_LT@
 VTV_CXXLINKFLAGS = @VTV_CXXLINKFLAGS@
 VTV_PCH_CXXFLAGS = @VTV_PCH_CXXFLAGS@
 WARN_FLAGS = @WARN_FLAGS@
diff --git a/libstdc++-v3/src/Makefile.am b/libstdc++-v3/src/Makefile.am
index 78e788cccb3..62d12f94967 100644
--- a/libstdc++-v3/src/Makefile.am
+++ b/libstdc++-v3/src/Makefile.am
@@ -220,6 +220,14 @@ AM_CXXFLAGS = \
 	$(XTEMPLATE_FLAGS) $(VTV_CXXFLAGS) \
 	$(WARN_CXXFLAGS) $(OPTIMIZE_CXXFLAGS) $(CONFIG_CXXFLAGS)
 
+# Special version of AM_CXXFLAGS, to be used by libtool when linking. (Uses
+# VTV_CXXFLAGS_LT instead of VTV_CXXFLAGS).
+AM_CXXFLAGS_LT = \
+	-std=gnu++98 \
+	$(glibcxx_compiler_pic_flag) \
+	$(XTEMPLATE_FLAGS) $(VTV_CXXFLAGS_LT) \
+	$(WARN_CXXFLAGS) $(OPTIMIZE_CXXFLAGS) $(CONFIG_CXXFLAGS)
+
 # Libtool notes
 
 # 1) In general, libtool expects an argument such as `--tag=CXX' when
@@ -265,7 +273,7 @@ CXXLINK = \
 	$(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
 	--mode=link $(CXX) \
 	$(VTV_CXXLINKFLAGS) \
-	$(OPT_LDFLAGS) $(SECTION_LDFLAGS) $(AM_CXXFLAGS) $(LTLDFLAGS) -o $@
+	$(OPT_LDFLAGS) $(SECTION_LDFLAGS) $(AM_CXXFLAGS_LT) $(LTLDFLAGS) -o $@
 
 # Symbol versioning for shared libraries.
 if ENABLE_SYMVERS
diff --git a/libstdc++-v3/src/Makefile.in b/libstdc++-v3/src/Makefile.in
index 684b7aee16b..aed4e69ba27 100644
--- a/libstdc++-v3/src/Makefile.in
+++ b/libstdc++-v3/src/Makefile.in
@@ -353,6 +353,7 @@ TOPLEVEL_INCLUDES = @TOPLEVEL_INCLUDES@
 USE_NLS = @USE_NLS@
 VERSION = @VERSION@
 VTV_CXXFLAGS = @VTV_CXXFLAGS@
+VTV_CXXFLAGS_LT = @VTV_CXXFLAGS_LT@
 VTV_CXXLINKFLAGS = @VTV_CXXLINKFLAGS@
 VTV_PCH_CXXFLAGS = @VTV_PCH_CXXFLAGS@
 WARN_FLAGS = @WARN_FLAGS@
@@ -585,6 +586,15 @@ AM_CXXFLAGS = \
 	$(WARN_CXXFLAGS) $(OPTIMIZE_CXXFLAGS) $(CONFIG_CXXFLAGS)
 
 
+# Special version of AM_CXXFLAGS, to be used by libtool when linking. (Uses
+# VTV_CXXFLAGS_LT instead of VTV_CXXFLAGS).
+AM_CXXFLAGS_LT = \
+	-std=gnu++98 \
+	$(glibcxx_compiler_pic_flag) \
+	$(XTEMPLATE_FLAGS) $(VTV_CXXFLAGS_LT) \
+	$(WARN_CXXFLAGS) $(OPTIMIZE_CXXFLAGS) $(CONFIG_CXXFLAGS)
+
+
 # Libtool notes
 
 # 1) In general, libtool expects an argument such as `--tag=CXX' when
@@ -630,7 +640,7 @@ CXXLINK = \
 	$(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
 	--mode=link $(CXX) \
 	$(VTV_CXXLINKFLAGS) \
-	$(OPT_LDFLAGS) $(SECTION_LDFLAGS) $(AM_CXXFLAGS) $(LTLDFLAGS) -o $@
+	$(OPT_LDFLAGS) $(SECTION_LDFLAGS) $(AM_CXXFLAGS_LT) $(LTLDFLAGS) -o $@
 
 @ENABLE_SYMVERS_TRUE@CLEANFILES = libstdc++-symbols.ver $(version_dep)
 @ENABLE_SYMVERS_DARWIN_TRUE@@ENABLE_SYMVERS_TRUE@version_arg = -Wl,-exported_symbols_list,libstdc++-symbols.explist
diff --git a/libstdc++-v3/src/c++11/Makefile.in b/libstdc++-v3/src/c++11/Makefile.in
index 86540509e81..576e26a47e5 100644
--- a/libstdc++-v3/src/c++11/Makefile.in
+++ b/libstdc++-v3/src/c++11/Makefile.in
@@ -320,6 +320,7 @@ TOPLEVEL_INCLUDES = @TOPLEVEL_INCLUDES@
 USE_NLS = @USE_NLS@
 VERSION = @VERSION@
 VTV_CXXFLAGS = @VTV_CXXFLAGS@
+VTV_CXXFLAGS_LT = @VTV_CXXFLAGS_LT@
 VTV_CXXLINKFLAGS = @VTV_CXXLINKFLAGS@
 VTV_PCH_CXXFLAGS = @VTV_PCH_CXXFLAGS@
 WARN_FLAGS = @WARN_FLAGS@
diff --git a/libstdc++-v3/src/c++17/Makefile.in b/libstdc++-v3/src/c++17/Makefile.in
index 63984ecd52a..34beb85c1b1 100644
--- a/libstdc++-v3/src/c++17/Makefile.in
+++ b/libstdc++-v3/src/c++17/Makefile.in
@@ -300,6 +300,7 @@ TOPLEVEL_INCLUDES = @TOPLEVEL_INCLUDES@
 USE_NLS = @USE_NLS@
 VERSION = @VERSION@
 VTV_CXXFLAGS = @VTV_CXXFLAGS@
+VTV_CXXFLAGS_LT = @VTV_CXXFLAGS_LT@
 VTV_CXXLINKFLAGS = @VTV_CXXLINKFLAGS@
 VTV_PCH_CXXFLAGS = @VTV_PCH_CXXFLAGS@
 WARN_FLAGS = @WARN_FLAGS@
diff --git a/libstdc++-v3/src/c++20/Makefile.in b/libstdc++-v3/src/c++20/Makefile.in
index e6892d370fb..2e1f797e9d0 100644
--- a/libstdc++-v3/src/c++20/Makefile.in
+++ b/libstdc++-v3/src/c++20/Makefile.in
@@ -295,6 +295,7 @@ TOPLEVEL_INCLUDES = @TOPLEVEL_INCLUDES@
 USE_NLS = @USE_NLS@
 VERSION = @VERSION@
 VTV_CXXFLAGS = @VTV_CXXFLAGS@
+VTV_CXXFLAGS_LT = @VTV_CXXFLAGS_LT@
 VTV_CXXLINKFLAGS = @VTV_CXXLINKFLAGS@
 VTV_PCH_CXXFLAGS = @VTV_PCH_CXXFLAGS@
 WARN_FLAGS = @WARN_FLAGS@
diff --git a/libstdc++-v3/src/c++98/Makefile.in b/libstdc++-v3/src/c++98/Makefile.in
index ae75fbf4dd6..b3ccc664fa2 100644
--- a/libstdc++-v3/src/c++98/Makefile.in
+++ b/libstdc++-v3/src/c++98/Makefile.in
@@ -316,6 +316,7 @@ TOPLEVEL_INCLUDES = @TOPLEVEL_INCLUDES@
 USE_NLS = @USE_NLS@
 VERSION = @VERSION@
 VTV_CXXFLAGS = @VTV_CXXFLAGS@
+VTV_CXXFLAGS_LT = @VTV_CXXFLAGS_LT@
 VTV_CXXLINKFLAGS = @VTV_CXXLINKFLAGS@
 VTV_PCH_CXXFLAGS = @VTV_PCH_CXXFLAGS@
 WARN_FLAGS = @WARN_FLAGS@
diff --git a/libstdc++-v3/src/filesystem/Makefile.in b/libstdc++-v3/src/filesystem/Makefile.in
index 74a6d2765fc..fcf82a081a6 100644
--- a/libstdc++-v3/src/filesystem/Makefile.in
+++ b/libstdc++-v3/src/filesystem/Makefile.in
@@ -324,6 +324,7 @@ TOPLEVEL_INCLUDES = @TOPLEVEL_INCLUDES@
 USE_NLS = @USE_NLS@
 VERSION = @VERSION@
 VTV_CXXFLAGS = @VTV_CXXFLAGS@
+VTV_CXXFLAGS_LT = @VTV_CXXFLAGS_LT@
 VTV_CXXLINKFLAGS = @VTV_CXXLINKFLAGS@
 VTV_PCH_CXXFLAGS = @VTV_PCH_CXXFLAGS@
 WARN_FLAGS = @WARN_FLAGS@
diff --git a/libstdc++-v3/testsuite/Makefile.in b/libstdc++-v3/testsuite/Makefile.in
index c9dd7f5da61..7ba6a32faaf 100644
--- a/libstdc++-v3/testsuite/Makefile.in
+++ b/libstdc++-v3/testsuite/Makefile.in
@@ -254,6 +254,7 @@ TOPLEVEL_INCLUDES = @TOPLEVEL_INCLUDES@
 USE_NLS = @USE_NLS@
 VERSION = @VERSION@
 VTV_CXXFLAGS = @VTV_CXXFLAGS@
+VTV_CXXFLAGS_LT = @VTV_CXXFLAGS_LT@
 VTV_CXXLINKFLAGS = @VTV_CXXLINKFLAGS@
 VTV_PCH_CXXFLAGS = @VTV_PCH_CXXFLAGS@
 WARN_FLAGS = @WARN_FLAGS@
-- 
2.31.0.rc2.261.g7f71774620-goog


^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: [PATCH v1] libstdc++-v3: Update VTV vars for libtool link commands [PR99172]
  2021-03-11  4:50 [PATCH v1] libstdc++-v3: Update VTV vars for libtool link commands [PR99172] Caroline Tice
@ 2021-03-11 15:31 ` Caroline Tice
  2021-03-11 16:27   ` Jonathan Wakely
  0 siblings, 1 reply; 8+ messages in thread
From: Caroline Tice @ 2021-03-11 15:31 UTC (permalink / raw)
  To: GCC Patches; +Cc: libstdc++

Adding the libstdc++ mailing list to the patch.

-- Caroline
cmtice@google.com

On Wed, Mar 10, 2021 at 8:50 PM Caroline Tice <cmtice@google.com> wrote:
>
> This patch is to fix PR 99172.
>
> Currently when GCC is configured with --enable-vtable-verify, the
> libstdc++-v3 Makefiles add "-fvtable-verify=std
> -Wl,-u_vtable_map_vars_start,-u_vtable_map_vars_end" to libtool link
> commands. The "-fvtable-verify=std" piece causes alternate versions of
> libtool (such as slibtool) to fail, unable to find "-lvtv" (GNU
> libtool just removes that piece).
>
> This patch updates the libstdc++-v3 Makefiles to not pass
> "-fvtable-verify=std" to the libtool link commands, while continuing
> to pass the rest of the VTV  flags (which are necessary for VTV to
> work).
>
> I tested this by configuring with --enable-vtable-verify, boostrapping
> the compiler, and running all the regression testsuites (including
> libvtv & libstdc++) without any regressions.  I only ran it on a linux
> system, on an x86_64 machine.
>
> I also gave a copy of the patch to the person who reported the bug,
> and they verified that the patch fixes their issue.
>
> Is this ok to commit?
>
> -- Caroline Tice
> cmtice@google.com
>
> libstdc++-v3/ChangeLog
>
> 2021-03-10  Caroline Tice  <cmtice@google.com>
>
>         PR libstdc++/99172
>         * Makefile.in: Regenerate.
>         * acinclude.m4: Add definitions for VTV_CXXFLAGS_LT.
>         * configure: Regenerate.
>         * doc/Makefile.in: Regenerate.
>         * include/Maefile.in: Regenerate.
>         * libsupc++/Makefile.in: Regenerate.
>         * po/Makefile.in: Regenerate.
>         * python/Makefile.in: Regenerate.
>         * src/Makefile.am (AM_CXXFLAGS_LT): New definition.
>         (CXXLINK): Update to use AM_CXXFLAGS_LT instead of AM_CXXFLAGS.
>         * src/Makefile.in: Regenerate.
>         * src/c++11/Makefile.in: Regenerate.
>         * src/c++17/Makefile.in: Regenerate.
>         * src/c++20/Makefile.in: Regenerate.
>         * src/c++98/Makefile.in: Regenerate.
>         * src/filesystem/Makefile.in: Regenerate.
>         * testsuite/Makefile.in: Regenerate.

^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: [PATCH v1] libstdc++-v3: Update VTV vars for libtool link commands [PR99172]
  2021-03-11 15:31 ` Caroline Tice
@ 2021-03-11 16:27   ` Jonathan Wakely
  2021-03-11 16:31     ` Jonathan Wakely
  0 siblings, 1 reply; 8+ messages in thread
From: Jonathan Wakely @ 2021-03-11 16:27 UTC (permalink / raw)
  To: Caroline Tice; +Cc: GCC Patches, libstdc++

On 11/03/21 07:31 -0800, Caroline Tice via Libstdc++ wrote:
>Adding the libstdc++ mailing list to the patch.

Thanks.

>-- Caroline
>cmtice@google.com
>
>On Wed, Mar 10, 2021 at 8:50 PM Caroline Tice <cmtice@google.com> wrote:
>>
>> This patch is to fix PR 99172.
>>
>> Currently when GCC is configured with --enable-vtable-verify, the
>> libstdc++-v3 Makefiles add "-fvtable-verify=std
>> -Wl,-u_vtable_map_vars_start,-u_vtable_map_vars_end" to libtool link
>> commands. The "-fvtable-verify=std" piece causes alternate versions of
>> libtool (such as slibtool) to fail, unable to find "-lvtv" (GNU
>> libtool just removes that piece).
>>
>> This patch updates the libstdc++-v3 Makefiles to not pass
>> "-fvtable-verify=std" to the libtool link commands, while continuing
>> to pass the rest of the VTV  flags (which are necessary for VTV to
>> work).
>>
>> I tested this by configuring with --enable-vtable-verify, boostrapping
>> the compiler, and running all the regression testsuites (including
>> libvtv & libstdc++) without any regressions.  I only ran it on a linux
>> system, on an x86_64 machine.
>>
>> I also gave a copy of the patch to the person who reported the bug,
>> and they verified that the patch fixes their issue.
>>
>> Is this ok to commit?

Should the same change be made to CXXLINK in src/*/Makefile.am, for
consistency if nothing else?

The patch is OK for gcc-11 now, but for stage 1 I'm wondering about
simplifying it.

Why do we ever add -Wl,-u options to CXXFLAGS when those are linker
options?

Could we move the -Wl,-u options to VTV_CXXLINKFLAGS instead, so
they're only used when actually linking?

Then VTV_CXXFLAGS would just be -fvtable-verify=std (and so
VTV_PCH_CXXFLAGS would be redundant), and instead of having
AM_CXXFLAGS and AM_CXXFLAGS_LT we could just filter out the
-fvtable-verify=std option from the CXXLINK options:

CXXLINK = \
	$(LIBTOOL) --tag CXX \
	$(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
	--mode=link $(CXX) \
	$(VTV_CXXLINKFLAGS) \
	$(OPT_LDFLAGS) $(SECTION_LDFLAGS) \
	$(filter-out,-fvtable-verify=std,$(AM_CXXFLAGS)) \
	$(LTLDFLAGS) -o $@

Would that make sense?

Or just add  -fvtable-verify=none to the CXXLINK command to cancel out
the  -fvtable-verify=std option from AM_CXXFLAGS:

CXXLINK = \
	$(LIBTOOL) --tag CXX \
	$(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
	--mode=link $(CXX) \
	$(VTV_CXXLINKFLAGS) \
	$(OPT_LDFLAGS) $(SECTION_LDFLAGS) \
	$(AM_CXXFLAGS) -fvtable-verify=none \
	$(LTLDFLAGS) -o $@

That seems cleaner to me, rather than adding another variable with
minor differences from the existing AM_CXXFLAGS.


^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: [PATCH v1] libstdc++-v3: Update VTV vars for libtool link commands [PR99172]
  2021-03-11 16:27   ` Jonathan Wakely
@ 2021-03-11 16:31     ` Jonathan Wakely
  2021-03-11 16:46       ` Jakub Jelinek
  0 siblings, 1 reply; 8+ messages in thread
From: Jonathan Wakely @ 2021-03-11 16:31 UTC (permalink / raw)
  To: Caroline Tice; +Cc: GCC Patches, libstdc++

On 11/03/21 16:27 +0000, Jonathan Wakely wrote:
>That seems cleaner to me, rather than adding another variable with
>minor differences from the existing AM_CXXFLAGS.

My specific concern is that AM_CXXFLAGS and AM_CXXFLAGS_LT will get
out of sync, i.e. we'll add something to the former and forget to add
it to the latter.

If we keep using AM_CXXFLAGS but cancel out the -fvtable-verify=std
option, then there aren't two separate variables that can diverge.

But I think it's too late in the gcc-11 process for that kind of
refactoring.


^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: [PATCH v1] libstdc++-v3: Update VTV vars for libtool link commands [PR99172]
  2021-03-11 16:31     ` Jonathan Wakely
@ 2021-03-11 16:46       ` Jakub Jelinek
  2021-03-11 17:10         ` Jonathan Wakely
  0 siblings, 1 reply; 8+ messages in thread
From: Jakub Jelinek @ 2021-03-11 16:46 UTC (permalink / raw)
  To: Jonathan Wakely; +Cc: Caroline Tice, libstdc++, GCC Patches

On Thu, Mar 11, 2021 at 04:31:51PM +0000, Jonathan Wakely via Gcc-patches wrote:
> On 11/03/21 16:27 +0000, Jonathan Wakely wrote:
> > That seems cleaner to me, rather than adding another variable with
> > minor differences from the existing AM_CXXFLAGS.
> 
> My specific concern is that AM_CXXFLAGS and AM_CXXFLAGS_LT will get
> out of sync, i.e. we'll add something to the former and forget to add
> it to the latter.
> 
> If we keep using AM_CXXFLAGS but cancel out the -fvtable-verify=std
> option, then there aren't two separate variables that can diverge.
> 
> But I think it's too late in the gcc-11 process for that kind of
> refactoring.

I think $(filter-out -fvtable-verify=std,$(AM_CXXFLAGS)) should be fairly
simple thing if that is all that needs to be done.

	Jakub


^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: [PATCH v1] libstdc++-v3: Update VTV vars for libtool link commands [PR99172]
  2021-03-11 16:46       ` Jakub Jelinek
@ 2021-03-11 17:10         ` Jonathan Wakely
  2021-03-12 23:33           ` Caroline Tice
  0 siblings, 1 reply; 8+ messages in thread
From: Jonathan Wakely @ 2021-03-11 17:10 UTC (permalink / raw)
  To: Jakub Jelinek; +Cc: libstdc++, GCC Patches, Caroline Tice

On 11/03/21 17:46 +0100, Jakub Jelinek via Libstdc++ wrote:
>On Thu, Mar 11, 2021 at 04:31:51PM +0000, Jonathan Wakely via Gcc-patches wrote:
>> On 11/03/21 16:27 +0000, Jonathan Wakely wrote:
>> > That seems cleaner to me, rather than adding another variable with
>> > minor differences from the existing AM_CXXFLAGS.
>>
>> My specific concern is that AM_CXXFLAGS and AM_CXXFLAGS_LT will get
>> out of sync, i.e. we'll add something to the former and forget to add
>> it to the latter.
>>
>> If we keep using AM_CXXFLAGS but cancel out the -fvtable-verify=std
>> option, then there aren't two separate variables that can diverge.
>>
>> But I think it's too late in the gcc-11 process for that kind of
>> refactoring.
>
>I think $(filter-out -fvtable-verify=std,$(AM_CXXFLAGS)) should be fairly
>simple thing if that is all that needs to be done.

Yes, we could do that now, and then in stage 1 look at the other
changes (like moving -Wl,-u options to the link flags not cxxflags).

Using filter-out does assume that no target is going to add anything
different that should also be filtered out, but that's true as of
today.


^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: [PATCH v1] libstdc++-v3: Update VTV vars for libtool link commands [PR99172]
  2021-03-11 17:10         ` Jonathan Wakely
@ 2021-03-12 23:33           ` Caroline Tice
  2021-03-15 12:28             ` Jonathan Wakely
  0 siblings, 1 reply; 8+ messages in thread
From: Caroline Tice @ 2021-03-12 23:33 UTC (permalink / raw)
  To: Jonathan Wakely; +Cc: Jakub Jelinek, libstdc++, GCC Patches

[-- Attachment #1: Type: text/plain, Size: 1908 bytes --]

I have updated the patch as you suggested, to filter the
"-fvtable-verify=std" out of AM_CXXFLAGS, and I have verified that it
passes the testsuite with no regressions and fixes the reported bug.

Is this OK to commit now?

-- Caroline Tice
cmtice@google.com

libstdc++-v3/ChangeLog

2021-03-12  Caroline Tice  <cmtice@google.com>

        PR libstdc++/99172
        * src/Makefile.am (AM_CXXFLAGS_PRE, AM_CXXFLAGS): Add
        AM_CXXFLAGS_PRE with the old definition of AM_CXXFLAGS; make
        AM_CXXFLAGS to be AM_CXXFLAGS_PRE with '-fvtable-verify=std'
        filtered out.
        * src/Makefile.in: Regenerate.



-- Caroline
cmtice@google.com


On Thu, Mar 11, 2021 at 9:10 AM Jonathan Wakely <jwakely@redhat.com> wrote:
>
> On 11/03/21 17:46 +0100, Jakub Jelinek via Libstdc++ wrote:
> >On Thu, Mar 11, 2021 at 04:31:51PM +0000, Jonathan Wakely via Gcc-patches wrote:
> >> On 11/03/21 16:27 +0000, Jonathan Wakely wrote:
> >> > That seems cleaner to me, rather than adding another variable with
> >> > minor differences from the existing AM_CXXFLAGS.
> >>
> >> My specific concern is that AM_CXXFLAGS and AM_CXXFLAGS_LT will get
> >> out of sync, i.e. we'll add something to the former and forget to add
> >> it to the latter.
> >>
> >> If we keep using AM_CXXFLAGS but cancel out the -fvtable-verify=std
> >> option, then there aren't two separate variables that can diverge.
> >>
> >> But I think it's too late in the gcc-11 process for that kind of
> >> refactoring.
> >
> >I think $(filter-out -fvtable-verify=std,$(AM_CXXFLAGS)) should be fairly
> >simple thing if that is all that needs to be done.
>
> Yes, we could do that now, and then in stage 1 look at the other
> changes (like moving -Wl,-u options to the link flags not cxxflags).
>
> Using filter-out does assume that no target is going to add anything
> different that should also be filtered out, but that's true as of
> today.
>

[-- Attachment #2: v2-0001-libstdc-v3-Update-VTV-vars-for-libtool-link-comma.patch --]
[-- Type: application/octet-stream, Size: 2369 bytes --]

From dc3eb3ba4bfaa77d3164b495697777737e5e564c Mon Sep 17 00:00:00 2001
From: Caroline Tice <cmtice@google.com>
Date: Fri, 12 Mar 2021 07:34:36 -0800
Subject: [PATCH v2] libstdc++-v3: Update VTV vars for libtool link commands
 [PR99172]

This fixes PR 99172

Currently when GCC is configured with --enable-vtable-verify, the
libstdc++-v3 Makefiles add "-fvtable-verify=std
-Wl,-u_vtable_map_vars_start,-u_vtable_map_vars_end" to libtool link
commands. The "-fvtable-verify=std" piece causes alternate versions of
libtool (such as slibtool) to fail, unable to find "-lvtv" (GNU
libtool just removes that piece).

This patch updates the libstdc++-v3 Makefiles to not pass
"-fvtable-verify=std" to the libtool link commands.
---
 libstdc++-v3/src/Makefile.am | 4 +++-
 libstdc++-v3/src/Makefile.in | 3 ++-
 2 files changed, 5 insertions(+), 2 deletions(-)

diff --git a/libstdc++-v3/src/Makefile.am b/libstdc++-v3/src/Makefile.am
index 78e788cccb3..16f4cc6eff4 100644
--- a/libstdc++-v3/src/Makefile.am
+++ b/libstdc++-v3/src/Makefile.am
@@ -214,12 +214,14 @@ compatibility-condvar.o: compatibility-condvar.cc
 # set this option because CONFIG_CXXFLAGS has to be after
 # OPTIMIZE_CXXFLAGS on the compile line so that -O2 can be overridden
 # as the occasion calls for it.
-AM_CXXFLAGS = \
+AM_CXXFLAGS_PRE = \
 	-std=gnu++98 \
 	$(glibcxx_compiler_pic_flag) \
 	$(XTEMPLATE_FLAGS) $(VTV_CXXFLAGS) \
 	$(WARN_CXXFLAGS) $(OPTIMIZE_CXXFLAGS) $(CONFIG_CXXFLAGS)
 
+AM_CXXFLAGS = $(filter-out -fvtable-verify=std,$(AM_CXXFLAGS_PRE))
+
 # Libtool notes
 
 # 1) In general, libtool expects an argument such as `--tag=CXX' when
diff --git a/libstdc++-v3/src/Makefile.in b/libstdc++-v3/src/Makefile.in
index 684b7aee16b..4df5c829a7f 100644
--- a/libstdc++-v3/src/Makefile.in
+++ b/libstdc++-v3/src/Makefile.in
@@ -578,12 +578,13 @@ libstdc___la_LINK = $(CXXLINK) $(libstdc___la_LDFLAGS) $(lt_host_flags)
 # set this option because CONFIG_CXXFLAGS has to be after
 # OPTIMIZE_CXXFLAGS on the compile line so that -O2 can be overridden
 # as the occasion calls for it.
-AM_CXXFLAGS = \
+AM_CXXFLAGS_PRE = \
 	-std=gnu++98 \
 	$(glibcxx_compiler_pic_flag) \
 	$(XTEMPLATE_FLAGS) $(VTV_CXXFLAGS) \
 	$(WARN_CXXFLAGS) $(OPTIMIZE_CXXFLAGS) $(CONFIG_CXXFLAGS)
 
+AM_CXXFLAGS = $(filter-out -fvtable-verify=std,$(AM_CXXFLAGS_PRE))
 
 # Libtool notes
 
-- 
2.31.0.rc2.261.g7f71774620-goog


^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: [PATCH v1] libstdc++-v3: Update VTV vars for libtool link commands [PR99172]
  2021-03-12 23:33           ` Caroline Tice
@ 2021-03-15 12:28             ` Jonathan Wakely
  0 siblings, 0 replies; 8+ messages in thread
From: Jonathan Wakely @ 2021-03-15 12:28 UTC (permalink / raw)
  To: Caroline Tice; +Cc: Jakub Jelinek, libstdc++, GCC Patches

On 12/03/21 15:33 -0800, Caroline Tice wrote:
>I have updated the patch as you suggested, to filter the
>"-fvtable-verify=std" out of AM_CXXFLAGS, and I have verified that it
>passes the testsuite with no regressions and fixes the reported bug.

This means we also don't pass it to LTCXXCOMPILE, instead of just
removing it from CXXLINK as in the original patch.  Since I have never
understood what libtool is for, I don't really know if that's OK, but
if it works then it works.

>Is this OK to commit now?

OK, thanks.

>-- Caroline Tice
>cmtice@google.com
>
>libstdc++-v3/ChangeLog
>
>2021-03-12  Caroline Tice  <cmtice@google.com>
>
>        PR libstdc++/99172
>        * src/Makefile.am (AM_CXXFLAGS_PRE, AM_CXXFLAGS): Add
>        AM_CXXFLAGS_PRE with the old definition of AM_CXXFLAGS; make
>        AM_CXXFLAGS to be AM_CXXFLAGS_PRE with '-fvtable-verify=std'
>        filtered out.
>        * src/Makefile.in: Regenerate.
>
>
>
>-- Caroline
>cmtice@google.com
>
>
>On Thu, Mar 11, 2021 at 9:10 AM Jonathan Wakely <jwakely@redhat.com> wrote:
>>
>> On 11/03/21 17:46 +0100, Jakub Jelinek via Libstdc++ wrote:
>> >On Thu, Mar 11, 2021 at 04:31:51PM +0000, Jonathan Wakely via Gcc-patches wrote:
>> >> On 11/03/21 16:27 +0000, Jonathan Wakely wrote:
>> >> > That seems cleaner to me, rather than adding another variable with
>> >> > minor differences from the existing AM_CXXFLAGS.
>> >>
>> >> My specific concern is that AM_CXXFLAGS and AM_CXXFLAGS_LT will get
>> >> out of sync, i.e. we'll add something to the former and forget to add
>> >> it to the latter.
>> >>
>> >> If we keep using AM_CXXFLAGS but cancel out the -fvtable-verify=std
>> >> option, then there aren't two separate variables that can diverge.
>> >>
>> >> But I think it's too late in the gcc-11 process for that kind of
>> >> refactoring.
>> >
>> >I think $(filter-out -fvtable-verify=std,$(AM_CXXFLAGS)) should be fairly
>> >simple thing if that is all that needs to be done.
>>
>> Yes, we could do that now, and then in stage 1 look at the other
>> changes (like moving -Wl,-u options to the link flags not cxxflags).
>>
>> Using filter-out does assume that no target is going to add anything
>> different that should also be filtered out, but that's true as of
>> today.
>>



^ permalink raw reply	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2021-03-15 12:28 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-03-11  4:50 [PATCH v1] libstdc++-v3: Update VTV vars for libtool link commands [PR99172] Caroline Tice
2021-03-11 15:31 ` Caroline Tice
2021-03-11 16:27   ` Jonathan Wakely
2021-03-11 16:31     ` Jonathan Wakely
2021-03-11 16:46       ` Jakub Jelinek
2021-03-11 17:10         ` Jonathan Wakely
2021-03-12 23:33           ` Caroline Tice
2021-03-15 12:28             ` Jonathan Wakely

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).