1 |
< |
### RPM lcg root 5.12.00 |
2 |
< |
# INITENV +PATH PYTHONPATH %i/lib/python |
3 |
< |
Source: cvs://:pserver:cvs@root.cern.ch:2401/user/cvs?passwd=Ah<Z&tag=-rv%(echo %v | tr . -)&module=root&output=/%{n}_v%{v}.source.tar.gz |
4 |
< |
#Source: ftp://root.cern.ch/%n/%{n}_v%{v}.source.tar.gz |
5 |
< |
Requires: gccxml python qt gsl castor openssl mysql libpng libjpg libtiff dcap pcre zlib |
1 |
> |
### RPM lcg root 5.22.00d |
2 |
> |
## INITENV +PATH PYTHONPATH %i/lib/python |
3 |
> |
## INITENV SET ROOTSYS %i |
4 |
> |
#Source: cvs://:pserver:cvs@root.cern.ch:2401/user/cvs?passwd=Ah<Z&tag=-rv%(echo %realversion | tr . -)&module=root&output=/%{n}_v%{realversion}.source.tar.gz |
5 |
> |
Source: ftp://root.cern.ch/%n/%{n}_v%{realversion}.source.tar.gz |
6 |
> |
%define closingbrace ) |
7 |
> |
%define online %(case %cmsplatf in *onl_*_*%closingbrace echo true;; *%closingbrace echo false;; esac) |
8 |
> |
|
9 |
> |
Patch0: root-5.18-00-libpng |
10 |
> |
Patch1: root-5.21-04-CINT-maxlongline |
11 |
> |
Patch2: root-5.22-00-TMVA-shut-the-hell-up-for-once |
12 |
> |
Patch3: root-5.22-00a-TMVA-shut-the-hell-up-again |
13 |
> |
Patch4: root-5.22-00d-fireworks-graf3d-gui |
14 |
> |
Patch5: root-5.22-00a-roofit-silence-static-printout |
15 |
> |
Patch6: root-5.22-00a-TMVA-just-shut-the-hell-up |
16 |
> |
Patch7: root-5.22-00a-th1 |
17 |
> |
Patch8: root-5.22-00a-smatrix |
18 |
> |
Patch9: root-5.22-00a-fireworks1 |
19 |
> |
Patch10: root-5.22-00a-gcc44 |
20 |
> |
Patch11: root-5.22-00a-fireworks2 |
21 |
> |
Patch12: root-5.22-00a-fireworks3 |
22 |
> |
Patch13: root-5.22-00a-gcc43-array-bounds-dictionary-workaround |
23 |
> |
Patch14: root-5.22-00a-fireworks4 |
24 |
> |
Patch15: root-5.22-00d-fireworks5 |
25 |
> |
Patch16: root-5.22-00d-genreflex_python26_popen3 |
26 |
> |
Patch17: root-5.22-00d-fireworks6 |
27 |
> |
Patch18: root-5.22-00d-linker-gnu-hash-style |
28 |
> |
|
29 |
> |
%define cpu %(echo %cmsplatf | cut -d_ -f2) |
30 |
> |
|
31 |
> |
Requires: gccxml gsl castor libjpg dcap pcre python |
32 |
> |
|
33 |
> |
%if "%online" != "true" |
34 |
> |
Requires: qt openssl libpng zlib libungif xrootd |
35 |
> |
%else |
36 |
> |
%define skiplibtiff true |
37 |
> |
%endif |
38 |
> |
|
39 |
> |
%if "%cpu" == "amd64" |
40 |
> |
%define skiplibtiff true |
41 |
> |
%endif |
42 |
> |
|
43 |
> |
%if "%skiplibtiff" != "true" |
44 |
> |
Requires: libtiff |
45 |
> |
%endif |
46 |
> |
|
47 |
|
%prep |
48 |
|
%setup -n root |
49 |
+ |
%patch0 -p1 |
50 |
+ |
%patch1 -p1 |
51 |
+ |
%patch2 -p1 |
52 |
+ |
%patch3 -p1 |
53 |
+ |
%patch4 -p1 |
54 |
+ |
|
55 |
+ |
%patch5 -p1 |
56 |
+ |
%patch6 -p1 |
57 |
+ |
%patch7 -p1 |
58 |
+ |
%patch8 -p1 |
59 |
+ |
%patch9 -p1 |
60 |
+ |
|
61 |
+ |
# patch10 is compiler version dependent, see below |
62 |
+ |
%patch11 -p1 |
63 |
+ |
%patch12 -p1 |
64 |
+ |
# patch13 is compiler version dependent, see below |
65 |
+ |
|
66 |
+ |
# work around patch issue... |
67 |
+ |
rm graf3d/gl/src/gl2ps.c |
68 |
+ |
%patch14 -p1 |
69 |
+ |
#work around patch issues in patch14(?) |
70 |
+ |
rm graf3d/eve/inc/TEveLegoOverlay.h.orig |
71 |
+ |
rm graf3d/eve/src/TEveLegoOverlay.cxx |
72 |
+ |
rm graf3d/gl/inc/gl2ps.h.orig |
73 |
+ |
rm graf3d/gl/src/gl2ps.c.orig |
74 |
+ |
%patch15 -p1 |
75 |
+ |
%patch16 -p1 |
76 |
+ |
%patch17 -p1 |
77 |
+ |
|
78 |
+ |
case %gccver in |
79 |
+ |
4.3.*) |
80 |
+ |
%patch13 -p1 |
81 |
+ |
;; |
82 |
+ |
4.4.*) |
83 |
+ |
%patch10 -p1 |
84 |
+ |
;; |
85 |
+ |
esac |
86 |
|
|
87 |
+ |
# The following patch can only be applied on SLC5 or later (extra linker |
88 |
+ |
# options only available with the SLC5 binutils) |
89 |
+ |
case %cmsplatf in |
90 |
+ |
slc5_* | slc5onl_* ) |
91 |
+ |
%patch18 -p1 |
92 |
+ |
;; |
93 |
+ |
esac |
94 |
+ |
|
95 |
|
%build |
96 |
+ |
|
97 |
|
mkdir -p %i |
98 |
|
export ROOTSYS=%_builddir/root |
99 |
< |
CONFIG_ARGS="--enable-table |
99 |
> |
export PYTHONV=$(echo $PYTHON_VERSION | cut -f1,2 -d.) |
100 |
> |
|
101 |
> |
%if "%online" == "true" |
102 |
> |
# Use system qt. Also skip xrootd and odbc for online case: |
103 |
> |
|
104 |
> |
EXTRA_CONFIG_ARGS="--with-f77=/usr |
105 |
> |
--disable-xrootd |
106 |
> |
--disable-odbc |
107 |
> |
--disable-qt --disable-qtgsi" |
108 |
> |
%else |
109 |
> |
EXTRA_CONFIG_ARGS="--with-f77=${GCC_ROOT} |
110 |
> |
--with-xrootd=$XROOTD_ROOT |
111 |
> |
--enable-qt --with-qt-libdir=${QT_ROOT}/lib --with-qt-incdir=${QT_ROOT}/include |
112 |
> |
--with-ssl-incdir=${OPENSSL_ROOT}/include |
113 |
> |
--with-ssl-libdir=${OPENSSL_ROOT}/lib |
114 |
> |
--enable-qtgsi" |
115 |
> |
%endif |
116 |
> |
|
117 |
> |
CONFIG_ARGS="--enable-table |
118 |
|
--disable-builtin-pcre |
119 |
|
--disable-builtin-freetype |
120 |
|
--disable-builtin-zlib |
121 |
|
--with-gccxml=${GCCXML_ROOT} |
122 |
< |
--enable-python --with-python-libdir=${PYTHON_ROOT}/lib --with-python-incdir=${PYTHON_ROOT}/include |
18 |
< |
--enable-mysql --with-mysql-libdir=${MYSQL_ROOT}/lib --with-mysql-incdir=${MYSQL_ROOT}/include |
19 |
< |
--with-dcap-libdir=${DCAP_ROOT}/lib |
20 |
< |
--with-dcap-incdir=${DCAP_ROOT}/include |
122 |
> |
--enable-python --with-python-libdir=${PYTHON_ROOT}/lib --with-python-incdir=${PYTHON_ROOT}/include/python${PYTHONV} |
123 |
|
--enable-explicitlink |
22 |
– |
--enable-qtgsi |
23 |
– |
--enable-qt --with-qt-libdir=${QT_ROOT}/lib --with-qt-incdir=${QT_ROOT}/include |
24 |
– |
--enable-mathcore |
124 |
|
--enable-mathmore |
125 |
|
--enable-reflex |
126 |
|
--enable-cintex |
127 |
|
--enable-minuit2 |
29 |
– |
--enable-roofit |
128 |
|
--disable-ldap |
129 |
|
--disable-krb5 |
130 |
< |
--with-dcap-libdir=${DCAP_ROOT}/lib |
130 |
> |
--with-gsl-incdir=${GSL_ROOT}/include |
131 |
> |
--with-gsl-libdir=${GSL_ROOT}/lib |
132 |
> |
--with-dcap-libdir=${DCAP_ROOT}/lib |
133 |
|
--with-dcap-incdir=${DCAP_ROOT}/include |
34 |
– |
--with-ssl-incdir=${OPENSSL_ROOT}/include |
35 |
– |
--with-ssl-libdir=${OPENSSL_ROOT}/lib |
36 |
– |
--with-shift-incdir=${CASTOR_ROOT}/include |
37 |
– |
--with-shift-libdir=${CASTOR_ROOT}/lib |
134 |
|
--disable-pgsql |
135 |
< |
--disable-xml" |
135 |
> |
--disable-mysql |
136 |
> |
--disable-xml ${EXTRA_CONFIG_ARGS}" |
137 |
|
|
138 |
|
case $(uname)-$(uname -m) in |
139 |
|
Linux-x86_64) |
140 |
< |
./configure linuxx8664gcc $CONFIG_ARGS;; |
141 |
< |
Linux*) |
142 |
< |
./configure linux $CONFIG_ARGS;; |
140 |
> |
./configure linuxx8664gcc $CONFIG_ARGS --with-shift-libdir=${CASTOR_ROOT}/lib --with-shift-incdir=${CASTOR_ROOT}/include/shift --disable-astiff;; |
141 |
> |
Linux-i*86) |
142 |
> |
./configure linux $CONFIG_ARGS --with-shift-libdir=${CASTOR_ROOT}/lib --with-shift-incdir=${CASTOR_ROOT}/include/shift;; |
143 |
|
Darwin*) |
144 |
< |
./configure macosx $CONFIG_ARGS;; |
144 |
> |
./configure macosx $CONFIG_ARGS --disable-rfio --disable-builtin_afterimage ;; |
145 |
> |
Linux-ppc64*) |
146 |
> |
./configure linux $CONFIG_ARGS --disable-rfio;; |
147 |
|
esac |
148 |
|
|
149 |
< |
make %makeprocesses |
149 |
> |
case %cmsplatf in |
150 |
> |
osx*) |
151 |
> |
makeopts= |
152 |
> |
;; |
153 |
> |
*) |
154 |
> |
makeopts="%makeprocesses" |
155 |
> |
;; |
156 |
> |
esac |
157 |
> |
|
158 |
> |
make $makeopts |
159 |
|
make cintdlls |
160 |
+ |
|
161 |
|
%install |
162 |
|
# Override installers if we are using GNU fileutils cp. On OS X |
163 |
|
# ROOT's INSTALL is defined to "cp -pPR", which only works with |
170 |
|
cp="cp -pPR" |
171 |
|
fi |
172 |
|
|
173 |
< |
#export ROOTSYS=%i/root |
173 |
> |
export ROOTSYS=%i |
174 |
|
make INSTALL="$cp" INSTALLDATA="$cp" install |
175 |
< |
mkdir -p %i/root/lib/python |
176 |
< |
cp -r reflex/python/genreflex %i/root/lib/python |
175 |
> |
mkdir -p $ROOTSYS/lib/python |
176 |
> |
cp -r cint/reflex/python/genreflex $ROOTSYS/lib/python |
177 |
> |
# |
178 |
> |
|
179 |
> |
# SCRAM ToolBox toolfile |
180 |
> |
mkdir -p %i/etc/scram.d |
181 |
> |
# rootcore toolfile |
182 |
> |
cat << \EOF_TOOLFILE >%i/etc/scram.d/rootcore |
183 |
> |
<doc type=BuildSystem::ToolDoc version=1.0> |
184 |
> |
<Tool name=rootcore version=%v> |
185 |
> |
<info url="http://root.cern.ch/root/"></info> |
186 |
> |
<lib name=Tree> |
187 |
> |
<lib name=Net> |
188 |
> |
<lib name=Thread> |
189 |
> |
<lib name=MathCore> |
190 |
> |
<lib name=RIO> |
191 |
> |
<lib name=Core> |
192 |
> |
<lib name=Cint> |
193 |
> |
<Client> |
194 |
> |
<Environment name=ROOTCORE_BASE default="%i"></Environment> |
195 |
> |
<Environment name=LIBDIR default="$ROOTCORE_BASE/lib"></Environment> |
196 |
> |
<Environment name=INCLUDE default="$ROOTCORE_BASE/include"></Environment> |
197 |
> |
<Environment name=INCLUDE default="$ROOTCORE_BASE/cint"></Environment> |
198 |
> |
</Client> |
199 |
> |
<use name=sockets> |
200 |
> |
<use name=pcre> |
201 |
> |
<use name=zlib> |
202 |
> |
<Runtime name=PATH value="$ROOTCORE_BASE/bin" type=path> |
203 |
> |
<Runtime name=ROOTSYS value="$ROOTCORE_BASE/"> |
204 |
> |
<Runtime name=PYTHONPATH value="$ROOTCORE_BASE/lib" type=path> |
205 |
> |
</Tool> |
206 |
> |
EOF_TOOLFILE |
207 |
> |
|
208 |
> |
# root toolfile, alias for rootphysics. Using rootphysics is preferred. |
209 |
> |
cat << \EOF_TOOLFILE >%i/etc/scram.d/root |
210 |
> |
<doc type=BuildSystem::ToolDoc version=1.0> |
211 |
> |
<Tool name=root version=%v> |
212 |
> |
<info url="http://root.cern.ch/root/"></info> |
213 |
> |
<use name=rootphysics> |
214 |
> |
</Tool> |
215 |
> |
EOF_TOOLFILE |
216 |
> |
|
217 |
> |
# roothistmatrix toolfile |
218 |
> |
cat << \EOF_TOOLFILE >%i/etc/scram.d/roothistmatrix |
219 |
> |
<doc type=BuildSystem::ToolDoc version=1.0> |
220 |
> |
<Tool name=roothistmatrix version=%v> |
221 |
> |
<info url="http://root.cern.ch/root/"></info> |
222 |
> |
<lib name=Hist> |
223 |
> |
<lib name=Matrix> |
224 |
> |
<use name=ROOTCore> |
225 |
> |
</Tool> |
226 |
> |
EOF_TOOLFILE |
227 |
> |
|
228 |
> |
# rootgpad toolfile |
229 |
> |
cat << \EOF_TOOLFILE >%i/etc/scram.d/rootgpad |
230 |
> |
<doc type=BuildSystem::ToolDoc version=1.0> |
231 |
> |
<Tool name=rootgpad version=%v> |
232 |
> |
<info url="http://root.cern.ch/root/"></info> |
233 |
> |
<lib name=Gpad> |
234 |
> |
<lib name=Graf> |
235 |
> |
<use name=roothistmatrix> |
236 |
> |
</Tool> |
237 |
> |
EOF_TOOLFILE |
238 |
> |
|
239 |
> |
# rootphysics toolfile |
240 |
> |
cat << \EOF_TOOLFILE >%i/etc/scram.d/rootphysics |
241 |
> |
<doc type=BuildSystem::ToolDoc version=1.0> |
242 |
> |
<Tool name=rootphysics version=%v> |
243 |
> |
<info url="http://root.cern.ch/root/"></info> |
244 |
> |
<lib name=Physics> |
245 |
> |
<use name=roothistmatrix> |
246 |
> |
</Tool> |
247 |
> |
EOF_TOOLFILE |
248 |
> |
|
249 |
> |
# rootgraphics toolfile, identical to old "root" toolfile |
250 |
> |
cat << \EOF_TOOLFILE >%i/etc/scram.d/rootgraphics |
251 |
> |
<doc type=BuildSystem::ToolDoc version=1.0> |
252 |
> |
<Tool name=rootgraphics version=%v> |
253 |
> |
<info url="http://root.cern.ch/root/"></info> |
254 |
> |
<lib name=TreePlayer> |
255 |
> |
<lib name=Graf3d> |
256 |
> |
<lib name=Postscript> |
257 |
> |
<use name=rootgpad> |
258 |
> |
</Tool> |
259 |
> |
EOF_TOOLFILE |
260 |
> |
|
261 |
> |
# rootcintex toolfile |
262 |
> |
cat << \EOF_TOOLFILE >%i/etc/scram.d/rootcintex |
263 |
> |
<doc type=BuildSystem::ToolDoc version=1.0> |
264 |
> |
<Tool name=rootcintex version=%v> |
265 |
> |
<info url="http://root.cern.ch/root/"></info> |
266 |
> |
<lib name=Cintex> |
267 |
> |
<use name=ROOTRflx> |
268 |
> |
<use name=ROOTCore> |
269 |
> |
</Tool> |
270 |
> |
EOF_TOOLFILE |
271 |
> |
|
272 |
> |
# (temporarily eviscerated) rootinteractive toolfile (GQt/qt lib dependencies |
273 |
> |
# have been removed for the moment) |
274 |
> |
cat << \EOF_TOOLFILE >%i/etc/scram.d/rootinteractive |
275 |
> |
<doc type=BuildSystem::ToolDoc version=1.0> |
276 |
> |
<Tool name=rootinteractive version=%v> |
277 |
> |
<info url="http://root.cern.ch/root/"></info> |
278 |
> |
<lib name=Rint> |
279 |
> |
<lib name=GQt> |
280 |
> |
<lib name=Gui> |
281 |
> |
<use name=qt> |
282 |
> |
<use name=libjpg> |
283 |
> |
<use name=libpng> |
284 |
> |
<use name=rootgpad> |
285 |
> |
</Tool> |
286 |
> |
EOF_TOOLFILE |
287 |
> |
|
288 |
> |
# rootmath toolfile |
289 |
> |
cat << \EOF_TOOLFILE >%i/etc/scram.d/rootmath |
290 |
> |
<doc type=BuildSystem::ToolDoc version=1.0> |
291 |
> |
<Tool name=rootmath version=%v> |
292 |
> |
<info url="http://root.cern.ch/root/"></info> |
293 |
> |
<lib name=GenVector> |
294 |
> |
<lib name=MathMore> |
295 |
> |
<use name=ROOTCore> |
296 |
> |
<use name=gsl> |
297 |
> |
</Tool> |
298 |
> |
EOF_TOOLFILE |
299 |
> |
|
300 |
> |
# rootminuit toolfile |
301 |
> |
cat << \EOF_TOOLFILE >%i/etc/scram.d/rootminuit |
302 |
> |
<doc type=BuildSystem::ToolDoc version=1.0> |
303 |
> |
<Tool name=rootminuit version=%v> |
304 |
> |
<info url="http://root.cern.ch/root/"></info> |
305 |
> |
<lib name=Minuit> |
306 |
> |
<use name=rootgpad> |
307 |
> |
</Tool> |
308 |
> |
EOF_TOOLFILE |
309 |
> |
|
310 |
> |
# rootminuit2 toolfile |
311 |
> |
cat << \EOF_TOOLFILE >%i/etc/scram.d/rootminuit2 |
312 |
> |
<doc type=BuildSystem::ToolDoc version=1.0> |
313 |
> |
<Tool name=rootminuit2 version=%v> |
314 |
> |
<info url="http://root.cern.ch/root/"></info> |
315 |
> |
<lib name=Minuit2> |
316 |
> |
<use name=rootgpad> |
317 |
> |
</Tool> |
318 |
> |
EOF_TOOLFILE |
319 |
> |
|
320 |
> |
# rootrflx toolfile |
321 |
> |
cat << \EOF_TOOLFILE >%i/etc/scram.d/rootrflx |
322 |
> |
<doc type=BuildSystem::ToolDoc version=1.0> |
323 |
> |
<Tool name=rootrflx version=%v> |
324 |
> |
<info url="http://root.cern.ch/root/"></info> |
325 |
> |
<lib name=Reflex> |
326 |
> |
<Client> |
327 |
> |
<Environment name=ROOTRFLX_BASE default="%i"></Environment> |
328 |
> |
<Environment name=LIBDIR default="$ROOTRFLX_BASE/lib"></Environment> |
329 |
> |
<Environment name=INCLUDE default="$ROOTRFLX_BASE/include"></Environment> |
330 |
> |
</Client> |
331 |
> |
<use name=sockets> |
332 |
> |
<use name=gccxml> |
333 |
> |
<Runtime name=PATH value="$ROOTRFLX_BASE/bin" type=path> |
334 |
> |
<Runtime name=ROOTSYS value="$ROOTRFLX_BASE/"> |
335 |
> |
<Runtime name=GENREFLEX value="$ROOTRFLX_BASE/bin/genreflex"> |
336 |
> |
</Tool> |
337 |
> |
EOF_TOOLFILE |
338 |
> |
|
339 |
> |
# roothtml toolfile |
340 |
> |
cat << \EOF_TOOLFILE >%i/etc/scram.d/roothtml |
341 |
> |
<doc type=BuildSystem::ToolDoc version=1.0> |
342 |
> |
<Tool name=roothtml version=%v> |
343 |
> |
<info url="http://root.cern.ch/root/"></info> |
344 |
> |
<lib name=Html> |
345 |
> |
<use name=rootgpad> |
346 |
> |
</Tool> |
347 |
> |
EOF_TOOLFILE |
348 |
> |
|
349 |
> |
# rootmlp toolfile |
350 |
> |
cat << \EOF_TOOLFILE >%i/etc/scram.d/rootmlp |
351 |
> |
<doc type=BuildSystem::ToolDoc version=1.0> |
352 |
> |
<Tool name=rootmlp version=%v> |
353 |
> |
<info url="http://root.cern.ch/root/"></info> |
354 |
> |
<lib name=MLP> |
355 |
> |
<use name=RootGraphics> |
356 |
> |
</Tool> |
357 |
> |
EOF_TOOLFILE |
358 |
> |
|
359 |
> |
# roottmva toolfile |
360 |
> |
cat << \EOF_TOOLFILE >%i/etc/scram.d/roottmva |
361 |
> |
<doc type=BuildSystem::ToolDoc version=1.0> |
362 |
> |
<Tool name=roottmva version=%v> |
363 |
> |
<info url="http://root.cern.ch/root/"></info> |
364 |
> |
<lib name=TMVA> |
365 |
> |
<use name=ROOTMLP> |
366 |
> |
<use name=rootminuit> |
367 |
> |
</Tool> |
368 |
> |
EOF_TOOLFILE |
369 |
> |
|
370 |
> |
# rootthread toolfile |
371 |
> |
cat << \EOF_TOOLFILE >%i/etc/scram.d/rootthread |
372 |
> |
<doc type=BuildSystem::ToolDoc version=1.0> |
373 |
> |
<Tool name=rootthread version=%v> |
374 |
> |
<info url="http://root.cern.ch/root/"></info> |
375 |
> |
<use name=ROOTCore> |
376 |
> |
</Tool> |
377 |
> |
EOF_TOOLFILE |
378 |
> |
|
379 |
> |
%post |
380 |
> |
%{relocateConfig}etc/scram.d/root |
381 |
> |
%{relocateConfig}etc/scram.d/rootcore |
382 |
> |
%{relocateConfig}etc/scram.d/roothistmatrix |
383 |
> |
%{relocateConfig}etc/scram.d/rootphysics |
384 |
> |
%{relocateConfig}etc/scram.d/rootgraphics |
385 |
> |
%{relocateConfig}etc/scram.d/rootcintex |
386 |
> |
%{relocateConfig}etc/scram.d/rootinteractive |
387 |
> |
%{relocateConfig}etc/scram.d/rootmath |
388 |
> |
%{relocateConfig}etc/scram.d/rootminuit |
389 |
> |
%{relocateConfig}etc/scram.d/rootminuit2 |
390 |
> |
%{relocateConfig}etc/scram.d/rootrflx |
391 |
> |
%{relocateConfig}etc/scram.d/roothtml |
392 |
> |
%{relocateConfig}etc/scram.d/rootmlp |
393 |
> |
%{relocateConfig}etc/scram.d/roottmva |
394 |
> |
%{relocateConfig}etc/scram.d/rootthread |