]> git.pld-linux.org Git - packages/povray.git/blobdiff - povray.spec
- up to 3.8.0-beta.2
[packages/povray.git] / povray.spec
index 70aa5977dd7d1d4541db6eb8dafd17607e3027c1..3cb46d52719f43ef912d59d2899780ff20bc8e28 100644 (file)
@@ -1,36 +1,48 @@
-
-#
-# todo:
-#      patch for s#/usr/local#/usr# in povray.ini
 #
-
 # Conditional build:
-# _without_x   - without X11 subpackage
-# _without_pvm - [temporarily disabled by default] without PVM support
+%bcond_without x       # - without X11 subpackage
+%bcond_with    pvm     # - with PVM support
+%bcond_with    svga    # - with svgalib support (doesn't work on many platforms)
 #
+%define        subver  beta.2
+%define        rel     1
 Summary:       Persistence of Vision Ray Tracer
-Summary(pl):   Persistence of Vision Ray Tracer
+Summary(pl.UTF-8):     Persistence of Vision Ray Tracer
 Name:          povray
-Version:       3.50c
-Release:       1
-License:       distributable
+Version:       3.8.0
+Release:       0.%{subver}.%{rel}
+Epoch:         1
+License:       AGPL v3+
 Group:         Applications/Graphics
-Source0:       ftp://ftp.povray.org/pub/povray/Official/Unix/povuni_s.tgz
-Source1:       %{name}-%{version}.md5sum
-Patch0:                %{name}-legal.patch
-Patch1:                %{name}-types.patch
-# pvm support not yet available - http://pvmpov.sourceforge.net/
+#Source0Download: https://github.com/POV-Ray/povray/releases
+Source0:       https://github.com/POV-Ray/povray/archive/v%{version}-%{subver}/%{name}-%{version}-%{subver}.tar.gz
+# Source0-md5: f253c837495da02189723059236e9434
+Patch1:                x32.patch
 URL:           http://www.povray.org/
-BuildRequires: libjpeg-devel
-BuildRequires: libpng-devel >= 1.0.8
+BuildRequires: OpenEXR-devel >= 1.2
+BuildRequires: SDL-devel >= 1.2
+BuildRequires: autoconf >= 2.59
+BuildRequires: automake >= 1:1.9
+BuildRequires: boost-devel >= 1.38
+BuildRequires: libjpeg-devel >= 6b
+BuildRequires: libpng-devel >= 2:1.4.0
 BuildRequires: libstdc++-devel
-BuildRequires: libtiff-devel
-BuildRequires: zlib-devel
-%{!?_without_x:BuildRequires:XFree86-devel}
-#%{!?_without_pvm:BuildRequires:pvm-devel >= 3.4.3-24 }
+BuildRequires: libtiff-devel >= 3.6.1
+BuildRequires: perl-base
+%{?with_pvm:BuildRequires:     pvm-devel >= 3.4.3-24}
+%{?with_svga:BuildRequires:    svgalib-devel}
+%{?with_x:BuildRequires:       xorg-lib-libX11-devel}
+BuildRequires: zlib-devel >= 1.2.1
+Requires:      OpenEXR >= 1.2
+Requires:      SDL >= 1.2
+Requires:      libtiff >= 3.6.1
+Requires:      zlib >= 1.2.1
 BuildRoot:     %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
 
-%define                _libdir         %{_datadir}
+%if %{with pvm}
+%define                _pvmarch        %(/usr/bin/pvmgetarch)
+%define                _pvmroot        /usr/%{_lib}/pvm3
+%endif
 
 %description
 The Persistence of Vision(tm) Ray-Tracer creates three-dimensional,
@@ -42,120 +54,165 @@ not a fast process by any means, but it produces very high quality
 images with realistic reflections, shading, perspective and other
 effects.
 
