Subject: | Requires, Provides, and Changelog requests |
It would be nice to have the ability to have a changelog, Requires, and
Provides statement that's supported by the stock RPM spec file.
I've provided some minor modifications that do this in the form of a
patch file.
Subject: | DWIW-features.patch |
*** DWIW.pm 2011-04-08 15:13:18.000000000 -0500
--- DWIW.pm.all 2011-04-08 15:12:45.000000000 -0500
***************
*** 15,27 ****
my $TOP_VAL = {
tags => [ {}, 1 ],
description => [ '', 1 ],
! items => [ [], 1],
! requirements => [ [], 0],
pre => [ '', 0 ],
post => [ '', 0 ],
preun => [ '', 0 ],
postun => [ '', 0 ],
cleanup => [ '', 0 ],
};
my $TAGS_VAL = {
--- 15,28 ----
my $TOP_VAL = {
tags => [ {}, 1 ],
description => [ '', 1 ],
! items => [ [], 1 ],
! requirements => [ [], 0 ],
pre => [ '', 0 ],
post => [ '', 0 ],
preun => [ '', 0 ],
postun => [ '', 0 ],
cleanup => [ '', 0 ],
+ changelog => [ '', 0 ],
};
my $TAGS_VAL = {
***************
*** 36,41 ****
--- 37,44 ----
Distribution => [ '', 0 ],
Vendor => [ '', 0 ],
Packager => [ '', 0 ],
+ Provides => [ '', 0 ],
+ Requires => [ '', 0 ],
};
my $ITEM_VAL = {
***************
*** 64,71 ****
--- 67,77 ----
#Distribution => 'WSS Linux',
#Vendor => 'White Socks Software, Inc.',
#Packager => 'Santa Claus <sclaus@northpole.com>',
+ #Provides => 'virtual_pkg',
+ #Requires => 'foo >= 1.0',
},
description => 'abc def ghi',
+ changelog => "* Mon Apr 8 2011 - knewman (at) globaldataguard.com\n- Added changelog to example spec\n",
items => [
{
defaults => 1,
***************
*** 151,159 ****
$res .= mk_spec_file_line($item) . "\n";
}
! foreach my $section(qw( pre post preun postun )) {
$res .= "\n\n%$section\n$x->{ $section }\n\n" if $x->{ $section };
}
$res;
}
--- 157,166 ----
$res .= mk_spec_file_line($item) . "\n";
}
! foreach my $section(qw( pre post preun postun changelog )) {
$res .= "\n\n%$section\n$x->{ $section }\n\n" if $x->{ $section };
}
+
$res;
}