]> sourceware.org Git - valgrind.git/commitdiff
massif regtest: fix building aligned new overloads with pre-C++17 compilers
authorPaul Floyd <pjfloyd@wanadoo.fr>
Fri, 3 Nov 2023 21:23:26 +0000 (22:23 +0100)
committerPaul Floyd <pjfloyd@wanadoo.fr>
Fri, 3 Nov 2023 21:29:24 +0000 (22:29 +0100)
massif/tests/Makefile.am

index 7117f9b844594b2b859e72c839902439257d4b28..7ec415eac16665e3c3e147f7217ee18eeb65bc2c 100644 (file)
@@ -73,13 +73,16 @@ check_PROGRAMS = \
        new-cpp \
        null \
        one \
-       overloaded-new \
        pages_as_heap \
        peak \
        realloc \
        thresholds \
        zero
 
+if HAVE_ALIGNED_CXX_ALLOC
+check_PROGRAMS += overloaded-new
+endif
+
 inlinfomalloc_CFLAGS = $(AM_CFLAGS) -w
 
 AM_CFLAGS   += $(AM_FLAG_M3264_PRI)
@@ -92,10 +95,8 @@ bug469146_SOURCES    = bug469146.cpp
 bug469146_CXXFLAGS     = $(AM_CXXFLAGS) -O2 -fno-optimize-sibling-calls @FLAG_W_NO_USE_AFTER_FREE@ @FLAG_W_NO_ATTRIBUTES@
 new_cpp_SOURCES                = new-cpp.cpp
 overloaded_new_SOURCES = overloaded-new.cpp
-# pre C++11 compilers don't have exception specs
-# C++11 and later compilers may complain about not having
-# exception specs
-overloaded_new_CXXFLAGS        = $(AM_CXXFLAGS) -Wno-implicit-exception-spec-mismatch -Wno-missing-exception-spec
+# aligned new needs C++17
+overloaded_new_CXXFLAGS        = $(AM_CXXFLAGS) -Wno-implicit-exception-spec-mismatch -Wno-missing-exception-spec -std=c++17
 
 # Suppress warnings for issues we are testing for
 alloc_fns_CFLAGS       = $(AM_CFLAGS) -Wno-unused-result
This page took 0.027302 seconds and 5 git commands to generate.