Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(335)

Unified Diff: cmake/CMakeLists.txt

Issue 1975933002: cmake: fixes for windows (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Created 4 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | cmake/README.md » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cmake/CMakeLists.txt
diff --git a/cmake/CMakeLists.txt b/cmake/CMakeLists.txt
index f1a96a981854f215432b7f6e9c2a04c7f8b30328..bdb5ecb640196429482ae4bd9bdd34db2fd6d32b 100644
--- a/cmake/CMakeLists.txt
+++ b/cmake/CMakeLists.txt
@@ -123,10 +123,12 @@ file (GLOB_RECURSE ssse3_srcs ../src/*ssse3*.cpp ../src/*SSSE3*.cpp)
file (GLOB_RECURSE sse41_srcs ../src/*sse4*.cpp ../src/*SSE4*.cpp)
file (GLOB_RECURSE avx_srcs ../src/*_avx.cpp)
file (GLOB_RECURSE avx2_srcs ../src/*_avx2.cpp)
-set_source_files_properties(${ssse3_srcs} PROPERTIES COMPILE_FLAGS -mssse3)
-set_source_files_properties(${sse41_srcs} PROPERTIES COMPILE_FLAGS -msse4.1)
-set_source_files_properties(${avx_srcs} PROPERTIES COMPILE_FLAGS -mavx)
-set_source_files_properties(${avx2_srcs} PROPERTIES COMPILE_FLAGS -mavx2)
+if (NOT WIN32)
+ set_source_files_properties(${ssse3_srcs} PROPERTIES COMPILE_FLAGS -mssse3)
+ set_source_files_properties(${sse41_srcs} PROPERTIES COMPILE_FLAGS -msse4.1)
+ set_source_files_properties(${avx_srcs} PROPERTIES COMPILE_FLAGS -mavx)
+ set_source_files_properties(${avx2_srcs} PROPERTIES COMPILE_FLAGS -mavx2)
+endif()
# Detect our optional dependencies.
# If we can't find them, don't build the parts of Skia that use them.
@@ -265,6 +267,7 @@ target_link_libraries(skia
PRIVATE ${libs})
if (MSVC)
+ string(REGEX REPLACE " /W3 " " " CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS}")
set(cc_flags "/w /GR-")
else()
set(cc_flags "-w -fno-rtti -fno-exceptions")
« no previous file with comments | « no previous file | cmake/README.md » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698