1 # Copyright (C) 2003 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 3, or (at your option)
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, see <http://www.gnu.org/licenses/>.
16 package Automake
::RuleDef
;
19 use Automake
::ChannelDefs
;
20 use Automake
::ItemDef
;
23 use vars
'@ISA', '@EXPORT';
24 @ISA = qw
/Automake::ItemDef Exporter/;
25 @EXPORT = qw
(&RULE_AUTOMAKE
&RULE_USER
);
29 Automake::RuleDef - a class for rule definitions
33 use Automake::RuleDef;
34 use Automake::Location;
38 This class gathers data related to one Makefile-rule definition.
44 =item C<RULE_AUTOMAKE>, C<RULE_USER>
46 Possible owners for rules.
50 use constant RULE_AUTOMAKE
=> 0; # Rule defined by Automake.
51 use constant RULE_USER
=> 1; # Rule defined in the user's Makefile.am.
55 my ($class, $name, $comment, $location, $owner, $source) = @_;
57 my $self = Automake
::ItemDef
::new
($class, $comment, $location, $owner);
58 $self->{'source'} = $source;
59 $self->{'name'} = $name;
66 return $self->{'source'};
72 return $self->{'name'};
79 L<Automake::Rule>, L<Automake::ItemDef>.
85 ### Setup "GNU" style for perl-mode and cperl-mode.
87 ## perl-indent-level: 2
88 ## perl-continued-statement-offset: 2
89 ## perl-continued-brace-offset: 0
90 ## perl-brace-offset: 0
91 ## perl-brace-imaginary-offset: 0
92 ## perl-label-offset: -2
93 ## cperl-indent-level: 2
94 ## cperl-brace-offset: 0
95 ## cperl-continued-brace-offset: 0
96 ## cperl-label-offset: -2
97 ## cperl-extra-newline-before-brace: t
98 ## cperl-merge-trailing-else: nil
99 ## cperl-continued-statement-offset: 2