mirror of
https://github.com/baldurk/renderdoc.git
synced 2026-05-06 01:50:38 +00:00
Fix compilation on GCC 8. Closes #984
This commit is contained in:
@@ -125,13 +125,14 @@ file(WRITE
|
||||
"\n"
|
||||
"OSX_ICONFILE=${CMAKE_CURRENT_BINARY_DIR}/RenderDoc.icns\n")
|
||||
|
||||
# propagate build version info. Lots of escaping needed here to pass ""s into the define value
|
||||
# Ignore warnings - qmake has no way to do this per-file, so we must do it globally
|
||||
if(CMAKE_COMPILER_IS_GNUCXX)
|
||||
file(APPEND
|
||||
${CMAKE_BINARY_DIR}/qrenderdoc/qrenderdoc_cmake.pri
|
||||
"QMAKE_CXXFLAGS+=-Wno-unknown-warning -Wno-implicit-fallthrough\n")
|
||||
"QMAKE_CXXFLAGS+=-Wno-unknown-warning -Wno-implicit-fallthrough -Wno-cast-function-type -Wno-stringop-truncation\n")
|
||||
endif()
|
||||
|
||||
# propagate build version info. Lots of escaping needed here to pass ""s into the define value
|
||||
file(APPEND
|
||||
${CMAKE_BINARY_DIR}/qrenderdoc/qrenderdoc_cmake.pri
|
||||
"DEFINES+=GIT_COMMIT_HASH='\\\\\"${GIT_COMMIT_HASH}\\\\\"'\n")
|
||||
|
||||
@@ -15,7 +15,13 @@ set(MODULE_INCLUDES
|
||||
set(MODULE_DEFINES
|
||||
PRIVATE -DRENDERDOC_PLATFORM_LINUX)
|
||||
|
||||
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-unknown-warning-option -Wno-unused-private-field")
|
||||
if(CMAKE_CXX_COMPILER_ID MATCHES "Clang")
|
||||
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-unknown-warning-option -Wno-unused-private-field")
|
||||
endif()
|
||||
|
||||
if(CMAKE_COMPILER_IS_GNUCXX)
|
||||
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-cast-function-type -Wno-stringop-truncation")
|
||||
endif()
|
||||
|
||||
# Set up rpath to find librenderdoc.so
|
||||
set(CMAKE_SKIP_BUILD_RPATH TRUE)
|
||||
|
||||
Reference in New Issue
Block a user