]> SALOME platform Git repositories - modules/kernel.git/commitdiff
Salome HOME
bos #42382: [CEA][Windows] KERNEL compilation broken by commit 02ccddf4c bos/42382 V9_13_0b1 11/head
authorNabil Ghodbane <nabil.ghodbane@cea.fr>
Thu, 27 Jun 2024 12:43:05 +0000 (14:43 +0200)
committerNabil Ghodbane <nabil.ghodbane@cea.fr>
Thu, 27 Jun 2024 12:43:05 +0000 (14:43 +0200)
src/Launcher_SWIG/CMakeLists.txt
src/Launcher_SWIG/LauncherResourceDefinition.hxx

index 357aef6b02638e38d3109825ac02270c3404e489..76e73d525fe0b399852ab8f77cc56fd4be8ef758 100644 (file)
@@ -43,14 +43,23 @@ INCLUDE_DIRECTORIES(
 ADD_LIBRARY(LauncherWrapHelper LauncherResourceDefinition.cxx)
 TARGET_LINK_LIBRARIES(LauncherWrapHelper Launcher)
 INSTALL(TARGETS LauncherWrapHelper EXPORT ${PROJECT_NAME}TargetGroup DESTINATION ${SALOME_INSTALL_LIBS})
-
+IF(WIN32)
+  ADD_LIBRARY(LauncherWrapHelper_static STATIC  LauncherResourceDefinition.cxx)
+  SET_TARGET_PROPERTIES(LauncherWrapHelper_static PROPERTIES OUTPUT_NAME LauncherWrapHelper)
+  TARGET_LINK_LIBRARIES(LauncherWrapHelper_static  Launcher)
+  INSTALL(TARGETS LauncherWrapHelper_static EXPORT ${PROJECT_NAME}TargetGroup DESTINATION ${SALOME_INSTALL_LIBS})
+ENDIF(WIN32)
 SWIG_ADD_LIBRARY(${Launcher_target_name} LANGUAGE python SOURCES Launcher.i)
 
 IF(${MACHINE} STREQUAL WINDOWS)
   SET_TARGET_PROPERTIES(_${Launcher_target_name} PROPERTIES DEBUG_OUTPUT_NAME _${Launcher_target_name}_d)
 ENDIF(${MACHINE} STREQUAL WINDOWS)
 
-SWIG_LINK_LIBRARIES(${Launcher_target_name} ${PYTHON_LIBRARIES} ${PLATFORM_LIBS} LauncherWrapHelper)
+IF(WIN32)
+  SWIG_LINK_LIBRARIES(${Launcher_target_name} ${PYTHON_LIBRARIES} ${PLATFORM_LIBS} LauncherWrapHelper_static)
+ELSE(WIN32)
+  SWIG_LINK_LIBRARIES(${Launcher_target_name} ${PYTHON_LIBRARIES} ${PLATFORM_LIBS} LauncherWrapHelper)
+ENDIF(WIN32)
 
 SWIG_CHECK_GENERATION(${Launcher_target_name})
 
index 9b32bb8e5356d13aaa7255e5f955d66bb36ef8c1..d5eb65cc7ca06ac7374d0635afffe133b12a8333 100644 (file)
 #include "SALOME_Launcher_SWIG.hxx"
 #include "SALOME_ResourcesCatalog_Parser.hxx"
 
-#ifndef SWIG
-struct LAUNCHER_SWIG_EXPORT ResourceDefinition_cpp
-#else
-struct ResourceDefinition_cpp
-#endif
+
+typedef struct ResourceDefinition_cpp
 {
 public:
   std::string name;
@@ -49,4 +46,4 @@ public:
 public:
   void fromPRT(const ParserResourcesType& other);
   ParserResourcesType toPRT() const;
-};
+}ResourceDefinition_cpp ;