mirror of
https://github.com/citra-emu/citra.git
synced 2024-11-29 17:10:05 +00:00
Fixing cmake to support clang-cl
This commit is contained in:
parent
3174bfd50c
commit
105926e51e
@ -62,8 +62,12 @@ if (NOT DEFINED ARCHITECTURE)
|
|||||||
endif()
|
endif()
|
||||||
message(STATUS "Target architecture: ${ARCHITECTURE}")
|
message(STATUS "Target architecture: ${ARCHITECTURE}")
|
||||||
|
|
||||||
|
IF (WIN32 AND (${CMAKE_CXX_COMPILER_ID} MATCHES "Clang"))
|
||||||
|
set(CMAKE_CXX_FLAGS "-Xclang -std=c++14")# -Qunused-arguments -Xclang -Wno-missing-braces ")
|
||||||
|
ELSE()
|
||||||
set(CMAKE_CXX_STANDARD 14)
|
set(CMAKE_CXX_STANDARD 14)
|
||||||
set(CMAKE_CXX_STANDARD_REQUIRED ON)
|
set(CMAKE_CXX_STANDARD_REQUIRED ON)
|
||||||
|
ENDIF()
|
||||||
|
|
||||||
if (NOT MSVC)
|
if (NOT MSVC)
|
||||||
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-attributes")
|
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-attributes")
|
||||||
@ -98,7 +102,7 @@ else()
|
|||||||
# /Zo - enahnced debug info for optimized builds
|
# /Zo - enahnced debug info for optimized builds
|
||||||
set(CMAKE_C_FLAGS "/W3 /MP /Zi /Zo" CACHE STRING "" FORCE)
|
set(CMAKE_C_FLAGS "/W3 /MP /Zi /Zo" CACHE STRING "" FORCE)
|
||||||
# /EHsc - C++-only exception handling semantics
|
# /EHsc - C++-only exception handling semantics
|
||||||
set(CMAKE_CXX_FLAGS "${CMAKE_C_FLAGS} /EHsc" CACHE STRING "" FORCE)
|
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${CMAKE_C_FLAGS} /EHsc" CACHE STRING "" FORCE)
|
||||||
|
|
||||||
# /MDd - Multi-threaded Debug Runtime DLL
|
# /MDd - Multi-threaded Debug Runtime DLL
|
||||||
set(CMAKE_C_FLAGS_DEBUG "/Od /MDd" CACHE STRING "" FORCE)
|
set(CMAKE_C_FLAGS_DEBUG "/Od /MDd" CACHE STRING "" FORCE)
|
||||||
|
Loading…
Reference in New Issue
Block a user