5 eval "exec /usr/local/bin/perl -S $0 $*"
6 if $running_under_some_shell;
8 # automake - create Makefile.in from Makefile.am
9 # Copyright (C) 1994 Free Software Foundation, Inc.
11 # This program is free software; you can redistribute it and/or modify
12 # it under the terms of the GNU General Public License as published by
13 # the Free Software Foundation; either version 2, or (at your option)
16 # This program is distributed in the hope that it will be useful,
17 # but WITHOUT ANY WARRANTY; without even the implied warranty of
18 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
19 # GNU General Public License for more details.
21 # You should have received a copy of the GNU General Public License
22 # along with this program; if not, write to the Free Software
23 # Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
25 # Originally written by David Mackenzie <djm@gnu.ai.mit.edu>.
26 # Perl reimplementation by Tom Tromey <tromey@drip.colorado.edu>.
29 # Parameters set by configure. Not to be changed.
30 $PACKAGE = "@PACKAGE@";
31 $VERSION = "@VERSION@";
33 $am_dir = "@datadir@/@PACKAGE@";
35 # Commonly found files we look for and automatically include in
39 "THANKS", "TODO", "README", "NEWS", "COPYING", "COPYING.LIB",
40 "INSTALL", "ABOUT-NLS", "ChangeLog", "configure", "configure.in",
41 "config.guess", "config.sub"
44 # Commonly used files we auto-include, but only sometimes.
47 "version.texi", "aclocal.m4", "acconfig.h", "config.h.top",
48 "config.h.bot", "stamp-h.in", "mdate-sh", "ansi2knr.c",
49 "ansi2knr.1", 'stamp-vti', "mkinstalldirs", "install-sh"
52 $USAGE = " --amdir=DIR directory storing config files
53 --help print this help, then exit
54 --version print version number, then exit
55 --include-deps include generated dependencies in Makefile\n";
59 # This is TRUE if GNU make specific automatic dependency generation
60 # code should be included in generated Makefile.in.
61 $use_dependencies = 1;
63 # This holds our (eventual) exit status. We don't actually exit until
64 # we have processed all input files.
67 # These two variables are used when generating each Makefile.in. They
68 # hold the Makefile.in until it is ready to be printed.
73 # Suffixes found during a run.
76 # This holds the contents of a Makefile.am, as parsed by read_am_file.
79 # This holds the "relative directory" of the current Makefile.in. Eg
80 # for src/Makefile.in, this is "src".
83 # This holds a list of files that are included in the distribution.
86 # List of dependencies for the obvious targets.
97 # TRUE if current directory holds any C source files.
98 $dir_holds_sources = 0;
100 # TRUE if install targets should work recursively.
101 $recursive_install = 0;
105 # Parse command line.
106 @input_files = &parse_arguments (@ARGV);
108 # Now do all the work on each file.
109 foreach $am_file (@input_files)
111 if (! -f ($am_file . '.am'))
113 print STDERR "automake: $am_file" . ".am: no such file\n";
118 &generate_makefile ($am_file);
125 ################################################################
127 # Parse command line.
130 local (@arglist) = @_;
133 while ($#arglist >= 0)
135 if ($arglist[0] eq "--version")
137 print "Automake version $VERSION\n";
140 elsif ($arglist[0] eq "--help")
144 elsif ($arglist[0] =~ /^--amdir=(.+)$/)
148 elsif ($arglist[0] eq '--amdir')
153 "automake: no argument given for option \`$arglist[0]'\n";
157 $am_dir = $arglist[0];
159 elsif ($arglist[0] eq '--include-deps')
161 $use_dependencies = 0;
163 elsif ($arglist[0] eq '--')
165 # Stop option processing.
167 push (@make_list, @arglist);
170 elsif ($arglist[0] =~ /^-/)
172 print STDERR "automake: unrecognized option -- \`$arglist[0]'\n";
177 push (@make_list, $arglist[0]);
185 # Look around for some files.
186 push (@make_list, 'Makefile') if -f 'Makefile.am';
188 foreach (<*/Makefile.am>)
191 push (@make_list, $_);
194 if ($#make_list >= 0)
196 print "automake: using ", join (' ', @make_list), "\n";
200 print STDERR "automake: no \"Makefile.am\" found or specified\n";
208 ################################################################
210 # Generate a Makefile.in given the name of the corresponding Makefile.
211 sub generate_makefile
213 local ($makefile) = @_;
215 print "creating ", $makefile, ".in\n";
217 $relative_dir = &dirname ($makefile);
220 $output_trailer = '';
223 @dist_common = ('Makefile.in', 'Makefile.am');
227 $dir_holds_sources = 0;
228 $recursive_install = 0;
235 # Generate header before reading .am file. The header must come
236 # before anything else, and read_am_file copies code into the
240 # This is always the default target. This gives us freedom to do
241 # things in whatever order is convenient.
242 $output_rules .= "default: all\n\n";
244 &read_am_file ($makefile . '.am');
247 local ($programs) = (defined ($contents{'AM_PROGRAMS'})
248 ? $contents{'AM_PROGRAMS'}
249 : $contents{'PROGRAMS'});
250 local ($libprograms) = (defined ($contents{'AM_LIBPROGRAMS'})
251 ? $contents{'AM_LIBPROGRAMS'}
252 : $contents{'LIBPROGRAMS'});
253 local ($libraries) = (defined ($contents{'AM_LIBRARIES'})
254 ? $contents{'AM_LIBRARIES'}
255 : $contents{'LIBRARIES'});
256 local ($scripts) = (defined ($contents{'AM_SCRIPTS'})
257 ? $contents{'AM_SCRIPTS'}
258 : $contents{'SCRIPTS'});
259 local ($libscripts) = (defined ($contents{'AM_LIBSCRIPTS'})
260 ? $contents{'AM_LIBSCRIPTS'}
261 : $contents{'LIBSCRIPTS'});
263 &handle_programs ($programs, $libprograms, $libraries);
264 &handle_scripts ($scripts, $libscripts);
265 &handle_libraries ($libraries);
274 &handle_dependencies;
276 &handle_merge_targets;
279 if (! open (GM_FILE, "> " . $makefile . ".in"))
281 print STDERR "automake: cannot open ", $makefile, ".in: ", $!, "\n";
286 print GM_FILE $output_vars;
287 print GM_FILE $output_rules;
288 print GM_FILE $output_trailer;
293 ################################################################
295 # Generate header of Makefile.in.
300 . "# Makefile.in generated automatically by automake "
302 . " from Makefile.am\n");
304 $output_vars = $output_vars . &file_contents ('header-vars');
307 # Handle C programs and libraries.
310 local ($programs, $libprograms, $libraries) = @_;
312 if (!$programs && !$libprograms && !$libraries)
317 $dir_holds_sources = 1;
320 $output_vars .= &file_contents ('compile-vars');
321 $output_rules .= &file_contents ('compile');
323 # Check for automatic de-ANSI-fication.
325 push (@suffixes, '.c', '.o');
326 push (@clean, 'compile');
328 if (defined $contents{'@kr@'})
331 push (@suffixes, '._c', '._o');
333 &require_file ('ansi2knr.c');
334 &require_file ('ansi2knr.1');
336 $output_vars .= &file_contents ('kr-vars');
337 $output_rules .= &file_contents ('compile-kr');
338 $output_rules .= &file_contents ('clean-kr');
343 local (@sources, @objects);
344 push (@sources, '${SOURCES}') if (defined $contents{'SOURCES'});
345 push (@objects, '${OBJECTS}') if (defined $contents{'OBJECTS'});
348 foreach $one_file (split (' ', ($programs . ' '
352 # Look for file_SOURCES and file_OBJECTS. FIXME file_OBJECTS
353 # should probably not be used(?)
354 if (defined $contents{$one_file . "_SOURCES"})
356 if (! defined $contents{$one_file . "_OBJECTS"})
358 # Turn sources into objects.
359 $_ = $contents{$one_file . "_SOURCES"};
361 # Ugh: Perl syntax vs Emacs.
362 local ($krc1, $krc2) = ('\.\$\{kr\}c', '\.\$\(kr\)c');
367 s/\.[cCmylfs]/$obj/g;
369 $output_vars .= $one_file . "_OBJECTS = " . $_ . "\n";
372 push (@sources, '${' . $one_file . "_SOURCES}");
373 push (@objects, '${' . $one_file . "_OBJECTS}");
377 $output_vars .= ($one_file . "_SOURCES = " . $one_file . ".c\n"
378 . $one_file . "_OBJECTS = ". $one_file
380 push (@sources, $one_file . '.c');
381 push (@objects, $one_file . $obj);
384 if (defined $contents{'CONFIG_HEADER'})
386 $output_rules .= ('$(' . $one_file . "_OBJECTS): "
387 . $contents{'CONFIG_HEADER'} . "\n");
391 $output_vars .= "\n";
393 # Re-init SOURCES and OBJECTS. FIXME other code shouldn't depend
395 $contents{'SOURCES'} = join (' ', @sources);
396 $contents{'OBJECTS'} = join (' ', @objects);
398 # Some boilerplate, and install rules.
401 $output_rules .= &file_contents ('programs');
402 push (@install_exec, "install-programs");
403 push (@uninstall, 'uninstall-programs');
404 push (@clean, 'programs');
408 $output_rules .= &file_contents ('libprograms');
409 push (@install_exec, 'install-libprograms');
410 push (@uninstall, 'uninstall-libprograms');
411 push (@clean, 'libprograms');
415 if ($programs || $libprograms)
417 local ($fcont) = &file_contents ('program');
419 foreach $one_file (split (' ', $programs . ' ' . $libprograms))
421 if (! defined $contents{$one_file . "_LDADD"})
423 # User didn't define prog_LDADD override. So do it.
424 $output_vars .= $one_file . '_LDADD = ${LDADD}' . "\n";
427 ($munge = $fcont) =~ s/@PROGRAM@/$one_file/g;
428 $output_rules .= $munge;
436 local ($libraries) = @_;
438 return if (!$libraries);
440 local (@liblist) = split (' ', $libraries);
442 $output_rules .= &file_contents ('libraries');
443 local ($onefile) = &file_contents ('library');
444 local ($onelib, $munge);
445 foreach $onelib (@liblist)
447 ($munge = $onefile) =~ s/@LIBRARY@/$onelib/g;
448 $output_rules .= $munge;
451 # Turn "foo" into "libfoo.a" and include macro definition.
452 grep (($_ = 'lib' . $_ . '.a') && 0, @liblist);
453 $output_vars .= ("LIBFILES = " . join (' ', @liblist) . "\n\n"
454 . &file_contents ('libraries-vars'));
456 push (@install_exec, 'install-libraries');
457 push (@uninstall, 'uninstall-libraries');
458 push (@clean, 'libraries');
464 local ($scripts, $libscripts) = @_;
468 $output_rules .= &file_contents ('scripts');
469 push (@install_exec, 'install-scripts');
470 push (@uninstall, 'uninstall-scripts');
471 push (@clean, 'scripts');
476 $output_rules .= &file_contents ('libscripts');
477 push (@install_exec, 'install-libscripts');
478 push (@uninstall, 'uninstall-libscripts');
479 push (@clean, 'libscripts');
483 # Handle all Texinfo source.
486 return if (! defined $contents{TEXINFOS});
488 local (@texis) = split (' ', $contents{TEXINFOS});
491 print STDERR "automake: sorry, only one file allowed in \`TEXINFOS'\n";
497 ($infobase = $texis[0]) =~ s/\.texi$//;
499 # If 'version.texi' is referenced by input file, then include
500 # automatic versioning capability.
501 system ("grep version.texi " . $relative_dir . "/" . $texis[0]
502 . " > /dev/null 2>&1");
506 push (@texis, 'version.texi');
507 push (@dist_common, 'version.texi', 'stamp-vti');
508 push (@clean, 'vti');
511 ($tfile = &file_contents ('texi-version')) =~ s/@TEXI@/$texis[0]/g;
512 $output_rules = $output_rules . $tfile;
514 &require_file ('mdate-sh');
517 # If user specified file_TEXINFOS, then use that as explicit
519 if (defined $contents{$infobase . "_TEXINFOS"})
521 push (@texis, "\$" . $infobase . '_TEXINFOS');
522 push (@dist_common, "\$" . $infobase . '_TEXINFOS');
527 $output_rules = ($output_rules . $infobase . ".info: "
528 . join (' ', @texis) . "\n\n");
532 $output_vars = $output_vars . &file_contents ('texinfos-vars');
533 $output_rules = $output_rules . &file_contents ('texinfos');
535 push (@suffixes, '.texi', '.info', '.dvi');
536 push (@uninstall, 'uninstall-info');
537 push (@clean, 'info');
538 push (@info, '$(INFO_DEPS)');
539 push (@dvi, '$(DVIS)');
540 # Make sure documentation is made and installed first.
541 unshift (@install_data, 'install-info');
542 unshift (@all, 'info');
544 $output_vars .= ("INFOS = " . $infobase . ".info*\n"
545 . "INFO_DEPS = " . $infobase . ".info\n"
546 . "DVIS = " . $infobase . ".dvi\n\n");
548 # Do some error checking.
549 &require_file ('texinfo.tex');
552 # Handle any man pages.
555 return if (! defined $contents{'MANS'});
557 $output_vars .= &file_contents ('mans-vars');
558 $output_rules .= &file_contents ('mans');
560 push (@install_data, 'install-man');
561 push (@uninstall, 'uninstall-man');
564 # Handle DATA and PACKAGEDATA.
567 if (defined $contents{'DATA'})
569 $output_rules .= &file_contents ('data');
570 push (@install_data, 'install-ddata');
571 push (@uninstall, 'uninstall-ddata');
574 if (defined $contents{'PACKAGEDATA'})
576 $output_rules .= &file_contents ('packagedata');
577 push (@install_data, 'install-pdata');
578 push (@uninstall, 'uninstall-pdata');
585 local ($tagging) = 0;
587 if (defined ($contents{'SUBDIRS'}))
589 $output_rules .= &file_contents ('tags');
592 elsif ($dir_holds_sources || defined ($contents{'ETAGS_ARGS'}))
594 $output_rules .= &file_contents ('tags-subd');
600 $output_rules .= &file_contents ('tags-clean');
601 push (@clean, 'tags');
605 # Handle 'dist' target.
608 # Look for common files that should be included in distribution.
610 foreach $cfile (@common_files)
612 if (-f ($relative_dir . "/" . $cfile))
614 push (@dist_common, $cfile);
618 $output_vars .= "DIST_COMMON = " . join (' ', @dist_common) . "\n\n";
621 $output_vars .= &file_contents ('dist-vars');
622 if ($relative_dir ne '.')
625 $output_vars .= "subdir = " . $relative_dir . "\n\n";
626 $output_rules .= &file_contents ('dist-subd');
630 $output_rules .= &file_contents (defined ($contents{'SUBDIRS'})
636 # Handle auto-dependency code.
637 sub handle_dependencies
639 if ($use_dependencies)
641 # Include GNU-make-specific auto-dep code.
642 if ($dir_holds_sources)
644 $output_rules .= &file_contents ('depend');
649 # Include any auto-generated deps that are present.
650 if (-d ($relative_dir . "/.deps") && -f ($relative_dir . "/.deps/.P"))
653 local ($gpat) = $relative_dir . "/.deps/*.P";
655 foreach $depfile (<${gpat}>)
657 if (! open (DEP_FILE, $depfile))
659 print STDERR "automake: couldn't open $depfile: $!\n";
664 $output_rules .= join ('', <DEP_FILE>);
669 $output_rules .= "\n";
674 # Handle subdirectories.
677 return if (! defined ($contents{'SUBDIRS'}));
679 $output_rules .= &file_contents ('subdirs');
681 push (@all, "all-recursive");
682 push (@check, "check-recursive");
683 push (@info, "info-recursive");
684 push (@dvi, "dvi-recursive");
686 $recursive_install = 1;
689 # Handle remaking and configure stuff.
692 if ($relative_dir ne '.')
695 $output_rules .= &file_contents ('remake-subd');
701 $output_vars .= "ACLOCAL = aclocal.m4\n";
702 push (@dist_common, 'aclocal.m4');
704 $output_rules .= &file_contents ('remake');
706 # Look for some files we need.
707 &require_file ('install-sh');
708 &require_file ('mkinstalldirs');
711 if (defined ($configure{'CONFIG_HEADER'})
712 && $contents{'CONFIG_HEADER'} !~ m,/,)
714 # Header defined and in this directory.
717 $output_vars .= "ACCONFIG = acconfig.h\n";
718 push (@dist_common, 'acconfig.h');
720 if (-f 'config.h.top')
722 $output_vars .= "CONFIG_TOP = config.h.top\n";
723 push (@dist_common, 'config.h.top');
725 if (-f 'config.h.bot')
727 $output_vars .= "CONFIG_BOT = config.h.bot\n";
728 push (@dist_common, 'config.h.bot');
731 push (@dist_common, 'stamp-h.in', $contents{'CONFIG_HEADER'} . '.in');
733 $output_rules .= &file_contents ('remake-hdr');
737 # Handle footer elements.
740 if ($contents{'SOURCES'})
742 $output_vars .= "SOURCES = " . $contents{'SOURCES'} . "\n";
744 if ($contents{'OBJECTS'})
746 $output_vars .= "OBJECTS = " . $contents{'OBJECTS'} . "\n";
748 if ($contents{'SOURCES'} || $contents{'OBJECTS'})
750 $output_vars .= "\n";
753 $output_trailer .= ".SUFFIXES:\n";
756 $output_trailer .= ".SUFFIXES: " . join (' ', @suffixes) . "\n";
758 $output_trailer .= "\n" . &file_contents ('footer');
761 # There are several targets which need to be merged. This is because
762 # their complete definition is compiled from many parts. Note that we
763 # avoid double colon rules, otherwise we'd use them instead.
764 sub handle_merge_targets
766 &do_one_merge_target ('all', @all);
767 &do_one_merge_target ('info', @info);
768 &do_one_merge_target ('dvi', @dvi);
769 &do_one_merge_target ('check', @check);
771 # Handle the various install targets specially. We do this so
772 # that (eg) "make install-exec" will run "install-exec-recursive"
773 # if required, but "make install" won't run it twice. Step one is
774 # to see if the user specified local versions of any of the
776 if (defined $contents{'install-exec-local'})
778 push (@install_exec, 'install-exec-local');
780 if (defined $contents{'install-data-local'})
782 push (@install_data, 'install-data-local');
784 if (defined $contents{'uninstall-local'})
786 push (@uninstall, 'uninstall-local');
789 if (defined $contents{'install-local'})
791 print STDERR "automake: use \`install-data' or \`install-exec', not \`install'\n";
794 # Step two: if we are doing recursive makes, write out the
797 if ($recursive_install)
799 push (@install, 'install-recursive');
800 push (@uninstall, 'uninstall-recursive');
802 if ($#install_exec >= 0)
804 $output_rules .= ('install-exec-am: '
805 . join (' ', @install_exec)
807 @install_exec = ('install-exec-recursive', 'install-exec-am');
808 push (@install, 'install-exec-am');
810 if ($#install_data >= 0)
812 $output_rules .= ('install-data-am: '
813 . join (' ', @install_data)
815 @install_data = ('install-data-recursive', 'install-data-am');
816 push (@install, 'install-data-am');
818 if ($#uninstall >= 0)
820 $output_rules .= ('uninstall-am: '
821 . join (' ', @uninstall)
823 @uninstall = ('uninstall-recursive', 'uninstall-am');
827 # Step three: print definitions users can use.
828 if ($#install_exec >= 0)
830 $output_rules .= ("install-exec: "
831 . join (' ', @install_exec)
833 push (@install, 'install-exec') if (!$recursive_install);
835 if ($#install_data >= 0)
837 $output_rules .= ("install-data: "
838 . join (' ', @install_data)
840 push (@install, 'install-data') if (!$recursive_install);
843 $output_rules .= ('install: '
844 . join (' ', @install)
847 . join (' ', @uninstall)
851 # Helper for handle_merge_targets.
852 sub do_one_merge_target
854 local ($name, @values) = @_;
856 if (defined $contents{$name . '-local'})
858 # User defined local form of target. So include it.
859 push (@values, $name . '-local');
862 $output_rules .= $name . ": " . join (' ', @values) . "\n\n";
865 # Handle all 'clean' targets.
868 push (@clean, 'generic');
869 $output_rules .= &file_contents ('clean');
871 local ($target) = $recursive_install ? 'clean-am' : 'clean';
872 &do_one_clean_target ($target, 'mostly', '', @clean);
873 &do_one_clean_target ($target, '', 'mostly', @clean);
874 &do_one_clean_target ($target, 'dist', '', @clean);
875 &do_one_clean_target ($target, 'maintainer-', 'dist', @clean);
878 if ($recursive_install)
880 @deps = ('am', 'recursive');
881 &do_one_clean_target ('', 'mostly', '', @deps);
882 &do_one_clean_target ('', '', '', @deps);
883 &do_one_clean_target ('', 'dist', '', @deps);
884 &do_one_clean_target ('', 'maintainer-', '', @deps);
888 # Helper for handle_clean.
889 sub do_one_clean_target
891 local ($target, $name, $last_name, @deps) = @_;
893 # Special case: if target not passed, then don't generate
894 # dependency on next "lower" clean target (eg no
895 # clean<-mostlyclean derivation). In this case the target is
896 # implicitly known to be 'clean'.
897 local ($flag) = $target;
903 $output_rules .= $name . $target . ": ";
906 if ($last_name || $name ne 'mostly')
908 $output_rules .= $last_name . $target . " ";
912 $output_rules .= ($name . 'clean-' . join (' ' . $name . 'clean-', @deps)
915 # FIXME shouldn't we really print these messages before running
917 if ($name . $target eq 'maintainer-clean')
919 # Print a special warning.
921 ("\t@echo \"This command is intended for maintainers to use;\"\n"
922 . "\t@echo \"it deletes files that may require special "
923 . "tools to rebuild.\"\n");
925 $output_rules .= "\n";
928 ################################################################
930 # Read Makefile.am and set up %contents. Simultaneously copy lines
931 # from Makefile.am into $output_trailer or $output_vars as
932 # appropriate. NOTE we put rules in the trailer section. We want
933 # user rules to come after our generated stuff.
936 local ($amfile) = @_;
938 if (! open (AMFILE, $amfile))
940 print STDERR "automake: couldn't open $amfile: $!\n";
945 local ($was_rule) = 0;
946 local ($last_var_name) = '';
956 $output_trailer .= $_ . "\n";
960 $output_vars .= $_ . "\n";
961 if (substr ($_, -1) eq "\\")
963 $contents{$last_var_name} .= substr ($_, 0,
968 $contents{$last_var_name} .= $_;
974 # Special case: this means we want automatic
975 # de-ANSI-fication. FIXME think of a better way.
976 $contents{'@kr@'} = 1;
978 elsif (m/^ *([a-zA-Z_.][a-zA-Z0-9_.]*) *:/)
982 # Value here doesn't matter; for targets we only note
985 $output_trailer .= $_ . "\n";
987 elsif (m/^ *([A-Za-z][A-Za-z0-9_]*)[ ]*=[ ]*(.*)$/)
989 # Found a variable reference.
992 if (substr ($2, -1) eq "\\")
994 $contents{$1} = substr ($2, 0, length ($2) - 1);
1000 $output_vars .= $_ . "\n";
1004 # Special rule: if looking at a blank line, append it to
1005 # whatever we saw last.
1008 $output_trailer .= "\n";
1012 $output_vars .= "\n";
1017 # This isn't an error; it is probably a continued rule.
1018 # In fact, this is what we assume.
1019 $output_trailer .= $_ . "\n";
1022 $saw_bk = (substr ($_, -1) eq "\\");
1025 # Include some space after user code.
1026 $output_vars .= "\n";
1027 $output_trailer .= "\n";
1031 ################################################################
1033 # Return contents of a file from $am_dir.
1036 local ($basename) = @_;
1037 local ($file) = $am_dir . '/' . $basename . '.am';
1039 if (! open (FC_FILE, $file))
1041 print STDERR "automake: installation error: cannot open \"$file\"\n";
1045 # Yes, we really want to slurp it.
1046 local ($results) = join ('', <FC_FILE>);
1053 ################################################################
1055 # Verify that the file must exist in the current directory.
1059 local ($fullfile) = $relative_dir . "/" . $file;
1063 print STDERR "automake: required file \"$fullfile\" not found\n";
1068 push (@dist_common, $file);
1073 ################################################################
1075 # Return directory name of file.
1081 ($sub = $file) =~ s,/+[^/]+,,g;
1090 ################################################################
1092 # Print usage information.
1095 print "Usage: automake [OPTION] ... [Makefile]...\n";
1097 print "\nFiles which are automatically distributed, if found:\n";
1098 $~ = "USAGE_FORMAT";
1099 local (@lcomm) = sort ((@common_files, @common_sometimes));
1101 while ($#lcomm >= 0)
1103 $one = shift (@lcomm);
1104 $two = shift (@lcomm);
1111 format USAGE_FORMAT =
1112 @<<<<<<<<<<<<<<<< @<<<<<<<<<<<<<<<<