|
@@ -1,58 +1,123 @@
|
|
-%define vtkver 5.4
|
|
+# Disable OSMesa builds for now - see Bug 744434
|
|
-%define version %{vtkver}.2
|
|
+%bcond_with OSMesa
|
|
-%define vtkdata_dir %{_datadir}/vtk-data-%{version}
|
|
+# Make Java conditional
|
|
-%define qt_designer_plugins_dir %(qmake -query QT_INSTALL_PREFIX)/plugins/designer
|
|
+%bcond_without java
|
|
-%define tcl_ver %(echo "puts [info tclversion]" | %{_bindir}/tclsh)
|
|
+
|
|
|
|
+%{!?tcl_version: %global tcl_version %(echo 'puts $tcl_version' | tclsh)}
|
|
|
|
+%{!?tcl_sitelib: %global tcl_sitelib %{_datadir}/tcl%{tcl_version}}
|
|
|
|
+
|
|
|
|
+%define _hdf5_version 1.8.14
|
|
|
|
+
|
|
Summary: The Visualization Toolkit - A high level 3D visualization library
|
|
Summary: The Visualization Toolkit - A high level 3D visualization library
|
|
-Summary: The Visualization Toolkit - ハイレベル3D可視化ライブラリ
|
|
+Summary(ja): The Visualization Toolkit - ハイレベル3D可視化ライブラリ
|
|
-Group: System Environment/Libraries
|
|
|
|
Name: vtk
|
|
Name: vtk
|
|
-Version: %{version}
|
|
+Version: 6.1.0
|
|
-Release: 3%{?_dist_release}
|
|
+Release: 1%{?_dist_release}
|
|
-Source0: vtk-%{version}.tar.gz
|
|
+
|
|
-Source1: vtkdata-%{version}.tar.gz
|
|
+# This is a variant BSD license, a cross between BSD and ZLIB.
|
|
-Patch2: vtk-5.2.1-boost-1.42.patch
|
|
+# For all intents, it has the same rights and restrictions as BSD.
|
|
|
|
+# http://fedoraproject.org/wiki/Licensing/BSD#VTKBSDVariant
|
|
License: BSD style
|
|
License: BSD style
|
|
|
|
+Group: System Environment/Libraries
|
|
URL: http://www.vtk.org/
|
|
URL: http://www.vtk.org/
|
|
|
|
+
|
|
|
|
+Source0: http://www.vtk.org/files/release/6.1/VTK-%{version}.tar.gz
|
|
|
|
+Source1: http://www.vtk.org/files/release/6.1/VTKData-%{version}.tar.gz
|
|
|
|
+
|
|
|
|
+# Use system libraries
|
|
|
|
+# http://public.kitware.com/Bug/view.php?id=11823
|
|
|
|
+Patch0: vtk-6.1.0-system.patch
|
|
|
|
+# Install some more needed cmake files to try to support paraview build
|
|
|
|
+# http://www.vtk.org/Bug/view.php?id=14157
|
|
|
|
+Patch1: vtk-install.patch
|
|
|
|
+# Patch to vtk to use system netcdf library
|
|
|
|
+Patch2: vtk-6.1.0-netcdf.patch
|
|
|
|
+# Fix compilation with mesa 10.4
|
|
|
|
+# https://bugzilla.redhat.com/show_bug.cgi?id=1138466
|
|
|
|
+Patch3: vtk-glext.patch
|
|
|
|
+# Fix types for std::min/man
|
|
|
|
+# http://www.vtk.org/Bug/view.php?id=15249
|
|
|
|
+Patch4: vtk-type.patch
|
|
|
|
+
|
|
|
|
+BuildRoot: %{_tmppath}/%{name}-%{version}-root
|
|
BuildRequires: cmake >= 2.0.0
|
|
BuildRequires: cmake >= 2.0.0
|
|
-BuildRequires: xorg-x11-devel, mesa-libGL-devel
|
|
+BuildRequires: gcc-c++
|
|
-BuildRequires: expat-devel, zlib-devel
|
|
+%{?with_java:BuildRequires: java-devel}
|
|
-BuildRequires: netcdf
|
|
+BuildRequires: libX11-devel, libXt-devel, libXext-devel
|
|
-BuildRequires: libjpeg-devel, libpng-devel, libtiff-devel, freetype2-devel
|
|
+BuildRequires: libICE-devel, libGL-devel
|
|
-BuildRequires: tcl, tk, python, python-devel
|
|
+%{?with_OSMesa:BuildRequires: mesa-libOSMesa-devel}
|
|
-BuildRequires: qt4-devel
|
|
+BuildRequires: tk-devel, tcl-devel
|
|
-BuildRequires: libboost-devel
|
|
+BuildRequires: python-devel
|
|
|
|
+BuildRequires: expat-devel, freetype2-devel, libjpeg-turbo-devel, libpng-devel
|
|
|
|
+BuildRequires: gl2ps-devel
|
|
|
|
+BuildRequires: libtiff-devel, zlib-devel
|
|
BuildRequires: libxml2-devel
|
|
BuildRequires: libxml2-devel
|
|
-BuildRoot: %{_tmppath}/%{name}-%{version}-root
|
|
+BuildRequires: qt4-devel qt4-designer
|
|
-Requires: cmake
|
|
+#BuildRequires: qtwebkit-devel
|
|
-Requires: xorg-x11-libs, mesa-libGL
|
|
+BuildRequires: chrpath
|
|
-Requires: expat, zlib
|
|
+BuildRequires: doxygen, graphviz
|
|
-Requires: netcdf
|
|
+BuildRequires: gnuplot
|
|
-Requires: libjpeg, libpng, libtiff, freetype2
|
|
+BuildRequires: libboost-devel
|
|
-Obsoletes: %{name}-ruby < %{version}
|
|
+BuildRequires: hdf5-devel
|
|
|
|
+BuildRequires: jsoncpp-devel
|
|
|
|
+BuildRequires: libtheora-devel
|
|
|
|
+#BuildRequires: mysql-devel
|
|
|
|
+BuildRequires: mariadb-devel
|
|
|
|
+BuildRequires: netcdf-cxx-devel
|
|
|
|
+#BuildRequires: postgresql-devel
|
|
|
|
+BuildRequires: libpq-devel
|
|
|
|
+BuildRequires: R-devel
|
|
|
|
+BuildRequires: PyQt4-devel
|
|
|
|
+BuildRequires: sip-devel
|
|
|
|
+BuildRequires: sqlite3-devel
|
|
|
|
+BuildRequires: wget
|
|
|
|
+#BuildRequires: %{_includedir}/Xm
|
|
|
|
+BuildRequires: openMotif-devel
|
|
|
|
+BuildRequires: blas-devel
|
|
|
|
+BuildRequires: lapack-devel
|
|
|
|
+%{!?with_java:Conflicts: vtk-java}
|
|
|
|
+Requires: hdf5 = %{_hdf5_version}
|
|
|
|
+
|
|
Distribution: Project Vine
|
|
Distribution: Project Vine
|
|
Vendor: Vine Linux
|
|
Vendor: Vine Linux
|
|
Packager: owa
|
|
Packager: owa
|
|
|
|
|
|
|
|
+# Do not check .so files in the python_sitearch directory
|
|
|
|
+%global __provides_exclude_from ^%{python_sitearch}/.*\\.so$
|
|
|
|
+
|
|
%description
|
|
%description
|
|
-VTK - the Visualization Toolkit is an object oriented, high
|
|
+VTK is an open-source software system for image processing, 3D
|
|
-level library that allows one to easily write C++ programs, Tcl,
|
|
+graphics, volume rendering and visualization. VTK includes many
|
|
-Python and Java scripts that do 3D visualization. This package
|
|
+advanced algorithms (e.g., surface reconstruction, implicit modeling,
|
|
-provides the shared libraries needed to run C++ programs that use VTK.
|
|
+decimation) and rendering techniques (e.g., hardware-accelerated
|
|
-To compile C++ code that uses VTK you have to install vtk-devel.
|
|
+volume rendering, LOD control).
|
|
-
|
|
|
|
-VTK enables users to concentrate on their work by providing a
|
|
|
|
-large number of excellent and feature packed high level functions that
|
|
|
|
-do visualization. The library needs OpenGL to render the graphics and
|
|
|
|
-for Linux machines Mesa is necessary. The terms/copyright can be read
|
|
|
|
-in %{_docdir}/vtk-%{version}-%{release}/README.html. VTK-Linux-HOWTO has
|
|
|
|
-information about using vtk, getting documentataion or help and
|
|
|
|
-instructions on building VTK. This package is relocatable.
|
|
|
|
|
|
|
|
%package devel
|
|
%package devel
|
|
Summary: VTK header files for building C++ code.
|
|
Summary: VTK header files for building C++ code.
|
|
|
|
+Summary(ja): C++ プログラムをビルドするための VTK ヘッダファイル集
|
|
Group: Development/Libraries
|
|
Group: Development/Libraries
|
|
Requires: %{name} = %{version}-%{release}
|
|
Requires: %{name} = %{version}-%{release}
|
|
|
|
+%{?with_OSMesa:Requires: mesa-libOSMesa-devel}
|
|
|
|
+Requires: cmake
|
|
|
|
+Requires: blas-devel
|
|
|
|
+Requires: gl2ps-devel
|
|
|
|
+Requires: expat-devel
|
|
|
|
+Requires: freetype2-devel
|
|
|
|
+Requires: hdf5-devel
|
|
|
|
+Requires: lapack-devel
|
|
|
|
+Requires: libjpeg-turbo-devel
|
|
|
|
+Requires: libpng-devel
|
|
|
|
+Requires: libogg-devel
|
|
|
|
+Requires: libtheora-devel
|
|
|
|
+Requires: libtiff-devel
|
|
|
|
+Requires: libxml2-devel
|
|
|
|
+Requires: libpq-devel
|
|
|
|
+Requires: libmysqlclient-devel
|
|
|
|
+Requires: qt4-devel
|
|
|
|
+#Requires: qtwebkit-devel%{?_isa}
|
|
|
|
+#Requires: jsoncpp-devel%{?_isa}
|
|
|
|
+# bz #1183210 + #1183530
|
|
|
|
+Requires: python-devel
|
|
|
|
|
|
%description devel
|
|
%description devel
|
|
This provides the VTK header files required to compile C++
|
|
This provides the VTK header files required to compile C++
|
|
@@ -60,251 +125,439 @@ programs that use VTK to do 3D visualisation.
|
|
|
|
|
|
|
|
|
|
%package tcl
|
|
%package tcl
|
|
-Summary: Tcl bindings for VTK.
|
|
+Summary: Tcl bindings for VTK
|
|
-Group: Applications/Engineering
|
|
+Summary(ja): VTK の tcl バインディング
|
|
|
|
+Group: System Environment/Libraries
|
|
Requires: %{name} = %{version}-%{release}
|
|
Requires: %{name} = %{version}-%{release}
|
|
Requires: tcl
|
|
Requires: tcl
|
|
|
|
|
|
%description tcl
|
|
%description tcl
|
|
-VTK - the Visualization Toolkit is an object oriented, high level
|
|
+tcl bindings for VTK
|
|
-library that allows one to easily write C++ programs, Tcl, Python and Java
|
|
|
|
-scripts that do 3D visualization. This package provides the shared
|
|
|
|
-libraries that enable one to use VTK via Tcl scripts. This version also
|
|
|
|
-provides the vtkTkRenderWindow class. This package does not require the vtk
|
|
|
|
-package to be installed. The library needs OpenGL to render the graphics and
|
|
|
|
-for Linux machines Mesa is necessary.
|
|
|
|
|
|
|
|
-The terms/copyright can be read in
|
|
+%description tcl -l ja
|
|
-/usr/share/doc/vtk-tcl-%{version}-%{release}/README.html. VTK-Linux-HOWTO has
|
|
+VTK の tcl バインディングです。
|
|
-information about using vtk, getting documentation or help and instructions on
|
|
|
|
-building VTK. This package is relocatable.
|
|
|
|
|
|
|
|
|
|
|
|
%package python
|
|
%package python
|
|
Summary: Python bindings for VTK.
|
|
Summary: Python bindings for VTK.
|
|
-Group: Applications/Engineering
|
|
+Summary(ja): VTK の python バインディング
|
|
|
|
+Group: System Environment/Libraries
|
|
Requires: %{name} = %{version}-%{release}
|
|
Requires: %{name} = %{version}-%{release}
|
|
Requires: python
|
|
Requires: python
|
|
|
|
|
|
-%description python
|
|
+%description python
|
|
-This provides the shared libraries that enable one to use VTK from
|
|
+python bindings for VTK
|
|
-python scripts. You will need python and vtk installed to use this.
|
|
+
|
|
-Remember to set your PYTHONPATH variable properly before running your
|
|
+%description python -l ja
|
|
-scripts.
|
|
+VTK の python バインディングです。
|
|
|
|
+
|
|
|
|
+%if %{with java}
|
|
|
|
+%package java
|
|
|
|
+Summary: Java bindings for VTK
|
|
|
|
+Summary(ja): VTK の Java バインディング
|
|
|
|
+Group: System Environment/Libraries
|
|
|
|
+Requires: %{name} = %{version}-%{release}
|
|
|
|
+Requires: java
|
|
|
|
+
|
|
|
|
+%description java
|
|
|
|
+Java bindings for VTK
|
|
|
|
+
|
|
|
|
+%description java -l ja
|
|
|
|
+VTK の Java バインディングです。
|
|
|
|
+%endif
|
|
|
|
|
|
|
|
|
|
%package qt
|
|
%package qt
|
|
-Summary: QT VTK widget
|
|
+Summary: Qt bindings for VTK
|
|
|
|
+Summary(ja): VTK の Qt バインディング
|
|
Group: System Environment/Libraries
|
|
Group: System Environment/Libraries
|
|
Requires: %{name} = %{version}-%{release}
|
|
Requires: %{name} = %{version}-%{release}
|
|
-Requires: qt
|
|
|
|
|
|
|
|
%description qt
|
|
%description qt
|
|
-The vtkQt classes combine VTK and Qt(TM) for X11.
|
|
+Qt bindings for VTK
|
|
|
|
|
|
|
|
+%description qt -l ja
|
|
|
|
+VTK の Qt バインディングです。
|
|
|
|
|
|
-%package examples
|
|
+
|
|
-Summary: C++, Tcl and Python example programs/scripts for VTK.
|
|
+%package qt-python
|
|
-Group: Development/Libraries
|
|
+Summary: Qt Python bindings for VTK
|
|
|
|
+Summary(ja): VTK の Qt Python バインディング
|
|
|
|
+Group: System Environment/Libraries
|
|
Requires: %{name} = %{version}-%{release}
|
|
Requires: %{name} = %{version}-%{release}
|
|
|
|
|
|
-%description examples
|
|
+%description qt-python
|
|
-This package contains all the examples from the VTK source.
|
|
+Qt Python bindings for VTK
|
|
-To compile the C++ examples you will need to install the vtk-devel
|
|
+
|
|
-package as well. The Python and Tcl examples can be run with the
|
|
+%description qt-python -l ja
|
|
-corresponding packages (vtk-python, vtk-tcl).
|
|
+VTK の Qt Python バインディングです。
|
|
|
|
+
|
|
|
|
+%package qt-tcl
|
|
|
|
+Summary: Qt TCL bindings for VTK
|
|
|
|
+Summary(ja): VTK の Qt TCL バインディング
|
|
|
|
+Group: System Environment/Libraries
|
|
|
|
+Requires: %{name} = %{version}-%{release}
|
|
|
|
+
|
|
|
|
+%description qt-tcl
|
|
|
|
+Qt TCL bindings for VTK
|
|
|
|
+
|
|
|
|
+%description qt-tcl -l ja
|
|
|
|
+VTK の Qt TCL バインディングです。
|
|
|
|
|
|
|
|
|
|
%package testing-progs
|
|
%package testing-progs
|
|
Summary: Tests programs for VTK.
|
|
Summary: Tests programs for VTK.
|
|
|
|
+Summary(ja): VTK のテスト用プログラム
|
|
Group: Development/Libraries
|
|
Group: Development/Libraries
|
|
Requires: %{name} = %{version}-%{release}
|
|
Requires: %{name} = %{version}-%{release}
|
|
|
|
|
|
%description testing-progs
|
|
%description testing-progs
|
|
-This package contains all testing programs from the VTK
|
|
+Testing programs for VTK
|
|
-source. The source code of these programs can be found in the
|
|
+
|
|
-vtk-examples package.
|
|
+%description testing-progs -l ja
|
|
|
|
+VTK のテスト用プログラムです。
|
|
|
|
+
|
|
|
|
|
|
|
|
+%package examples
|
|
|
|
+Summary: Examples for VTK
|
|
|
|
+Summary(ja): VTK のサンプル集
|
|
|
|
+Group: Applications/Engineering
|
|
|
|
+Requires: %{name} = %{version}-%{release}
|
|
|
|
+Requires: vtk-data = %{version}
|
|
|
|
+
|
|
|
|
+%description examples
|
|
|
|
+This package contains all the examples from the VTK source.
|
|
|
|
+To compile the C++ examples you will need to install the vtk-devel
|
|
|
|
+package as well. The Python and Tcl examples can be run with the
|
|
|
|
+corresponding packages (vtk-python, vtk-tcl).
|
|
|
|
|
|
%package data
|
|
%package data
|
|
-Summary: Data for VTK.
|
|
+Summary: Example data file for VTK
|
|
|
|
+Summary(ja): VTK のサンプルデータファイル
|
|
Group: Development/Libraries
|
|
Group: Development/Libraries
|
|
-Requires: %{name} = %{version}-%{release}
|
|
+BuildArch: noarch
|
|
-Prefix: /usr
|
|
|
|
|
|
|
|
%description data
|
|
%description data
|
|
This package contains all the data from the VTKData repository.
|
|
This package contains all the data from the VTKData repository.
|
|
These data are required to run various examples from the examples package.
|
|
These data are required to run various examples from the examples package.
|
|
|
|
|
|
-
|
|
|
|
%prep
|
|
%prep
|
|
-%setup -q -n VTK
|
|
+%setup -q -n VTK-%{version}
|
|
-%patch2 -p1 -b .boost-1.42
|
|
+%patch0 -p1 -b .system
|
|
|
|
+%patch1 -p1 -b .install
|
|
|
|
+%patch2 -p1 -b .netcdf
|
|
|
|
+%patch3 -p1 -b .glext
|
|
|
|
+%patch4 -p1 -b .type
|
|
|
|
+# Remove included thirdparty sources just to be sure
|
|
|
|
+# TODO - vtksqlite
|
|
|
|
+for x in autobahn vtkexpat vtkfreetype vtkgl2ps vtkhdf5 vtkjpeg vtklibxml2 vtknetcdf vtkoggtheora vtkpng vtktiff twisted vtkzlib zope
|
|
|
|
+do
|
|
|
|
+ rm -r ThirdParty/*/${x}
|
|
|
|
+done
|
|
|
|
|
|
-# fix data path
|
|
+# Replace relative path ../../../VTKData with %{_datadir}/vtkdata-%{version}
|
|
-find . -type f | xargs sed -i -e 's|../../../../VTKData|%{vtkdata_dir}|g'
|
|
+# otherwise it will break on symlinks.
|
|
|
|
+grep -rl '\.\./\.\./\.\./\.\./VTKData' . | xargs \
|
|
|
|
+ perl -pi -e's,\.\./\.\./\.\./\.\./VTKData,%{_datadir}/vtkdata-%{version},g'
|
|
|
|
|
|
|
|
+# Save an unbuilt copy of the Example's sources for %doc
|
|
|
|
+mkdir vtk-examples
|
|
|
|
+cp -a Examples vtk-examples
|
|
|
|
+# Don't ship Win32 examples
|
|
|
|
+rm -r vtk-examples/Examples/GUI/Win32
|
|
|
|
+find vtk-examples -type f | xargs chmod -R a-x
|
|
|
|
|
|
%build
|
|
%build
|
|
-## This section wad fixed reference to Mandriva package
|
|
+export CFLAGS="%{optflags} -D_UNICODE"
|
|
-# Remove old cmake files
|
|
+export CXXFLAGS="%{optflags} -D_UNICODE"
|
|
-rm -f CMake/FindBoost*
|
|
+%if %{with java}
|
|
|
|
+export JAVA_HOME=/usr/lib/jvm/java
|
|
|
|
+# Arm/Aarch64 builders have less ram
|
|
|
|
+# https://bugzilla.redhat.com/show_bug.cgi?id=1115920
|
|
|
|
+%ifnarch s390
|
|
|
|
+export JAVA_TOOL_OPTIONS=-Xmx2048m
|
|
|
|
+%endif
|
|
|
|
+%endif
|
|
|
|
|
|
-# Due to cmake prefix point already for _prefix, we need
|
|
+mkdir build
|
|
-# push only the necessary extra paths
|
|
+pushd build
|
|
%cmake \
|
|
%cmake \
|
|
- -DVTK_INSTALL_BIN_DIR:PATH=/bin \
|
|
+ -DBUILD_DOCUMENTATION:BOOL=ON \
|
|
- -DVTK_INSTALL_PACKAGE_DIR=/%{_lib}/vtk-%{vtkver} \
|
|
+ -DBUILD_EXAMPLES:BOOL=ON \
|
|
- -DVTK_INSTALL_INCLUDE_DIR:PATH=/include/vtk-%{vtkver} \
|
|
+ -DBUILD_TESTING:BOOL=OFF \
|
|
- -DVTK_PYTHON_MODULE_PLATFORM_INSTALL_DIR=/%{_lib}/pyhton%{pyver}/site-packages \
|
|
+ -DVTK_CUSTOM_LIBRARY_SUFFIX="" \
|
|
- -DVTK_DATA_ROOT:PATH=/share/vtk-%{vtkver} \
|
|
+ -DVTK_INSTALL_ARCHIVE_DIR:PATH=%{_lib}/vtk \
|
|
- \
|
|
+ -DVTK_INSTALL_DATA_DIR=share/vtk \
|
|
- -DVTK_USE_SYSTEM_LIBPROJ4:BOOL=OFF \
|
|
+ -DVTK_INSTALL_INCLUDE_DIR:PATH=include/vtk \
|
|
- -DVTK_WRAP_PYTHON:BOOL=ON \
|
|
+ -DVTK_INSTALL_LIBRARY_DIR:PATH=%{_lib}/vtk \
|
|
- -DVTK_WRAP_JAVA:BOOL=OFF \
|
|
+ -DVTK_INSTALL_PACKAGE_DIR:PATH=%{_lib}/cmake/vtk \
|
|
- -DVTK_WRAP_TCL:BOOL=ON \
|
|
+ -DVTK_INSTALL_PYTHON_MODULE_DIR:PATH=%{_lib}/python%{python_version}/site-packages \
|
|
- -DVTK_USE_RENDERING:BOOL=ON \
|
|
+ -DVTK_INSTALL_QT_DIR:PATH=%{_lib}/qt4/plugins/designer \
|
|
- -DDESIRED_QT_VERSION=4 \
|
|
+ -DVTK_INSTALL_TCL_DIR:PATH=share/tcl%{tcl_version}/vtk \
|
|
- -DBUILD_DOCUMENTATION:BOOL=OFF \
|
|
+ -DTK_INTERNAL_PATH:PATH=/usr/include/tk-private/generic \
|
|
- -DBUILD_EXAMPLES:BOOL=ON \
|
|
+%if %{with OSMesa}
|
|
- -DBUILD_SHARED_LIBS:BOOL=ON \
|
|
+ -DVTK_OPENGL_HAS_OSMESA:BOOL=ON \
|
|
- -DBUILD_TESTING:BOOL=ON \
|
|
+%endif
|
|
- -DVTK_USE_SYSTEM_EXPAT=ON \
|
|
+%if %{with java}
|
|
- -DVTK_USE_SYSTEM_JPEG=ON \
|
|
+ -DVTK_WRAP_JAVA:BOOL=ON \
|
|
- -DVTK_USE_SYSTEM_PNG=ON \
|
|
+ -DJAVA_INCLUDE_PATH:PATH=$JAVA_HOME/include \
|
|
- -DVTK_USE_SYSTEM_TIFF=ON \
|
|
+ -DJAVA_INCLUDE_PATH2:PATH=$JAVA_HOME/include/linux \
|
|
- -DVTK_USE_SYSTEM_ZLIB=ON \
|
|
+ -DJAVA_AWT_INCLUDE_PATH:PATH=$JAVA_HOME/include \
|
|
- -DVTK_USE_SYSTEM_FREETYPE=ON \
|
|
+%else
|
|
- -DVTK_USE_ANSI_STDLIB:BOOL=ON \
|
|
+ -DVTK_WRAP_JAVA:BOOL=OFF \
|
|
- -DVTK_USE_PARALLEL:BOOL=ON \
|
|
+%endif
|
|
- -DVTK_USE_GUISUPPORT:BOOL=ON \
|
|
+ -DVTK_WRAP_PYTHON:BOOL=ON \
|
|
- -DVTK_USE_QVTK=ON \
|
|
+ -DVTK_WRAP_PYTHON_SIP:BOOL=ON \
|
|
- -DVTK_PYTHON_SETUP_ARGS:STRING="--prefix=%{_prefix} --root=%{buildroot}" \
|
|
+ -DSIP_INCLUDE_DIR:PATH=/usr/include/python%{python_version} \
|
|
- -DVTK_INSTALL_QT_PLUGIN_DIR=%{qt_designer_plugins_dir} \
|
|
+ -DVTK_WRAP_TCL:BOOL=ON \
|
|
- -DVTK_USE_GL2PS:BOOL=ON \
|
|
+ -DVTK_Group_Imaging:BOOL=ON \
|
|
- -DVTK_USE_SYSTEM_LIBXML2:BOOL=ON \
|
|
+ -DVTK_Group_Qt:BOOL=ON \
|
|
- -DVTK_USE_QVTK_QTOPENGL:BOOL=ON \
|
|
+ -DVTK_Group_Rendering:BOOL=ON \
|
|
- -DVTK_USE_BOOST:BOOL=ON \
|
|
+ -DVTK_Group_StandAlone:BOOL=ON \
|
|
- -DTCL_LIBRARY:FILEPATH=%{_libdir}/libtcl%{tcl_ver}.so\
|
|
+ -DVTK_Group_Tk:BOOL=ON \
|
|
- -DTK_LIBRARY:FILEPATH=%{_libdir}/libtk%{tcl_ver}.so\
|
|
+ -DVTK_Group_Views:BOOL=ON \
|
|
- ;
|
|
+ -DModule_vtkFiltersStatisticsGnuR:BOOL=ON \
|
|
-
|
|
+ -DModule_vtkTestingCore:BOOL=ON \
|
|
-## don't use _smp_mflags
|
|
+ -DModule_vtkTestingRendering:BOOL=ON \
|
|
-##%__make %{?_smp_mflags}
|
|
+ -DVTK_USE_OGGTHEORA_ENCODER=ON \
|
|
-%__make
|
|
+ -DVTK_USE_SYSTEM_LIBRARIES=ON \
|
|
|
|
+ -DVTK_USE_SYSTEM_HDF5:BOOL=ON \
|
|
|
|
+ -DVTK_USE_SYSTEM_LIBPROJ4:BOOL=OFF \
|
|
|
|
+ -DVTK_USE_SYSTEM_NETCDF:BOOL=ON \
|
|
|
|
+ -DTCL_LIBRARY:FILEPATH=%{_libdir}/libtcl%{tcl_version}.so \
|
|
|
|
+ -DTK_LIBRARY:FILEPATH=%{_libdir}/libtk%{tcl_version}.so \
|
|
|
|
+ ..
|
|
|
|
+
|
|
|
|
+# TODO - MPI
|
|
|
|
+#-DVTK_Group_MPI:BOOL=ON \
|
|
|
|
+# Needed for some tests. Fails to compile at the moment. We don't run test though.
|
|
|
|
+# -DVTK_DATA_ROOT:PATH=%{_datadir}/vtkdata-%{version} \
|
|
|
|
+# Not working, see http://public.kitware.com/Bug/view.php?id=11978
|
|
|
|
+# -DVTK_USE_ODBC=ON \
|
|
|
|
+# Commented old flags in case we'd like to reactive some of them
|
|
|
|
+# -DVTK_USE_DISPLAY:BOOL=OFF \ # This prevents building of graphics tests
|
|
|
|
+# -DVTK_USE_MPI:BOOL=ON \
|
|
|
|
+
|
|
|
|
+# Got intermittent build error with -j
|
|
|
|
+make %{?_smp_mflags}
|
|
|
|
+
|
|
|
|
+# Remove executable bits from sources (some of which are generated)
|
|
|
|
+find . -name \*.c -or -name \*.cxx -or -name \*.h -or -name \*.hxx -or \
|
|
|
|
+ -name \*.gif | xargs chmod -x
|
|
|
|
|
|
|
|
|
|
%install
|
|
%install
|
|
rm -rf $RPM_BUILD_ROOT
|
|
rm -rf $RPM_BUILD_ROOT
|
|
-%makeinstall DESTDIR=$RPM_BUILD_ROOT
|
|
+pushd build
|
|
|
|
+make install DESTDIR=$RPM_BUILD_ROOT
|
|
|
|
+
|
|
|
|
+# ld config
|
|
|
|
+mkdir -p $RPM_BUILD_ROOT%{_sysconfdir}/ld.so.conf.d
|
|
|
|
+echo %{_libdir}/vtk > $RPM_BUILD_ROOT%{_sysconfdir}/ld.so.conf.d/vtk-%{_arch}.conf
|
|
|
|
+
|
|
|
|
+# Gather list of non-python/tcl libraries
|
|
|
|
+ls $RPM_BUILD_ROOT%{_libdir}/vtk/*.so.* \
|
|
|
|
+ | grep -Ev '(Java|Qt|Python27D|TCL)' | sed -e's,^%{buildroot},,' > libs.list
|
|
|
|
+
|
|
|
|
+# List of executable utilities
|
|
|
|
+cat > utils.list << EOF
|
|
|
|
+vtkEncodeString
|
|
|
|
+EOF
|
|
|
|
+
|
|
|
|
+# List of executable examples
|
|
|
|
+cat > examples.list << EOF
|
|
|
|
+HierarchicalBoxPipeline
|
|
|
|
+MultiBlock
|
|
|
|
+Arrays
|
|
|
|
+Cube
|
|
|
|
+RGrid
|
|
|
|
+SGrid
|
|
|
|
+Medical1
|
|
|
|
+Medical2
|
|
|
|
+Medical3
|
|
|
|
+finance
|
|
|
|
+AmbientSpheres
|
|
|
|
+Cylinder
|
|
|
|
+DiffuseSpheres
|
|
|
|
+SpecularSpheres
|
|
|
|
+Cone
|
|
|
|
+Cone2
|
|
|
|
+Cone3
|
|
|
|
+Cone4
|
|
|
|
+Cone5
|
|
|
|
+Cone6
|
|
|
|
+EOF
|
|
|
|
+
|
|
|
|
+# Install examples too
|
|
|
|
+for filelist in examples.list; do
|
|
|
|
+ for file in `cat $filelist`; do
|
|
|
|
+ install -p bin/$file $RPM_BUILD_ROOT%{_bindir}
|
|
|
|
+ done
|
|
|
|
+done
|
|
|
|
|
|
-%if %{_lib} == lib64
|
|
+# Fix up filelist paths
|
|
- mkdir -p $RPM_BUILD_ROOT%{_libdir}
|
|
+for filelist in utils.list examples.list; do
|
|
- mv $RPM_BUILD_ROOT%{_prefix}/lib/python%{pyver} $RPM_BUILD_ROOT%{_libdir}/
|
|
+ perl -pi -e's,^,%{_bindir}/,' $filelist
|
|
- mv $RPM_BUILD_ROOT%{_prefix}/lib/vtk-%{vtkver}/* $RPM_BUILD_ROOT%{_libdir}/vtk-%{vtkver}/
|
|
+done
|
|
-%endif
|
|
|
|
-mv $RPM_BUILD_ROOT%{_libdir}/vtk-%{vtkver}/lib*.so* $RPM_BUILD_ROOT%{_libdir}/
|
|
|
|
|
|
|
|
-rm -f bin/*.so*
|
|
+# Remove any remnants of rpaths on files we install
|
|
-install -m 755 bin/* $RPM_BUILD_ROOT%{_bindir}
|
|
+# Seems to be some kind of java path
|
|
-rm -rf doc
|
|
+for file in `cat examples.list`; do
|
|
-for d in Common Filtering GenericFiltering Graphics Hybrid IO Imaging Parallel Rendering VolumeRendering Widgets
|
|
+ chrpath -d $RPM_BUILD_ROOT$file
|
|
-do
|
|
|
|
- install -d -m 755 doc/Testing/$d
|
|
|
|
- cp -a $d/Testing/* doc/Testing/$d
|
|
|
|
done
|
|
done
|
|
|
|
+chrpath -d $RPM_BUILD_ROOT%{_qt4_plugindir}/designer/libQVTKWidgetPlugin.so
|
|
|
|
|
|
-cp -a Examples doc
|
|
+# Main package contains utils and core libs
|
|
-find doc -name "*.o" -exec rm {} \;
|
|
+cat libs.list utils.list > main.list
|
|
-find doc -name CMakeCache.txt -exec rm {} \;
|
|
+popd
|
|
-find doc -name Makefile -exec rm {} \;
|
|
|
|
-find doc -name DartTestfile.txt -exec rm {} \;
|
|
|
|
-find doc -name .NoDartCoverage -exec rm {} \;
|
|
|
|
-find doc -name "cmake.*" -exec rm {} \;
|
|
|
|
|
|
|
|
-echo "%defattr (-, root, root)" > testing-progs-list
|
|
+# Make scripts executable
|
|
-find ${RPM_BUILD_ROOT}%{_bindir} -type f | \
|
|
+#chmod a+x %{buildroot}%{_libdir}/vtk/doxygen/*.pl
|
|
- sed -e "s#^${RPM_BUILD_ROOT}##g" | \
|
|
+#chmod a+x %{buildroot}%{_libdir}/vtk/testing/*.{py,tcl}
|
|
- egrep -v '^%{_bindir}/(vtk|pvtk|vtkWrap.*|vtkParseJava|VTKJavaExecutable|vtkpython|pvtkpython)$' \
|
|
|
|
- >> testing-progs-list
|
|
|
|
|
|
|
|
-tar zxvf %{SOURCE1}
|
|
+# Remove exec bit from non-scripts and %%doc
|
|
-install -d $RPM_BUILD_ROOT%{_datadir}
|
|
+for file in `find %{buildroot} -type f -perm 0755 \
|
|
-cp -r VTKData $RPM_BUILD_ROOT/%{vtkdata_dir}
|
|
+ | xargs -r file | grep ASCII | awk -F: '{print $1}'`; do
|
|
|
|
+ head -1 $file | grep '^#!' > /dev/null && continue
|
|
|
|
+ chmod 0644 $file
|
|
|
|
+done
|
|
|
|
+find Utilities/Upgrading -type f | xargs chmod -x
|
|
|
|
+
|
|
|
|
+# install VTKdata
|
|
|
|
+mkdir -p $RPM_BUILD_ROOT%{_datadir}
|
|
|
|
+pushd $RPM_BUILD_ROOT%{_datadir}
|
|
|
|
+tar -zpxf %{SOURCE1}
|
|
|
|
+mv VTK-%{version} %{name}-%{version}
|
|
|
|
+
|
|
|
|
+# (Verbosely) fix 0555 permissions
|
|
|
|
+find . -type f -perm 0555 | xargs -r echo chmod 0755 | sh -x
|
|
|
|
+# Remove execute bits from not-scripts
|
|
|
|
+for file in `find . -type f -perm 0755`; do
|
|
|
|
+ head -1 $file | grep '^#!' > /dev/null && continue
|
|
|
|
+ chmod 0644 $file
|
|
|
|
+done
|
|
|
|
+popd
|
|
|
|
|
|
-# Remove any possible verdict docs
|
|
+# Setup Wrapping docs tree
|
|
-rm -rf %buildroot/%{_libdir}/vtk-%{vtkver}/doc
|
|
+rm -rf _docs
|
|
|
|
+mkdir -p _docs
|
|
|
|
+cp -pr --parents Wrapping/*/README* _docs/
|
|
|
|
|
|
|
|
+%clean
|
|
|
|
+rm -rf $RPM_BUILD_ROOT
|
|
|
|
|
|
%post -p /sbin/ldconfig
|
|
%post -p /sbin/ldconfig
|
|
-%post tcl -p /sbin/ldconfig
|
|
+
|
|
-%post python -p /sbin/ldconfig
|
|
|
|
-%post qt -p /sbin/ldconfig
|
|
|
|
%postun -p /sbin/ldconfig
|
|
%postun -p /sbin/ldconfig
|
|
|
|
+
|
|
|
|
+%post tcl -p /sbin/ldconfig
|
|
|
|
+
|
|
%postun tcl -p /sbin/ldconfig
|
|
%postun tcl -p /sbin/ldconfig
|
|
|
|
+
|
|
|
|
+%post python -p /sbin/ldconfig
|
|
|
|
+
|
|
%postun python -p /sbin/ldconfig
|
|
%postun python -p /sbin/ldconfig
|
|
-%clean
|
|
|
|
-rm -rf $RPM_BUILD_ROOT
|
|
|
|
|
|
|
|
-%files
|
|
+%if %{with java}
|
|
|
|
+%post java -p /sbin/ldconfig
|
|
|
|
+
|
|
|
|
+%postun java -p /sbin/ldconfig
|
|
|
|
+%endif
|
|
|
|
+
|
|
|
|
+%post qt -p /sbin/ldconfig
|
|
|
|
+
|
|
|
|
+%postun qt -p /sbin/ldconfig
|
|
|
|
+
|
|
|
|
+%post qt-tcl -p /sbin/ldconfig
|
|
|
|
+
|
|
|
|
+%postun qt-tcl -p /sbin/ldconfig
|
|
|
|
+
|
|
|
|
+%post qt-python -p /sbin/ldconfig
|
|
|
|
+
|
|
|
|
+%postun qt-python -p /sbin/ldconfig
|
|
|
|
+
|
|
|
|
+
|
|
|
|
+%files -f build/main.list
|
|
%defattr(-,root,root)
|
|
%defattr(-,root,root)
|
|
-%doc Copyright.txt README.html TestingLogo.gif vtkLogo.jpg
|
|
+%doc Copyright.txt README.html vtkLogo.jpg vtkBanner.gif _docs/Wrapping
|
|
-%{_libdir}/*.so.*
|
|
+%config(noreplace) %{_sysconfdir}/ld.so.conf.d/vtk-%{_arch}.conf
|
|
|
|
+%{_datadir}/vtk
|
|
|
|
+%dir %{_libdir}/vtk
|
|
|
|
|
|
%files devel
|
|
%files devel
|
|
%defattr(-,root,root)
|
|
%defattr(-,root,root)
|
|
%doc Utilities/Upgrading
|
|
%doc Utilities/Upgrading
|
|
-%doc %{_libdir}/vtk-%{vtkver}/doxygen
|
|
+%{_bindir}/vtkHashSource
|
|
-%{_includedir}/vtk-%{vtkver}/
|
|
+%{_bindir}/vtkWrapHierarchy
|
|
-%{_libdir}/*.so
|
|
+%{_includedir}/vtk
|
|
-%{_libdir}/vtk-%{vtkver}/CMake/
|
|
+%{_libdir}/vtk/*.so
|
|
-%{_libdir}/vtk-%{vtkver}/*.cmake
|
|
+%{_libdir}/vtk/libvtkWrappingTools.a
|
|
-%{_libdir}/vtk-%{vtkver}/hints
|
|
+%{_libdir}/cmake/vtk/
|
|
-%{qt_designer_plugins_dir}/libQVTKWidgetPlugin.so
|
|
+%{_bindir}/vtkParseOGLExt
|
|
-
|
|
+%{_docdir}/vtk-6.1/
|
|
|
|
+%{tcl_sitelib}/vtk/vtktcl.c
|
|
|
|
|
|
%files tcl
|
|
%files tcl
|
|
%defattr(-,root,root)
|
|
%defattr(-,root,root)
|
|
-%dir %{_libdir}/vtk-%{vtkver}/testing
|
|
+%{_libdir}/vtk/*TCL.so.*
|
|
|
|
+%exclude %{_libdir}/vtk/*QtTCL.so.*
|
|
%{_bindir}/vtk
|
|
%{_bindir}/vtk
|
|
%{_bindir}/vtkWrapTcl
|
|
%{_bindir}/vtkWrapTcl
|
|
%{_bindir}/vtkWrapTclInit
|
|
%{_bindir}/vtkWrapTclInit
|
|
-%{_libdir}/libvtk*TCL.so.*
|
|
+%{tcl_sitelib}/vtk/
|
|
-%{_libdir}/vtk-%{vtkver}/tcl/
|
|
+%exclude %{tcl_sitelib}/vtk/vtktcl.c
|
|
-%{_libdir}/vtk-%{vtkver}/testing/*tcl
|
|
|
|
-%{_libdir}/vtk-%{vtkver}/pkgIndex.tcl
|
|
|
|
-
|
|
|
|
|
|
|
|
%files python
|
|
%files python
|
|
%defattr(-,root,root)
|
|
%defattr(-,root,root)
|
|
%{_bindir}/vtkpython
|
|
%{_bindir}/vtkpython
|
|
%{_bindir}/vtkWrapPython
|
|
%{_bindir}/vtkWrapPython
|
|
%{_bindir}/vtkWrapPythonInit
|
|
%{_bindir}/vtkWrapPythonInit
|
|
-%{_libdir}/libvtk*Python*.so.*
|
|
+%{_libdir}/vtk/*Python27D.so.*
|
|
-%{_libdir}/python%{pyver}/site-packages/*
|
|
+%{python_sitearch}/*
|
|
-%{_libdir}/vtk-%{vtkver}/testing/*py
|
|
+%exclude %{_libdir}/vtk/*QtPython27D.so.*
|
|
|
|
|
|
|
|
+%if %{with java}
|
|
|
|
+%files java
|
|
|
|
+%defattr(-,root,root)
|
|
|
|
+%{_libdir}/vtk/*Java.so.*
|
|
|
|
+%{_libdir}/vtk/vtk.jar
|
|
|
|
+%{_bindir}/vtkParseJava
|
|
|
|
+%{_bindir}/vtkWrapJava
|
|
|
|
+%endif
|
|
|
|
|
|
%files qt
|
|
%files qt
|
|
%defattr(-,root,root)
|
|
%defattr(-,root,root)
|
|
-%{_libdir}/libQVTK.so.*
|
|
+%{_libdir}/vtk/lib*Qt*.so.*
|
|
-
|
|
+%exclude %{_libdir}/vtk/*TCL.so.*
|
|
|
|
+%exclude %{_libdir}/vtk/*Python27D.so.*
|
|
|
|
+%{_qt4_plugindir}/designer/libQVTKWidgetPlugin.so
|
|
|
|
|
|
-%files examples
|
|
+%files qt-python
|
|
%defattr(-,root,root)
|
|
%defattr(-,root,root)
|
|
-%doc doc/Examples/
|
|
+%{_libdir}/vtk/*Python27D.so.*
|
|
-%doc doc/Testing/
|
|
|
|
|
|
|
|
|
|
+%files qt-tcl
|
|
|
|
+%defattr(-,root,root)
|
|
|
|
+%{_libdir}/vtk/*TCL.so.*
|
|
|
|
|
|
-%files testing-progs -f testing-progs-list
|
|
+%files testing-progs
|
|
|
|
+#-f testing-progs-list
|
|
|
|
|
|
|
|
+%files examples -f build/examples.list
|
|
|
|
+%defattr(-,root,root)
|
|
|
|
+%doc vtk-examples/Examples
|
|
|
|
|
|
%files data
|
|
%files data
|
|
%defattr(-,root,root)
|
|
%defattr(-,root,root)
|
|
-%{vtkdata_dir}
|
|
+%{_datadir}/%{name}-%{version}
|
|
|
|
|
|
|
|
|
|
%changelog
|
|
%changelog
|
|
|
|
+* Wed Jan 28 2015 Ryoichi INAGAKI <ryo1@toki.waseda.jp> 6.1.0-1
|
|
|
|
+- updated to 6.1.0
|
|
|
|
+- built with tcl/tk 8.5.15, libpng 1.6.12 and hdf5 1.8.14
|
|
|
|
+- added java, qt-tcl and qt-python subpackage
|
|
|
|
+
|
|
* Mon May 09 2011 Shu KONNO <owa@bg.wakwak.com> 5.4.2-3
|
|
* Mon May 09 2011 Shu KONNO <owa@bg.wakwak.com> 5.4.2-3
|
|
- s/qt-devel/qt4-devel/ at BR:
|
|
- s/qt-devel/qt4-devel/ at BR:
|
|
- add BR: libxml2-devel
|
|
- add BR: libxml2-devel
|