From: Mike S. <msc...@ao...> - 2002-11-06 23:27:53
|
Hi all, and here's part two of our new weekly series: "Log4perl Recipe of the Week": How can I install Log::Log4perl on Microsoft Windows? Log::Log4perl is fully supported on the Win32 platform. It has been tested with Activestate perl 5.6.1 under Windows 98 and rumor has it that it also runs smoothly on all other major flavors (Windows NT, 2000, XP, etc.). Typically, Win32 systems don't have the "make" utility installed, so the standard "perl Makefile.PL; make install" on the downloadable distribution won't work. But don't despair, there's a very easy solution! The "Log::Log4perl" homepage provides a so-called PPD file for ActiveState's "ppm" installer, which comes with ActiveState perl by default. The DOS command line ppm install "http://log4perl.sourceforge.net/ppm/Log-Log4perl.ppd" will contact the Log4perl homepage, download the latest "Log::Log4perl" distribution and install it. If your ActiveState installation lacks any of the modules "Log::Log4perl" depends upon, "ppm" will automatically contact ActivateState and download them from their CPAN-like repository. That's it! Afterwards, just create a Perl script like use Log::Log4perl qw(:easy); Log::Log4perl->easy_init($DEBUG); my $logger = get_logger("Twix::Bar"); $logger->debug("Watch me!"); and run it. It should print something like 2002/11/06 01:22:05 Watch me! If you find that something doesn't work, please let us know at log...@li... -- we'll apprechiate it. That's it for today! As always, this recipe will be added to the FAQ, available at http://log4perl.sourceforge.net/releases/Log-Log4perl/docs/html/Log/Log4perl/FAQ.html Have fun! -- -- Mike Mike Schilli log...@pe... |