home *** CD-ROM | disk | FTP | other *** search
- <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
- <HTML>
-
- <HEAD>
- <TITLE>ActivePerl faq1 - Availability and Installation</TITLE>
- <LINK rev="made" href="mailto:support@ActiveState.com">
- <META name="GENERATOR" charset="iso-8859-1" content="Microsoft FrontPage 4.0">
- <META name="ProgId" content="FrontPage.Editor.Document">
- <LINK rel="STYLESHEET" href="../../Active.css" type="text/css" media="screen">
- </HEAD>
-
- <BODY bgcolor="#ffffff">
-
- <TABLE border="0" cellpadding="0" cellspacing="0" width="100%">
- <TR>
- <TD class="block" valign="MIDDLE" width="100%" bgcolor="#cccccc"><STRONG>
- <P class="block"> ActivePerl FAQ</P>
- </STRONG></TD>
- </TR>
- </TABLE>
- <UL>
- <LI><A href="#NAME">NAME</A></LI>
- <LI><A href="#DESCRIPTION">DESCRIPTION</A>
- <UL>
- <LI><A href="#What_is_Perl_">What is Perl?</A></LI>
- <LI><A href="#Where_can_I_get_tons_of_informat">Where can I get tons of information about
- Perl?</A></LI>
- <LI><A href="#Where_is_the_Perl_for_Win32_inte">Where can I get the ActivePerl interpreter?</A></LI>
- <LI><A href="#What_do_I_get_with_ActiveState_s">What do I get with ActivePerl?</A></LI>
- <LI><A href="#How_do_I_install_the_Perl_for_Wi">How do I install ActivePerl?</A></LI>
- <LI><A href="#How_can_I_customize_my_installat">How can I customize my installation of
- ActivePerl?</A></LI>
- <LI><A href="#How_do_I_uninstall_Perl_for_Win3">How do I uninstall ActivePerl?</A></LI>
- <LI><A href="#What_is_ActiveX_Scripting_">What is ActiveX Scripting?</A></LI>
- <LI><A href="#Is_there_an_ActiveX_Scripting_ve">Is there an ActiveX Scripting version of Perl
- available?</A></LI>
- <LI><A href="#When_I_double_click_the_perl_exe">When I double-click the perl.exe icon in
- Explorer, I get</A></LI>
- <LI><A href="#How_can_I_get_Perl_to_run_a_Perl">How can I get Perl to run a Perl script at the
- 4DOS command line by</A></LI>
- <LI><A href="#Can_I_build_perl_from_the_source">Can I build perl from the source code?</A></LI>
- </UL>
- </LI>
- <LI><A href="#AUTHOR_AND_COPYRIGHT">AUTHOR AND COPYRIGHT</A></LI>
- </UL>
- <HR>
- <H1><A name="NAME">NAME</A></H1>
- <P>ActivePerl faq1 - Availability and Installation</P>
- <HR>
- <H1><A name="DESCRIPTION">DESCRIPTION</A></H1>
- <P>Getting, installing, and using Perl.</P>
- <HR>
- <H2><A name="What_is_Perl_">What is Perl?</A></H2>
- <P>Perl is a scripting language widely used for system administration and programming on the World
- Wide Web. It originated in the UNIX community and has a strong UNIX slant, but usage on Windows is
- growing rapidly. ActivePerl is a port of core Perl to Windows.</P>
- <P>perl (small 'p') is the program used to interpret the Perl language.</P>
- <HR>
- <H2><A name="Where_can_I_get_tons_of_informat">Where can I get tons of information about Perl?</A></H2>
- <P>Extensive online documentation is included with Perl itself. You can read the documentation with
- the <CODE>perldoc</CODE> command, as in <CODE>perldoc document_name</CODE>. You should start with
- the perl document and the perlfaq document. For information on other ways of accessing the Perl
- documentation (including HTML versions of this documentation), see <A href="../ActivePerl-faq3.html#Where_can_I_get_documentation_on">Where
- can I get documentation on ActivePerl?</A>.</P>
- <P>To get more information about Perl, check out these URLs:</P>
- <UL>
- <LI>
- <P><A href="http://www.ActiveState.com">http://www.ActiveState.com</A> - The ActivePerl Home
- Page.</P>
- </LI>
- <LI>
- <P><A href="http://www.perl.com">http://www.perl.com</A> - The Perl home page.</P>
- </LI>
- <LI>
- <P><A href="http://language.perl.com">http://language.perl.com</A> - The Perl language home
- page.</P>
- </LI>
- <LI>
- <P><A href="http://www.yahoo.com/Computers_and_Internet/Programming_Languages/Perl/">http://www.yahoo.com/Computers_and_Internet/Programming_Languages/Perl/</A>
- - The Yahoo Perl page.</P>
- </LI>
- </UL>
- <P>There are several good books about Perl. The premier book on ActivePerl is <EM>Learning Perl On
- Win32 Systems</EM> By Schwartz, Olson, and Christiansen (O'Reilly & Associates, 1997). This is
- the Gecko book, and has a picture of a gecko (little chubby lizard with big toes and a smile) on the
- front cover.</P>
- <P>For general perl, two books to consider are <EM>Programming Perl</EM>, 2nd Edition, by Larry
- Wall, Tom Christiansen and Randal L. Schwartz (O'Reilly & Associates, 1996) and <EM>Learning
- Perl</EM>, by Randal L. Schwartz (O'Reilly & Associates, 1993). These are referred to by Perl
- enthusiasts as the Camel book and the Llama book, respectively.</P>
- <P>If you are new to Perl and there are any terms mentioned in this FAQ that you don't get, try one
- of the above resources. See the <EM>perlbook</EM> document that comes with Perl for more
- information.</P>
- <HR>
- <H2><A name="Where_is_the_Perl_for_Win32_inte">Where can I get the ActivePerl interpreter?</A></H2>
- <P>ActivePerl is available from the ActiveState home page.</P>
- <P>To download ActivePerl from ActiveState, look in this directory:</P>
- <PRE>
- <A href="http://www.ActiveState.com/ActivePerl">http://www.ActiveState.com/ActivePerl</A>
- </PRE>
- <HR>
- <H2><A name="What_do_I_get_with_ActiveState_s">What do I get with ActivePerl?</A></H2>
- <P>ActivePerl is a complete, self-installing distribution of Perl based on the standard Perl
- sources. It is distributed online at the ActiveState site.</P>
- <P>"Perl for Win32" generally refers to ActivePerl for Windows.</P>
- <P>Perl for Win32 was developed by ActiveState Tool Corporation (originally Hip Communications) for
- Microsoft Corporation. This effort was undertaken for inclusion in Microsoft's Windows NT Resource
- Kit.</P>
- <P>Since then, ActiveState and various Perl porters have worked to keep ActivePerl current with the
- standard release of Perl. The oneperl effort, a joint effort between ActiveState, O'Reilly, and
- various volunteers, has joined the Win32 and standard Perl source code into one common source tree.</P>
- <HR>
- <H2><A name="How_do_I_install_the_Perl_for_Wi">How do I install ActivePerl?</A></H2>
- <P>Simply double-click the archive you downloaded, and you will be guided through the installation
- process by the installation wizard. You can select the parts of the Perl package you want installed,
- and the location you want to install them to.</P>
- <HR>
- <H2><A name="How_do_I_uninstall_Perl_for_Win3">How do I uninstall ActivePerl?</A></H2>
- <P>Go to Add/Remove Programs in the Control Panel, choose ActivePerl from the list box, and click
- Remove.</P>
- <HR>
- <H2><A name="What_is_ActiveX_Scripting_">What is ActiveX Scripting?</A></H2>
- <P>ActiveX Scripting is a Microsoft technology that consists of script engines and script hosts. A
- script engine, such as PerlScript, VBScript, or JScript, is a programming language that can be
- embedded in a scripting host, such as Windows Scripting Host, Microsoft Exchange, and Active Server
- Pages (ASP).</P>
- <HR>
- <H2><A name="Is_there_an_ActiveX_Scripting_ve">Is there an ActiveX Scripting version of Perl
- available?</A></H2>
- <P>Yes. This is called PerlScript. It is part of ActivePerl, and can be optionally installed during
- installation.</P>
- <P>PerlScript can be used within any ActiveX Scripting Host such as Microsoft Internet Explorer 4.0,
- Microsoft Exchange, and the Windows Scripting Host.</P>
- <HR>
- <H2><A name="When_I_double_click_the_perl_exe">When I double-click the perl.exe icon in Explorer, I
- get an empty DOS window with a blinking cursor.</A></H2>
- <P>ActivePerl is a command-line program. It expects to be run from the command line, not from
- Explorer.</P>
- <P>If you want to run a Perl script, write the script out using a text editor like Notepad. A good
- starter program is:</P>
- <PRE>
- print "Hello, World!\n";
- </PRE>
- <P>Save the program to a file (such as <EM>C:\temp\hello.pl</EM>). Now, start a command prompt
- window (sometimes erroneously called a DOS window), and type the following line at the command
- prompt:</P>
- <PRE>
- C:\> perl c:\temp\hello.pl
- </PRE>
- <P>This should print out the words <CODE>Hello, World!</CODE> on the screen. You may have to do some
- fiddling with the <CODE>PATH</CODE> environment variable, or specify the full path name to <EM>perl.exe</EM>,
- in order for this to work.</P>
- <P><EM>perl.exe</EM> has a lot of nifty command-line arguments that can make your work easier. See <EM>perlrun</EM>
- for details.</P>
- <P>To answer the original question about what's happening when you start perl from an Explorer
- window rather than a command-line window: starting from Explorer is roughly the same as starting
- perl without any command line arguments. When perl is started without a script file specified on the
- command line, it expects to receive a Perl program as standard input, i.e., from the keyboard.</P>
- <P>The blinking cursor means perl is waiting for your input. You can actually type in a Perl program
- from the keyboard, and then tell perl to execute it by typing the Ctrl-Z, which is the end-of-file
- marker on Windows systems.</P>
- <HR>
- <H2><A name="How_can_I_get_Perl_to_run_a_Perl">How can I get Perl to run a Perl script at the 4DOS
- command line by typing the name of the script without the extension or "perl", just like a
- regular exe file?</A></H2>
- <P>See also <A href="ActivePerl-Winfaq4.html#How_do_I_associate_Perl_scripts_">How do I associate
- Perl scripts with perl?</A>.</P>
- <P>You can add a line like</P>
- <PRE>
- SET .PL=C:\PERL\BIN\PERL.EXE
- </PRE>
- <P>to your <EM>AUTOEXEC.BAT</EM> file under Win95/98. You can then type <scriptname> with no
- extension to run your script, even if you are not in the same directory as the script and the script
- path is on your path.</P>
- <P>Note, however, that this only works with 4DOS, not <EM>COMMAND.COM</EM>, <EM>CMD32.EXE</EM>, or <EM>CMD.EXE</EM>.
- With those shells you still need to type</P>
- <PRE>
- perl scriptname.pl <arg> <arg> <arg>
- </PRE>
- <HR>
- <H2><A name="Can_I_build_perl_from_the_source">Can I build perl from the source code?</A></H2>
- <P>The Perl source code includes complete instructions on building Perl. You can obtain the latest
- Perl source from:</P>
- <PRE>
- <A href="http://www.perl.com/CPAN/src/latest.tar.gz">http://www.perl.com/CPAN/src/latest.tar.gz</A>
- </PRE>
- <P>Once you extract the source, read the <EM>README</EM> and <EM>README.win32</EM> files for
- instructions on compiling Perl.</P>
- <P>You can use the following C compilers to build a native Win32 build of Perl:</P>
- <DL>
- <DT><STRONG><A name="item_Microsoft">Microsoft's Visual C++ (commercial product)</A></STRONG></DT>
- <DD>
- <P>The Microsoft compiler, which includes compilation tools, API and tool documentation, and an
- integrated development environment.</P>
- <PRE>
- <A href="http://www.microsoft.com/visualc/">http://www.microsoft.com/visualc/</A>
- </PRE>
- </DD>
- <DT><STRONG><A name="item_Borland">Borland C++ Builder (commercial product)</A></STRONG></DT>
- <DD>
- <P>Borland C++ provides an integrated development environment, compilation tools, and
- documentation for building Win32 applications.</P>
- <PRE>
- <A href="http://www.inprise.com/bcppbuilder/">http://www.inprise.com/bcppbuilder/</A>
- </PRE>
- </DD>
- <DT><STRONG><A name="item_The">Mingw32 Libraries with GCC or EGCS Compilers (free software)</A></STRONG></DT>
- <DD>
- <P>GCC and EGCS are both high quality freeware compilers that have been ported to the Win32
- platform. Together with the freely available Mingw32 libraries, they can be used to build Perl
- and extensions. They do not provide an integrated development environment, and all of the tools
- must be run from the command line. The Mingw32 library reuses some of the code developed for
- Cygwin32 (see below).</P>
- <P>EGCS/Mingw32 binaries can be obtained from:</P>
- <PRE>
- <A href="ftp://ftp.xraylith.wisc.edu/pub/khan/gnu-win32/mingw32/">ftp://ftp.xraylith.wisc.edu/pub/khan/gnu-win32/mingw32/</A>
- </PRE>
- <P>GCC/Mingw32 binaries are available at:</P>
- <PRE>
- <A href="http://agnes.dida.physik.uni-essen.de/~janjaap/mingw32/">http://agnes.dida.physik.uni-essen.de/~janjaap/mingw32/</A>
- </PRE>
- </DD>
- <DT><STRONG><A name="item_Cygwin32">Cygwin32 (free software)</A></STRONG></DT>
- <DD>
- <P>You can approximate a UNIX development and execution environment on Win32 with the Cygwin32
- toolchain. This is a port of numerous GNU tools, and includes an emulation API that provides
- access to many UNIX features not found on Win32:</P>
- <PRE>
- <A href="http://www.cygnus.com/misc/gnu-win32">http://www.cygnus.com/misc/gnu-win32</A>
- </PRE>
- </DD>
- </DL>
- <HR>
- <H1><A name="AUTHOR_AND_COPYRIGHT">AUTHOR AND COPYRIGHT</A></H1>
- <P>This FAQ was originally assembled and maintained by Evangelo Prodromou. It has been revised and
- updated by Brian Jepson of O'Reilly & Associates, David Grove, David Dmytryshyn and David Sparks
- of ActiveState.</P>
- <P>This FAQ is in the public domain. If you use it, however, please ensure that you give credit to
- the original authors. <!-- beginning of leaf footer-->
- </P>
- <TABLE border="0" cellpadding="0" cellspacing="0" width="100%">
- <TR>
- <TD class="block" valign="MIDDLE" width="100%" bgcolor="#cccccc"><STRONG>
- <P class="block"> ActivePerl FAQ</P>
- </STRONG></TD>
- </TR>
- </TABLE>
- <!-- end of leaf footer-->
-
- </BODY>
-
- </HTML>
-