From 3879e448f88f7a02aa97fb225c6672652a934e87 Mon Sep 17 00:00:00 2001 From: Andre Schulz Date: Sat, 11 May 2024 13:46:54 +0200 Subject: [PATCH] Raise C++ version to C++14 GoogleTest requires C++14 since 1.13.0 (see release notes [1]). This is required for running CI on macOS with GitHub Actions in a later commit because Homebrew will install GoogleTest 1.15.2 [2]. [1] https://github.com/google/googletest/releases/tag/v1.13.0 [2] https://formulae.brew.sh/formula/googletest --- Makefile.inc | 2 +- tests/Makefile | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/Makefile.inc b/Makefile.inc index 39eeb2d52..9a7638b25 100644 --- a/Makefile.inc +++ b/Makefile.inc @@ -2,7 +2,7 @@ CXX ?= g++ CXXWARNINGS ?= -Wall -Wextra -Wundef -pedantic CXXINTRINSICS ?= -march=native -CXXFEATURES ?= -funsafe-math-optimizations -fno-math-errno -std=c++11 +CXXFEATURES ?= -funsafe-math-optimizations -fno-math-errno -std=c++14 CXXFLAGS ?= ${CXXWARNINGS} ${CXXINTRINSICS} ${CXXFEATURES} -g -O3 # Delete this if OpenMP is not available (e.g., OS X without gcc) diff --git a/tests/Makefile b/tests/Makefile index 21c65d743..9964f8863 100644 --- a/tests/Makefile +++ b/tests/Makefile @@ -8,7 +8,7 @@ GTEST_LDFLAGS = `pkg-config --libs gtest_main` SOURCES = $(wildcard math/gtest_*.cc) $(wildcard mve/gtest_*.cc) $(wildcard sfm/gtest_*.cc) $(wildcard util/gtest_*.cc) $(wildcard fssr/gtest_*.cc) INCLUDES = -I${MVE_ROOT}/libs ${GTEST_CFLAGS} CXXWARNINGS = -Wall -Wextra -pedantic -Wno-sign-compare -CXXFLAGS = -std=c++11 -pthread ${CXXWARNINGS} ${INCLUDES} +CXXFLAGS = -std=c++14 -pthread ${CXXWARNINGS} ${INCLUDES} LDLIBS += ${GTEST_LDFLAGS} ${LIBJPEG_LDFLAGS} ${LIBPNG_LDFLAGS} ${LIBTIFF_LDFLAGS} test: ${SOURCES:.cc=.o} libmve_fssr.a libmve_sfm.a libmve.a libmve_util.a