[Paraview] howto : Build paraview (git master) on OSX 10.9
Biddiscombe, John A.
biddisco at cscs.ch
Thu Nov 7 07:38:31 EST 2013
Just in case anyone else makes the attempt and fails and to remind myself when I lose my config … (apologies, I’ve never used a mac before, so I’m new to this and I’ve had it less than 24 hours so it may be there are easier ways to get this done).
Assuming you are using default clang
/usr/bin/c++ --version
Apple LLVM version 5.0 (clang-500.2.79) (based on LLVM 3.3svn)
Target: x86_64-apple-darwin13.0.2
Thread model: posix
qt4 - did not compile out of the box, this link
http://trac.macports.org/ticket/40852
lists a bunch of patches. I downloaded the diffs for the Qt part (ignore the mac ports diffs) and applied them to the qt-4.8.5 source from
http://download.qt-project.org/official_releases/qt/4.8/4.8.5/qt-everywhere-opensource-src-4.8.5.tar.gz
I only applied the patches with .2 in them where there are more than one for the same file (was that wrong?)
patch-src_3rdparty_clucene_src_CLucene_search_FieldCacheImpl.cpp.diff
patch-src_3rdparty_webkit_Source_WebCore_platform_Timer.cpp.2.diff
patch-src_3rdparty_webkit_Source_WebCore_platform_Timer.cpp.diff
patch-src_3rdparty_webkit_Source_WebCore_platform_Timer.h.diff
patch-src_3rdparty_webkit_Source_WebCore_platform_network_qt_QNetworkReplyHandler.cpp.diff
patch-src_3rdparty_webkit_Source_WebKit_qt_Api_qgraphicswebview.cpp.diff
patch-src_3rdparty_webkit_Source_WebKit_qt_QtWebKit.pro-2.diff
patch-src_3rdparty_webkit_Source_WebKit_qt_QtWebKit.pro.diff
patch-src_3rdparty_webkit_Source_WebKit_qt_WebCoreSupport_NotificationPresenterClientQt.cpp.diff
patch-src_corelib_global_qglobal.h.diff
patch-src_plugins_bearer_corewlan_qcorewlanengine.mm.diff
To build Qt I used the following config line (I had to disable webkit even with the patches supplied, also lib tiff gave me trouble so I disabled that too)
configure --prefix=/Users/biddisco/apps/qt/4.8.5/clang_64 -system-zlib -confirm-license -opensource -nomake demos -nomake examples -cocoa -fast -release -no-3dnow -L/opt/X11/lib -I/opt/X11/include -platform unsupported/macx-clang -no-qt3support -no-libtiff -no-webkit -nomake docs -arch x86_64
Mpich-3.0.4 did not compile out of the box either, so instead I installed ‘brew’ for package management and used
brew install mpich2
Which in fact installs
mpich2-3.0.4
Which is just what we want
Before building paraview, apply a couple of small patches
diff --git a/ParaViewCore/ServerManager/Core/vtkSMRangeDomainTemplate.h b/ParaViewCore/ServerManager/Core/vtkSMRangeDomainTemplate.h
index e08931a..8b2c832 100644
--- a/ParaViewCore/ServerManager/Core/vtkSMRangeDomainTemplate.h
+++ b/ParaViewCore/ServerManager/Core/vtkSMRangeDomainTemplate.h
@@ -158,7 +158,7 @@ protected:
this->Valid[0] = this->Valid[1] = true;
}
- bool operator==(const vtkEntry& other)
+ bool operator==(const vtkEntry& other) const
{
return this->Valid == other.Valid && this->Value == other.Value;
}
diff --git a/CMake/branded_paraview_main.cxx.in b/CMake/branded_paraview_main.cxx.in
index ddec6fb..e1f2fa8 100644
--- a/CMake/branded_paraview_main.cxx.in
+++ b/CMake/branded_paraview_main.cxx.in
@@ -44,6 +44,7 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#endif
#include <clocale>
+#include "stdlib.h"
int main(int argc, char* argv[])
{
And in google protbuf
diff --git a/src/google/protobuf/message.h b/src/google/protobuf/message.h
index c0062f9..98a5812 100644
--- a/src/google/protobuf/message.h
+++ b/src/google/protobuf/message.h
@@ -116,7 +116,7 @@
// HP C++'s iosfwd doesn't work.
#include <iostream>
#else
-#include <iosfwd>
+#include <sstream>
#endif
#include <google/protobuf/message_lite.h>
Then run cmake (installed by brew also) in the paraview tree and configure with MPI etc and build. Disable webkit (needs to be done in several places which is a bit annoying)
My paraview seems to be working fine. Tested mpiexec –n 2 bin/pvserver and all is correct, I can render a sphere and see each process doing the right thing.
HTH
JB
--
John Biddiscombe, email:biddisco @.at.@ cscs.ch
http://www.cscs.ch/
CSCS, Swiss National Supercomputing Centre | Tel: +41 (91) 610.82.07
Via Trevano 131, 6900 Lugano, Switzerland | Fax: +41 (91) 610.82.82
More information about the ParaView
mailing list