-%description -l pl
-Persistence of Vision(tm) Ray-Tracer tworzy trójwymiarowe,
-fotorealistyczne obrazy za pomoc± techniki renderingu zwanej
-ray-tracing. Program pobiera z pliku tekstowego informacje opisuj±ce
-obiekty oraz ¶wiat³o przedstawianego ¶wiata, a nastêpnie generuje
-rysunek z punktu widzenia kamery, która tak¿e jest definiowana w w/w
-pliku tekstowym. Ray-tracing nie pozwala na szybkie tworzenie obrazów,
-ale za to twórca otrzymuje wyskokiej jako¶ci bitmapy z realistycznymi
-efektami, tj. odbicia ¶wiat³a, cienie, perspektywa i inne.
+%description -l pl.UTF-8
+Persistence of Vision(tm) Ray-Tracer tworzy trójwymiarowe,
+fotorealistyczne obrazy za pomocą techniki renderingu zwanej
+ray-tracing. Program pobiera z pliku tekstowego informacje opisujące
+obiekty oraz światło przedstawianego świata, a następnie generuje
+rysunek z punktu widzenia kamery, która także jest definiowana w w/w
+pliku tekstowym. Ray-tracing nie pozwala na szybkie tworzenie obrazów,
+ale za to twórca otrzymuje wyskokiej jakości bitmapy z realistycznymi
+efektami, tj. odbicia światła, cienie, perspektywa i inne.
 
 %package X11
 Summary:       X Window povray executable
-Summary(pl):   povray pod X Window
+Summary(pl.UTF-8):     povray pod X Window
 Group:         Applications/Graphics
-Requires:      %{name} = %{version}
+Requires:      %{name} = %{epoch}:%{version}-%{release}
 
 %description X11
 The Persistence of Vision(tm) Ray-Tracer X Window executable.
 
-%description X11 -l pl
+%description X11 -l pl.UTF-8
 Plik wykonywalny The Persistence of Vision(tm) Ray-Tracer dla X
 Window.
 
 %package pvm
-Summary:       PVM/unix povray executable
+Summary:       PVM/Unix povray executable
+Summary(pl.UTF-8):     Plik wykonywalny povray dla PVM/Unix
 Group:         Applications/Graphics
-Requires:      %{name} = %{version}
+Requires:      %{name} = %{epoch}:%{version}-%{release}
 
 %description pvm
-The Persistence of Vision(tm) Ray-Tracer PVM/unix executable.
+The Persistence of Vision(tm) Ray-Tracer PVM/Unix executable.
 
-%description X11 -l pl
+%description pvm -l pl.UTF-8
 Plik wykonywalny The Persistence of Vision(tm) Ray-Tracer dla
-PVM/unix.
+PVM/Unix.
 
 %package pvm-X11
 Summary:       PVM/xwin povray executable
+Summary(pl.UTF-8):     Plik wykonywalny povray dla PVM/xwin
 Group:         Applications/Graphics
-Requires:      %{name} = %{version}
+Requires:      %{name} = %{epoch}:%{version}-%{release}
 
 %description pvm-X11
 The Persistence of Vision(tm) Ray-Tracer PVM/xwin executable.
 
-%description X11 -l pl
+%description pvm-X11 -l pl.UTF-8
 Plik wykonywalny The Persistence of Vision(tm) Ray-Tracer dla
 PVM/xwin.
 
 %prep
-cd %{_sourcedir}
-md5sum -c %{name}-%{version}.md5sum
-cd -
-%setup -q
-%patch0 -p1
-%ifarch alpha
+%setup -q -n %{name}-%{version}-%{subver}
+%ifarch x32
 %patch1 -p1
 %endif
 
 %build
-%{__aclocal}
-%{__autoconf}
-%{__automake}
-%if %{!?_without_x:1}%{?_without_x:0}
+cd unix
+./prebuild.sh
+cd ..
+
+COMPILED_BY="PLD/Linux Team";export COMPILED_BY;
+# disable optimiz-arch, it means -march=native for gcc
+%if %{with x} && %{with pvm}
 %configure \
-       --x-includes=%{_prefix}/X11R6/include \
-       --x-libraries=%{_prefix}/X11R6/lib
+       --libdir=%{_datadir} \
+       --disable-optimiz-arch \
+       --enable-pvm \
+       --with-pvm-arch=%{_pvmarch} \
+       --with-pvm-libs=%{_libdir}
 %{__make}
-install src/povray x-povray
+install unix/povray x-pvmpov
+%endif
+
+%if %{with pvm}
 %{__make} clean
+
+%configure \
+       --libdir=%{_datadir} \
+       --disable-optimiz-arch \
+       --enable-pvm \
+       --with-pvm-arch=%{_pvmarch} \
+       --with-pvm-libs=%{_libdir} \
+       --without-x
+%{__make}
+install unix/povray pvmpov
 %endif
 
+%if %{with x}
 %configure \
