%general-entities; ]> $LastChangedBy$ $Date$ Perl Modules Perl modules Introduction to Perl Modules The Perl module packages add useful objects to the Perl language. Modules utilized by packages throughout BLFS are listed here, along with their dependencies. Installation of the modules shown on this page should be accomplished by installing the listed dependencies (from the bottom and working up to the top) and then the desired module. Most references to Perl modules are in the form of Module, Module::SubName or Module::Sub::Name, though sometimes you'll see Module, Module-SubName or Module-Sub-Name. The references on this page that reflect an external URL are in the latter form, as these are the official package names. Archive::Zip-&Archive-Zip-version; Archive::Zip The Archive::Zip module allows a Perl program to create, manipulate, read, and write Zip archive files. The two modules listed below can be installed using the Perl module . Archive-Zip-&Archive-Zip-version; Compress::Zlib-&Compress-Zlib-version; Compress::Zlib The Compress::Zlib module provides a Perl interface to the Zlib compression library. Most of the functionality provided by Zlib is available in Compress::Zlib. The module can be split into two general areas of functionality, namely in-memory compression/decompression and read/write access to gzip files. The Compress::Zlib module requires the following sed after untarring the distribution tarball (before any other build commands) to use the system-installed copy of Zlib. sed -i -e "s|BUILD_ZLIB = True|BUILD_ZLIB = False|" \ -e "s|INCLUDE = ./zlib-src|INCLUDE = /usr/include|" \ -e "s|LIB = ./zlib-src|LIB = /usr/lib|" \ config.in Compress-Zlib-&Compress-Zlib-version; () Date::Manip-&DateManip-version; Date::Manip Date::Manip is a set of routines designed to make any common date/time manipulation easy to do. Operations such as comparing two times, calculating a time a given amount of time from another, or parsing international times are all easily done. From the very beginning, the main focus of Date::Manip has been to be able to do ANY desired date/time operation easily. DateManip-&DateManip-version; () Finance::Quote-&Finance-Quote-version; Finance::Quote Finance::Quote is used to get stock quotes from various Internet sources, including Yahoo! Finance, Fidelity Investments, and the Australian Stock Exchange. There are two methods of using this module – a functional interface that is depreciated, and an object-orientated method that provides greater flexibility and stability. With the exception of straight currency exchange rates, all information is returned as a two-dimensional hash (or a reference to such a hash, if called in a scalar context). After you've installed the package, issue perldoc Finance::Quote for full information. Alternatively, you can issue perldoc lib/Finance/Quote.pm after unpacking the distribution tarball and changing into the top-level directory. The module and dependencies can be installed using the Perl module . To run the regression test suite, you'll need to create a symbolic link to the test directory using the following command after unpacking the tarball and changing into the root directory of the sources: ln -s test t Some tests will fail depending on certain conditions. See the INSTALL file for full details. Finance-Quote-&Finance-Quote-version; Finance::QuoteHist-&Finance-QuoteHist-version; Finance::QuoteHist The Finance::QuoteHist bundle is several modules designed to fetch historical stock quotes from the web. The module and dependencies can be installed using the Perl module . Finance-QuoteHist-&Finance-QuoteHist-version; Text-CSV_XS-&Text-CSV_XS-version; Text::CSV_XS HTML::Parser-&HTML-Parser-version; HTML::Parser The HTML::Parser distribution is a collection of modules that parse and extract information from HTML documents. In order to use the included HTML::HeadParser module, you will also need to install . The two modules listed below can be installed using the Perl Module . HTML-Parser-&HTML-Parser-version; HTML-Tagset-&HTML-Tagset-version; HTML::Tagset HTML::TableExtract-&HTML-TableExtract-version; HTML::TableExtract HTML-TableExtract-&HTML-TableExtract-version; LWP-&LWP-version; LWP The libwww-perl (LWP) collection is a set of Perl modules which provides a simple and consistent application programming interface to the World-Wide Web. The main focus of the library is to provide classes and functions that allow you to write WWW clients. The library also contains modules that are of more general use and even classes that help you implement simple HTTP servers. The LWP modules and all its Perl module dependencies can be installed using the Perl Module . LWP-&LWP-version; URI-&URI-version; URI Business-ISBN-&Business-ISBN-version; (optional, only used during the test suite) Business::ISBN Business-ISBN-Data-&Business-ISBN-Data-version; Business::ISBN::Data Test-Prereq-&Test-Prereq-version; Test::Prereq (optional) Module-CoreList-&Module-Corelist-version; Module::Corelist Crypt-SSLeay-&Crypt-SSLeay-version; (optional, for HTTPS support) Crypt::SSLeay Module::Build-&Module-Build-version; Module::Build The Module::Build module is a system for building, testing, and installing Perl modules. It is meant to be an alternative to ExtUtils::MakeMaker. Developers may alter the behavior of the module through subclassing in a much more straightforward way than with MakeMaker. It also does not require a make command on your system. Most of the Module::Build code is pure-Perl and written in a very cross-platform way. The Module::Build module (as well as any other Perl module that uses the Module::Build build system) uses . All the dependencies can be installed using the . Module-Build-&Module-Build-version; Module-Signature-&Module-Signature-version; (optional) Module::Signature Digest-SHA-&Digest-SHA-version; Digest::SHA PAR-Dist-&PAR-Dist-version; PAR::Dist ExtUtils-ParseXS-&ExtUtils-ParseXS-version; ExtUtils::ParseXS ExtUtils-CBuilder-&ExtUtils-CBuilder-version; ExtUtils::CBuilder Archive-Tar-&Archive-Tar-version; Archive::Tar IO-Zlib-&IO-Zlib-version; IO::Zlib Text-Diff-&Text-Diff-version; Text::Diff Algorithm-Diff-&Algorithm-Diff-version; Algorithm::Diff YAML-&YAML-version; YAML Module::Build Build and Installation Instructions perl Build.PL && ./Build test Now, as the root user: ./Build install Module::Info-&Module-Info-version; Module::Info The Module::Info module is quite useful for tasks other than just support of other modules. It can be used from the command-line to tell you if a particular module is included in, or has been installed into your Perl installation. Additionally, Module::Info can tell you what version of a module is installed and what dependencies are required for it. You can even use Module::Info to gather dependencies of uninstalled modules. Module-Info-&Module-Info-version; () Net::DNS-&Net-DNS-version; Net::DNS Net::DNS is a DNS resolver implemented in Perl. It can be used to perform nearly any type of DNS query from a Perl script. The Net::DNS module and all its dependencies can be installed using the Perl Module . Net-DNS-&Net-DNS-version; Digest-HMAC-&Digest-HMAC-version; Digest::HMAC Digest-SHA1-&Digest-SHA1-version; Digest::SHA1 Net-IP-&Net-IP-version; Net::IP IO-Socket-INET6-&IO-Socket-INET6-version; (required for IPv6 support) IO::Socket::INET6 Socket6-&Socket6-version; Socket6 Digest-BubbleBabble-&Digest-BubbleBabble-version; (optional, only used during the test suite) Digest::BubbleBabble SGMLSpm-&SGMLSpm-version; SGMLSpm The SGMLSpm module is a Perl library used for parsing the output from James Clark's SGMLS and NSGMLS parsers. This module requires modified installation instructions, shown below. SGMLSpm-&SGMLSpm-version; If your system's Perl version is different than &LFS-Perl-version;, you'll need to modify the sed command below to reflect the version you have installed. sed -i -e "s@/usr/local/bin@/usr/bin@" \ -e "s@/usr/local/lib/perl5@/usr/lib/perl5/site_perl/&LFS-Perl-version;@" \ -e "s@/usr/local/lib/www/docs@/usr/share/doc/perl5@" \ Makefile Now, as the root user: make install && install -v -m755 -d /usr/share/doc/perl5 && make install_html && rm -v -f /usr/share/doc/perl5/SGMLSpm/sample.pl && install -v -m644 DOC/sample.pl /usr/share/doc/perl5/SGMLSpm Test::Pod-&Test-Pod-version; Test::Pod The Test:Pod module is (most of the time, optionally) used by other modules during the build process to check the validity of POD (Plain Old Documentation) files. The Test::Pod module is typically included by module authors to automatically find and check all POD files in a module distribution. This module and all the dependencies can be installed using the . Test-Pod-&Test-Pod-version; Pod-Simple-&Pod-Simple-version; Pod::Simple Pod-Escapes-&Pod-Escapes-version; Pod::Escapes Test::Simple-&Test-Simple-version; Test::Simple The Test::Simple module contains utilities designed to assist developers in creating tests. A version of Test::Simple was installed during LFS with the Perl-&LFS-Perl-version; installation, however, some of the sub-modules contained in Test::Simple have been updated (notably, the Test::More module) and these updated modules are now required by other modules. This updated version of Test::Simple also now includes the Test:Builder:Tester module, required by many of the modules on this page. Note that installing this updated version of Test::Simple will overwrite some files from the original Perl installation, but there's really nothing to be alarmed about as these modules are only used by developers creating tests, or for running the test suites during additional module installations. Test-Simple-&Test-Simple-version; () Tk-&Perl-Tk-version; Tk The Tk module is a Perl interface to the Tk package. The goal of this release is Unicode support via Perl's and core-Tk's use of UTF-8. Tk-&Perl-Tk-version; builds and loads into a threaded Perl but is NOT yet thread safe. The module can be installed using the Perl Module . Tk-&Perl-Tk-version; and XML::Parser-&XML-Parser-version; XML::Parser The XML::Parser module is a Perl extension interface to James Clark's XML parser, expat. The module can be installed using the Perl Module . XML-Parser-&XML-Parser-version; Standard Installation of Perl Modules Install Perl modules by running the following commands: perl Makefile.PL && make && make test Now, as the root user: make install (Alternate) Auto Installation of Perl Modules. There is an alternate way of installing the modules using Perl's built-in install command. The command automatically downloads the source from the CPAN archive, extracts it, runs the commands mentioned above, and removes the build source tree. You may still need to install dependent library packages before running the automated installation method. The first time you run this command, you'll be prompted to enter some information regarding download locations and methods. This information is retained in files located in ~/.cpan. Start the perl shell with the following command as the root user: perl -MCPAN -e shell Each module may now be installed from this shell with the command: install [Module::Name] For additional commands and help, type help. Alternatively, for scripted or non-interactive installations, use the following syntax as the root user: perl -MCPAN -e 'install [Module::Name]'