From c34d99e40e914e16431234c484eafcb34fda1b06 Mon Sep 17 00:00:00 2001 From: Tillmann Karras Date: Tue, 4 Nov 2014 02:29:33 +0100 Subject: [PATCH] Work around LLVM header peculiarity Bug report: http://llvm.org/bugs/show_bug.cgi?id=21472 --- CMakeLists.txt | 5 +++++ Source/Core/VideoCommon/CMakeLists.txt | 1 - 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index baad81aca4..83f7b6ddf9 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -764,6 +764,11 @@ add_custom_command(TARGET unittests POST_BUILD COMMAND ${CMAKE_CTEST_COMMAND}) # Start compiling our code # add_definitions(-std=gnu++0x) + +# These aren't actually needed for C11/C++11 +# but some dependencies require them (LLVM, libav). +add_definitions(-D__STDC_LIMIT_MACROS -D__STDC_CONSTANT_MACROS) + add_subdirectory(Source) diff --git a/Source/Core/VideoCommon/CMakeLists.txt b/Source/Core/VideoCommon/CMakeLists.txt index df783cac0e..87b23a25ff 100644 --- a/Source/Core/VideoCommon/CMakeLists.txt +++ b/Source/Core/VideoCommon/CMakeLists.txt @@ -59,6 +59,5 @@ add_dolphin_library(videocommon "${SRCS}" "${LIBS}") if(${CMAKE_SYSTEM_NAME} MATCHES "Linux") if(LIBAV_FOUND) target_link_libraries(videocommon ${LIBS} ${LIBAV_LIBRARIES}) - add_definitions(-D__STDC_CONSTANT_MACROS) endif() endif()