+       --libdir=%{_datadir} \
+       --disable-optimiz-arch
+%{__make}
+install unix/povray x-povray
+%{__make} clean
+%endif
+
+%configure \
+       --libdir=%{_datadir} \
+       --disable-optimiz-arch \
        --without-x
 %{__make}
 
 %install
 rm -rf $RPM_BUILD_ROOT
-install -d $RPM_BUILD_ROOT{%{_sysconfdir},%{_prefix}/X11R6/bin}
+install -d $RPM_BUILD_ROOT{%{_sysconfdir},%{_bindir},%{_datadir}}
+%if %{with pvm}
+install -d $RPM_BUILD_ROOT%{_pvmroot}/bin/%{_pvmarch}
+%endif
 
 %{__make} install \
+       INSTALL="install -c -D" \
+       mkdir_p="mkdir -p" \
        DESTDIR=$RPM_BUILD_ROOT
 
-%if %{!?_without_x:1}%{?_without_x:0}
-install x-povray $RPM_BUILD_ROOT%{_prefix}/X11R6/bin
+%if %{with x}
+install x-povray $RPM_BUILD_ROOT%{_bindir}
 %endif
 
-install povray.ini $RPM_BUILD_ROOT%{_sysconfdir}
-install povray.conf $RPM_BUILD_ROOT%{_sysconfdir}
-ln -sf %{_sysconfdir}/povray.ini $RPM_BUILD_ROOT%{_datadir}/povray-3.5/povray.ini
+%if %{with x} && %{with pvm}
+install x-pvmpov $RPM_BUILD_ROOT%{_bindir}/x-pvmpov
+ln -s %{_bindir}/x-pvmpov $RPM_BUILD_ROOT%{_pvmroot}/bin/%{_pvmarch}/x-pvmpov
+%endif
+
+%if %{with pvm}
+install pvmpov $RPM_BUILD_ROOT%{_bindir}/pvmpov
+ln -s %{_bindir}/pvmpov $RPM_BUILD_ROOT%{_pvmroot}/bin/%{_pvmarch}/pvmpov
+%endif
 
 %clean
 rm -rf $RPM_BUILD_ROOT
 
 %files
 %defattr(644,root,root,755)
-%doc AUTHORS ChangeLog NEWS README* povlegal.doc *.txt doc/html
+%doc AUTHORS ChangeLog NEWS README* changes.txt
 %attr(755,root,root) %{_bindir}/povray
-%{_libdir}/povray*
-%{_mandir}/man?/*
-%config(noreplace) %verify(not md5 size mtime) %{_sysconfdir}/povray.*
-
-%if %{!?_without_x:1}%{?_without_x:0}
+%{_datadir}/povray*
+%{_docdir}/povray*
+%{_mandir}/man1/povray.1*
+%dir %{_sysconfdir}/povray
+%dir %{_sysconfdir}/povray/3.7
+%config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}/3.7/povray.conf
+%config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}/3.7/povray.ini
+
+%if %{with x}
 %files X11
 %defattr(644,root,root,755)
-%attr(755,root,root) %{_prefix}/X11R6/bin/x-povray
+%attr(755,root,root) %{_bindir}/x-povray
 %endif
 
-#%if %{!?_without_pvm:1}%{?_without_pvm:0}
-#%files pvm
-#%defattr(644,root,root,755)
-#%attr(755,root,root) %{_pvm_root}/bin/%{_pvm_arch}/pvmpov
-#
-#%if %{!?_without_x:1}%{?_without_x:0}
-#%files pvm-X11
-#%defattr(644,root,root,755)
-#%attr(755,root,root) %{_pvm_root}/bin/%{_pvm_arch}/x-pvmpov
-#%endif
-#%endif
+%if %{with pvm}
+%files pvm
+%defattr(644,root,root,755)
+%attr(755,root,root) %{_pvmroot}/bin/%{_pvmarch}/pvmpov
+%attr(755,root,root) %{_bindir}/pvmpov
+%endif
+
+%if %{with pvm} && %{with x}
+%files pvm-X11
+%defattr(644,root,root,755)
+%attr(755,root,root) %{_pvmroot}/bin/%{_pvmarch}/x-pvmpov
+%attr(755,root,root) %{_bindir}/x-pvmpov
+%endif
This page took 0.27674 seconds and 4 git commands to generate.