From 1a4d66c84ecb56abf116f81e919c810fe1c6648e Mon Sep 17 00:00:00 2001
From: Ulrich Kemloh <kemlohulrich@gmail.com>
Date: Sun, 2 Nov 2014 16:22:56 +0100
Subject: [PATCH] OSX compatibilty

---
 JPSvis.pro   | 37 ++++++++++++++++++++++++++++++++++++-
 src/main.cpp |  1 +
 2 files changed, 37 insertions(+), 1 deletion(-)

diff --git a/JPSvis.pro b/JPSvis.pro
index c90dd42..54961cf 100644
--- a/JPSvis.pro
+++ b/JPSvis.pro
@@ -378,7 +378,7 @@ LIBS += -L/usr/lib \
  }
  
 #Static compilation linux
-unix {
+unix:!macx {
 #INCLUDEPATH += /usr/include/vtk-5.8
 #LIBS += -L/usr/lib \
 INCLUDEPATH +=/usr/local/include/vtk-5.10
@@ -415,6 +415,41 @@ LIBS += -L/usr/local/lib/vtk-5.10 \
  }
 
 macx {
+        INCLUDEPATH += /Users/piccolo/VTK6/include/vtk-6.1
+        LIBS += -L/Users/piccolo/VTK6/lib \
+            /Users/piccolo/VTK6/lib/libvtkFiltersGeometry-6.1.a /Users/piccolo/VTK6/lib/libvtkFiltersCore-6.1.a \
+            /Users/piccolo/VTK6/lib/libvtkCommonExecutionModel-6.1.a /Users/piccolo/VTK6/lib/libvtkCommonDataModel-6.1.a \
+            /Users/piccolo/VTK6/lib/libvtkCommonMath-6.1.a /Users/piccolo/VTK6/lib/libvtkCommonCore-6.1.a \
+            /Users/piccolo/VTK6/lib/libvtksys-6.1.a /Users/piccolo/VTK6/lib/libvtkCommonMisc-6.1.a \
+            /Users/piccolo/VTK6/lib/libvtkCommonSystem-6.1.a /Users/piccolo/VTK6/lib/libvtkCommonTransforms-6.1.a \
+            /Users/piccolo/VTK6/lib/libvtkFiltersModeling-6.1.a /Users/piccolo/VTK6/lib/libvtkFiltersGeneral-6.1.a \
+            /Users/piccolo/VTK6/lib/libvtkCommonComputationalGeometry-6.1.a /Users/piccolo/VTK6/lib/libvtkFiltersSources-6.1.a \
+            /Users/piccolo/VTK6/lib/libvtkIOImage-6.1.a /Users/piccolo/VTK6/lib/libvtkDICOMParser-6.1.a \
+            /Users/piccolo/VTK6/lib/libvtkIOCore-6.1.a /Users/piccolo/VTK6/lib/libvtkzlib-6.1.a \
+            /Users/piccolo/VTK6/lib/libvtkmetaio-6.1.a /Users/piccolo/VTK6/lib/libvtkjpeg-6.1.a \
+            /Users/piccolo/VTK6/lib/libvtkpng-6.1.a /Users/piccolo/VTK6/lib/libvtktiff-6.1.a \
+            /Users/piccolo/VTK6/lib/libvtkIOXML-6.1.a /Users/piccolo/VTK6/lib/libvtkIOGeometry-6.1.a /Users/piccolo/VTK6/lib/libvtkjsoncpp-6.1.a \
+            /Users/piccolo/VTK6/lib/libvtkIOXMLParser-6.1.a /Users/piccolo/VTK6/lib/libvtkexpat-6.1.a /Users/piccolo/VTK6/lib/libvtkImagingStatistics-6.1.a \
+            /Users/piccolo/VTK6/lib/libvtkImagingCore-6.1.a /Users/piccolo/VTK6/lib/libvtkInteractionStyle-6.1.a /Users/piccolo/VTK6/lib/libvtkFiltersExtraction-6.1.a \
+            /Users/piccolo/VTK6/lib/libvtkFiltersStatistics-6.1.a /Users/piccolo/VTK6/lib/libvtkImagingFourier-6.1.a /Users/piccolo/VTK6/lib/libvtkalglib-6.1.a \
+            /Users/piccolo/VTK6/lib/libvtkRenderingCore-6.1.a /Users/piccolo/VTK6/lib/libvtkRenderingVolumeOpenGL-6.1.a /Users/piccolo/VTK6/lib/libvtkRenderingOpenGL-6.1.a \
+            /Users/piccolo/VTK6/lib/libvtkImagingHybrid-6.1.a /Users/piccolo/VTK6/lib/libvtkRenderingVolume-6.1.a /Users/piccolo/VTK6/lib/libvtkTestingRendering-6.1.a \
+            -framework AGL -framework OpenGL -framework ApplicationServices -framework IOKit -framework Cocoa /Users/piccolo/VTK6/lib/libvtkIOImage-6.1.a \
+            /Users/piccolo/VTK6/lib/libvtkDICOMParser-6.1.a /Users/piccolo/VTK6/lib/libvtkIOCore-6.1.a /Users/piccolo/VTK6/lib/libvtkmetaio-6.1.a /Users/piccolo/VTK6/lib/libvtkpng-6.1.a \
+            /Users/piccolo/VTK6/lib/libvtktiff-6.1.a /Users/piccolo/VTK6/lib/libvtkzlib-6.1.a /Users/piccolo/VTK6/lib/libvtkjpeg-6.1.a -lm /Users/piccolo/VTK6/lib/libvtkRenderingCore-6.1.a \
+            /Users/piccolo/VTK6/lib/libvtkFiltersGeometry-6.1.a /Users/piccolo/VTK6/lib/libvtkFiltersSources-6.1.a /Users/piccolo/VTK6/lib/libvtkFiltersExtraction-6.1.a \
+            /Users/piccolo/VTK6/lib/libvtkFiltersGeneral-6.1.a /Users/piccolo/VTK6/lib/libvtkFiltersCore-6.1.a /Users/piccolo/VTK6/lib/libvtkCommonComputationalGeometry-6.1.a \
+            /Users/piccolo/VTK6/lib/libvtkFiltersStatistics-6.1.a /Users/piccolo/VTK6/lib/libvtkImagingFourier-6.1.a /Users/piccolo/VTK6/lib/libvtkImagingCore-6.1.a \
+            /Users/piccolo/VTK6/lib/libvtkCommonExecutionModel-6.1.a /Users/piccolo/VTK6/lib/libvtkCommonDataModel-6.1.a /Users/piccolo/VTK6/lib/libvtkCommonMisc-6.1.a \
+            /Users/piccolo/VTK6/lib/libvtkCommonSystem-6.1.a /Users/piccolo/VTK6/lib/libvtkCommonTransforms-6.1.a /Users/piccolo/VTK6/lib/libvtkCommonMath-6.1.a \
+            /Users/piccolo/VTK6/lib/libvtkCommonCore-6.1.a /Users/piccolo/VTK6/lib/libvtksys-6.1.a /Users/piccolo/VTK6/lib/libvtkalglib-6.1.a \
+            /Users/piccolo/VTK6/lib/libvtkRenderingAnnotation-6.1.a  /Users/piccolo/VTK6/lib/libvtkRenderingLabel-6.1.a       \
+            /Users/piccolo/VTK6/lib/libvtkRenderingFreeType-6.1.a /Users/piccolo/VTK6/lib/libvtkfreetype-6.1.a /Users/piccolo/VTK6/lib/libvtkftgl-6.1.a \
+            /Users/piccolo/VTK6/lib/libvtkRenderingCore-6.1.a  /Users/piccolo/VTK6/lib/libvtkRenderingFreeTypeOpenGL-6.1.a \
+
+}
+
+macx_dyn {
         INCLUDEPATH += /Users/piccolo/VTK/include/vtk-6.1
 
         LIBS += -L/Users/piccolo/VTK/lib \
diff --git a/src/main.cpp b/src/main.cpp
index d6790d5..e9ee6be 100644
--- a/src/main.cpp
+++ b/src/main.cpp
@@ -54,6 +54,7 @@
 
 #include <QApplication>
 #include "MainWindow.h"
+#include <locale.h>
 
 
 #define vtkErrorMacro (x) ()
-- 
GitLab