Skip to content

Commit d56feba

Browse files
author
Nicholas Sielicki
committed
chore(build): replace -Wc++-compat' with -x c++'
As of this commit, a build with CFLAGS="-x c++" succeeds; ie: all source files in the tree are both valid C++ source code AND valid C code. Convert wcpp-compat distcheck builds to actually build with C++, to prevent future pull requests from breaking C++ compatibility going forward. stack-info: PR: #578, branch: aws-nslick/stack/25 Signed-off-by: Nicholas Sielicki <[email protected]>
1 parent df37f90 commit d56feba

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

configure.ac

+2-2
Original file line numberDiff line numberDiff line change
@@ -144,14 +144,14 @@ AC_DEFINE_UNQUOTED([OFI_NCCL_TRACE], [${trace}], [Defined to 1 unit test output
144144
AC_ARG_ENABLE([picky-compiler],
145145
[AS_HELP_STRING([--disable-picky-compiler], [Disable adding picky compiler flags.])])
146146
AS_IF([test "${enable_picky_compiler}" != "no"],
147-
[picky_compiler_flags="-Wall -Wc++-compat -Wextra -Wno-unused-parameter"
147+
[picky_compiler_flags="-Wall -Wextra -Wno-unused-parameter"
148148
AC_MSG_NOTICE([Adding ${picky_compiler_flags} to CFLAGS.])
149149
CFLAGS="${CFLAGS} ${picky_compiler_flags}"
150150
AS_UNSET([picky_compiler_flags])])
151151

152152
AC_ARG_ENABLE([werror],
153153
[AS_HELP_STRING([--enable-werror], [Enable setting -Werror. Off by default, unless building from Git tree.])])
154-
werror_flags="-Werror -Wno-error=unused-parameter -Wno-error=missing-field-initializers"
154+
werror_flags="-Werror -Wno-error=unused-parameter -Wno-error=missing-field-initializers -x c++"
155155
AS_IF([test -d "${srcdir}/.git" -a -z "${enable_werror}"],
156156
[AC_MSG_NOTICE([Found .git directory. Adding ${werror_flags} to CFLAGS.])
157157
CFLAGS="${CFLAGS} ${werror_flags}"],

0 commit comments

Comments
 (0)