Resurrect autoconf from the 'full' branch
[msysgit.git] / share / automake-1.10 / Automake / Rule.pm
blob59f9dda8c99506e0fcab3473c0e8d5844cd90dc1
1 # Copyright (C) 2003, 2004, 2006 Free Software Foundation, Inc.
3 # This program is free software; you can redistribute it and/or modify
4 # it under the terms of the GNU General Public License as published by
5 # the Free Software Foundation; either version 2, or (at your option)
6 # any later version.
8 # This program is distributed in the hope that it will be useful,
9 # but WITHOUT ANY WARRANTY; without even the implied warranty of
10 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
11 # GNU General Public License for more details.
13 # You should have received a copy of the GNU General Public License
14 # along with this program; if not, write to the Free Software
15 # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
16 # 02110-1301, USA.
18 package Automake::Rule;
19 use strict;
20 use Carp;
22 use Automake::Item;
23 use Automake::RuleDef;
24 use Automake::ChannelDefs;
25 use Automake::Channels;
26 use Automake::Options;
27 use Automake::Condition qw (TRUE FALSE);
28 use Automake::DisjConditions;
29 require Exporter;
30 use vars '@ISA', '@EXPORT', '@EXPORT_OK';
31 @ISA = qw/Automake::Item Exporter/;
32 @EXPORT = qw (reset register_suffix_rule suffix_rules_count
33 suffixes rules $suffix_rules $KNOWN_EXTENSIONS_PATTERN
34 depend %dependencies %actions accept_extensions
35 reject_rule msg_rule msg_cond_rule err_rule err_cond_rule
36 rule rrule ruledef rruledef);
38 =head1 NAME
40 Automake::Rule - support for rules definitions
42 =head1 SYNOPSIS
44 use Automake::Rule;
45 use Automake::RuleDef;
48 =head1 DESCRIPTION
50 This package provides support for Makefile rule definitions.
52 An C<Automake::Rule> is a rule name associated to possibly
53 many conditional definitions. These definitions are instances
54 of C<Automake::RuleDef>.
56 Therefore obtaining the value of a rule under a given
57 condition involves two lookups. One to look up the rule,
58 and one to look up the conditional definition:
60 my $rule = rule $name;
61 if ($rule)
63 my $def = $rule->def ($cond);
64 if ($def)
66 return $def->location;
68 ...
70 ...
72 when it is known that the rule and the definition
73 being looked up exist, the above can be simplified to
75 return rule ($name)->def ($cond)->location; # do not write this.
77 but is better written
79 return rrule ($name)->rrule ($cond)->location;
81 or even
83 return rruledef ($name, $cond)->location;
85 The I<r> variants of the C<rule>, C<def>, and C<ruledef> methods add
86 an extra test to ensure that the lookup succeeded, and will diagnose
87 failures as internal errors (with a message which is much more
88 informative than Perl's warning about calling a method on a
89 non-object).
91 =head2 Global variables
93 =over 4
95 =cut
97 my $_SUFFIX_RULE_PATTERN =
98 '^(\.[a-zA-Z0-9_(){}$+@\-]+)(\.[a-zA-Z0-9_(){}$+@\-]+)' . "\$";
100 # Suffixes found during a run.
101 use vars '@_suffixes';
103 # Same as $suffix_rules (declared below), but records only the
104 # default rules supplied by the languages Automake supports.
105 use vars '$_suffix_rules_default';
107 =item C<%dependencies>
109 Holds the dependencies of targets which dependencies are factored.
110 Typically, C<.PHONY> will appear in plenty of F<*.am> files, but must
111 be output once. Arguably all pure dependencies could be subject to
112 this factorization, but it is not unpleasant to have paragraphs in
113 Makefile: keeping related stuff altogether.
115 =cut
117 use vars '%dependencies';
119 =item <%actions>
121 Holds the factored actions. Tied to C<%dependencies>, i.e., filled
122 only when keys exists in C<%dependencies>.
124 =cut
126 use vars '%actions';
128 =item <$suffix_rules>
130 This maps the source extension for all suffix rule seen to
131 a C<hash> whose keys are the possible output extensions.
133 Note that this is transitively closed by construction:
134 if we have
135 exists $suffix_rules{$ext1}{$ext2}
136 && exists $suffix_rules{$ext2}{$ext3}
137 then we also have
138 exists $suffix_rules{$ext1}{$ext3}
140 So it's easy to check whether C<.foo> can be transformed to
141 C<.$(OBJEXT)> by checking whether
142 C<$suffix_rules{'.foo'}{'.$(OBJEXT)'}> exists. This will work even if
143 transforming C<.foo> to C<.$(OBJEXT)> involves a chain of several
144 suffix rules.
146 The value of C<$suffix_rules{$ext1}{$ext2}> is the a pair
147 C<[ $next_sfx, $dist ]> where C<$next_sfx> is target suffix
148 for the next rule to use to reach C<$ext2>, and C<$dist> the
149 distance to C<$ext2'>.
151 The content of this variable should be updated via the
152 C<register_suffix_rule> function.
154 =cut
156 use vars '$suffix_rules';
158 =item C<$KNOWN_EXTENSIONS_PATTERN>
160 Pattern that matches all know input extensions (i.e. extensions used
161 by the languages supported by Automake). Using this pattern (instead
162 of `\..*$') to match extensions allows Automake to support dot-less
163 extensions.
165 New extensions should be registered with C<accept_extensions>.
167 =cut
169 use vars qw ($KNOWN_EXTENSIONS_PATTERN @_known_extensions_list);
170 $KNOWN_EXTENSIONS_PATTERN = "";
171 @_known_extensions_list = ();
173 =back
175 =head2 Error reporting functions
177 In these functions, C<$rule> can be either a rule name, or
178 an instance of C<Automake::Rule>.
180 =over 4
182 =item C<err_rule ($rule, $message, [%options])>
184 Uncategorized errors about rules.
186 =cut
188 sub err_rule ($$;%)
190 msg_rule ('error', @_);
193 =item C<err_cond_rule ($cond, $rule, $message, [%options])>
195 Uncategorized errors about conditional rules.
197 =cut
199 sub err_cond_rule ($$$;%)
201 msg_cond_rule ('error', @_);
204 =item C<msg_cond_rule ($channel, $cond, $rule, $message, [%options])>
206 Messages about conditional rules.
208 =cut
210 sub msg_cond_rule ($$$$;%)
212 my ($channel, $cond, $rule, $msg, %opts) = @_;
213 my $r = ref ($rule) ? $rule : rrule ($rule);
214 msg $channel, $r->rdef ($cond)->location, $msg, %opts;
217 =item C<msg_rule ($channel, $targetname, $message, [%options])>
219 Messages about rules.
221 =cut
223 sub msg_rule ($$$;%)
225 my ($channel, $rule, $msg, %opts) = @_;
226 my $r = ref ($rule) ? $rule : rrule ($rule);
227 # Don't know which condition is concerned. Pick any.
228 my $cond = $r->conditions->one_cond;
229 msg_cond_rule ($channel, $cond, $r, $msg, %opts);
233 =item C<$bool = reject_rule ($rule, $error_msg)>
235 Bail out with C<$error_msg> if a rule with name C<$rule> has been
236 defined.
238 Return true iff C<$rule> is defined.
240 =cut
242 sub reject_rule ($$)
244 my ($rule, $msg) = @_;
245 if (rule ($rule))
247 err_rule $rule, $msg;
248 return 1;
250 return 0;
253 =back
255 =head2 Administrative functions
257 =over 4
259 =item C<accept_extensions (@exts)>
261 Update C<$KNOWN_EXTENSIONS_PATTERN> to recognize the extensions
262 listed C<@exts>. Extensions should contain a dot if needed.
264 =cut
266 sub accept_extensions (@)
268 push @_known_extensions_list, @_;
269 $KNOWN_EXTENSIONS_PATTERN =
270 '(?:' . join ('|', map (quotemeta, @_known_extensions_list)) . ')';
273 =item C<rules>
275 Returns the list of all L<Automake::Rule> instances. (I.e., all
276 rules defined so far.)
278 =cut
280 use vars '%_rule_dict';
281 sub rules ()
283 return values %_rule_dict;
287 =item C<Automake::Rule::reset>
289 The I<forget all> function. Clears all know rules and reset some
290 other internal data.
292 =cut
294 sub reset()
296 %_rule_dict = ();
297 @_suffixes = ();
298 # The first time we initialize the variables,
299 # we save the value of $suffix_rules.
300 if (defined $_suffix_rules_default)
302 $suffix_rules = $_suffix_rules_default;
304 else
306 $_suffix_rules_default = $suffix_rules;
309 %dependencies =
311 # Texinfoing.
312 'dvi' => [],
313 'dvi-am' => [],
314 'pdf' => [],
315 'pdf-am' => [],
316 'ps' => [],
317 'ps-am' => [],
318 'info' => [],
319 'info-am' => [],
320 'html' => [],
321 'html-am' => [],
323 # Installing/uninstalling.
324 'install-data-am' => [],
325 'install-exec-am' => [],
326 'uninstall-am' => [],
328 'install-man' => [],
329 'uninstall-man' => [],
331 'install-dvi' => [],
332 'install-dvi-am' => [],
333 'install-html' => [],
334 'install-html-am' => [],
335 'install-info' => [],
336 'install-info-am' => [],
337 'install-pdf' => [],
338 'install-pdf-am' => [],
339 'install-ps' => [],
340 'install-ps-am' => [],
342 'installcheck-am' => [],
344 # Cleaning.
345 'clean-am' => [],
346 'mostlyclean-am' => [],
347 'maintainer-clean-am' => [],
348 'distclean-am' => [],
349 'clean' => [],
350 'mostlyclean' => [],
351 'maintainer-clean' => [],
352 'distclean' => [],
354 # Tarballing.
355 'dist-all' => [],
357 # Phoning.
358 '.PHONY' => [],
359 # Recursive install targets (so `make -n install' works for BSD Make).
360 '.MAKE' => [],
362 %actions = ();
365 =item C<register_suffix_rule ($where, $src, $dest)>
367 Register a suffix rules defined on C<$where> that transform
368 files ending in C<$src> into files ending in C<$dest>.
370 This upgrades the C<$suffix_rules> variables.
372 =cut
374 sub register_suffix_rule ($$$)
376 my ($where, $src, $dest) = @_;
378 verb "Sources ending in $src become $dest";
379 push @_suffixes, $src, $dest;
381 # When transforming sources to objects, Automake uses the
382 # %suffix_rules to move from each source extension to
383 # `.$(OBJEXT)', not to `.o' or `.obj'. However some people
384 # define suffix rules for `.o' or `.obj', so internally we will
385 # consider these extensions equivalent to `.$(OBJEXT)'. We
386 # CANNOT rewrite the target (i.e., automagically replace `.o'
387 # and `.obj' by `.$(OBJEXT)' in the output), or warn the user
388 # that (s)he'd better use `.$(OBJEXT)', because Automake itself
389 # output suffix rules for `.o' or `.obj'...
390 $dest = '.$(OBJEXT)' if ($dest eq '.o' || $dest eq '.obj');
392 # Reading the comments near the declaration of $suffix_rules might
393 # help to understand the update of $suffix_rules that follows...
395 # Register $dest as a possible destination from $src.
396 # We might have the create the \hash.
397 if (exists $suffix_rules->{$src})
399 $suffix_rules->{$src}{$dest} = [ $dest, 1 ];
401 else
403 $suffix_rules->{$src} = { $dest => [ $dest, 1 ] };
406 # If we know how to transform $dest in something else, then
407 # we know how to transform $src in that "something else".
408 if (exists $suffix_rules->{$dest})
410 for my $dest2 (keys %{$suffix_rules->{$dest}})
412 my $dist = $suffix_rules->{$dest}{$dest2}[1] + 1;
413 # Overwrite an existing $src->$dest2 path only if
414 # the path via $dest which is shorter.
415 if (! exists $suffix_rules->{$src}{$dest2}
416 || $suffix_rules->{$src}{$dest2}[1] > $dist)
418 $suffix_rules->{$src}{$dest2} = [ $dest, $dist ];
423 # Similarly, any extension that can be derived into $src
424 # can be derived into the same extensions as $src can.
425 my @dest2 = keys %{$suffix_rules->{$src}};
426 for my $src2 (keys %$suffix_rules)
428 if (exists $suffix_rules->{$src2}{$src})
430 for my $dest2 (@dest2)
432 my $dist = $suffix_rules->{$src}{$dest2} + 1;
433 # Overwrite an existing $src2->$dest2 path only if
434 # the path via $src is shorter.
435 if (! exists $suffix_rules->{$src2}{$dest2}
436 || $suffix_rules->{$src2}{$dest2}[1] > $dist)
438 $suffix_rules->{$src2}{$dest2} = [ $src, $dist ];
445 =item C<$count = suffix_rules_count>
447 Return the number of suffix rules added while processing the current
448 F<Makefile> (excluding predefined suffix rules).
450 =cut
452 sub suffix_rules_count ()
454 return (scalar keys %$suffix_rules) - (scalar keys %$_suffix_rules_default);
457 =item C<@list = suffixes>
459 Return the list of known suffixes.
461 =cut
463 sub suffixes ()
465 return @_suffixes;
468 =item C<rule ($rulename)>
470 Return the C<Automake::Rule> object for the rule
471 named C<$rulename> if defined. Return 0 otherwise.
473 =cut
475 sub rule ($)
477 my ($name) = @_;
478 # Strip $(EXEEXT) from $name, so we can diagnose
479 # a clash if `ctags$(EXEEXT):' is redefined after `ctags:'.
480 $name =~ s,\$\(EXEEXT\)$,,;
481 return $_rule_dict{$name} if exists $_rule_dict{$name};
482 return 0;
485 =item C<rule ($rulename, $cond>
487 Return the C<Automake::RuleDef> object for the rule named
488 C<$rulename> if defined in condition C<$cond>. Return false
489 if the condition or the rule does not exist.
491 =cut
493 sub ruledef ($$)
495 my ($name, $cond) = @_;
496 my $rule = rule $name;
497 return $rule && $rule->def ($cond);
500 =item C<rrule ($rulename)
502 Return the C<Automake::Rule> object for the variable named
503 C<$rulename>. Abort with an internal error if the variable was not
504 defined.
506 The I<r> in front of C<var> stands for I<required>. One
507 should call C<rvar> to assert the rule's existence.
509 =cut
511 sub rrule ($)
513 my ($name) = @_;
514 my $r = rule $name;
515 prog_error ("undefined rule $name\n" . &rules_dump)
516 unless $r;
517 return $r;
520 =item C<rruledef ($varname, $cond)>
522 Return the C<Automake::RuleDef> object for the rule named
523 C<$rulename> if defined in condition C<$cond>. Abort with an internal
524 error if the condition or the rule does not exist.
526 =cut
528 sub rruledef ($$)
530 my ($name, $cond) = @_;
531 return rrule ($name)->rdef ($cond);
534 # Create the variable if it does not exist.
535 # This is used only by other functions in this package.
536 sub _crule ($)
538 my ($name) = @_;
539 my $r = rule $name;
540 return $r if $r;
541 return _new Automake::Rule $name;
544 sub _new ($$)
546 my ($class, $name) = @_;
548 # Strip $(EXEEXT) from $name, so we can diagnose
549 # a clash if `ctags$(EXEEXT):' is redefined after `ctags:'.
550 (my $keyname = $name) =~ s,\$\(EXEEXT\)$,,;
552 my $self = Automake::Item::new ($class, $name);
553 $_rule_dict{$keyname} = $self;
554 return $self;
558 =itcem C<@conds = define ($rulename, $source, $owner, $cond, $where)>
560 Define a new rule. C<$rulename> is the list of targets. C<$source>
561 is the filename the rule comes from. C<$owner> is the owner of the
562 rule (C<RULE_AUTOMAKE> or C<RULE_USER>). C<$cond> is the
563 C<Automake::Condition> under which the rule is defined. C<$where> is
564 the C<Automake::Location> where the rule is defined.
566 Returns a (possibly empty) list of C<Automake::Condition>s where the
567 rule's definition should be output.
569 =cut
571 sub define ($$$$$)
573 my ($target, $source, $owner, $cond, $where) = @_;
575 prog_error "$where is not a reference"
576 unless ref $where;
577 prog_error "$cond is not a reference"
578 unless ref $cond;
580 # Don't even think about defining a rule in condition FALSE.
581 return () if $cond == FALSE;
583 # For now `foo:' will override `foo$(EXEEXT):'. This is temporary,
584 # though, so we emit a warning.
585 (my $noexe = $target) =~ s,\$\(EXEEXT\)$,,;
586 my $noexerule = rule $noexe;
587 my $tdef = $noexerule ? $noexerule->def ($cond) : undef;
589 if ($noexe ne $target
590 && $tdef
591 && $noexerule->name ne $target)
593 # The no-exeext option enables this feature.
594 if (! option 'no-exeext')
596 msg ('obsolete', $tdef->location,
597 "deprecated feature: target `$noexe' overrides "
598 . "`$noexe\$(EXEEXT)'\n"
599 . "change your target to read `$noexe\$(EXEEXT)'");
600 msg ('obsolete', $where, "target `$target' was defined here");
602 # Don't `return ()' now, as this might hide target clashes
603 # detected below.
607 # A GNU make-style pattern rule has a single "%" in the target name.
608 msg ('portability', $where,
609 "`%'-style pattern rules are a GNU make extension")
610 if $target =~ /^[^%]*%[^%]*$/;
612 # Diagnose target redefinitions.
613 if ($tdef)
615 my $oldowner = $tdef->owner;
616 # Ok, it's the name target, but the name maybe different because
617 # `foo$(EXEEXT)' and `foo' have the same key in our table.
618 my $oldname = $tdef->name;
620 # Don't mention true conditions in diagnostics.
621 my $condmsg =
622 $cond == TRUE ? '' : " in condition `" . $cond->human . "'";
624 if ($owner == RULE_USER)
626 if ($oldowner == RULE_USER)
628 # Ignore `%'-style pattern rules. We'd need the
629 # dependencies to detect duplicates, and they are
630 # already diagnosed as unportable by -Wportability.
631 if ($target !~ /^[^%]*%[^%]*$/)
633 ## FIXME: Presently we can't diagnose duplicate user rules
634 ## because we don't distinguish rules with commands
635 ## from rules that only add dependencies. E.g.,
636 ## .PHONY: foo
637 ## .PHONY: bar
638 ## is legitimate. (This is phony.test.)
640 # msg ('syntax', $where,
641 # "redefinition of `$target'$condmsg...", partial => 1);
642 # msg_cond_rule ('syntax', $cond, $target,
643 # "... `$target' previously defined here");
645 # Return so we don't redefine the rule in our tables,
646 # don't check for ambiguous condition, etc. The rule
647 # will be output anyway beauce &read_am_file ignore the
648 # return code.
649 return ();
651 else
653 # Since we parse the user Makefile.am before reading
654 # the Automake fragments, this condition should never happen.
655 prog_error ("user target `$target'$condmsg seen after Automake's"
656 . " definition\nfrom " . $tdef->source);
659 else # $owner == RULE_AUTOMAKE
661 if ($oldowner == RULE_USER)
663 # -am targets listed in %dependencies support a -local
664 # variant. If the user tries to override TARGET or
665 # TARGET-am for which there exists a -local variant,
666 # just tell the user to use it.
667 my $hint = 0;
668 my $noam = $target;
669 $noam =~ s/-am$//;
670 if (exists $dependencies{"$noam-am"})
672 $hint = "consider using $noam-local instead of $target";
675 msg_cond_rule ('override', $cond, $target,
676 "user target `$target' defined here"
677 . "$condmsg...", partial => 1);
678 msg ('override', $where,
679 "... overrides Automake target `$oldname' defined here",
680 partial => $hint);
681 msg_cond_rule ('override', $cond, $target, $hint)
682 if $hint;
684 # Don't overwrite the user definition of TARGET.
685 return ();
687 else # $oldowner == RULE_AUTOMAKE
689 # Automake should ignore redefinitions of its own
690 # rules if they came from the same file. This makes
691 # it easier to process a Makefile fragment several times.
692 # Hower it's an error if the target is defined in many
693 # files. E.g., the user might be using bin_PROGRAMS = ctags
694 # which clashes with our `ctags' rule.
695 # (It would be more accurate if we had a way to compare
696 # the *content* of both rules. Then $targets_source would
697 # be useless.)
698 my $oldsource = $tdef->source;
699 return () if $source eq $oldsource && $target eq $oldname;
701 msg ('syntax', $where, "redefinition of `$target'$condmsg...",
702 partial => 1);
703 msg_cond_rule ('syntax', $cond, $target,
704 "... `$oldname' previously defined here");
705 return ();
708 # Never reached.
709 prog_error ("Unreachable place reached.");
712 # Conditions for which the rule should be defined.
713 my @conds = $cond;
715 # Check ambiguous conditional definitions.
716 my $rule = _crule $target;
717 my ($message, $ambig_cond) = $rule->conditions->ambiguous_p ($target, $cond);
718 if ($message) # We have an ambiguity.
720 if ($owner == RULE_USER)
722 # For user rules, just diagnose the ambiguity.
723 msg 'syntax', $where, "$message ...", partial => 1;
724 msg_cond_rule ('syntax', $ambig_cond, $target,
725 "... `$target' previously defined here");
726 return ();
728 else
730 # FIXME: for Automake rules, we can't diagnose ambiguities yet.
731 # The point is that Automake doesn't propagate conditions
732 # everywhere. For instance &handle_PROGRAMS doesn't care if
733 # bin_PROGRAMS was defined conditionally or not.
734 # On the following input
735 # if COND1
736 # foo:
737 # ...
738 # else
739 # bin_PROGRAMS = foo
740 # endif
741 # &handle_PROGRAMS will attempt to define a `foo:' rule
742 # in condition TRUE (which conflicts with COND1). Fixing
743 # this in &handle_PROGRAMS and siblings seems hard: you'd
744 # have to explain &file_contents what to do with a
745 # condition. So for now we do our best *here*. If `foo:'
746 # was already defined in condition COND1 and we want to define
747 # it in condition TRUE, then define it only in condition !COND1.
748 # (See cond14.test and cond15.test for some test cases.)
749 @conds = $rule->not_always_defined_in_cond ($cond)->conds;
751 # No conditions left to define the rule.
752 # Warn, because our workaround is meaningless in this case.
753 if (scalar @conds == 0)
755 msg 'syntax', $where, "$message ...", partial => 1;
756 msg_cond_rule ('syntax', $ambig_cond, $target,
757 "... `$target' previously defined here");
758 return ();
763 # Finally define this rule.
764 for my $c (@conds)
766 my $def = new Automake::RuleDef ($target, '', $where->clone,
767 $owner, $source);
768 $rule->set ($c, $def);
771 # We honor inference rules with multiple targets because many
772 # make support this and people use it. However this is disallowed
773 # by POSIX. We'll print a warning later.
774 my $target_count = 0;
775 my $inference_rule_count = 0;
777 for my $t (split (' ', $target))
779 ++$target_count;
780 # Check if the rule is a suffix rule: either it's a rule for
781 # two known extensions...
782 if ($t =~ /^($KNOWN_EXTENSIONS_PATTERN)($KNOWN_EXTENSIONS_PATTERN)$/
783 # ...or it's a rule with unknown extensions (.i.e, the rule
784 # looks like `.foo.bar:' but `.foo' or `.bar' are not
785 # declared in SUFFIXES and are not known language
786 # extensions). Automake will complete SUFFIXES from
787 # @suffixes automatically (see handle_footer).
790 || ($t =~ /$_SUFFIX_RULE_PATTERN/o && accept_extensions($1)))
792 ++$inference_rule_count;
793 register_suffix_rule ($where, $1, $2);
797 # POSIX allows multiple targets before the colon, but disallows
798 # definitions of multiple inference rules. It's also
799 # disallowed to mix plain targets with inference rules.
800 msg ('portability', $where,
801 "Inference rules can have only one target before the colon (POSIX).")
802 if $inference_rule_count > 0 && $target_count > 1;
804 return @conds;
807 =item C<depend ($target, @deps)>
809 Adds C<@deps> to the dependencies of target C<$target>. This should
810 be used only with factored targets (those appearing in
811 C<%dependees>).
813 =cut
815 sub depend ($@)
817 my ($category, @dependees) = @_;
818 push (@{$dependencies{$category}}, @dependees);
821 =back
823 =head1 SEE ALSO
825 L<Automake::RuleDef>, L<Automake::Condition>,
826 L<Automake::DisjConditions>, L<Automake::Location>.
828 =cut
832 ### Setup "GNU" style for perl-mode and cperl-mode.
833 ## Local Variables:
834 ## perl-indent-level: 2
835 ## perl-continued-statement-offset: 2
836 ## perl-continued-brace-offset: 0
837 ## perl-brace-offset: 0
838 ## perl-brace-imaginary-offset: 0
839 ## perl-label-offset: -2
840 ## cperl-indent-level: 2
841 ## cperl-brace-offset: 0
842 ## cperl-continued-brace-offset: 0
843 ## cperl-label-offset: -2
844 ## cperl-extra-newline-before-brace: t
845 ## cperl-merge-trailing-else: nil
846 ## cperl-continued-statement-offset: 2
847 ## End: