From d3c9ee685713ccbe443571b8ab4fbe4c2fbcd4e0da6123a2dd649c9a3d400037 Mon Sep 17 00:00:00 2001 From: Christoph G Date: Sat, 3 Dec 2016 13:07:03 +0000 Subject: [PATCH] Accepting request 443561 from home:badshah400:branches:science Update to v5.2. Switch to Qt5 if available, several other improvements (see .changes) OBS-URL: https://build.opensuse.org/request/show/443561 OBS-URL: https://build.opensuse.org/package/show/science/paraview?expand=0&rev=45 --- ParaView-v5.1.2.tar.gz | 3 - ParaView-v5.2.0.tar.gz | 3 + ParaViewGettingStarted-5.2.0.pdf | 3 + ParaViewGuide-5.2.0.pdf | 3 + ParaViewTutorial.pdf | 3 + ...uild-sciberquesttoolkit-with-opengl2.patch | 23 +++ paraview-default-qtstyle.patch | 8 +- paraview-desktop-entry-fix.patch | 6 +- paraview-find-qhelpgenerator-qt5.patch | 42 +++++ paraview-fix-file-contains-date-time.patch | 12 +- paraview-pythonqt-build-fix.patch | 45 ++++++ paraview.changes | 34 ++++ paraview.spec | 148 +++++++++++------- require-only-cmake-3_0.patch | 11 -- 14 files changed, 258 insertions(+), 86 deletions(-) delete mode 100644 ParaView-v5.1.2.tar.gz create mode 100644 ParaView-v5.2.0.tar.gz create mode 100644 ParaViewGettingStarted-5.2.0.pdf create mode 100644 ParaViewGuide-5.2.0.pdf create mode 100644 ParaViewTutorial.pdf create mode 100644 paraview-build-sciberquesttoolkit-with-opengl2.patch create mode 100644 paraview-find-qhelpgenerator-qt5.patch create mode 100644 paraview-pythonqt-build-fix.patch delete mode 100644 require-only-cmake-3_0.patch diff --git a/ParaView-v5.1.2.tar.gz b/ParaView-v5.1.2.tar.gz deleted file mode 100644 index 2d41c9a..0000000 --- a/ParaView-v5.1.2.tar.gz +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:ff02b7307a256b7c6e8ad900dee5796297494df7f9a0804fe801eb2f66e6a187 -size 51635420 diff --git a/ParaView-v5.2.0.tar.gz b/ParaView-v5.2.0.tar.gz new file mode 100644 index 0000000..a982c88 --- /dev/null +++ b/ParaView-v5.2.0.tar.gz @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:894e42ef8475bb49e4e7e64f4ee2c37c714facd18bfbb1d6de7f69676b062c96 +size 47087129 diff --git a/ParaViewGettingStarted-5.2.0.pdf b/ParaViewGettingStarted-5.2.0.pdf new file mode 100644 index 0000000..af1e779 --- /dev/null +++ b/ParaViewGettingStarted-5.2.0.pdf @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:5c44fe986a0efe8027ee44bba18a2a129575c136458a7e542706b3d03672e205 +size 898741 diff --git a/ParaViewGuide-5.2.0.pdf b/ParaViewGuide-5.2.0.pdf new file mode 100644 index 0000000..1418d80 --- /dev/null +++ b/ParaViewGuide-5.2.0.pdf @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:22f709c73f9c8e0ba600dd351e3881baef0adc0deae8541b9d14bd12acf105f1 +size 39313719 diff --git a/ParaViewTutorial.pdf b/ParaViewTutorial.pdf new file mode 100644 index 0000000..44b8c21 --- /dev/null +++ b/ParaViewTutorial.pdf @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:9ed9d020de2abd2c265f1e2b5dd9b4acdcb57a31fd169ac884121c533aa61781 +size 46108965 diff --git a/paraview-build-sciberquesttoolkit-with-opengl2.patch b/paraview-build-sciberquesttoolkit-with-opengl2.patch new file mode 100644 index 0000000..5e2bc4e --- /dev/null +++ b/paraview-build-sciberquesttoolkit-with-opengl2.patch @@ -0,0 +1,23 @@ +Index: ParaView-v5.2.0/Plugins/SciberQuestToolKit/plugin.cmake +=================================================================== +--- ParaView-v5.2.0.orig/Plugins/SciberQuestToolKit/plugin.cmake ++++ ParaView-v5.2.0/Plugins/SciberQuestToolKit/plugin.cmake +@@ -1,4 +1,4 @@ +-if(VTK_RENDERING_BACKEND STREQUAL "OpenGL") ++if(VTK_RENDERING_BACKEND STREQUAL "OpenGL" OR VTK_RENDERING_BACKEND STREQUAL "OpenGL2") + pv_plugin(SciberQuestToolKit + DESCRIPTION + "SciberQuestToolKit - Domain specific visualization tools for magnetospheric sciences." +Index: ParaView-v5.2.0/Plugins/SciberQuestToolKit/SciberQuest/module.cmake +=================================================================== +--- ParaView-v5.2.0.orig/Plugins/SciberQuestToolKit/SciberQuest/module.cmake ++++ ParaView-v5.2.0/Plugins/SciberQuestToolKit/SciberQuest/module.cmake +@@ -14,7 +14,7 @@ vtk_module(vtkSciberQuest + vtkPVCommon + vtkPVServerManagerApplication + vtkParallelCore +- vtkRenderingOpenGL ++ vtkRenderingOpenGL2 + vtksys + TEST_LABELS + PARAVIEW diff --git a/paraview-default-qtstyle.patch b/paraview-default-qtstyle.patch index e8c2c08..5a69bc5 100644 --- a/paraview-default-qtstyle.patch +++ b/paraview-default-qtstyle.patch @@ -1,6 +1,8 @@ ---- ParaView-v5.1.0_old/CMake/branded_paraview_main.cxx.in 2016-06-18 11:39:09.000000000 -0400 -+++ ParaView-v5.1.0/CMake/branded_paraview_main.cxx.in 2016-06-21 08:01:39.384393053 -0400 -@@ -72,15 +72,15 @@ +Index: ParaView-v5.2.0/CMake/branded_paraview_main.cxx.in +=================================================================== +--- ParaView-v5.2.0.orig/CMake/branded_paraview_main.cxx.in ++++ ParaView-v5.2.0/CMake/branded_paraview_main.cxx.in +@@ -72,15 +72,15 @@ static bool checkenv(const char* vname) int main(int argc, char* argv[]) { diff --git a/paraview-desktop-entry-fix.patch b/paraview-desktop-entry-fix.patch index 0195020..c6507cd 100644 --- a/paraview-desktop-entry-fix.patch +++ b/paraview-desktop-entry-fix.patch @@ -1,7 +1,7 @@ -Index: ParaView-v4.2.0-source/Applications/ParaView/paraview.desktop.in +Index: ParaView-v5.2.0/Applications/ParaView/paraview.desktop.in =================================================================== ---- ParaView-v4.2.0-source.orig/Applications/ParaView/paraview.desktop.in -+++ ParaView-v4.2.0-source/Applications/ParaView/paraview.desktop.in +--- ParaView-v5.2.0.orig/Applications/ParaView/paraview.desktop.in ++++ ParaView-v5.2.0/Applications/ParaView/paraview.desktop.in @@ -1,7 +1,9 @@ [Desktop Entry] -Version=@PARAVIEW_VERSION_FULL@ diff --git a/paraview-find-qhelpgenerator-qt5.patch b/paraview-find-qhelpgenerator-qt5.patch new file mode 100644 index 0000000..f3ed0ef --- /dev/null +++ b/paraview-find-qhelpgenerator-qt5.patch @@ -0,0 +1,42 @@ +Index: ParaView-v5.2.0/CMake/ParaViewMacros.cmake +=================================================================== +--- ParaView-v5.2.0.orig/CMake/ParaViewMacros.cmake ++++ ParaView-v5.2.0/CMake/ParaViewMacros.cmake +@@ -251,9 +251,16 @@ function (generate_htmls_from_xmls outpu + # file we use. + get_filename_component(first_xml "${first_xml}" NAME) + ++ if (PARAVIEW_QT_VERSION STREQUAL "4") ++ set(qt_binary_dir_hints "${QT_BINARY_DIR}") ++ else() # Qt5 ++ # Qt5's CMake config doesn't support QT_BINARY_DIR ++ set(qt_binary_dir_hints "${Qt5_DIR}/../../../bin") ++ endif() ++ + find_program(QT_XMLPATTERNS_EXECUTABLE +- xmlpatterns +- HINTS "${QT_BINARY_DIR}" ++ NAMES xmlpatterns xmlpatterns-qt5 ++ HINTS "${qt_binary_dir_hints}" + DOC "xmlpatterns used to generate html from Proxy documentation.") + mark_as_advanced(QT_XMLPATTERNS_EXECUTABLE) + +@@ -339,9 +346,16 @@ function(build_help_project name) + message(FATAL_ERROR "No DESTINATION_DIRECTORY specified in build_help_project()") + endif() + ++ if (PARAVIEW_QT_VERSION STREQUAL "4") ++ set(qt_binary_dir_hints "${QT_BINARY_DIR}") ++ else() # Qt5 ++ # Qt5's CMake config doesn't support QT_BINARY_DIR ++ set(qt_binary_dir_hints "${Qt5_DIR}/../../../bin") ++ endif() ++ + find_program(QT_HELP_GENERATOR +- qhelpgenerator +- HINTS "${QT_BINARY_DIR}" ++ NAMES qhelpgenerator qhelpgenerator-qt5 ++ HINTS "${qt_binary_dir_hints}" + DOC "qhelpgenerator used to compile Qt help project files") + mark_as_advanced(QT_HELP_GENERATOR) + diff --git a/paraview-fix-file-contains-date-time.patch b/paraview-fix-file-contains-date-time.patch index 0566d8c..5ab3350 100644 --- a/paraview-fix-file-contains-date-time.patch +++ b/paraview-fix-file-contains-date-time.patch @@ -1,7 +1,7 @@ -Index: ParaView-v4.2.0-source/VTK/ThirdParty/netcdf/vtknetcdf/libdispatch/error.c +Index: ParaView-v5.2.0/VTK/ThirdParty/netcdf/vtknetcdf/libdispatch/error.c =================================================================== ---- ParaView-v4.2.0-source.orig/VTK/ThirdParty/netcdf/vtknetcdf/libdispatch/error.c -+++ ParaView-v4.2.0-source/VTK/ThirdParty/netcdf/vtknetcdf/libdispatch/error.c +--- ParaView-v5.2.0.orig/VTK/ThirdParty/netcdf/vtknetcdf/libdispatch/error.c ++++ ParaView-v5.2.0/VTK/ThirdParty/netcdf/vtknetcdf/libdispatch/error.c @@ -9,7 +9,7 @@ #include "ncdispatch.h" @@ -11,10 +11,10 @@ Index: ParaView-v4.2.0-source/VTK/ThirdParty/netcdf/vtknetcdf/libdispatch/error. const char * nc_inq_libvers(void) -Index: ParaView-v4.2.0-source/Plugins/AnalyzeNIfTIReaderWriter/vtknifti1_io.cxx +Index: ParaView-v5.2.0/Plugins/AnalyzeNIfTIReaderWriter/vtknifti1_io.cxx =================================================================== ---- ParaView-v4.2.0-source.orig/Plugins/AnalyzeNIfTIReaderWriter/vtknifti1_io.cxx -+++ ParaView-v4.2.0-source/Plugins/AnalyzeNIfTIReaderWriter/vtknifti1_io.cxx +--- ParaView-v5.2.0.orig/Plugins/AnalyzeNIfTIReaderWriter/vtknifti1_io.cxx ++++ ParaView-v5.2.0/Plugins/AnalyzeNIfTIReaderWriter/vtknifti1_io.cxx @@ -438,7 +438,7 @@ void vtknifti1_io::nifti_disp_lib_hist( *//*--------------------------------------------------------------------*/ void vtknifti1_io::nifti_disp_lib_version( void ) diff --git a/paraview-pythonqt-build-fix.patch b/paraview-pythonqt-build-fix.patch new file mode 100644 index 0000000..53504c2 --- /dev/null +++ b/paraview-pythonqt-build-fix.patch @@ -0,0 +1,45 @@ +From 1cdde87a94d4282279337a9e7079f34d7a9b64cf Mon Sep 17 00:00:00 2001 +From: Utkarsh Ayachit +Date: Thu, 17 Nov 2016 11:07:35 -0500 +Subject: [PATCH] Fix build issues with PythonQtPlugin. + +--- + Plugins/PythonQtPlugin/CMakeLists.txt | 14 +++----------- + 1 file changed, 3 insertions(+), 11 deletions(-) + +diff --git a/Plugins/PythonQtPlugin/CMakeLists.txt b/Plugins/PythonQtPlugin/CMakeLists.txt +index d87853b..d249961 100644 +--- a/Plugins/PythonQtPlugin/CMakeLists.txt ++++ b/Plugins/PythonQtPlugin/CMakeLists.txt +@@ -7,6 +7,8 @@ else() + include(${PARAVIEW_USE_FILE}) + endif() + ++include(ParaViewQt) ++pv_find_package_qt(qt_targets REQUIRED QT4_COMPONENTS QtGui QT5_COMPONENTS Widgets) + + set(CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} ${CMAKE_CURRENT_SOURCE_DIR}) + find_package(PythonQt REQUIRED) +@@ -23,17 +25,7 @@ set(PythonQtPlugin_MOC_SRCS + pqPythonEventFilter.h + ) + +-if (PARAVIEW_QT_VERSION VERSION_GREATER "4") +- qt5_wrap_cpp(MOC_SRCS +- ${PythonQtPlugin_MOC_SRCS} +- ${decorator_file} +- ) +-else () +- qt4_wrap_cpp(MOC_SRCS +- ${PythonQtPlugin_MOC_SRCS} +- ${decorator_file} +- ) +-endif () ++pv_qt_wrap_cpp(MOC_SRCS ${PythonQtPlugin_MOC_SRCS} ${decorator_file}) + + set(srcs + pqPythonQtPlugin.cxx +-- +2.7.4 + + diff --git a/paraview.changes b/paraview.changes index 3dab8a4..34e76fc 100644 --- a/paraview.changes +++ b/paraview.changes @@ -1,3 +1,37 @@ +------------------------------------------------------------------- +Thu Nov 24 18:38:09 UTC 2016 - badshah400@gmail.com + +- Update to version 5.2.0: See a summary of changes at: + https://blog.kitware.com/paraview-5-2-0-release-notes/ . +- Use cmake macros (except for %cmake) for %build and %install + actions; drop the paraview_cmake_options and send the options + directly to cmake. We do not use the %cmake macro because + it passes the RPM optflags to cmake, and with paraview 5.2 these + flags cause compilation errors; see + https://gitlab.kitware.com/paraview/paraview/issues/17049. +- Turn off system GL2PS and DIY for bundled VTK. +- Switch to using Qt5 for openSUSE > 13.2 and Leap 42.2 and + higher (Qt5 >= 5.6.0 is required). +- Add BuildRequires on python-Sphinx, python-qt*-devel; new + requirements. +- Add BuildRequires on pkgconfig(libpng), pkgconfig(freetype2) and + pkgconfig(xt); these are all required and being implicitly + pulled in by libqt4-devel. +- Add paraview-find-qhelpgenerator-qt5.patch: Help find + qhelpgenerator-qt5 instead of qhelpgenerator when Qt5 is used. +- Add paraview-pythonqt-build-fix.patch to fix build issues with + PythonQtPlugin; patch taken from upstream. +- Add paraview-build-sciberquesttoolkit-with-opengl2.patch to + enable building of SciberQuestToolKit even when OpenGL2 is used + as the default VTK rendering (needs testing). +- Drop require-only-cmake-3_0.patch, cmake >= 3.3 is now required. +- Add documentation linked to from the Help menu in main + application as additional sources and install them where it + looks for them (ParaViewGettingStarted-5.2.0.pdf, + ParaViewGuide-5.2.0.pdf, ParaViewTutorial.pdf). +- Send other docs to %{_docdir} by explicitly passing the cmake + option VTK_INSTALL_DOC_DIR. + ------------------------------------------------------------------- Fri Jul 29 05:13:00 UTC 2016 - foss@grueninger.de diff --git a/paraview.spec b/paraview.spec index 7d4ae0a..4afe3a7 100644 --- a/paraview.spec +++ b/paraview.spec @@ -16,9 +16,15 @@ # -%define major_ver 5.1 +%if 0%{?suse_version} > 1320 || (0%{?suse_version} == 1315 && 0%{?sle_version} >= 120200) +%define use_qt5 1 +%else +%define use_qt5 0 +%endif + +%define major_ver 5.2 Name: paraview -Version: 5.1.2 +Version: 5.2.0 Release: 0 Summary: Data analysis and visualization application License: BSD-3-Clause @@ -26,35 +32,62 @@ Group: Productivity/Scientific/Physics Url: http://www.paraview.org Source0: http://www.paraview.org/files/v%{major_ver}/ParaView-v%{version}.tar.gz Source1: %{name}-rpmlintrc +Source2: http://www.paraview.org/files/v%{major_ver}/ParaViewGettingStarted-%{version}.pdf +Source3: http://www.paraview.org/files/v%{major_ver}/ParaViewGuide-%{version}.pdf +Source4: http://www.paraview.org/files/v%{major_ver}/ParaViewTutorial.pdf # PATCH-FIX-OPENSUSE paraview-default-qtstyle.patch badshah400@gmail.com -- Make paraview inherit default qt gui look and feel, instead of using the Plastique theme Patch0: paraview-default-qtstyle.patch # PATCH-FIX-UPSTREAM paraview-desktop-entry-fix.patch badshah400@gmail.com -- Fix desktop menu entry by inserting proper required categories Patch1: paraview-desktop-entry-fix.patch # PATCH-FIX-UPSTREAM paraview-fix-file-contains-date-time.patch badshah400@gmail.com -- Remove reference to __DATE__ and __TIME__ from source Patch2: paraview-fix-file-contains-date-time.patch -Patch3: require-only-cmake-3_0.patch +# PATCH-FIX-UPSTREAM paraview-find-qhelpgenerator-qt5.patch badshah400@gmail.com -- Help find qhelpgenerator-qt5 instead of qhelpgenerator when Qt5 is used +Patch4: paraview-find-qhelpgenerator-qt5.patch +# PATCH-FIX-UPSTREAM paraview-pythonqt-build-fix.patch badshah400@gmail.com -- Fix build issues with PythonQtPlugin; patch taken from upstream. +Patch5: paraview-pythonqt-build-fix.patch +# PATCH-FIX-UPSTREAM paraview-build-sciberquesttoolkit-with-opengl2.patch badshah400@gmail.com -- Enable building of SciberQuestToolKit even when OpenGL2 is used as the default VTK rendering +Patch6: paraview-build-sciberquesttoolkit-with-opengl2.patch BuildRequires: Mesa-devel BuildRequires: boost-devel -BuildRequires: cmake >= 3.0 +BuildRequires: cmake >= 3.3 BuildRequires: desktop-file-utils BuildRequires: doxygen BuildRequires: gnuplot BuildRequires: graphviz BuildRequires: libexpat-devel BuildRequires: libjpeg-devel +BuildRequires: pkgconfig(libpng) +BuildRequires: pkgconfig(xt) #BuildRequires: libpq5 -BuildRequires: libQtWebKit-devel BuildRequires: libpqxx-devel -BuildRequires: libqt4-devel >= 4.7.0 BuildRequires: libtiff-devel BuildRequires: openssl-devel +BuildRequires: python-Sphinx BuildRequires: python-devel BuildRequires: python-matplotlib +BuildRequires: pkgconfig(freetype2) %py_requires BuildRequires: fdupes BuildRequires: python-twisted BuildRequires: python-zope.interface +%if 0%{?use_qt5} +BuildRequires: python-qt5-devel +BuildRequires: pkgconfig(Qt5Core) +BuildRequires: pkgconfig(Qt5Gui) +BuildRequires: pkgconfig(Qt5Help) +BuildRequires: pkgconfig(Qt5Network) +BuildRequires: pkgconfig(Qt5PrintSupport) +BuildRequires: pkgconfig(Qt5WebKit) +BuildRequires: pkgconfig(Qt5WebKitWidgets) +BuildRequires: pkgconfig(Qt5Widgets) +BuildRequires: pkgconfig(Qt5X11Extras) +BuildRequires: pkgconfig(Qt5Xml) +%else +BuildRequires: libQtWebKit-devel +BuildRequires: libqt4-devel >= 4.7.0 +BuildRequires: python-qt4-devel BuildRequires: qt4-assistant-adp-devel +%endif BuildRequires: readline-devel BuildRequires: tk-devel BuildRequires: wget @@ -115,7 +148,9 @@ This package provides the SciberQuestToolKit plugin for paraview. %patch0 -p1 %patch1 -p1 %patch2 -p1 -%patch3 -p1 +%patch4 -p1 +%patch5 -p1 +%patch6 -p1 %build # Prepare for gcc 4.9.0: work around gcc 4.9.0 regression @@ -125,66 +160,60 @@ sed -i -e 's/-Wl,--fatal-warnings//' VTK/CMake/vtkCompilerExtras.cmake export CC='gcc' export CXX='g++' export MAKE='make' -export CFLAGS="%{optflags}" -export CXXFLAGS="%{optflags}" -%define paraview_cmake_options \\\ - -DCMAKE_INSTALL_PREFIX:PATH=%{_prefix} \\\ - -DVTK_INSTALL_INCLUDE_DIR:PATH=include/%{name} \\\ - -DVTK_INSTALL_ARCHIVE_DIR:PATH=%{_lib}/%{name} \\\ - -DVTK_INSTALL_LIBRARY_DIR:PATH=%{_lib}/%{name} \\\ - -DVTK_INSTALL_DATA_DIR=%{_datadir}/%{name} \\\ - -DBUILD_SHARED_LIBS:BOOL=ON \\\ - -DCMAKE_CXX_COMPILER:FILEPATH=$CXX \\\ - -DCMAKE_C_COMPILER:FILEPATH=$CC \\\ - -DCMAKE_BUILD_TYPE=RelWithDebInfo \\\ - -DPARAVIEW_BUILD_QT_GUI:BOOL=ON \\\ - -DPARAVIEW_QT_QMAKE_EXECUTABLE=%{_bindir}/qmake \\\ - -DPARAVIEW_BUILD_PLUGIN_SLACTools:BOOL=ON \\\ - -DPARAVIEW_ENABLE_PYTHON:BOOL=ON \\\ - -DVTK_WRAP_PYTHON:BOOL=ON \\\ - -DVTK_WRAP_PYTHON_SIP:BOOL=ON \\\ - -DVTK_OPENGL_HAS_OSMESA:BOOL=OFF \\\ - -DVTK_USE_SYSTEM_EXPAT:BOOL=ON \\\ - -DVTK_USE_SYSTEM_FREETYPE:BOOL=ON \\\ - -DVTK_USE_SYSTEM_JPEG:BOOL=ON \\\ - -DVTK_USE_SYSTEM_PNG:BOOL=ON \\\ - -DVTK_USE_SYSTEM_TIFF:BOOL=ON \\\ - -DVTK_USE_SYSTEM_ZLIB:BOOL=ON \\\ - -DVTK_USE_SYSTEM_ZOPE:BOOL=ON \\\ - -DVTK_USE_SYSTEM_TWISTED:BOOL=ON \\\ - -DBUILD_DOCUMENTATION:BOOL=ON \\\ - -DBUILD_EXAMPLES:BOOL=ON \\\ - -DBUILD_TESTING:BOOL=OFF - -mkdir temp_dir -pushd temp_dir -cmake .. \ +mkdir build && pushd build +cmake -DCMAKE_INSTALL_PREFIX:PATH=%{_prefix} \ -DPV_INSTALL_LIB_DIR:PATH=%{_lib}/%{name} \ - %{paraview_cmake_options} + -DVTK_INSTALL_INCLUDE_DIR:PATH=include/%{name} \ + -DVTK_INSTALL_ARCHIVE_DIR:PATH=%{_lib}/%{name} \ + -DVTK_INSTALL_LIBRARY_DIR:PATH=%{_lib}/%{name} \ + -DVTK_INSTALL_DATA_DIR=share/%{name} \ + -DVTK_INSTALL_DOC_DIR=share/doc/packages/%{name} \ + -DCMAKE_CXX_COMPILER:FILEPATH=$CXX \ + -DCMAKE_C_COMPILER:FILEPATH=$CC \ + -DCMAKE_BUILD_TYPE=RelWithDebInfo \ + -DPARAVIEW_BUILD_QT_GUI:BOOL=ON \ +%if 0%{?use_qt5} + -DPARAVIEW_QT_VERSION:STRING="5" \ +%else + -DPARAVIEW_QT_VERSION:STRING="4" \ +%endif + -DPARAVIEW_BUILD_PLUGIN_SLACTools:BOOL=ON \ + -DPARAVIEW_ENABLE_PYTHON:BOOL=ON \ + -DVTK_WRAP_PYTHON:BOOL=ON \ + -DVTK_WRAP_PYTHON_SIP:BOOL=ON \ + -DVTK_OPENGL_HAS_OSMESA:BOOL=OFF \ + -DVTK_USE_SYSTEM_EXPAT:BOOL=ON \ + -DVTK_USE_SYSTEM_FREETYPE:BOOL=ON \ + -DVTK_USE_SYSTEM_JPEG:BOOL=ON \ + -DVTK_USE_SYSTEM_PNG:BOOL=ON \ + -DVTK_USE_SYSTEM_TIFF:BOOL=ON \ + -DVTK_USE_SYSTEM_ZLIB:BOOL=ON \ + -DVTK_USE_SYSTEM_ZOPE:BOOL=ON \ + -DVTK_USE_SYSTEM_TWISTED:BOOL=ON \ + -DVTK_USE_SYSTEM_GL2PS:BOOL=OFF \ + -DBUILD_DOCUMENTATION:BOOL=ON \ + -DBUILD_EXAMPLES:BOOL=ON \ + -DBUILD_TESTING:BOOL=OFF \ + .. -make %{?_smp_mflags} -popd +# FIXME: CAUSES ERRORS WITH THE IN-APP PYTHON SHELL WHICH STILL LOOKS FOR PY MODULES IN THE DEFAULT DIR %{_libdir}/%{name}/site-packages +# -DVTK_INSTALL_PYTHON_MODULE_DIR:PATH="%{python_sitearch}/%{name}" \ + +%make_jobs %install find . \( -name \*.txt -o -name \*.xml -o -name '*.[ch]' -o -name '*.[ch][px][px]' \) -print0 | xargs -0 chmod -x -pushd temp_dir -%makeinstall DESTDIR=%{buildroot} -popd -rm -rf temp_dir/ - -# FIX A BUNCH OF RPMLINT WARNINGS REGARDING python-bytecode-inconsistent-mtime -%py_compile %{buildroot}%{_libdir}/%{name}/site-packages/vtk/ -for i in `ls -d %{buildroot}%{_libdir}/%{name}/site-packages/vtk/*/`; -do - %py_compile $i/ -done - -%py_compile %{buildroot}%{_libdir}/%{name}/site-packages/paraview/vtk/util +%cmake_install # UNNECESSARY STATIC LIB rm -fr %{buildroot}%{_libexecdir}/libFmmMesh.a +# INSTALL DOCUMENTATION USED BY THE HELP MENU IN MAIN APP +install -Dm0644 %{S:2} %{buildroot}%{_datadir}/%{name}-%{major_ver}/doc/GettingStarted.pdf +install -Dm0644 %{S:3} %{buildroot}%{_datadir}/%{name}-%{major_ver}/doc/Guide.pdf +install -Dm0644 %{S:4} %{buildroot}%{_datadir}/%{name}-%{major_ver}/doc/Tutorial.pdf + %fdupes %{buildroot}/ %post @@ -206,14 +235,13 @@ rm -fr %{buildroot}%{_libexecdir}/libFmmMesh.a %doc License_v1.2.txt %{_libdir}/%{name}/ %{_bindir}/* -%{_datadir}/doc/%{name}-%{major_ver}/ -%{_datadir}/%{name}/ +%{_docdir}/%{name}/ +%{_datadir}/%{name}-%{major_ver}/ %dir %{_datadir}/appdata %{_datadir}/appdata/%{name}.appdata.xml %{_datadir}/applications/%{name}.desktop %{_datadir}/icons/hicolor/*/apps/%{name}.png %{_datadir}/cmake/hdf5/ - %exclude %{_libdir}/%{name}/libSciberQuestToolKit.so %files -n %{name}-plugin-SciberQuestToolKit diff --git a/require-only-cmake-3_0.patch b/require-only-cmake-3_0.patch deleted file mode 100644 index 89ecc87..0000000 --- a/require-only-cmake-3_0.patch +++ /dev/null @@ -1,11 +0,0 @@ ---- ParaView-v5.1.0_old/CMakeLists.txt 2016-06-18 11:39:09.000000000 -0400 -+++ ParaView-v5.1.0/CMakeLists.txt 2016-06-21 04:42:25.261364363 -0400 -@@ -28,7 +28,7 @@ - # SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - # - #========================================================================== --cmake_minimum_required(VERSION 3.3) -+cmake_minimum_required(VERSION 3.0) - - project(ParaView) -