From 3bb1629e0b8ef14c9e3c9459239335b81f7f8204 Mon Sep 17 00:00:00 2001 From: Ben Pfaff Date: Mon, 15 Feb 2010 15:15:03 -0800 Subject: [PATCH] perl-module: Automatically update PSPP.pm version number check. Until now the $PSPP::VERSION variable was hard-coded in the source tree and had to be manually updated whenever configure.ac was updated to specify a new version number. This is easy to forget. So this commit makes perl-module/lib/PSPP.pm a generated file, with the value of $PSPP::VERSION automatically expanded from the @VERSION_FOR_PERL@ variable already set up by "configure". --- configure.ac | 2 +- perl-module/lib/{PSPP.pm => PSPP.pm.in} | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) rename perl-module/lib/{PSPP.pm => PSPP.pm.in} (99%) diff --git a/configure.ac b/configure.ac index a1f5f655..491cfeac 100644 --- a/configure.ac +++ b/configure.ac @@ -229,7 +229,7 @@ RELOCATABLE_STRIP=: PSPP_CHECK_PREREQS -AC_CONFIG_FILES([Makefile gl/Makefile tests/atlocal]) +AC_CONFIG_FILES([Makefile gl/Makefile tests/atlocal perl-module/lib/PSPP.pm]) AC_OUTPUT echo "PSPP configured successfully." diff --git a/perl-module/lib/PSPP.pm b/perl-module/lib/PSPP.pm.in similarity index 99% rename from perl-module/lib/PSPP.pm rename to perl-module/lib/PSPP.pm.in index fd2f5a5f..a99c77db 100644 --- a/perl-module/lib/PSPP.pm +++ b/perl-module/lib/PSPP.pm.in @@ -21,7 +21,7 @@ None by default. =cut BEGIN { - $PSPP::VERSION='0.7.3'; + $PSPP::VERSION='@VERSION_FOR_PERL@'; require XSLoader; XSLoader::load('PSPP', $PSPP::VERSION); } -- 2.30.2