orion / rpms / paraview

Forked from rpms/paraview 4 years ago
Clone
11ff22f
Name:           paraview
f5fc6f8
Version:        2.4.4
df271c4
Release:        4%{?dist}
11ff22f
Summary:        Parallel visualization application
11ff22f
11ff22f
Group:          Applications/Engineering
11ff22f
License:        Distributable
11ff22f
URL:            http://www.paraview.org/
11ff22f
Source0:        http://www.paraview.org/files/v2.4/paraview-%{version}.tar.gz
11ff22f
Source1:        paraview_22x22.png
11ff22f
Source2:        paraview.xml
11ff22f
Patch0:         paraview-2.4.2-tcltk.patch
11ff22f
Patch1:         paraview-2.4.3-png.patch
11ff22f
Patch2:         paraview-2.4.3-python.patch
11ff22f
BuildRoot:      %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
11ff22f
dc468ba
BuildRequires:  cmake, lam-devel
710af13
BuildRequires:  libGLU-devel, libXt-devel, mesa-libOSMesa-devel
11ff22f
BuildRequires:  python-devel, tk-devel, hdf5-devel
11ff22f
BuildRequires:  freetype-devel, libjpeg-devel, libpng-devel, libtiff-devel, zlib-devel
11ff22f
BuildRequires:  expat-devel
11ff22f
BuildRequires:  /usr/bin/desktop-file-install
d340521
11ff22f
Requires:       %{name}-data = %{version}-%{release}
11ff22f
Requires(post):   /usr/bin/update-desktop-database
11ff22f
Requires(postun): /usr/bin/update-desktop-database
11ff22f
11ff22f
11ff22f
%description
11ff22f
ParaView is an application designed with the need to visualize large data
11ff22f
sets in mind. The goals of the ParaView project include the following:
11ff22f
11ff22f
    * Develop an open-source, multi-platform visualization application.
11ff22f
    * Support distributed computation models to process large data sets.
11ff22f
    * Create an open, flexible, and intuitive user interface.
11ff22f
    * Develop an extensible architecture based on open standards.
11ff22f
11ff22f
ParaView runs on distributed and shared memory parallel as well as single
11ff22f
processor systems and has been successfully tested on Windows, Linux and
11ff22f
various Unix workstations and clusters. Under the hood, ParaView uses the
11ff22f
Visualization Toolkit as the data processing and rendering engine and has a
11ff22f
user interface written using a unique blend of Tcl/Tk and C++.
11ff22f
11ff22f
NOTE: This version has NOT been compiled with MPI support.
11ff22f
11ff22f
11ff22f
%package        mpi
11ff22f
Summary:        Parallel visualization application
11ff22f
Group:          Applications/Engineering
11ff22f
Requires:       %{name}-data = %{version}-%{release}
11ff22f
Provides:       %{name}
11ff22f
Requires(post):   /usr/bin/update-desktop-database
11ff22f
Requires(postun): /usr/bin/update-desktop-database
11ff22f
11ff22f
%description    mpi
11ff22f
ParaView is an application designed with the need to visualize large data
11ff22f
sets in mind. The goals of the ParaView project include the following:
11ff22f
11ff22f
    * Develop an open-source, multi-platform visualization application.
11ff22f
    * Support distributed computation models to process large data sets.
11ff22f
    * Create an open, flexible, and intuitive user interface.
11ff22f
    * Develop an extensible architecture based on open standards.
