summaryrefslogtreecommitdiffstats
path: root/Bugzilla/Install/Requirements.pm
diff options
context:
space:
mode:
authormkanat%bugzilla.org <>2006-09-14 12:12:22 +0200
committermkanat%bugzilla.org <>2006-09-14 12:12:22 +0200
commit47ee48a70f9abe53bc5e934f6e83c997b350dc6b (patch)
tree0b0e055d03e90ab5f448600c7681653a97068307 /Bugzilla/Install/Requirements.pm
parent8af30bf52079932a49dd628ca6045c313846f34a (diff)
downloadbugzilla-47ee48a70f9abe53bc5e934f6e83c997b350dc6b.tar.gz
bugzilla-47ee48a70f9abe53bc5e934f6e83c997b350dc6b.tar.xz
Bug 277502: Re-organize checksetup.pl to be understood more easily (make it a short series of subroutines)
Patch By Max Kanat-Alexander <mkanat@bugzilla.org> (module owner) a=justdave
Diffstat (limited to 'Bugzilla/Install/Requirements.pm')
-rw-r--r--Bugzilla/Install/Requirements.pm17
1 files changed, 17 insertions, 0 deletions
diff --git a/Bugzilla/Install/Requirements.pm b/Bugzilla/Install/Requirements.pm
index ea3d81eb9..fbe153b25 100644
--- a/Bugzilla/Install/Requirements.pm
+++ b/Bugzilla/Install/Requirements.pm
@@ -25,6 +25,8 @@ package Bugzilla::Install::Requirements;
use strict;
+use POSIX ();
+
use base qw(Exporter);
our @EXPORT = qw(
REQUIRED_MODULES
@@ -33,6 +35,7 @@ our @EXPORT = qw(
check_requirements
check_graphviz
+ display_version_and_os
have_vers
vers_cmp
install_command
@@ -392,6 +395,20 @@ sub check_graphviz {
return $return;
}
+sub display_version_and_os {
+ # Display version information
+ printf "\n* This is Bugzilla " . BUGZILLA_VERSION . " on perl %vd\n",
+ $^V;
+ my @os_details = POSIX::uname;
+ # 0 is the name of the OS, 2 is the major version,
+ my $os_name = $os_details[0] . ' ' . $os_details[2];
+ if (ON_WINDOWS) {
+ require Win32;
+ $os_name = Win32::GetOSName();
+ }
+ # 3 is the minor version.
+ print "* Running on $os_name $os_details[3]\n"
+}
# This was originally clipped from the libnet Makefile.PL, adapted here to
# use the below vers_cmp routine for accurate version checking.