[otrs-cvs] otrs/bin otrs.CheckModules.pl,1.43,1.44

"CVS commits notifications of OTRS.org" <[email protected]>
Newsgroups gmane.comp.otrs.cvs
Message-ID <[email protected]>
Comments:
Update of /home/cvs/otrs/bin
In directory lancelot:/tmp/cvs-serv20817/bin

Modified Files:
	otrs.CheckModules.pl 
Log Message:
Removed CPAN module Net::IMAP::Simple::SSL, this can be handled by Net::IMAP::Simple now. 
Also, Net::IMAP::Simple generates warnings that you should not be using Net::IMAP::Simple::SSL anymore if you do...!

Author: mb

Index: otrs.CheckModules.pl
===================================================================
RCS file: /home/cvs/otrs/bin/otrs.CheckModules.pl,v
retrieving revision 1.43
retrieving revision 1.44
diff -2 -u -d -r1.43 -r1.44
--- otrs.CheckModules.pl	11 Dec 2012 16:04:40 -0000	1.43
+++ otrs.CheckModules.pl	4 Jan 2013 19:15:37 -0000	1.44
@@ -2,5 +2,5 @@
 # --
 # bin/otrs.CheckModules.pl - to check needed cpan framework modules
-# Copyright (C) 2001-2012 OTRS AG, http://otrs.org/
+# Copyright (C) 2001-2013 OTRS AG, http://otrs.org/
 # --
 # $Id$
@@ -31,4 +31,6 @@
 use lib dirname($RealBin) . '/Custom';
 
+use ExtUtils::MakeMaker;
+
 use vars qw($VERSION);
 $VERSION = qw($Revision$) [1];
@@ -263,7 +265,7 @@
         Depends  => [
             {
-                Module   => 'Net::IMAP::Simple::SSL',
+                Module   => 'IO::Socket::SSL',
                 Required => 0,
-                Comment  => 'Required for SSL connections.',
+                Comment  => 'Required for IMAP SSL connections.',
             },
         ],
@@ -472,5 +474,5 @@
 }
 
-# try to load modules
+# try to determine module version number
 my $Depends = 0;
 for my $Module (@NeededModules) {
@@ -491,13 +493,12 @@
         print ".";
     }
-    if ( eval "require $Module->{Module}" ) {
 
-        # some strange CPAN module do not export VERSION
-        my $Version = eval "\$$Module->{Module}::Version::VERSION";
+    # use internal EU:MM sub to determine if given module is installed
+    # just as in Module::Version
+    my $File = MM->_installed_file_for_module( $Module->{Module} );
+    if ($File) {
 
-        # ask for CPAN module VERSION
-        if ( !$Version ) {
-            $Version = eval "\$$Module->{Module}::VERSION";
-        }
+        # determine version number
+        my $Version = version->parse( MM->parse_version($File) );
 
         # cleanup version number
---------------------------------------------------------------------
OTRS mailing list: cvs-log - Webpage: http://otrs.org/
Archive: http://lists.otrs.org/pipermail/cvs-log
To unsubscribe: http://lists.otrs.org/cgi-bin/listinfo/cvs-log
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.