[blfs] 01/02: protobuf-c: honor default CXXFLAGS

"Git Owner" ([email protected] via blfs-book Mailing List) <[email protected]>
Newsgroups gmane.linux.lfs.beyond.book
Message-ID <[email protected]>
This is an automated email from the git hooks/post-receive script.

git pushed a commit to branch trunk
in repository blfs.

commit 10e1b65700e22e4f59236983f597ccfd3fa5150c
Author: Xi Ruoyao <[email protected]>
AuthorDate: Thu May 21 16:50:14 2026 +0800

    protobuf-c: honor default CXXFLAGS
    
    Again, stupid autotools behavior (meson and cmake do not need this).
    Also document why we need to modify CXXFLAGS.
---
 general/genlib/protobuf-c.xml | 11 +++++++++--
 1 file changed, 9 insertions(+), 2 deletions(-)

diff --git a/general/genlib/protobuf-c.xml b/general/genlib/protobuf-c.xml
index 75d29f4aa3..8d817b3233 100644
--- a/general/genlib/protobuf-c.xml
+++ b/general/genlib/protobuf-c.xml
@@ -88,7 +88,7 @@
     <title>Installation of Protobuf-c</title>
 
     <para>
-      First fix issues caused by <xref linkend="protobuf"/> and later:
+      First fix issues caused by protobuf-34 and later:
     </para>
 
 <screen><userinput>patch -Np1 -i ../protobuf-c-&protobuf-c-version;-protobuf34_fix-1.patch</userinput></screen>
@@ -98,7 +98,8 @@
       commands:
     </para>
 
-<screen><userinput>CXXFLAGS+=" -std=c++20" ./configure --prefix=/usr --disable-static &amp;&amp;
+<screen><userinput>CXXFLAGS="${CXXFLAGS:--O2 -g} -std=c++20" \
+./configure --prefix=/usr --disable-static &amp;&amp;
 make</userinput></screen>
 
     <para>
@@ -116,6 +117,12 @@ make</userinput></screen>
   <sect2 role="commands">
     <title>Command Explanations</title>
 
+    <para>
+      <envar>CXXFLAGS="${CXXFLAGS:--O2 -g} -std=c++20"</envar>: Override the
+      default C++ standard (C++ 2017) of this package, as the headers from
+      protobuf-35 and later require C++ 2020 features.
+    </para>
+
     <xi:include xmlns:xi="http://www.w3.org/2001/XInclude"
       href="../../xincludes/static-libraries.xml"/>
 

-- 
To stop receiving notification emails like this one, please contact
the administrator of this repository.

-- 
http://lists.linuxfromscratch.org/sympa/info/blfs-book
Unsubscribe: See the above information page
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.