]> git.pld-linux.org Git - packages/povray.git/blob - povray.spec
- Release: 2
[packages/povray.git] / povray.spec
1
2 #
3 # todo:
4 #      patch for s#/usr/local#/usr# in povray.ini
5 #      (no)svga version
6 #
7
8 # Conditional build:
9 %bcond_without x        # - without X11 subpackage
10 %bcond_without pvm      # - without PVM support
11
12 %define         snap 20030110
13 Summary:        Persistence of Vision Ray Tracer
14 Summary(pl):    Persistence of Vision Ray Tracer
15 Name:           povray
16 Version:        3.50c
17 Release:        2
18 License:        distributable
19 Group:          Applications/Graphics
20 #Source0:       ftp://ftp.povray.org/pub/povray/Official/Unix/povuni_s.tgz
21 # based on sources from CVS at http://pvmpov.sourceforge.net/
22 Source0:        %{name}-%{version}-%{snap}.tar.gz
23 # Source0-md5: 4dc3a74c6182e9f9cb2fc46187fe7e6b
24 Patch0:         %{name}-legal.patch
25 Patch1:         %{name}-amd64.patch
26 Patch2:         %{name}-X-libs.patch
27 Patch3:         %{name}-lib64.patch
28 URL:            http://www.povray.org/
29 %{!?with_x:BuildRequires:XFree86-devel}
30 BuildRequires:  autoconf
31 BuildRequires:  automake
32 BuildRequires:  libjpeg-devel
33 BuildRequires:  libpng-devel >= 1.0.8
34 BuildRequires:  libstdc++-devel
35 BuildRequires:  libtiff-devel
36 %{!?with_pvm:BuildRequires:pvm-devel >= 3.4.3-24 }
37 BuildRequires:  zlib-devel
38 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
39
40 %define         _pvmarch        %(/usr/bin/pvmgetarch)
41 %define         _pvmroot        /usr/%{_lib}/pvm3
42
43 %description
44 The Persistence of Vision(tm) Ray-Tracer creates three-dimensional,
45 photo-realistic images using a rendering technique called ray-tracing.
46 It reads in a text file containing information describing the objects
47 and lighting in a scene and generates an image of that scene from the
48 view point of a camera also described in the text file. Ray-tracing is
49 not a fast process by any means, but it produces very high quality
50 images with realistic reflections, shading, perspective and other
51 effects.
52
53 %description -l pl
54 Persistence of Vision(tm) Ray-Tracer tworzy trójwymiarowe,
55 fotorealistyczne obrazy za pomoc± techniki renderingu zwanej
56 ray-tracing. Program pobiera z pliku tekstowego informacje opisuj±ce
57 obiekty oraz ¶wiat³o przedstawianego ¶wiata, a nastêpnie generuje
58 rysunek z punktu widzenia kamery, która tak¿e jest definiowana w w/w
59 pliku tekstowym. Ray-tracing nie pozwala na szybkie tworzenie obrazów,
60 ale za to twórca otrzymuje wyskokiej jako¶ci bitmapy z realistycznymi
61 efektami, tj. odbicia ¶wiat³a, cienie, perspektywa i inne.
62
63 %package X11
64 Summary:        X Window povray executable
65 Summary(pl):    povray pod X Window
66 Group:          Applications/Graphics
67 Requires:       %{name} = %{version}
68
69 %description X11
70 The Persistence of Vision(tm) Ray-Tracer X Window executable.
71
72 %description X11 -l pl
73 Plik wykonywalny The Persistence of Vision(tm) Ray-Tracer dla X
74 Window.
75
76 %package pvm
77 Summary:        PVM/unix povray executable
78 Summary(pl):    Plik wykonywalny povray dla PVM/unix
79 Group:          Applications/Graphics
80 Requires:       %{name} = %{version}
81
82 %description pvm
83 The Persistence of Vision(tm) Ray-Tracer PVM/unix executable.
84
85 %description pvm -l pl
86 Plik wykonywalny The Persistence of Vision(tm) Ray-Tracer dla
87 PVM/unix.
88
89 %package pvm-X11
90 Summary:        PVM/xwin povray executable
91 Summary(pl):    Plik wykonywalny povray dla PVM/xwin
92 Group:          Applications/Graphics
93 Requires:       %{name} = %{version}
94
95 %description pvm-X11
96 The Persistence of Vision(tm) Ray-Tracer PVM/xwin executable.
97
98 %description pvm-X11 -l pl
99 Plik wykonywalny The Persistence of Vision(tm) Ray-Tracer dla
100 PVM/xwin.
101
102 %prep
103 %setup -q
104 %patch1 -p1
105 %patch2 -p1
106 %if "%{_lib}" == "lib64"
107 %patch3 -p1
108 %endif
109
110 %build
111 %{__aclocal}
112 %{__autoconf}
113 %{__automake}
114 %if %{with x} && %{with pvm}
115 %configure \
116         --libdir=%{_datadir} \
117         --enable-pvm \
118         --with-pvm-arch=%{_pvmarch} \
119         --with-pvm-libs=%{_libdir} \
120         --x-includes=/usr/X11R6/include \
121         --x-libraries=/usr/X11R6/%{_lib}
122 %{__make}
123 install src/povray x-pvmpov
124 %endif
125
126 %if %{with pvm}
127 %{__make} clean
128
129 %configure \
130         --libdir=%{_datadir} \
131         --enable-pvm \
132         --with-pvm-arch=%{_pvmarch} \
133         --with-pvm-libs=%{_libdir} \
134         --without-x
135 %{__make}
136 install src/povray pvmpov
137 %endif
138
139 %if %{with x}
140 %configure \
141         --libdir=%{_datadir} \
142         --x-includes=/usr/X11R6/include \
143         --x-libraries=/usr/X11R6/%{_lib} 
144 %{__make}
145 install src/povray x-povray
146 %{__make} clean
147 %endif
148
149 %configure \
150         --libdir=%{_datadir} \
151         --without-x
152 %{__make}
153
154
155 %install
156 rm -rf $RPM_BUILD_ROOT
157 install -d $RPM_BUILD_ROOT{%{_sysconfdir},/usr/X11R6/bin} \
158         $RPM_BUILD_ROOT%{_pvmroot}/bin/%{_pvmarch}
159
160 %{__make} install \
161         DESTDIR=$RPM_BUILD_ROOT
162
163 %if %{with x}
164 install x-povray $RPM_BUILD_ROOT%{_bindir}
165 %endif
166
167 %if %{with x} && %{with pvm}
168 install x-pvmpov $RPM_BUILD_ROOT%{_bindir}/x-pvmpov
169 ln -s %{_bindir}/x-pvmpov $RPM_BUILD_ROOT%{_pvmroot}/bin/%{_pvmarch}/x-pvmpov
170 %endif
171
172 %if %{with pvm}
173 install pvmpov $RPM_BUILD_ROOT%{_bindir}/pvmpov
174 ln -s %{_bindir}/pvmpov $RPM_BUILD_ROOT%{_pvmroot}/bin/%{_pvmarch}/pvmpov
175 %endif
176
177 install povray.ini $RPM_BUILD_ROOT%{_sysconfdir}
178 install povray.conf $RPM_BUILD_ROOT%{_sysconfdir}
179 ln -sf %{_sysconfdir}/povray.ini $RPM_BUILD_ROOT%{_datadir}/povray-3.5/povray.ini
180
181 %clean
182 rm -rf $RPM_BUILD_ROOT
183
184 %files
185 %defattr(644,root,root,755)
186 %doc AUTHORS ChangeLog NEWS README* povlegal.doc *.txt doc/html
187 %attr(755,root,root) %{_bindir}/povray
188 %{_datadir}/povray*
189 %{_mandir}/man?/*
190 %config(noreplace) %verify(not md5 size mtime) %{_sysconfdir}/povray.*
191
192 %if %{with x}
193 %files X11
194 %defattr(644,root,root,755)
195 %attr(755,root,root) %{_bindir}/x-povray
196 %endif
197
198 %if %{with pvm} && %{with pvm}
199 %files pvm
200 %defattr(644,root,root,755)
201 %attr(755,root,root) %{_pvmroot}/bin/%{_pvmarch}/pvmpov
202 %attr(755,root,root) %{_bindir}/pvmpov
203 %endif
204
205 %if %{with pvm} && %{with x}
206 %files pvm-X11
207 %defattr(644,root,root,755)
208 %attr(755,root,root) %{_pvmroot}/bin/%{_pvmarch}/x-pvmpov
209 %attr(755,root,root) %{_bindir}/x-pvmpov
210 %endif
This page took 0.042673 seconds and 4 git commands to generate.