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