Skip to content

Commit

Permalink
configure.ac: use C++17 for newer Protobufs
Browse files Browse the repository at this point in the history
  • Loading branch information
intelfx committed Sep 27, 2023
1 parent a70c932 commit a98e196
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions configure.ac
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,12 @@ AS_IF([test x"$PROTOC" = x],
m4_ifdef([AM_PROG_AR], [AM_PROG_AR])

# Protobuf 3.6+ requires C++11.
AS_IF([pkg-config --atleast-version 3.6.0 protobuf],
[AX_CXX_COMPILE_STDCXX([11])])
# Protobuf 22+ requires C++14 nominally, but building with C++ <17 fails on my machine.
AS_IF([pkg-config --atleast-version 22.0.0 protobuf],
[AX_CXX_COMPILE_STDCXX([17])],
[pkg-config --atleast-version 3.6.0 protobuf],
[AX_CXX_COMPILE_STDCXX([11])]
)

WARNING_CXXFLAGS=""
PICKY_CXXFLAGS=""
Expand Down

0 comments on commit a98e196

Please sign in to comment.