11ff22f
11ff22f
ParaView runs on distributed and shared memory parallel as well as single
11ff22f
processor systems and has been successfully tested on Windows, Linux and
11ff22f
various Unix workstations and clusters. Under the hood, ParaView uses the
11ff22f
Visualization Toolkit as the data processing and rendering engine and has a
11ff22f
user interface written using a unique blend of Tcl/Tk and C++.
11ff22f
11ff22f
NOTE: This version has been compiled with LAM-MPI support and requires an
11ff22f
operating LAM-MPI runtime enviroment.
11ff22f
11ff22f
11ff22f
%package        data
11ff22f
Summary:        Data files for ParaView
11ff22f
Group:          Applications/Engineering
9455d00
Requires:       %{name} = %{version}-%{release}
11ff22f
Requires(post):   /usr/bin/update-mime-database
11ff22f
Requires(postun): /usr/bin/update-mime-database
11ff22f
11ff22f
%description    data
11ff22f
%{summary}.
11ff22f
11ff22f
11ff22f
%package        demos
11ff22f
Summary:        Demo files for ParaView
11ff22f
Group:          Applications/Engineering
11ff22f
Requires:       %{name}-data = %{version}-%{release}
11ff22f
11ff22f
%description    demos
11ff22f
%{summary}.
11ff22f
11ff22f
11ff22f
%prep
11ff22f
%setup -q
11ff22f
%patch -p1 -b .tcltk
11ff22f
%patch1 -p1 -b .png
11ff22f
%patch2 -p1 -b .python
11ff22f
rm -rf Utilities/TclTk
11ff22f
sed -i -e 's,INSTALL_FILES(/man/,INSTALL_FILES(/share/man/,' Utilities/IceT/doc/man/CMakeLists.txt
11ff22f
11ff22f
11ff22f
%build
11ff22f
rm -rf fedora fedora-mpi
11ff22f
mkdir fedora
11ff22f
pushd fedora
11ff22f
export CC='gcc'
11ff22f
export CXX='g++'
11ff22f
export MAKE='make'
11ff22f
export CFLAGS="$RPM_OPT_FLAGS"
11ff22f
export CXXFLAGS="$RPM_OPT_FLAGS"
11ff22f
cmake .. \
11ff22f
        -DCMAKE_INSTALL_PREFIX:PATH=%{_prefix} \
11ff22f
        -DPV_INSTALL_LIB_DIR:PATH=/%{_lib}/paraview-2.4 \
11ff22f
        -DCMAKE_SKIP_RPATH:BOOL=ON \
11ff22f
        -DBUILD_SHARED_LIBS:BOOL=ON \
11ff22f
        -DCMAKE_CXX_COMPILER:FILEPATH=$CXX \
11ff22f
        -DCMAKE_C_COMPILER:FILEPATH=$CC \
11ff22f
        -DCMAKE_VERBOSE_MAKEFILE:BOOL=ON \
11ff22f
        -DTCL_LIBRARY:PATH=tcl \
11ff22f
        -DTK_LIBRARY:PATH=tk \
11ff22f
        -DPARAVIEW_USE_SYSTEM_HDF5:BOOL=ON \
710af13
        -DPARAVIEW_WRAP_PYTHON:BOOL=ON \
710af13
        -DVTK_OPENGL_HAS_OSMESA:BOOL=ON \
11ff22f
        -DVTK_USE_SYSTEM_EXPAT:BOOL=ON \
11ff22f
        -DVTK_USE_SYSTEM_FREETYPE:BOOL=ON \
11ff22f
        -DVTK_USE_SYSTEM_JPEG:BOOL=ON \
11ff22f
        -DVTK_USE_SYSTEM_PNG:BOOL=ON \
11ff22f
        -DVTK_USE_SYSTEM_TIFF:BOOL=ON \
11ff22f
        -DVTK_USE_SYSTEM_ZLIB:BOOL=ON \
11ff22f
        -DBUILD_DOCUMENTATION:BOOL=ON \
11ff22f
        -DBUILD_EXAMPLES:BOOL=ON
11ff22f
make
11ff22f
popd
11ff22f
mkdir fedora-mpi
11ff22f
pushd fedora-mpi
11ff22f
export CC='gcc'
11ff22f
export CXX='g++'
11ff22f
export MAKE='make'
11ff22f
export CFLAGS="$RPM_OPT_FLAGS"
11ff22f
export CXXFLAGS="$RPM_OPT_FLAGS"
11ff22f
cmake .. \
11ff22f
        -DCMAKE_INSTALL_PREFIX:PATH=%{_prefix} \
