소스 검색

Fix Cuda compilation issue on Windows. (#1747)

Only propagates /bigobj flag to C++ files, as the option is not
recognized by nvcc.

Fixes #1722
Jérémie Dumas 4 년 전
부모
커밋
b44b9ec895
1개의 변경된 파일1개의 추가작업 그리고 1개의 파일을 삭제
  1. 1 1
      cmake/libigl.cmake

+ 1 - 1
cmake/libigl.cmake

@@ -84,7 +84,7 @@ target_compile_features(igl_common INTERFACE ${CXX11_FEATURES})
 # Other compilation flags
 if(MSVC)
   # Enable parallel compilation for Visual Studio
-  target_compile_options(igl_common INTERFACE /MP /bigobj)
+  target_compile_options(igl_common INTERFACE /MP $<$<COMPILE_LANGUAGE:CXX>:/bigobj>)
   target_compile_definitions(igl_common INTERFACE -DNOMINMAX)
 endif()