/[cvs]/eggdrop1.7/misc/modconfig
ViewVC logotype

Contents of /eggdrop1.7/misc/modconfig

Parent Directory Parent Directory | Revision Log Revision Log | View Revision Graph Revision Graph


Revision 1.4 - (show annotations) (download)
Mon Nov 20 13:53:32 2006 UTC (12 years, 8 months ago) by tothwolf
Branch: MAIN
CVS Tags: HEAD
Changes since 1.3: +2 -2 lines
* Updated copyright dates for 2006 (better late than never).

1 #! /bin/sh
2 #
3 # modconfig
4 #
5 # Copyright (C) 2000 - 2006 Eggheads Development Team
6 # Written by Fabian Knittel
7 #
8 # This program is free software; you can redistribute it and/or
9 # modify it under the terms of the GNU General Public License
10 # as published by the Free Software Foundation; either version 2
11 # of the License, or (at your option) any later version.
12 #
13 # This program is distributed in the hope that it will be useful,
14 # but WITHOUT ANY WARRANTY; without even the implied warranty of
15 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16 # GNU General Public License for more details.
17 #
18 # You should have received a copy of the GNU General Public License
19 # along with this program; if not, write to the Free Software
20 # Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
21 #
22 # $Id: modconfig,v 1.3 2005/01/21 01:43:38 wcc Exp $
23
24
25 mc_pn=`echo $0 | sed -e 's/^.*\///'`
26 mc_top_srcdir=
27 mc_srcdir=
28 mc_bindir=.
29
30 mc_flag_quiet=no
31 mc_flag_onlynew=no
32
33
34 # Read options
35 while true; do
36 case ${1} in
37 --top_srcdir=*)
38 mc_top_srcdir=`echo ${1} | sed -e 's/^--top_srcdir=//'`
39 ;;
40 --top_srcdir)
41 shift
42 mc_top_srcdir=${1}
43 ;;
44 --srcdir=*)
45 mc_srcdir=`echo ${1} | sed -e 's/^--srcdir=//'`
46 ;;
47 --srcdir)
48 shift
49 mc_srcdir=${1}
50 ;;
51 --bindir=*)
52 mc_bindir=`echo ${1} | sed -e 's/^--bindir=//'`
53 ;;
54 --bindir)
55 shift
56 mc_bindir=${1}
57 ;;
58 --quiet|-q)
59 mc_flag_quiet=yes
60 ;;
61 --only-new|-n)
62 mc_flag_onlynew=yes
63 ;;
64 --*)
65 echo "${mc_pn}: warning: unknown option \`${1}'." 2>&1
66 ;;
67 *)
68 # Non-option parameter.
69 break
70 ;;
71 esac
72
73 # Break out of loop if there are no more arguments to process.
74 if shift; then
75 :
76 else
77 break;
78 fi
79 done
80
81 # Find srcdir and top_srcdir
82 if test "x${mc_srcdir}" = x; then
83 if test "x${mc_top_srcdir}" != x; then
84 mc_srcdir=${mc_top_srcdir}/src
85 else
86 echo "${mc_pn}: error: could not find src directory." 2>&1
87 exit 1
88 fi
89 fi
90 if test "x${mc_top_srcdir}" = x; then
91 if test "x${mc_srcdir}" != x; then
92 mc_top_srcdir=${mc_srcdir}/..
93 else
94 echo "${mc_pn}: error: could not find top src directory." 2>&1
95 exit 1
96 fi
97 fi
98
99
100 #
101 # Files
102 #
103
104 # List of all selected modules (including the `.mod' at the end)
105 mc_fmodules=${mc_bindir}/.modules
106
107 # List of all modules we have detected so far.
108 mc_fknownmods=${mc_bindir}/.known_modules
109
110 # List of modules disabled by default
111 mc_fdisabledmods=${mc_top_srcdir}/disabled_modules
112
113 mc_mod_dir=${mc_srcdir}/mod
114
115 mc_mod_bin_dir=${mc_bindir}/src/mod
116 mc_fMakefile=${mc_mod_bin_dir}/Makefile
117
118 mc_fstatic_h=${mc_mod_dir}/static.h
119
120
121 # File descriptor usage:
122 # 1 Standard output
123 # 2 Errors
124 #
125 # 6 Misc messages and warnings
126 # 7 Goes to /dev/null
127 exec 7>/dev/null
128 if test "${mc_flag_quiet}" = yes; then
129 exec 6>&7
130 else
131 exec 6>&1
132 fi
133
134 # Detect flags needed to achieve 'echo -n' (originally from GNU autoconf) ...
135 if (echo "testing\c"; echo 1,2,3) | grep c >/dev/null; then
136 # Stardent Vistra SVR4 grep lacks -e, says ghazi@caip.rutgers.edu.
137 if (echo -n testing; echo 1,2,3) | sed s/-n/xn/ | grep xn >/dev/null
138 then
139 mc_n= mc_c='
140 ' mc_t=' '
141 else
142 mc_n=-n mc_c= mc_t=
143 fi
144 else
145 mc_n= mc_c='\c' mc_t=
146 fi
147
148 # This helps us call ourself.
149 mc_self_call="$0 --srcdir=${mc_srcdir} --top_srcdir=${mc_topsrcdir}"
150
151 # Assign parameters
152 mc_cmd=$1
153 if test "x${mc_cmd}" != x; then
154 shift
155 mc_paras=$*
156 fi
157
158 case x${mc_cmd} in
159 xhelp)
160 #
161 # Display help
162 #
163
164 cat 1>&6 <<EOF
165 Usage: ${mc_pn} [OPTIONS] COMMAND
166
167 Commands:
168 add Add a module to the list of active eggdrop modules.
169 del Remove a module from that list.
170 clear Clear the list.
171 static.h Create \`src/mod/static.h'.
172 Makefile Create \`src/mod/Makefile'.
173 configure Interactively select modules.
174 is-configured Exits 0/1 depending on wether modules where
175 configured or not.
176 update-depends Check all module dependencies and add modules missing.
177 help Displays this information.
178 detect-modules Find all available modules.
179 modules-still-exist Check wether all known modules still exist.
180
181 Options:
182 --top_srcdir=DIR Top directory (At least one of these two
183 --srcdir=DIR Source directory directories MUST be supplied.)
184 --bindir=DIR Binary directory
185 --quiet [-q] Quiet mode. Only show errors.
186
187 Options specific to the \`configure' command:
188
189 --only-new [-n] Only query new modules.
190 EOF
191 ;;
192 xis-configured)
193 #
194 # Determine wether the modules were configured yet.
195 #
196
197 if test -r "${mc_fmodules}"; then
198 exit 0
199 else
200 exit 1
201 fi
202 ;;
203 xmodules-still-exist)
204 #
205 # Check wether all known modules still exist.
206 #
207
208 if ${mc_self_call} -q is-configured; then
209 mc_known_mods=`cat ${mc_fknownmods}`
210
211 echo ${mc_n} "Checking for removed modules...${mc_c}" 1>&6
212 # Check wether all known mods still exist
213 for mc_mod in ${mc_known_mods}; do
214 echo ${mc_n} ".${mc_c}" >&6
215 if test ! -d ${mc_mod_dir}/${mc_mod}; then
216 grep -v "^${mc_mod}$" ${mc_fknownmods} > ${mc_fknownmods}_new
217 mv ${mc_fknownmods}_new ${mc_fknownmods}
218 fi
219 if test ! -f ${mc_mod_dir}/${mc_mod}/Makefile && test ! -f ${mc_mod_dir}/${mc_mod}/Makefile.in; then
220 grep -v "^${mc_mod}$" ${mc_fknownmods} > ${mc_fknownmods}_new
221 mv ${mc_fknownmods}_new ${mc_fknownmods}
222 fi
223 done
224 echo " done." 1>&6
225 fi
226 ;;
227 xdetect-modules)
228 #
229 # Detect modules. Active modules will be added to the `.modules' file. The
230 # behaviour changes as soon as `.modules' already exists.
231 #
232
233 echo ${mc_n} "Detecting modules...${mc_c}" >&6
234
235 if ${mc_self_call} -q is-configured; then
236 mc_mods_configured=yes
237
238 mv ${mc_fmodules} ${mc_fmodules}_old
239
240 mc_fmodules_old=${mc_fmodules}
241 mc_fmodules=${mc_fmodules}_old
242 else
243 mc_mods_configured=no
244
245 mc_fmodules_old=
246 fi
247
248 mc_mods=`echo ${mc_srcdir}/mod/*.mod | sed -e 's/\.mod//g'`
249 if test "${mc_mods}" = "${mc_srcdir}/mod/*"; then
250 echo "${mc_pn}: error: no modules detected." >&2
251 exit 1
252 fi
253
254 # Add them again.
255 mc_mods=`echo ${mc_mods} | sed -e 's/\.mod//g'`
256 for mc_mod in ${mc_mods}; do
257 mc_mod=`echo ${mc_mod} | sed -e 's/.*\///g'`
258 mc_new_mod_state=disabled
259 echo ${mc_n} ".${mc_c}" >&6
260
261 # Do we have an existing configuration?
262 if (test "${mc_mods_configured}" = yes); then
263 # Is the module active?
264 if (grep "^${mc_mod}\.mod\$" ${mc_fmodules} 1>&7 2>&1)
265 then
266 mc_new_mod_state=enabled
267 else
268 # Was it configured before?
269 if (grep "^${mc_mod}\.mod\$" ${mc_fknownmods} 1>&7 2>&1); then
270 :
271 else
272 mc_new_mod_state=enabled
273 fi
274 fi
275 else
276 if (sed s/\ //g ${mc_fdisabledmods} 2>&1 | grep "^${mc_mod}\$" 1>&7 2>&1)
277 then
278 :
279 else
280 mc_new_mod_state=enabled
281 fi
282 fi
283 if test "${mc_new_mod_state}" = enabled; then
284 ${mc_self_call} -q add ${mc_mod}
285 else
286 ${mc_self_call} -q del ${mc_mod}
287 fi
288 done
289
290 if test "x${mc_fmodules_old}" != x; then
291 # mc_fmodules actually points to the .modules_old file.
292 rm -f ${mc_fmodules}
293 touch ${mc_fmodules_old}
294 fi
295
296 echo " done." >&6
297 ;;
298 xMakefile)
299 #
300 # Build `src/mod/Makefile'
301 #
302
303 echo ${mc_n} "Building ${mc_fMakefile}... ${mc_c}" 1>&6
304
305 # Check for selected modules
306 if test -r ${mc_fmodules}; then
307 # Convert newlines to spaces.
308 mc_sel_modules=`cat ${mc_fmodules} | \
309 awk '{ printf("%s ", $0); }'`
310 else
311 echo "${mc_pn}: error: no modules selected. You did not run \`make config' yet." 1>&2;
312 exit 1
313 fi
314
315 mc_mod_objs=`echo ${mc_sel_modules} | sed -e 's/\.mod/.mod_o/g'`
316 mc_mod_libs=`echo ${mc_sel_modules} | sed -e 's/\.mod/.mod_so/g'`
317
318 if test ! -f ${mc_fMakefile}; then
319 echo "failed." 1>&6
320 echo "${mc_pn}: error: make file template not found." 1>&2
321 exit 1
322 fi
323
324 # The following sed expression modifies src/mod/Makefile to
325 # hold the new module names.
326 if (cat "${mc_fMakefile}" | \
327 sed -e "s/^\(mods =\).*$/\1 ${mc_sel_modules}/g" \
328 -e "s/^\(mod_objs =\).*$/\1 ${mc_mod_objs}/g" \
329 -e "s/^\(mod_libs =\).*$/\1 ${mc_mod_libs}/g" \
330 1> "${mc_fMakefile}_new"); then
331 mv "${mc_fMakefile}_new" "${mc_fMakefile}"
332 else
333 echo "failed." 1>&6
334 echo "${mc_pn}: sed failed to build ${mc_fMakefile}." 1>&2
335 exit 1
336 fi
337
338 echo "done." 1>&6
339 ;;
340 xstatic.h)
341 #
342 # Build `static.h'
343 #
344
345 echo ${mc_n} "Building static.h..." 1>&6
346
347 # Check for selected modules
348 if test ! -r ${mc_fmodules}; then
349 echo " failed." 1>&6
350 echo "${mc_pn}: error: no modules selected. You did not run \`make config' yet." 1>&2;
351 exit 1
352 fi
353 mc_sel_modules=`cat ${mc_fmodules} | sed -e 's/\.mod//g'`
354
355
356 # Note: All data is written to `src/mod/static.h' which is
357 # later included into `src/main.c'.
358
359 # Remove old static.h
360 rm -f ${mc_fstatic_h}
361
362 # Header
363 cat 1>> ${mc_fstatic_h} << EOF
364 /* src/mod/static.h -- header file for static compiles.
365 *
366 * NOTE: Do not edit directly. Instead, re-run \`make config'.
367 */
368
369 #ifndef _EGG_MOD_STATIC_H
370 #define _EGG_MOD_STATIC_H
371
372 EOF
373
374 # Create declarations for module _start functions
375 for mc_mod in ${mc_sel_modules}; do
376 echo ${mc_n} ".${mc_c}" 1>&6
377 echo "char *${mc_mod}_start();" 1>> ${mc_fstatic_h}
378 done
379 echo 1>> ${mc_fstatic_h}
380
381 # The link_statics() function ...
382 echo "static void link_statics()" 1>> ${mc_fstatic_h}
383 echo "{" 1>> ${mc_fstatic_h}
384 for mc_mod in ${mc_sel_modules}; do
385 echo " check_static(\"${mc_mod}\", ${mc_mod}_start);" 1>> ${mc_fstatic_h}
386 done
387 cat 1>> ${mc_fstatic_h} << EOF
388 }
389
390 #endif /* _EGG_MOD_STATIC_H */
391 EOF
392
393 echo " done." 1>&6
394 ;;
395 xdel)
396 #
397 # Remove a module from the list
398 #
399
400 if test "x${mc_paras}" = x; then
401 echo "${mc_pn}: error: no modules specified." 2>&1
402 exit 1
403 fi
404
405 mc_nfmodules="${mc_fmodules}_new"
406
407 # Remove trailing `.mod'
408 mc_mods=`echo ${mc_paras} | sed -e 's/\.mod//g'`
409 for mc_mod in ${mc_mods}; do
410 # Remove any path information
411 mc_mod=`echo ${mc_mod} | sed -e 's/.*\///'`
412 echo "${mc_pn}: disabling eggdrop module: ${mc_mod}" 1>&6
413
414 # Add module to the list of known modules.
415 if grep "^${mc_mod}\.mod$" ${mc_fknownmods} 1>&7 2>&7; then
416 if test ! -d ${mc_mod_dir}/${mc_mod}.mod; then
417 grep -v "^${mc_mod}\.mod$" ${mc_fknownmods} \
418 > ${mc_fknownmods}_new
419 mv ${mc_fknownmods}_new ${mc_fknownmods}
420 fi
421 else
422 if test ! -d ${mc_mod_dir}/${mc_mod}.mod; then
423 :
424 else
425 echo ${mc_mod}.mod 1>> ${mc_fknownmods}
426 fi
427 fi
428
429 # In case there are any active modules ...
430 if test -r ${mc_fmodules}; then
431 # Remove module from list of active modules.
432 if grep -v "^${mc_mod}\.mod$" ${mc_fmodules} \
433 1> ${mc_nfmodules}
434 then
435 :
436 else
437 echo "${mc_pn}: error: building new module file failed" 1>&2
438 echo "Grepping for ${mc_mod}.mod in ${mc_fmodules} and writing to ${mc_nfmodules}."
439 kill -STOP $$
440 exit 1
441 fi
442 mv ${mc_nfmodules} ${mc_fmodules}
443 fi
444 done
445 ;;
446 xadd)
447 #
448 # Add a module to the list
449 #
450
451 if test "x${mc_paras}" = x; then
452 echo "${mc_pn}: error: no modules specified." 2>&1
453 exit 1
454 fi
455
456 # Remove trailing `.mod'
457 mc_mods=`echo ${mc_paras} | sed -e 's/\.mod//g'`
458 for mc_mod in ${mc_mods}; do
459 # Remove any path information
460 mc_mod=`echo ${mc_mod} | sed -e 's/.*\///'`
461
462 # Add module to the list of known modules.
463 if grep "^${mc_mod}\.mod$" ${mc_fknownmods} 1>&7 2>&7; then
464 if test ! -d ${mc_mod_dir}/${mc_mod}.mod; then
465 grep -v "^${mc_mod}\.mod$" ${mc_fknownmods} > ${mc_fknownmods}_new
466 mv ${mc_fknownmods}_new ${mc_fknownmods}
467 fi
468 elif test -d ${mc_mod_dir}/${mc_mod}.mod; then
469 if test -f ${mc_mod_dir}/${mc_mod}.mod/Makefile || test -f ${mc_mod_dir}/${mc_mod}.mod/Makefile.in; then
470 echo ${mc_mod}.mod 1>> ${mc_fknownmods}
471 fi
472 fi
473
474 # Add module to the list of active modules.
475 if ! grep "^${mc_mod}\.mod$" ${mc_fmodules} 1>&7 2>&7; then
476 if test ! -d ${mc_mod_dir}/${mc_mod}.mod; then
477 echo "${mc_pn}: warning: module does not exist: \`${mc_mod}', ignoring." 1>&2
478 elif test -f ${mc_mod_dir}/${mc_mod}.mod/Makefile || test -f ${mc_mod_dir}/${mc_mod}.mod/Makefile.in; then
479 echo "${mc_pn}: enabling eggdrop module: ${mc_mod}" 1>&6
480
481 # Add it to the file
482 echo ${mc_mod}.mod 1>> ${mc_fmodules}
483 fi
484 fi
485 done
486 ;;
487 xclear)
488 #
489 # Clear list of modules
490 #
491
492 echo "${mc_pn}: cleared list of eggdrop modules." 1>&6
493 rm -f ${mc_fmodules}
494 touch ${mc_fmodules}
495 ;;
496 xupdate-depends)
497 #
498 # Check the dependencies and add modules which are depended on, but
499 # aren't enabled.
500 #
501
502 mc_all_depends=
503 mc_missing=
504
505 echo ${mc_n} "Calculating dependencies...${mc_c}" 1>&6
506
507 # Check for selected modules
508 if test ! -r ${mc_fmodules}; then
509 echo " failed." 1>&6
510 echo "${mc_pn}: error: no modules selected. You did not run configure yet." 1>&2
511 exit 1
512 fi
513 mc_sel_modules=`cat ${mc_fmodules}`
514
515 mc_new_mods="${mc_sel_modules}"
516 while (test "x${mc_new_mods}" != x); do
517 mc_mod_list="${mc_new_mods}"
518 mc_new_mods=
519
520 # Go through every module in the list
521 for mc_mod in ${mc_mod_list}; do
522 echo ${mc_n} ".${mc_c}" 1>&6
523
524 # We have an info file, don't we?
525 if (test ! -f ${mc_mod_dir}/${mc_mod}/modinfo); then
526 continue
527 fi
528
529 # Figure out the module's dependencies
530 mc_mod_depends=`grep "^DEPENDS:" ${mc_mod_dir}/${mc_mod}/modinfo | sed -e 's/^DEPENDS://'`
531
532 # Check wether the dependencies are fulfilled
533 for mc_m_depend in ${mc_mod_depends}; do
534 if (echo ${mc_sel_modules} | \
535 grep " ${mc_m_depend}" 1>&7 2>&7) || \
536 (echo ${mc_sel_modules} | \
537 grep "^${mc_m_depend}" 1>&7 2>&7)
538 then
539 :
540 else
541 # Does the module actually exist?
542 if test ! -d ${mc_mod_dir}/${mc_m_depend}.mod
543 then
544 mc_missing="${mc_missing} ${mc_m_depend}"
545 continue
546 fi
547
548 # This one is missing. Add it to the
549 # list.
550 mc_all_depends="${mc_all_depends} ${mc_m_depend}"
551 mc_sel_modules="${mc_sel_modules} ${mc_m_depend}"
552
553 # Add to list of modules to check in
554 # next dependency cycle.
555 mc_new_mods="${mc_new_mods} ${mc_m_depend}.mod"
556 fi
557 done
558 done
559 done
560 echo " done." 1>&6
561
562 # Warn about missing modules.
563 if test "x${mc_missing}" != x; then
564 cat 1>&2 <<EOF
565 ${mc_pn}: warning:
566
567 The following modules were not found but are needed:
568
569 `echo ${mc_missing} | sed -e 's/ /, /g'`
570
571 EOF
572 echo ${mc_n} "Press enter to continue... ${mc_c}"
573 read mc_ask_response
574 fi
575
576 if test "x${mc_all_depends}" != x; then
577 echo ${mc_n} "Adding modules needed to match dependencies... ${mc_c}" 1>&6
578 echo ${mc_all_depends} | sed -e 's/ /, /g' 1>&6
579
580 # Add the modules
581 ${mc_self_call} -q add ${mc_all_depends}
582
583 # Update the makefile
584 ${mc_self_call} -q Makefile
585 fi
586 ;;
587 xconfigure)
588 #
589 # Interactive module selection
590 #
591
592 cat 1>&6 <<EOF
593
594 -*- Eggdrop Interactive Module Selection -*-
595
596 EOF
597
598 # Check for selected modules
599 if test ! -r ${mc_fmodules}; then
600 echo "${mc_pn}: error: no modules selected. You did not run configure yet." 1>&2
601 exit 1
602 fi
603
604 # Read current list
605 mc_sel_modules=`cat ${mc_fmodules}`
606
607 # Detect available modules
608 mc_mods=`echo ${mc_mod_dir}/*.mod`
609
610 # Error out if we have no available modules
611 if test "${mc_mods}" = "echo ${mc_mod_dir}/*.mod"; then
612 echo "${mc_pn}: error: no modules found." 1>&2
613 exit 1
614 fi
615
616 # Loop through each available module
617 for mc_mod in ${mc_mods}; do
618 # Remove directory information from name
619 mc_mod=`echo ${mc_mod} | sed -e 's/.*\///'`
620
621 # Only ask for new modules?
622 if test "${mc_flag_onlynew}" = yes; then
623 # Did we already query for that module?
624 if grep "^${mc_mod}$" ${mc_fknownmods} 1>&7 2>&7; then
625 continue
626 fi
627 fi
628
629 # Remove .mod ending
630 mc_modname=`echo ${mc_mod} | sed -e 's/\.mod//g'`
631
632 # Note: We need to make sure that we only catch module names
633 # that match _exactly_. e.g. don't mix bseen and seen.
634 if (echo ${mc_sel_modules} | grep " ${mc_mod}" 1>&7 2>&7) ||
635 (echo ${mc_sel_modules} | grep "^${mc_mod}" 1>&7 2>&7)
636
637 then
638 # The module is selected.
639 mc_mstate="enabled"
640 mc_mdisp="(E)nable / (d)isable [E/d] ->"
641 else
642 # The module is NOT selected.
643 mc_mstate="disabled"
644 mc_mdisp="(e)nable / (D)isable [e/D] ->"
645 fi
646
647 # Display description
648 if test -r ${mc_mod_dir}/${mc_mod}/modinfo; then
649 echo "" 1>&6
650 grep "^DESC:" ${mc_mod_dir}/${mc_mod}/modinfo | \
651 sed -e 's/^DESC:/ /' 1>&6
652 echo "" 1>&6
653 fi
654
655 while true; do
656 echo ${mc_n} "\`${mc_modname}' is ${mc_mstate}: ${mc_mdisp} ${mc_c} " 1>&6
657 read mc_ask_response;
658
659 if (test "${mc_ask_response}" = D); then
660 mc_ask_response=d;
661 fi
662 if (test "${mc_ask_response}" = E); then
663 mc_ask_response=e;
664 fi
665
666 # If the user just presses [return] or
667 # if the selected state matches the old state,
668 # then we change nothing.
669 if test "x${mc_ask_response}" = x || \
670 (test "${mc_ask_response}" = d && \
671 test "${mc_mstate}" = disabled) || \
672 (test "${mc_ask_response}" = e && \
673 test "${mc_mstate}" = enabled); then
674 echo "Changing nothing." 1>&6
675 break;
676 fi
677 if (test "${mc_ask_response}" = e); then
678 # Add it to the list.
679 mc_sel_modules="${mc_sel_modules} ${mc_mod}"
680 echo "Enabled module '${mc_modname}'." 1>&6
681 break;
682 fi
683 if (test "${mc_ask_response}" = d); then
684 # Remove module from list.
685 mc_sel_modules=`echo ${mc_sel_modules} | sed -e "s/ ${mc_mod}//g" -e "s/^${mc_mod}//g"`
686 echo "Disabled module '${mc_modname}'." 1>&6
687 break;
688 fi
689 done
690 echo "" 1>&6
691 done
692
693 echo ${mc_n} "Recreating list of active modules...${mc_c}" 1>&6
694 ${mc_self_call} -q clear
695 if (${mc_self_call} -q add ${mc_sel_modules}); then
696 echo " done." 1>&6
697 else
698 echo " failed!" 1>&6
699 exit 1
700 fi
701 ;;
702 *)
703 if test "x${mc_cmd}" = x; then
704 echo "${mc_pn}: error: no command supplied." 1>&2
705 else
706 echo "${mc_pn}: error: ${mc_cmd}: unknown command." 1>&2
707 fi
708 ${mc_self_call} help
709 ;;
710 esac
711
712 exit 0

webmaster@eggheads.org
ViewVC Help
Powered by ViewVC 1.1.23