11ff22f
        -DPV_INSTALL_LIB_DIR:PATH=/%{_lib}/paraview-2.4-mpi \
11ff22f
        -DCMAKE_SKIP_RPATH:BOOL=ON \
11ff22f
        -DBUILD_SHARED_LIBS:BOOL=ON \
11ff22f
        -DCMAKE_CXX_COMPILER:FILEPATH=$CXX \
11ff22f
        -DCMAKE_C_COMPILER:FILEPATH=$CC \
11ff22f
        -DCMAKE_VERBOSE_MAKEFILE:BOOL=ON \
11ff22f
        -DTCL_LIBRARY:PATH=tcl \
11ff22f
        -DTK_LIBRARY:PATH=tk \
11ff22f
        -DPARAVIEW_USE_SYSTEM_HDF5:BOOL=ON \
710af13
        -DPARAVIEW_WRAP_PYTHON:BOOL=ON \
11ff22f
        -DVTK_USE_MPI:BOOL=ON \
11ff22f
        -DMPI_INCLUDE_PATH:PATH=%{_includedir}/lam \
11ff22f
        -DMPI_LIBRARY:STRING="-L%{_libdir}/lam -llammpio -llammpi++ -llamf77mpi -lmpi -llam -laio -lutil -ldl" \
710af13
        -DVTK_OPENGL_HAS_OSMESA:BOOL=ON \
11ff22f
        -DVTK_USE_SYSTEM_EXPAT:BOOL=ON \
11ff22f
        -DVTK_USE_SYSTEM_FREETYPE:BOOL=ON \
11ff22f
        -DVTK_USE_SYSTEM_JPEG:BOOL=ON \
11ff22f
        -DVTK_USE_SYSTEM_PNG:BOOL=ON \
11ff22f
        -DVTK_USE_SYSTEM_TIFF:BOOL=ON \
11ff22f
        -DVTK_USE_SYSTEM_ZLIB:BOOL=ON \
11ff22f
        -DBUILD_DOCUMENTATION:BOOL=ON \
11ff22f
        -DBUILD_EXAMPLES:BOOL=ON
