/[pdpsoft]/trunk/grid-mw-security/glexec/util/glexec_from_source/glexec_from_source.sh
ViewVC logotype

Contents of /trunk/grid-mw-security/glexec/util/glexec_from_source/glexec_from_source.sh

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1830 - (show annotations) (download) (as text)
Wed Jun 30 15:06:07 2010 UTC (11 years, 6 months ago) by msalle
File MIME type: application/x-shellscript
File size: 19740 byte(s)
Update for the new gsoap-from-tarball construction (in saml2_xacml2_c_lib)

1 #!/bin/sh
2
3 # Example script to demonstrate how to build gLExec and its gLite dependencies
4 # from source as obtained from CVS.
5 #
6 # Author: Mischa Sall\'e
7 #
8 # Questions and comments: <grid-mw-security@nikhef.nl>
9 #
10 ##############################################################################
11 # Global definitions, change where needed:
12 ##############################################################################
13
14 export platform=SUSE11_64 # Valid options: RH4_32 RH5_64 SUSE11_64 Deb5_64
15 export source=/tmp/source # Where to download sources
16 export globus=/tmp/build/globus # Where to install globus
17 export gridsite=/tmp/build/gridsite # Where to install/find gridsite
18 export glite=/tmp/build/glite # Where to find glite builds
19
20 # Do NOT change the remaining global variables
21 export prefix=${glite} # Where to install glite builds
22 # (normally same as ${glite}
23 #export CVSROOT=:pserver:anonymous@glite.cvs.cern.ch:/cvs/glite # anonymous CVS
24 export webcvs=http://glite.cvs.cern.ch/cgi-bin/glite.cgi/ # Web CVS
25
26 # Valid return codes: anything less than RC_FAILED is non-blocking
27 export RC_SUCCESS=0
28 export RC_SKIPPED=1
29 export RC_FAILED=2
30 export RC_MISSDEP=3
31
32 # Parse command line options
33 DEPEND=1
34 USAGE=0
35 targets=""
36 while [ $# -gt 0 ];do
37 case "$1" in
38 -c*) DEPEND=0 ;;
39 -h*) USAGE=1 ;;
40 *) targets="$targets $1" ;;
41 esac
42 shift
43 done
44
45 # Find correct globus for platform
46 case "$platform" in
47 RH4_32)
48 export globus_url=http://etics-repository.cern.ch/repository/download/registered/vdt/globus/4.0.3-VDT-1.6.1/slc4_ia32_gcc346/
49 export globus_tgz=globus-4.0.3-VDT-1.6.1-7.tar.gz
50 export globus_flav=gcc32dbg
51 ;;
52 RH5_64)
53 export globus_url=http://etics-repository.cern.ch/repository/download/registered/vdt/globus/4.0.7-VDT-1.10.1/sl5_x86_64_gcc412/
54 export globus_tgz=globus-4.0.7-VDT-1.10.1-1.tar.gz
55 export globus_flav=gcc64dbg
56 ;;
57 SUSE11_64)
58 export globus_url=http://eticssoft.web.cern.ch/eticssoft/repository//vdt/globus/4.0.7-VDT-1.10.1/SUSE11_x86_64_gcc432/
59 export globus_tgz=globus-4.0.7-VDT-1.10.1-1.tar.gz
60 export globus_flav=gcc64dbg
61 ;;
62 Deb5_64)
63 export globus_url=http://etics-repository.cern.ch/repository/download/registered/vdt/globus/4.0.8-VDT-2.0.0/deb5_x86_64_gcc432/
64 export globus_tgz=globus-4.0.8-VDT-2.0.0-2.tar.gz
65 export globus_flav=gcc64dbg
66 ;;
67 *)
68 echo "Unknown platform: \"$platform\"" >&2
69 echo "Valid platforms are:" >&2
70 echo " RH4_32" >&2
71 echo " RH5_64" >&2
72 echo " SUSE11_64" >&2
73 echo " Deb5_64" >&2
74 exit 1
75 ;;
76 esac
77
78 ##############################################################################
79 # Convenience functions
80 ##############################################################################
81
82 # Function which is used to create the dependency checking functions.
83 # arguments:
84 # $1 - target
85 # $2... - dependencies
86 setdeps() {
87 if [ $# -eq 0 ];then
88 echo "Error: $0 needs at least one argument." >&2
89 return $RC_FAILED
90 fi
91
92 # target
93 target=$1; shift
94 known_targets="$known_targets $target"
95
96 eval rc_$target=$RC_SKIPPED
97
98 depstring=""
99 # Only when we DO want dependency checking...
100 if [ $DEPEND -eq 1 ];then
101 while [ $# -gt 0 ];do
102 depstring="$depstring \$rc_$1 -lt \$RC_FAILED"
103 shift
104 if [ $# -gt 0 ];then
105 depstring="$depstring -a"
106 fi
107 done
108 fi
109
110 # define the dep_ function
111 if [ -n "$depstring" ];then
112 eval "dep_$target() {
113 if [ $depstring ];then
114 $target
115 rc_$target=\$?
116 else
117 rc_$target=\$RC_MISSDEP
118 fi
119 }"
120 else
121 eval "dep_$target() {
122 $target
123 rc_$target=\$?
124 }"
125 fi
126 }
127
128 # cvs checkout wrapper: a wget + untar is much faster than anonymous cvs
129 # checkout, especially due to a 30 sec. timeout of the CVS server.
130 cvsget() {
131 if [ $# -eq 1 ];then
132 url=${webcvs}${1}.tar.gz\?view=tar
133 elif [ $# -eq 2 ];then
134 url=${webcvs}${1}.tar.gz\?view=tar\&pathrev=$2
135 else
136 echo "Syntax error in $0 function" >&2
137 echo "Usage: $0 <component> [tar]" >&2
138 return $RC_FAILED
139 fi
140 # Retrieve tarball and untar on the fly
141 wget -nv -O - $url | tar -zvxf - || return $RC_FAILED
142 return $RC_SUCCESS
143 }
144
145 # Print function for results:
146 # $1 - name of component, result is in $rc_<name of component>
147 print_result() {
148 tool=$1
149 eval rc=\$rc_$tool
150 if [ "$rc" = "$RC_SKIPPED" ];then
151 return
152 fi
153 case "$rc" in
154 $RC_SUCCESS) result="SUCCESS" ;;
155 $RC_MISSDEP) result="MISSING DEPS" ;;
156 $RC_FAILED) result="FAILED" ;;
157 *) result="UNKNOWN: $rc" ;;
158 esac
159 printf "%-30s: %s\n" "$tool" "$result" >&2
160 }
161
162 # Prints usage message
163 usage() {
164 echo "Usage: `basename $0` [options] [targets]"
165 echo
166 echo "Options:"
167 echo " -c don't check dependencies"
168 echo " -h show this helptext"
169 echo
170 echo "Notes:"
171 echo "1. when no targets are specified, build all known targets (see below)."
172 echo "2. targets are build in specified order."
173 echo "3. when checking dependencies, only dependencies which are actually "
174 echo " being build will be checked"
175 echo
176 echo "Known targets:"
177 for target in $known_targets;do
178 echo " $target"
179 done
180 return $RC_SUCCESS
181 }
182
183 ##############################################################################
184 #
185 # Define all building functions
186 #
187 ##############################################################################
188
189 # GLOBUS
190 globus() {
191 cd ${source}
192 mkdir -p ${globus} && \
193 wget -nv -O ${globus_tgz} ${globus_url}${globus_tgz} && \
194 tar -C ${globus} -zxf ${globus_tgz} && \
195 cd ${globus} && \
196 find -type f -name \*.la|while read file;do
197 sed s+/opt/globus+${globus}+g ${file} > ${file}.new && \
198 mv -f ${file}.new ${file}
199 done || return $RC_FAILED
200 return $RC_SUCCESS
201 }
202
203 # VOMS: (C & C++ API only)
204 voms() {
205 cd ${source}
206 cvsget org.glite.security.voms glite-security-voms_R_1_9_16_2 && \
207 cd org.glite.security.voms && \
208 ./configure --prefix=${prefix} --with-globus-prefix=${globus} \
209 --disable-java --with-api-only && \
210 make && \
211 make install || return $RC_FAILED
212 return $RC_SUCCESS
213 }
214
215 # BUILD COMMON-CPP:
216 common_cpp() {
217 cd ${source}
218 cvsget org.glite.build.common-cpp || return $RC_FAILED
219 return $RC_SUCCESS
220 }
221
222 # LCMAPS:
223 lcmaps() {
224 cd ${source}
225 cvsget org.glite.security.lcmaps && \
226 cd org.glite.security.lcmaps && \
227 cp -fp ../org.glite.build.common-cpp/m4/{globus,glite,glite_security,lcmaps}.m4 ./project && \
228 ./bootstrap && \
229 ./configure --prefix=${prefix} --with-glite-location=${glite} \
230 --with-globus-prefix=${globus} \
231 --with-globus-thr-flavor=${globus_flav}pthr \
232 --with-globus-nothr-flavor=${globus_flav} && \
233 make && \
234 make install || return $RC_FAILED
235 return $RC_SUCCESS
236 }
237
238 # LCAS:
239 lcas() {
240 cd ${source}
241 cvsget org.glite.security.lcas && \
242 cd org.glite.security.lcas && \
243 cp -fp ../org.glite.build.common-cpp/m4/{glite,globus,lcmaps}.m4 ./project && \
244 ./bootstrap && \
245 ./configure --prefix=${prefix} --with-glite-location=${glite} \
246 --with-globus-prefix=${globus} \
247 --with-globus-thr-flavor=${globus_flav}pthr \
248 --with-globus-nothr-flavor=${globus_flav} && \
249 make && \
250 make install || return $RC_FAILED
251 return $RC_SUCCESS
252 }
253
254 # LCAS-INTERFACE:
255 lcas_interface() {
256 cd ${source}
257 cvsget org.glite.security.lcas-interface && \
258 cd org.glite.security.lcas-interface && \
259 cp -fp ../org.glite.build.common-cpp/m4/glite.m4 ./project && \
260 ./bootstrap && \
261 ./configure --prefix=${prefix} && \
262 make install || return $RC_FAILED
263 return $RC_SUCCESS
264 }
265
266 # GLEXEC: extra LDFLAG needed (only) for certain platforms, incl Debian-5 64
267 glexec() {
268 cd ${source}
269 cvsget org.glite.security.glexec && \
270 cd org.glite.security.glexec && \
271 cp -fp ../org.glite.build.common-cpp/m4/{glite,globus,lcmaps}.m4 ./project && \
272 ./bootstrap && \
273 LDFLAGS="-Wl,-rpath -Wl,${globus}/lib" \
274 ./configure --prefix=${prefix} \
275 --with-glite-location=${glite} \
276 --with-globus-prefix=${globus} \
277 --with-globus-thr-flavor=${globus_flav}pthr \
278 --with-globus-nothr-flavor=${globus_flav} && \
279 make && \
280 make install || return $RC_FAILED
281 return $RC_SUCCESS
282 }
283
284 # LCMAPS PLUGINS BASIC:
285 lcmaps_plugins_basic() {
286 cd ${source}
287 cvsget org.glite.security.lcmaps-plugins-basic && \
288 cd org.glite.security.lcmaps-plugins-basic && \
289 cp -fp ../org.glite.build.common-cpp/m4/{glite,globus,lcmaps,gridlist}.m4 ./project && \
290 ./bootstrap && \
291 ./configure --prefix=${prefix} --with-glite-location=${glite} \
292 --with-globus-prefix=${globus} \
293 --with-globus-thr-flavor=${globus_flav}pthr \
294 --with-globus-nothr-flavor=${globus_flav} && \
295 make && \
296 make install || return $RC_FAILED
297 return $RC_SUCCESS
298 }
299
300 # LCMAPS PLUGINS VERIFY-PROXY:
301 lcmaps_plugins_verify_proxy() {
302 cd ${source}
303 cvsget org.glite.security.lcmaps-plugins-verify-proxy && \
304 cd org.glite.security.lcmaps-plugins-verify-proxy && \
305 cp -fp ../org.glite.build.common-cpp/m4/{glite,glite_security}.m4 ./project && \
306 ./bootstrap && \
307 ./configure --prefix=${prefix} --with-glite-location=${glite} && \
308 make && \
309 make install || return $RC_FAILED
310 return $RC_SUCCESS
311 }
312
313 # LCMAPS PLUGINS VOMS:
314 lcmaps_plugins_voms() {
315 cd ${source}
316 cvsget org.glite.security.lcmaps-plugins-voms && \
317 cd org.glite.security.lcmaps-plugins-voms && \
318 cp -fp ../org.glite.build.common-cpp/m4/{glite,glite_security,globus,lcmaps,gridlist}.m4 ./project && \
319 ./bootstrap && \
320 ./configure --prefix=${glite} --with-glite-location=${glite} \
321 --with-globus-prefix=${globus} \
322 --with-globus-thr-flavor=${globus_flav}pthr \
323 --with-globus-nothr-flavor=${globus_flav} && \
324 make && \
325 make install || return $RC_FAILED
326 return $RC_SUCCESS
327 }
328
329 # LCMAPS PLUGINS AFS:
330 lcmaps_plugins_afs() {
331 cd ${source}
332 cvsget org.glite.security.lcmaps-plugins-afs && \
333 cd org.glite.security.lcmaps-plugins-afs && \
334 cp -fp ../org.glite.build.common-cpp/m4/{glite,globus}.m4 ./project && \
335 ./bootstrap && \
336 ./configure --prefix=${glite} --with-glite-location=${glite} \
337 --with-globus-prefix=${globus} \
338 --with-globus-thr-flavor=${globus_flav}pthr \
339 --with-globus-nothr-flavor=${globus_flav} && \
340 make && \
341 make install || return $RC_FAILED
342 return $RC_SUCCESS
343 }
344
345 # LCMAPS PLUGINS GUMS:
346 lcmaps_plugins_gums() {
347 cd ${source}
348 cvsget org.glite.security.lcmaps-plugins-gums && \
349 cd org.glite.security.lcmaps-plugins-gums && \
350 cp -fp ../org.glite.build.common-cpp/m4/{glite,glite_security,globus}.m4 ./project && \
351 ./bootstrap && \
352 ./configure --prefix=${glite} --with-glite-location=${glite} \
353 --with-globus-prefix=${globus} \
354 --with-globus-thr-flavor=${globus_flav}pthr \
355 --with-globus-nothr-flavor=${globus_flav} && \
356 make && \
357 make install || return $RC_FAILED
358 return $RC_SUCCESS
359 }
360
361 # PEP-C LIB: Will install in same libdir as LCMAPS
362 pep_c_lib() {
363 cd ${source}
364 # Make sure PEP-C is installed in lcmaps directory or else use default.
365 [ -f "${glite}/lib64/liblcmaps.so" ] && \
366 pepclibdir=${glite}/lib64 || \
367 pepclibdir=${glite}/lib
368 svn co http://svnweb.cern.ch/guest/glxa/pep-c-lib/tags/1_3_0 org.glite.authz.pep-c && \
369 cd org.glite.authz.pep-c && \
370 ./autotools.sh && \
371 ./configure --prefix=${glite} --libdir=${pepclibdir} && \
372 make && \
373 make html && \
374 make install || return $RC_FAILED
375 return $RC_SUCCESS
376 }
377
378 # LCMAPS PLUGINS C-PEP
379 lcmaps_plugins_c_pep() {
380 cd ${source}
381 cvsget org.glite.security.lcmaps-plugins-c-pep && \
382 cd org.glite.security.lcmaps-plugins-c-pep && \
383 cp -fp ../org.glite.build.common-cpp/m4/{glite,glite_security}.m4 ./project && \
384 ./bootstrap && \
385 ./configure --prefix=${glite} --with-glite-location=${glite} && \
386 make && \
387 make install || return $RC_FAILED
388 return $RC_SUCCESS
389 }
390
391 # SAML2XACML2 LIB:
392 saml2_xacml2_c_lib() {
393 cd ${source}
394 cvsget org.glite.security.saml2-xacml2-c-lib && \
395 cd org.glite.security.saml2-xacml2-c-lib && \
396 cp -fp ../org.glite.build.common-cpp/m4/glite.m4 ./project && \
397 export CXXFLAGS=-fPIC && \
398 tar -zxf gsoap-2.7.17.tar.gz && \
399 cd gsoap-2.7 && \
400 ../autogen.sh && \
401 ./configure --prefix=${glite} && \
402 make && \
403 make install && \
404 cd ../xacml-1.0 && \
405 ../autogen.sh && \
406 ./configure --prefix=${glite} --with-gsoap=${glite} && \
407 make && \
408 make install || return $RC_FAILED
409 return $RC_SUCCESS
410 }
411
412 # LCMAPS PLUGINS SCAS CLIENT:
413 lcmaps_plugins_scas_client() {
414 cd ${source}
415 cvsget org.glite.security.lcmaps-plugins-scas-client && \
416 cd org.glite.security.lcmaps-plugins-scas-client && \
417 cp -fp ../org.glite.build.common-cpp/m4/{glite,glite_security,lcmaps}.m4 ./project && \
418 ./bootstrap && \
419 ./configure --prefix=${glite} --with-glite-location=${glite} && \
420 make && \
421 make install || return $RC_FAILED
422 return $RC_SUCCESS
423 }
424
425 # SCAS
426 scas() {
427 cd ${source}
428 cvsget org.glite.security.scas && \
429 cd org.glite.security.scas && \
430 cp -fp ../org.glite.build.common-cpp/m4/{globus,glite,glite_security,lcmaps}.m4 ./project && \
431 ./bootstrap && \
432 ./configure --prefix=${prefix} --with-glite-location=${glite} \
433 --with-globus-prefix=${globus} \
434 --with-globus-thr-flavor=${globus_flav}pthr \
435 --with-globus-nothr-flavor=${globus_flav} && \
436 make && \
437 make install || return $RC_FAILED
438 return $RC_SUCCESS
439 }
440
441 # LCAS PLUGINS BASIC:
442 lcas_plugins_basic() {
443 cd ${source}
444 cvsget org.glite.security.lcas-plugins-basic && \
445 cd org.glite.security.lcas-plugins-basic && \
446 cp -fp ../org.glite.build.common-cpp/m4/{glite,globus,gridlist}.m4 ./project && \
447 ./bootstrap && \
448 ./configure --prefix=${glite} --with-glite-location=${glite} \
449 --with-globus-prefix=${globus} \
450 --with-globus-thr-flavor=${globus_flav}pthr \
451 --with-globus-nothr-flavor=${globus_flav} && \
452 make && \
453 make install || return $RC_FAILED
454 return $RC_SUCCESS
455 }
456
457 # LCAS PLUGINS CHECK-EXECUTABLE:
458 lcas_plugins_check_executable() {
459 cd ${source}
460 cvsget org.glite.security.lcas-plugins-check-executable && \
461 cd org.glite.security.lcas-plugins-check-executable && \
462 cp -fp ../org.glite.build.common-cpp/m4/{glite,globus,gridlist}.m4 ./project && \
463 ./bootstrap && \
464 ./configure --prefix=${glite} --with-glite-location=${glite} \
465 --with-globus-prefix=${globus} \
466 --with-globus-thr-flavor=${globus_flav}pthr \
467 --with-globus-nothr-flavor=${globus_flav} && \
468 make && \
469 make install || return $RC_FAILED
470 return $RC_SUCCESS
471 }
472
473 # GRIDSITE CORE:
474 gridsite_core() {
475 # Take libdir from lcas
476 [ -f "${glite}/lib64/liblcas.so" ] && \
477 gridsitelibdir=lib64 || \
478 gridsitelibdir=lib
479 cd ${source}
480 cvsget org.gridsite.core && \
481 cd org.gridsite.core/src && \
482 make prefix=${gridsite} libdir=${gridsitelibdir} && \
483 make prefix=${gridsite} install || return $RC_FAILED
484 return $RC_SUCCESS
485 }
486
487 # LCAS PLUGINS VOMS:
488 lcas_plugins_voms() {
489 cd ${source}
490 cvsget org.glite.security.lcas-plugins-voms && \
491 cd org.glite.security.lcas-plugins-voms && \
492 cp -fp ../org.glite.build.common-cpp/m4/{glite,glite_security,globus,gridsite,gridlist}.m4 ./project && \
493 ./bootstrap && \
494 ./configure --prefix=${glite} --with-glite-location=${glite} \
495 --with-globus-prefix=${globus} \
496 --with-globus-thr-flavor=${globus_flav}pthr \
497 --with-globus-nothr-flavor=${globus_flav} \
498 --with-gridsite-prefix=${gridsite} \
499 --with-gridsite-ssl=system && \
500 make && \
501 make install || return $RC_FAILED
502 return $RC_SUCCESS
503 }
504
505 # LCAS-LCMAPS GT4 interface:
506 lcas_lcmaps_gt4_interface() {
507 cd ${source}
508 cvsget org.glite.security.lcas-lcmaps-gt4-interface && \
509 cd org.glite.security.lcas-lcmaps-gt4-interface && \
510 cp -fp ../org.glite.build.common-cpp/m4/{glite,globus,lcmaps}.m4 ./project && \
511 ./bootstrap && \
512 ./configure --prefix=${prefix} \
513 --with-glite-location=${glite} \
514 --with-globus-prefix=${globus} \
515 --with-globus-thr-flavor=${globus_flav}pthr \
516 --with-globus-nothr-flavor=${globus_flav} && \
517 make && \
518 make install || return $RC_FAILED
519 return $RC_SUCCESS
520 }
521
522 ##############################################################################
523 #
524 # Define all dependency functions, NOTE: the order of the setdeps statements is
525 # important!
526 #
527 ##############################################################################
528
529 # GLOBUS: no dependencies
530 setdeps globus
531
532 # BUILD COMMON-CPP: no dependencies
533 setdeps common_cpp
534
535 # VOMS: depends globus
536 setdeps voms globus
537
538 # LCMAPS: depends globus, voms, common-cpp
539 setdeps lcmaps globus voms common_cpp
540
541 # LCAS: depends globus, common-cpp
542 setdeps lcas globus common_cpp
543
544 # LCAS-INTERFACE: depends common-cpp
545 setdeps lcas_interface common_cpp
546
547 # GLEXEC: depends globus, lcmaps, common-cpp, lcas, lcas-interface
548 setdeps glexec globus lcmaps common_cpp lcas lcas_interface
549
550 # LCMAPS PLUGINS BASIC: depends globus, lcmaps, common-cpp
551 setdeps lcmaps_plugins_basic globus lcmaps common_cpp
552
553 # LCMAPS PLUGINS VERIFY-PROXY: depends lcmaps, common-cpp
554 setdeps lcmaps_plugins_verify_proxy lcmaps common_cpp
555
556 # LCMAPS PLUGINS VOMS: depends globus, voms, lcmaps, common-cpp
557 setdeps lcmaps_plugins_voms globus voms lcmaps common_cpp
558
559 # LCMAPS PLUGINS AFS: depends lcmaps, common-cpp
560 setdeps lcmaps_plugins_afs lcmaps common_cpp
561
562 # LCMAPS PLUGINS GUMS: depends lcmaps, common-cpp
563 setdeps lcmaps_plugins_gums lcmaps common_cpp
564
565 # PEP-C LIB: Not dependent on LCMAPS, but need to install it in right place
566 setdeps pep_c_lib lcmaps
567
568 # LCMAPS PLUGINS C-PEP: depends lcmaps, pep-c lib, common-cpp
569 setdeps lcmaps_plugins_c_pep lcmaps pep_c_lib common_cpp
570
571 # SAML2XACML2 LIB: depends common-cpp
572 setdeps saml2_xacml2_c_lib common_cpp
573
574 # LCMAPS PLUGINS SCAS CLIENT: depends saml2-xacml2-c-lib, common-cpp
575 setdeps lcmaps_plugins_scas_client saml2_xacml2_c_lib common_cpp
576
577 # SCAS: depends saml2-xacml2-c-lib, common-cpp, lcmaps
578 setdeps scas saml2_xacml2_c_lib common_cpp lcmaps
579
580 # LCAS PLUGINS BASIC: depends globus, lcas, common-cpp
581 setdeps lcas_plugins_basic globus lcas common_cpp
582
583 # LCAS PLUGINS CHECK-EXECUTABLE: depends globus, lcas, common-cpp
584 setdeps lcas_plugins_check_executable globus lcas common_cpp
585
586 # GRIDSITE Core:
587 setdeps gridsite_core
588
589 # LCAS PLUGINS VOMS: depends globus, voms, lcas, common-cpp, gridsite
590 setdeps lcas_plugins_voms globus voms lcas common_cpp gridsite_core
591
592 # LCAS-LCMAPS GT4 interface: depends globus, lcmaps, common-cpp, lcas, lcas-interface
593 setdeps lcas_lcmaps_gt4_interface globus lcmaps common_cpp lcas lcas_interface
594
595 ##############################################################################
596 #
597 # Build all tools, taking care of dependencies
598 #
599 ##############################################################################
600
601 # Now that we know all the targets, we can print usage if requested
602 if [ "$USAGE" -eq 1 ];then
603 usage
604 exit 0
605 fi
606
607 # Figure out the build targets
608 build_targets=""
609 # If none specified, use all
610 if [ -z "$targets" ];then
611 build_targets=$known_targets
612 else
613 for target in $targets;do
614 echo $known_targets|tr ' ' '\n'|grep -q "^$target$" && \
615 build_targets="$build_targets $target" || \
616 echo "Skipping unknown target \"$target\"" >&2
617 done
618 fi
619
620 # Anything to be done?
621 if [ -n "$build_targets" ];then
622 # create the source dir
623 mkdir -p ${source} || {
624 echo "Creating of ${source} FAILED" >&2
625 exit 1 # Fatal...
626 }
627
628 # Do the builds
629 for target in $build_targets;do
630 eval dep_$target
631 done
632
633 # Print results
634 for target in $known_targets;do
635 print_result $target
636 done
637 fi
638

Properties

Name Value
svn:executable *

grid.support@nikhef.nl
ViewVC Help
Powered by ViewVC 1.1.28