Salome HOME
Workaround about SWIG_ADD_MODULE bug: remove duplicates in include directories
authorvsr <vsr@opencascade.com>
Tue, 29 Oct 2013 07:31:44 +0000 (07:31 +0000)
committervsr <vsr@opencascade.com>
Tue, 29 Oct 2013 07:31:44 +0000 (07:31 +0000)
src/SMESH_SWIG_WITHIHM/CMakeLists.txt

index ded3967..0a3e364 100644 (file)
@@ -74,6 +74,11 @@ SET(SMESH_Swig_SOURCES
   ${SMESH_Swig_HEADERS}
 )
 
+# workaround about SWIG_ADD_MODULE bug: remove duplicates in include directories
+GET_DIRECTORY_PROPERTY(_cmake_include_directories INCLUDE_DIRECTORIES)
+LIST(REMOVE_DUPLICATES _cmake_include_directories)
+SET_DIRECTORY_PROPERTIES(PROPERTIES INCLUDE_DIRECTORIES "${_cmake_include_directories}")
+
 # swig flags
 SET_SOURCE_FILES_PROPERTIES(libSMESH_Swig.i PROPERTIES CPLUSPLUS ON)
 SET_SOURCE_FILES_PROPERTIES(libSMESH_Swig.i PROPERTIES SWIG_DEFINITIONS "-shadow")