11ff22f
make
11ff22f
11ff22f
11ff22f
%install
11ff22f
rm -rf $RPM_BUILD_ROOT
11ff22f
11ff22f
#Fix permissions
11ff22f
find . \( -name \*.txt -o -name \*.xml -o -name '*.[ch]' -o -name '*.[ch][px][px]' \) -print0 | xargs -0 chmod -x
11ff22f
11ff22f
# Create some needed directories
11ff22f
install -d $RPM_BUILD_ROOT%{_datadir}/applications
11ff22f
install -d $RPM_BUILD_ROOT%{_datadir}/pixmaps
11ff22f
install -m644 %SOURCE1 $RPM_BUILD_ROOT%{_datadir}/pixmaps
11ff22f
install -d $RPM_BUILD_ROOT%{_datadir}/mime/packages
11ff22f
install -m644 %SOURCE2 $RPM_BUILD_ROOT%{_datadir}/mime/packages
11ff22f
11ff22f
# Install mpi version
11ff22f
pushd fedora-mpi
11ff22f
make install DESTDIR=$RPM_BUILD_ROOT
11ff22f
#Get rid of useless man and cmake files
c00a71c
install -m 755 bin/libvtkPVServerCommonPython.so $RPM_BUILD_ROOT%{_libdir}/paraview-2.4-mpi/
c00a71c
install -m 755 bin/libvtkPVServerManagerPython.so $RPM_BUILD_ROOT%{_libdir}/paraview-2.4-mpi/
11ff22f
rm -rf $RPM_BUILD_ROOT%{_mandir}
11ff22f
rm $RPM_BUILD_ROOT%{_libdir}/paraview-2.4-mpi/*ICET*cmake
11ff22f
cat > paraview-mpi.desktop <
11ff22f
[Desktop Entry]
11ff22f
Encoding=UTF-8
11ff22f
Name=ParaView Viewer MPI
11ff22f
GenericName=Data Viewer
11ff22f
Comment=ParaView allows MPI enabled viewing of large data sets
11ff22f
Type=Application
11ff22f
Terminal=false
11ff22f
Icon=paraview_22x22.png
11ff22f
MimeType=application/x-paraview
11ff22f
Categories=Application;Graphics;
11ff22f
Exec=mpirun C paraview-mpi
11ff22f
EOF
11ff22f
11ff22f
desktop-file-install --vendor=fedora \
11ff22f
       --add-category=X-Fedora \
11ff22f
       --dir %{buildroot}%{_datadir}/applications/ \
11ff22f
       paraview-mpi.desktop
11ff22f
11ff22f
popd
11ff22f
11ff22f
#Move the mpi binaries out of the way
11ff22f
pushd $RPM_BUILD_ROOT/%{_bindir}
11ff22f
for f in *
11ff22f
do
11ff22f
   mv $f ${f}-mpi
11ff22f
done
11ff22f
popd
11ff22f
11ff22f
#Install the normal version
11ff22f
pushd fedora
11ff22f
make install DESTDIR=$RPM_BUILD_ROOT
c00a71c
install -m 755 bin/libvtkPVServerCommonPython.so $RPM_BUILD_ROOT%{_libdir}/paraview-2.4/
c00a71c
install -m 755 bin/libvtkPVServerManagerPython.so $RPM_BUILD_ROOT%{_libdir}/paraview-2.4/
11ff22f
cat > paraview.desktop <
11ff22f
[Desktop Entry]
11ff22f
Encoding=UTF-8
11ff22f
Name=ParaView Viewer
11ff22f
GenericName=Data Viewer
11ff22f
Comment=ParaView allows viewing of large data sets
11ff22f
Type=Application
11ff22f
Terminal=false
11ff22f
Icon=paraview_22x22.png
11ff22f
MimeType=application/x-paraview
11ff22f
Categories=Application;Graphics;
11ff22f
Exec=paraview
11ff22f
EOF
11ff22f
11ff22f
desktop-file-install --vendor=fedora \
11ff22f
       --add-category=X-Fedora \
11ff22f
       --dir %{buildroot}%{_datadir}/applications/ \
11ff22f
       paraview.desktop
11ff22f
11ff22f
popd
11ff22f
11ff22f
11ff22f
%clean
11ff22f
rm -rf $RPM_BUILD_ROOT
11ff22f
11ff22f
11ff22f
%post
11ff22f
update-desktop-database &> /dev/null ||:
11ff22f
11ff22f
%postun
11ff22f
update-desktop-database &> /dev/null ||:
11ff22f
11ff22f
11ff22f
%post   mpi
11ff22f
update-desktop-database &> /dev/null ||:
11ff22f
11ff22f
%postun mpi
11ff22f
update-desktop-database &> /dev/null ||:
11ff22f
11ff22f
11ff22f
%post   data
11ff22f
update-mime-database %{_datadir}/mime &> /dev/null || :
11ff22f
11ff22f
%postun data
11ff22f
update-mime-database %{_datadir}/mime &> /dev/null || :
11ff22f
11ff22f
11ff22f
%files
11ff22f
%defattr(-,root,root,-)
11ff22f
%doc Copyright.txt README.html
11ff22f
%{_bindir}/paraview
11ff22f
%{_bindir}/pvbatch
11ff22f
%{_bindir}/pvclient
11ff22f
%{_bindir}/pvdataserver
710af13
%{_bindir}/pvpython
11ff22f
%{_bindir}/pvrenderserver
11ff22f
%{_bindir}/pvserver
11ff22f
%{_datadir}/applications/fedora-paraview.desktop
11ff22f
%{_libdir}/paraview-2.4/
11ff22f
11ff22f
11ff22f
%files mpi
11ff22f
%defattr(-,root,root,-)
11ff22f
%doc Copyright.txt README.html
11ff22f
%{_bindir}/paraview-mpi
11ff22f
%{_bindir}/pvbatch-mpi
11ff22f
%{_bindir}/pvclient-mpi
11ff22f
%{_bindir}/pvdataserver-mpi
710af13
%{_bindir}/pvpython-mpi
11ff22f
%{_bindir}/pvrenderserver-mpi
11ff22f
%{_bindir}/pvserver-mpi
11ff22f
%{_datadir}/applications/fedora-paraview-mpi.desktop
11ff22f
%{_libdir}/paraview-2.4-mpi/
11ff22f
11ff22f
11ff22f
%files data
11ff22f
%defattr(-,root,root,-)
11ff22f
%{_datadir}/paraview-2.4/
11ff22f
%exclude %{_datadir}/paraview-2.4/Demos
11ff22f
%{_datadir}/pixmaps/paraview_22x22.png
11ff22f
%{_datadir}/mime/packages/paraview.xml
11ff22f
11ff22f
11ff22f
%files demos
11ff22f
%defattr(-,root,root,-)
11ff22f
%{_datadir}/paraview-2.4/Demos/
11ff22f
11ff22f
11ff22f
%changelog
df271c4
* Thu Dec 14 2006 - Jef Spaleta <jspaleta@gmail.com> - 2.4.4-4
df271c4
- Bump and build for python 2.5
df271c4
c00a71c
* Fri Oct  6 2006 - Orion Poplawski <orion@cora.wnra.com> - 2.4.4-3
c00a71c
- Install needed python libraries to get around make install bug
c00a71c
710af13
* Wed Oct  4 2006 - Orion Poplawski <orion@cora.wnra.com> - 2.4.4-2
710af13
- Re-enable OSMESA support for FC6
710af13
- Enable python wrapping
710af13
f5fc6f8
* Fri Sep 15 2006 - Orion Poplawski <orion@cora.wnra.com> - 2.4.4-1
f5fc6f8
- Update to 2.4.4
f5fc6f8
9455d00
* Thu Jun 29 2006 - Orion Poplawski <orion@cora.wnra.com> - 2.4.3-8
9455d00
- No OSMesa support in FC5
9455d00
- Make data sub-package pull in main package (bug #193837)
9455d00
- A patch from CVS to fix vtkXOpenRenderWindow.cxx
dc468ba
- Need lam-devel for FC6
9455d00
0b2b598
* Fri Apr 21 2006 - Orion Poplawski <orion@cora.wnra.com> - 2.4.3-7
0b2b598
- Re-enable ppc
0b2b598
d340521
* Mon Apr 17 2006 - Orion Poplawski <orion@cora.wnra.com> - 2.4.3-6
d340521
- Exclude ppc due to gcc bug #189160
d340521
11ff22f
* Wed Apr 12 2006 - Orion Poplawski <orion@cora.wnra.com> - 2.4.3-5
11ff22f
- Cleanup permissions
11ff22f
11ff22f
* Mon Apr 10 2006 - Orion Poplawski <orion@cora.wnra.com> - 2.4.3-4
11ff22f
- Add icon and cleanup desktop file
11ff22f
11ff22f
* Mon Apr 10 2006 - Orion Poplawski <orion@cora.wnra.com> - 2.4.3-3
11ff22f
- Add VTK_USE_MANGLE_MESA for off screen rendering
11ff22f
- Cleanup source permisions
11ff22f
- Add an initial .desktop file
11ff22f
- Make requirement on -data specific to version
11ff22f
- Don't package Ice-T man pages and cmake files
11ff22f
11ff22f
* Thu Apr  6 2006 - Orion Poplawski <orion@cora.wnra.com> - 2.4.3-2
11ff22f
- Add mpi version
11ff22f
11ff22f
* Tue Apr  4 2006 - Orion Poplawski <orion@cora.wnra.com> - 2.4.3-1
11ff22f
- Initial Fedora Extras version