ViewVC Help
View File | Revision Log | Show Annotations | Root Listing
root/cvsroot/COMP/CMSDIST/root.spec
Revision: 1.166
Committed: Mon Jul 6 11:54:04 2009 UTC (15 years, 9 months ago) by elmer
Branch: MAIN
Changes since 1.165: +0 -3 lines
Log Message:
Remove lines for the Darwin build which delete libraries out of the libpng,
libtiff and libpng installation areas. (I'm not sure what was intended here,
but probably not this!)

File Contents

# User Rev Content
1 elmer 1.144 ### RPM lcg root 5.22.00a
2 dlange 1.57 ## INITENV +PATH PYTHONPATH %i/lib/python
3     ## INITENV SET ROOTSYS %i
4 ratnik 1.106 #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 elmer 1.144 Source: ftp://root.cern.ch/%n/%{n}_v%{realversion}.source.tar.gz
6 muzaffar 1.165 %define closingbrace )
7     %define online %(case %cmsplatf in *onl_*_*%closingbrace echo true;; *%closingbrace echo flase;; esac)
8 elmer 1.96
9 elmer 1.155 Patch0: root-5.18-00-libpng
10 elmer 1.141 Patch1: root-5.21-04-CINT-maxlongline
11     Patch2: root-5.22-00-TMVA-shut-the-hell-up-for-once
12 elmer 1.148 Patch3: root-5.22-00a-TMVA-shut-the-hell-up-again
13     Patch4: root-5.22-00a-CINTFunctional
14 elmer 1.149 Patch5: root-5.22-00a-TClass
15 elmer 1.150 Patch6: root-5.22-00a-fireworks-graf3d-gui
16 dlange 1.151 Patch7: root-5.22-00a-Reflex-Class
17 dlange 1.152 Patch8: root-5.22-00a-Cintex
18     Patch9: root-5.22-00a-roofit-silence-static-printout
19 elmer 1.155 Patch10: root-5.22-00a-TMVA-just-shut-the-hell-up
20 dlange 1.156 Patch11: root-5.22-00a-th1
21     Patch12: root-5.22-00a-smatrix
22     Patch13: root-5.22-00a-fireworks1
23 dlange 1.157 Patch14: root-5.22-00a-Reflex-gendict_selclass
24     Patch15: root-5.22-00a-MatrixInversion
25 elmer 1.159 Patch16: root-5.22-00a-gcc44
26 dlange 1.160 Patch17: root-5.22-00a-fireworks2
27     Patch18: root-5.22-00a-fireworks3
28     Patch19: root-5.22-00a-TBranchElement
29 dlange 1.162 Patch20: root-5.22-00a-tmplt
30     Patch21: root-5.22-00a-TBranchElement_TStreamerInfo
31 elmer 1.98
32     %define cpu %(echo %cmsplatf | cut -d_ -f2)
33     %define pythonv %(echo $PYTHON_VERSION | cut -d. -f1,2)
34    
35 ratnik 1.106 Requires: gccxml gsl castor libjpg dcap pcre python
36 dlange 1.103
37 muzaffar 1.164 %if "%online" != "true"
38 elmer 1.145 Requires: qt openssl mysql libpng zlib libungif xrootd
39 dlange 1.103 %else
40     %define skiplibtiff true
41     %endif
42    
43     %if "%cpu" == "amd64"
44     %define skiplibtiff true
45     %endif
46    
47     %if "%skiplibtiff" != "true"
48 elmer 1.98 Requires: libtiff
49     %endif
50 eulisse 1.25
51 eulisse 1.1 %prep
52     %setup -n root
53 ratnik 1.106 %patch0 -p1
54     %patch1 -p1
55 elmer 1.141 %patch2 -p1
56 elmer 1.148 %patch3 -p1
57     %patch4 -p1
58 elmer 1.149 %patch5 -p1
59 elmer 1.150 %patch6 -p1
60 dlange 1.154 %patch7 -p0
61     %patch8 -p0
62     %patch9 -p1
63 elmer 1.155 %patch10 -p1
64 dlange 1.156 %patch11 -p1
65     %patch12 -p1
66     %patch13 -p1
67 dlange 1.157 %patch14 -p0
68     %patch15 -p0
69 dlange 1.160 %patch16 -p1
70     %patch17 -p1
71     %patch18 -p1
72     %patch19 -p0
73 dlange 1.162 %patch20 -p0
74     %patch21 -p0
75 dlange 1.161 # work around patch issue...
76     rm graf3d/gl/src/gl2ps.c
77 dlange 1.160
78 elmer 1.159 case %gccver in
79     4.4)
80     %patch16 -p1
81     ;;
82     esac
83 dlange 1.157
84 eulisse 1.1 %build
85 andreasp 1.163
86 eulisse 1.1 mkdir -p %i
87 elmer 1.14 export ROOTSYS=%_builddir/root
88 dlange 1.103
89 muzaffar 1.164 %if "%online" == "true"
90 ratnik 1.111 # Build without mysql, and use system qt.
91     # Also skip xrootd and odbc for online case:
92    
93 muzaffar 1.164 EXTRA_CONFIG_ARGS="--with-f77=/usr
94 ratnik 1.111 --disable-mysql
95     --disable-xrootd
96     --disable-odbc
97 muzaffar 1.164 --disable-qt --disable-qtgsi"
98 dlange 1.103 %else
99 muzaffar 1.164 EXTRA_CONFIG_ARGS="--with-f77=${GCC_ROOT}
100 elmer 1.145 --with-xrootd=$XROOTD_ROOT
101 ratnik 1.106 --enable-mysql --with-mysql-libdir=${MYSQL_ROOT}/lib --with-mysql-incdir=${MYSQL_ROOT}/include
102     --enable-qt --with-qt-libdir=${QT_ROOT}/lib --with-qt-incdir=${QT_ROOT}/include
103     --with-ssl-incdir=${OPENSSL_ROOT}/include
104 muzaffar 1.164 --with-ssl-libdir=${OPENSSL_ROOT}/lib
105     --enable-qtgsi"
106 dlange 1.103 %endif
107    
108 muzaffar 1.164 CONFIG_ARGS="--enable-table
109 eulisse 1.20 --disable-builtin-pcre
110     --disable-builtin-freetype
111     --disable-builtin-zlib
112 elmer 1.98 --with-gccxml=${GCCXML_ROOT}
113 ratnik 1.79 --enable-python --with-python-libdir=${PYTHON_ROOT}/lib --with-python-incdir=${PYTHON_ROOT}/include/python2.4
114 eulisse 1.2 --enable-explicitlink
115 eulisse 1.20 --enable-mathmore
116 eulisse 1.2 --enable-reflex
117     --enable-cintex
118     --enable-minuit2
119 eulisse 1.7 --enable-roofit
120 elmer 1.98 --disable-ldap
121 gowdy 1.143 --disable-krb5
122 eulisse 1.34 --with-gsl-incdir=${GSL_ROOT}/include
123     --with-gsl-libdir=${GSL_ROOT}/lib
124 elmer 1.59 --with-dcap-libdir=${DCAP_ROOT}/lib
125 elmer 1.98 --with-dcap-incdir=${DCAP_ROOT}/include
126     --disable-pgsql
127 dlange 1.103 --disable-xml ${EXTRA_CONFIG_ARGS}"
128 elmer 1.98
129 elmer 1.141 #case %gccver in
130     # 4.*)
131     # CONFIG_ARGS="$CONFIG_ARGS --disable-cern"
132     # ;;
133     #esac
134 elmer 1.84
135 elmer 1.54 case $(uname)-$(uname -p) in
136 eulisse 1.2 Linux-x86_64)
137 elmer 1.141 ./configure linuxx8664gcc $CONFIG_ARGS --with-shift-libdir=${CASTOR_ROOT}/lib --with-shift-incdir=${CASTOR_ROOT}/include/shift --disable-astiff;;
138 elmer 1.54 Linux-i*86)
139 dlange 1.110 ./configure linux $CONFIG_ARGS --with-shift-libdir=${CASTOR_ROOT}/lib --with-shift-incdir=${CASTOR_ROOT}/include/shift;;
140 elmer 1.11 Darwin*)
141 andreasp 1.163 ./configure macosx $CONFIG_ARGS --disable-rfio --disable-builtin_afterimage ;;
142 elmer 1.54 Linux-ppc64*)
143 elmer 1.98 ./configure linux $CONFIG_ARGS --disable-rfio;;
144 eulisse 1.1 esac
145 eulisse 1.2
146 eulisse 1.147 case %cmsplatf in
147     osx*)
148     makeopts=
149     ;;
150     *)
151     makeopts="%makeprocesses"
152     ;;
153     esac
154    
155     make $makeopts
156 eulisse 1.20 make cintdlls
157 eulisse 1.147
158 eulisse 1.1 %install
159     # Override installers if we are using GNU fileutils cp. On OS X
160     # ROOT's INSTALL is defined to "cp -pPR", which only works with
161     # the system cp (/bin/cp). If you have fileutils on fink, you
162     # lose. Check which one is getting picked up and select syntax
163     # accordingly. (FIXME: do we need to check that -P is accepted?)
164     if (cp --help | grep -e '-P.*--parents') >/dev/null 2>&1; then
165     cp="cp -dpR"
166     else
167     cp="cp -pPR"
168     fi
169    
170 dlange 1.57 export ROOTSYS=%i
171 eulisse 1.5 make INSTALL="$cp" INSTALLDATA="$cp" install
172 dlange 1.57 mkdir -p $ROOTSYS/lib/python
173 elmer 1.141 cp -r cint/reflex/python/genreflex $ROOTSYS/lib/python
174 eulisse 1.35 #
175 elmer 1.98
176     # SCRAM ToolBox toolfile
177     mkdir -p %i/etc/scram.d
178     # rootcore toolfile
179     cat << \EOF_TOOLFILE >%i/etc/scram.d/rootcore
180     <doc type=BuildSystem::ToolDoc version=1.0>
181     <Tool name=rootcore version=%v>
182     <info url="http://root.cern.ch/root/"></info>
183 muzaffar 1.153 <lib name=Tree>
184     <lib name=Net>
185     <lib name=Thread>
186     <lib name=MathCore>
187     <lib name=RIO>
188     <lib name=Core>
189 elmer 1.98 <lib name=Cint>
190     <Client>
191     <Environment name=ROOTCORE_BASE default="%i"></Environment>
192     <Environment name=LIBDIR default="$ROOTCORE_BASE/lib"></Environment>
193     <Environment name=INCLUDE default="$ROOTCORE_BASE/include"></Environment>
194     <Environment name=INCLUDE default="$ROOTCORE_BASE/cint"></Environment>
195     </Client>
196     <use name=sockets>
197     <use name=pcre>
198     <use name=zlib>
199     <Runtime name=PATH value="$ROOTCORE_BASE/bin" type=path>
200     <Runtime name=ROOTSYS value="$ROOTCORE_BASE/">
201     <Runtime name=PYTHONPATH value="$ROOTCORE_BASE/lib" type=path>
202     </Tool>
203     EOF_TOOLFILE
204    
205 elmer 1.121 # root toolfile, alias for rootphysics. Using rootphysics is preferred.
206 elmer 1.98 cat << \EOF_TOOLFILE >%i/etc/scram.d/root
207     <doc type=BuildSystem::ToolDoc version=1.0>
208     <Tool name=root version=%v>
209     <info url="http://root.cern.ch/root/"></info>
210 elmer 1.121 <use name=rootphysics>
211     </Tool>
212     EOF_TOOLFILE
213    
214     # roothistmatrix toolfile
215     cat << \EOF_TOOLFILE >%i/etc/scram.d/roothistmatrix
216     <doc type=BuildSystem::ToolDoc version=1.0>
217     <Tool name=roothistmatrix version=%v>
218     <info url="http://root.cern.ch/root/"></info>
219 elmer 1.98 <lib name=Hist>
220     <lib name=Matrix>
221 elmer 1.121 <use name=ROOTCore>
222     </Tool>
223     EOF_TOOLFILE
224    
225 muzaffar 1.158 # rootgpad toolfile
226     cat << \EOF_TOOLFILE >%i/etc/scram.d/rootgpad
227     <doc type=BuildSystem::ToolDoc version=1.0>
228     <Tool name=rootgpad version=%v>
229     <info url="http://root.cern.ch/root/"></info>
230     <lib name=Gpad>
231     <lib name=Graf>
232     <use name=roothistmatrix>
233     </Tool>
234     EOF_TOOLFILE
235    
236 elmer 1.121 # rootphysics toolfile
237     cat << \EOF_TOOLFILE >%i/etc/scram.d/rootphysics
238     <doc type=BuildSystem::ToolDoc version=1.0>
239     <Tool name=rootphysics version=%v>
240     <info url="http://root.cern.ch/root/"></info>
241 elmer 1.98 <lib name=Physics>
242 elmer 1.121 <use name=roothistmatrix>
243 elmer 1.98 </Tool>
244     EOF_TOOLFILE
245    
246 elmer 1.121 # rootgraphics toolfile, identical to old "root" toolfile
247     cat << \EOF_TOOLFILE >%i/etc/scram.d/rootgraphics
248 elmer 1.120 <doc type=BuildSystem::ToolDoc version=1.0>
249 elmer 1.121 <Tool name=rootgraphics version=%v>
250 elmer 1.120 <info url="http://root.cern.ch/root/"></info>
251 elmer 1.121 <lib name=TreePlayer>
252     <lib name=Graf3d>
253     <lib name=Postscript>
254 muzaffar 1.158 <use name=rootgpad>
255 elmer 1.120 </Tool>
256     EOF_TOOLFILE
257    
258 elmer 1.98 # rootcintex toolfile
259     cat << \EOF_TOOLFILE >%i/etc/scram.d/rootcintex
260     <doc type=BuildSystem::ToolDoc version=1.0>
261     <Tool name=rootcintex version=%v>
262     <info url="http://root.cern.ch/root/"></info>
263     <lib name=Cintex>
264     <use name=ROOTRflx>
265     <use name=ROOTCore>
266     </Tool>
267     EOF_TOOLFILE
268    
269 elmer 1.146 # (temporarily eviscerated) rootinteractive toolfile (GQt/qt lib dependencies
270     # have been removed for the moment)
271 elmer 1.98 cat << \EOF_TOOLFILE >%i/etc/scram.d/rootinteractive
272     <doc type=BuildSystem::ToolDoc version=1.0>
273     <Tool name=rootinteractive version=%v>
274     <info url="http://root.cern.ch/root/"></info>
275     <lib name=Rint>
276 dlange 1.154 <lib name=GQt>
277     <lib name=Gui>
278     <use name=qt>
279 elmer 1.146 <use name=libjpg>
280     <use name=libpng>
281 muzaffar 1.158 <use name=rootgpad>
282 elmer 1.146 </Tool>
283     EOF_TOOLFILE
284    
285 elmer 1.98 # rootmath toolfile
286     cat << \EOF_TOOLFILE >%i/etc/scram.d/rootmath
287     <doc type=BuildSystem::ToolDoc version=1.0>
288     <Tool name=rootmath version=%v>
289     <info url="http://root.cern.ch/root/"></info>
290 muzaffar 1.153 <lib name=GenVector>
291 elmer 1.98 <lib name=MathMore>
292     <use name=ROOTCore>
293     <use name=gsl>
294     </Tool>
295     EOF_TOOLFILE
296    
297     # rootminuit toolfile
298     cat << \EOF_TOOLFILE >%i/etc/scram.d/rootminuit
299     <doc type=BuildSystem::ToolDoc version=1.0>
300     <Tool name=rootminuit version=%v>
301     <info url="http://root.cern.ch/root/"></info>
302     <lib name=Minuit>
303 muzaffar 1.158 <use name=rootgpad>
304 elmer 1.98 </Tool>
305     EOF_TOOLFILE
306    
307     # rootminuit2 toolfile
308     cat << \EOF_TOOLFILE >%i/etc/scram.d/rootminuit2
309     <doc type=BuildSystem::ToolDoc version=1.0>
310     <Tool name=rootminuit2 version=%v>
311     <info url="http://root.cern.ch/root/"></info>
312     <lib name=Minuit2>
313 muzaffar 1.158 <use name=rootgpad>
314 elmer 1.98 </Tool>
315     EOF_TOOLFILE
316    
317     # rootrflx toolfile
318     cat << \EOF_TOOLFILE >%i/etc/scram.d/rootrflx
319     <doc type=BuildSystem::ToolDoc version=1.0>
320     <Tool name=rootrflx version=%v>
321     <info url="http://root.cern.ch/root/"></info>
322     <lib name=Reflex>
323     <Client>
324     <Environment name=ROOTRFLX_BASE default="%i"></Environment>
325     <Environment name=LIBDIR default="$ROOTRFLX_BASE/lib"></Environment>
326     <Environment name=INCLUDE default="$ROOTRFLX_BASE/include"></Environment>
327     </Client>
328     <use name=sockets>
329     <use name=gccxml>
330     <Runtime name=PATH value="$ROOTRFLX_BASE/bin" type=path>
331     <Runtime name=ROOTSYS value="$ROOTRFLX_BASE/">
332     <Runtime name=GENREFLEX value="$ROOTRFLX_BASE/bin/genreflex">
333     </Tool>
334     EOF_TOOLFILE
335    
336     # roothtml toolfile
337     cat << \EOF_TOOLFILE >%i/etc/scram.d/roothtml
338     <doc type=BuildSystem::ToolDoc version=1.0>
339     <Tool name=roothtml version=%v>
340     <info url="http://root.cern.ch/root/"></info>
341     <lib name=Html>
342 muzaffar 1.158 <use name=rootgpad>
343 elmer 1.98 </Tool>
344     EOF_TOOLFILE
345    
346     # rootroofit toolfile
347     cat << \EOF_TOOLFILE >%i/etc/scram.d/rootroofit
348     <doc type=BuildSystem::ToolDoc version=1.0>
349     <Tool name=rootroofit version=%v>
350     <info url="http://root.cern.ch/root/"></info>
351 muzaffar 1.153 <lib name=RooFit>
352 ratnik 1.106 <lib name=RooFitCore>
353 elmer 1.98 <use name=ROOTMinuit>
354     </Tool>
355     EOF_TOOLFILE
356    
357     # rootmlp toolfile
358     cat << \EOF_TOOLFILE >%i/etc/scram.d/rootmlp
359     <doc type=BuildSystem::ToolDoc version=1.0>
360     <Tool name=rootmlp version=%v>
361     <info url="http://root.cern.ch/root/"></info>
362     <lib name=MLP>
363 muzaffar 1.153 <use name=RootGraphics>
364 elmer 1.98 </Tool>
365     EOF_TOOLFILE
366    
367     # roottmva toolfile
368     cat << \EOF_TOOLFILE >%i/etc/scram.d/roottmva
369     <doc type=BuildSystem::ToolDoc version=1.0>
370     <Tool name=roottmva version=%v>
371     <info url="http://root.cern.ch/root/"></info>
372     <lib name=TMVA>
373     <use name=ROOTMLP>
374 muzaffar 1.158 <use name=rootminuit>
375 elmer 1.98 </Tool>
376     EOF_TOOLFILE
377    
378     # rootthread toolfile
379     cat << \EOF_TOOLFILE >%i/etc/scram.d/rootthread
380     <doc type=BuildSystem::ToolDoc version=1.0>
381     <Tool name=rootthread version=%v>
382     <info url="http://root.cern.ch/root/"></info>
383     <use name=ROOTCore>
384     </Tool>
385     EOF_TOOLFILE
386    
387     %post
388     %{relocateConfig}etc/scram.d/root
389     %{relocateConfig}etc/scram.d/rootcore
390 elmer 1.120 %{relocateConfig}etc/scram.d/roothistmatrix
391 elmer 1.121 %{relocateConfig}etc/scram.d/rootphysics
392     %{relocateConfig}etc/scram.d/rootgraphics
393 elmer 1.98 %{relocateConfig}etc/scram.d/rootcintex
394     %{relocateConfig}etc/scram.d/rootinteractive
395     %{relocateConfig}etc/scram.d/rootmath
396     %{relocateConfig}etc/scram.d/rootminuit
397     %{relocateConfig}etc/scram.d/rootminuit2
398     %{relocateConfig}etc/scram.d/rootrflx
399     %{relocateConfig}etc/scram.d/roothtml
400     %{relocateConfig}etc/scram.d/rootroofit
401     %{relocateConfig}etc/scram.d/rootmlp
402     %{relocateConfig}etc/scram.d/roottmva
403     %{relocateConfig}etc/scram.d/rootthread