]> Creatis software - gdcm.git/blobdiff - vtk/CMakeLists.txt
Fix comments
[gdcm.git] / vtk / CMakeLists.txt
index bf3f5532779998cc76b61d4f2e3c6ca50aa8df37..72d0a74b25c4f0e612fd6a76a502d38b1cb3d71a 100644 (file)
@@ -43,17 +43,36 @@ TARGET_LINK_LIBRARIES(vtkgdcmdemo
 SET(vtkgdcmViewer_SOURCES
   vtkgdcmViewer.cxx
 )
-ADD_EXECUTABLE(vtkgdcmViewer ${vtkgdcmViewer_SOURCES})
+
+# let's do some APPLE/WIN32 magic here
+#IF(WIN32)
+#  SET(GUI_EXECUTABLE WIN32)
+#ENDIF(WIN32)
+IF(APPLE)
+  IF(VTK_USE_CARBON)
+    SET(GUI_EXECUTABLE MACOSX_BUNDLE)
+  ENDIF(VTK_USE_CARBON)
+  IF(VTK_USE_COCOA)
+    SET(GUI_EXECUTABLE MACOSX_BUNDLE)
+  ENDIF(VTK_USE_COCOA)
+  # when using X11 on Apple you don't need this...
+ENDIF(APPLE)
+
+ADD_EXECUTABLE(vtkgdcmViewer ${GUI_EXECUTABLE} ${vtkgdcmViewer_SOURCES})
 TARGET_LINK_LIBRARIES(vtkgdcmViewer
   vtkgdcm
   vtkRendering
 )
-ADD_EXECUTABLE(vtkgdcmViewer2 vtkgdcmViewer2.cxx)
+ADD_EXECUTABLE(vtkgdcmViewer2 ${GUI_EXECUTABLE} vtkgdcmViewer2.cxx)
 TARGET_LINK_LIBRARIES(vtkgdcmViewer2
   vtkgdcm
   vtkRendering
 )
-
+ADD_EXECUTABLE(vtkgdcmSerieViewer ${GUI_EXECUTABLE} vtkgdcmSerieViewer.cxx)
+TARGET_LINK_LIBRARIES(vtkgdcmSerieViewer
+  vtkgdcm
+  vtkRendering
+)
 #-----------------------------------------------------------------------------
 SET(vtkWriteDicom_SOURCES
   vtkWriteDicom.cxx
@@ -73,4 +92,4 @@ INSTALL_FILES(/include/gdcm FILES vtkGdcmWriter.h)
 INSTALL_TARGETS(/lib/gdcm/ vtkgdcm)
 INSTALL_TARGETS(/bin/ vtkgdcmViewer)
 INSTALL_TARGETS(/bin/ vtkgdcmViewer2)
-
+INSTALL_TARGETS(/bin/ vtkgdcmSerieViewer)