CMake: Add reminder for when we upgrade to C++17

This commit is contained in:
Sam Edwards 2018-05-24 14:47:12 -06:00
parent a3a24f9840
commit 85b8d96919

View File

@ -2,6 +2,13 @@ configure_file(pandaVersion.h.in pandaVersion.h)
configure_file(checkPandaVersion.h.in checkPandaVersion.h)
configure_file(checkPandaVersion.cxx.in checkPandaVersion.cxx)
if(CMAKE_CXX_STANDARD GREATER_EQUAL 17)
# This serves as a reminder to update checkPandaVersion.h.in when we upgrade
# to C++17, which supports inline variables - a cleaner way of depending on
# the Panda version symbol from a header than what we're currently doing.
message(FATAL_ERROR "Developer notice: Update checkPandaVersion.h.in for C++17!")
endif()
set(P3DTOOLBASE_HEADERS
${CMAKE_CURRENT_BINARY_DIR}/checkPandaVersion.h
${CMAKE_CURRENT_BINARY_DIR}/pandaVersion.h