if $dsubdirs;
$output_rules .= &file_contents ('subdirs', new Automake::Location);
- rvar ('RECURSIVE_TARGETS')->rdef (TRUE)->{'pretty'} = VAR_SORTED; # Gross!
+ rvar ('RECURSIVE_TARGETS')->rdef (TRUE)->{'pretty'} = VAR_PRETTY; # Gross!
}
use vars '@ISA', '@EXPORT';
@ISA = qw/Automake::ItemDef Exporter/;
@EXPORT = qw (&VAR_AUTOMAKE &VAR_CONFIGURE &VAR_MAKEFILE
- &VAR_ASIS &VAR_PRETTY &VAR_SILENT &VAR_SORTED);
+ &VAR_ASIS &VAR_PRETTY &VAR_SILENT);
=head1 NAME
use constant VAR_CONFIGURE => 1;# Variable defined in configure.ac.
use constant VAR_MAKEFILE => 2; # Variable defined in Makefile.am.
-=item C<VAR_ASIS>, C<VAR_PRETTY>, C<VAR_SILENT>, C<VAR_SORTED>
+=item C<VAR_ASIS>, C<VAR_PRETTY>, C<VAR_SILENT>
Possible print styles. C<VAR_ASIS> variables should be output as-is.
C<VAR_PRETTY> variables are wrapped on multiple lines if they cannot
-fit on one. C<VAR_SILENT> variables are not output at all. Finally,
-C<VAR_SORTED> variables should be sorted and then handled as
-C<VAR_PRETTY> variables.
+fit on one. C<VAR_SILENT> variables are not output at all.
C<VAR_SILENT> variables can also be overridden silently (unlike the
other kinds of variables whose overriding may sometimes produce
use constant VAR_PRETTY => 1; # Pretty printed on output.
use constant VAR_SILENT => 2; # Not output. (Can also be
# overridden silently.)
-use constant VAR_SORTED => 3; # Sorted and pretty-printed.
=back
definitions).
Finally, C<$pretty> tells how the variable should be output, and can
-be one of C<VAR_ASIS>, C<VAR_PRETTY>, or C<VAR_SILENT>, or
-C<VAR_SORTED> (see these definitions).
+be one of C<VAR_ASIS>, C<VAR_PRETTY>, or C<VAR_SILENT>.
=cut
$res .= $wrap;
}
- else # ($def->pretty == VAR_SORTED)
+ else
{
- # Suppress escaped new lines. &makefile_wrap will
- # add them back, maybe at other places.
- $val =~ s/\\$//mg;
- $res .= makefile_wrap ("$str$name $equals", "$str\t",
- sort (split (' ' , $val)));
+ prog_error ("unknonw variable type '$def->pretty'");
}
}
return $res;
C<$where>: the C<Location> of the assignment.
-C<$pretty>: whether C<$value> should be pretty printed (one of
-C<VAR_ASIS>, C<VAR_PRETTY>, C<VAR_SILENT>, or C<VAR_SORTED>, defined
-by by L<Automake::VarDef>). C<$pretty> applies only to real
-assignments. I.e., it does not apply to a C<+=> assignment (except
-when part of it is being done as a conditional C<=> assignment).
+C<$pretty>: whether C<$value> should be pretty printed (one of C<VAR_ASIS>,
+C<VAR_PRETTY>, or C<VAR_SILENT>, defined by L<Automake::VarDef>).
+C<$pretty> applies only to real assignments. I.e., it does not apply to
+a C<+=> assignment (except when part of it is being done as a conditional
+C<=> assignment).
=cut
prog_error "pretty argument missing"
unless defined $pretty && ($pretty == VAR_ASIS
|| $pretty == VAR_PRETTY
- || $pretty == VAR_SILENT
- || $pretty == VAR_SORTED);
+ || $pretty == VAR_SILENT);
# If there's a comment, make sure it is \n-terminated.
if ($comment)