aboutsummaryrefslogtreecommitdiffstats
path: root/Makefile.PL
diff options
context:
space:
mode:
Diffstat (limited to 'Makefile.PL')
-rw-r--r--Makefile.PL4
1 files changed, 3 insertions, 1 deletions
diff --git a/Makefile.PL b/Makefile.PL
index 8c0e5da..42c0140 100644
--- a/Makefile.PL
+++ b/Makefile.PL
@@ -2,8 +2,10 @@
# use 5.008;
use ExtUtils::MakeMaker;
+use MDK::Common qw(cat_);
-my $rpmtools_version = '5.0.3';
+(my $rpmtools_version) = cat_('rpmtools.spec') =~ /define\s+version\s+(\d+\.\d+\.\d+)/
+ or die "no version found\n";
sub MY::postamble {
<<MAKEMAKEFILE;