Beefy Boxes and Bandwidth Generously Provided by pair Networks
Do you know where your variables are?
 
PerlMonks  

Preferred Windows Perl?

by dsheroh (Parson)
on Aug 24, 2007 at 14:57 UTC ( #634889=perlquestion: print w/ replies, xml ) Need Help??
dsheroh has asked for the wisdom of the Perl Monks concerning the following question:

I've just come upon the need to write some Perl under Windows. I know there are at least two Windows Perl distributions, ActiveState and cygwin. Are there any significant advantages or drawbacks of either or is it pretty much six of one, half-dozen of the other?

Comment on Preferred Windows Perl?
Re: Preferred Windows Perl?
by RMGir (Prior) on Aug 24, 2007 at 15:03 UTC
    I've used both, and both are fairly decent perl's.

    It's easier, as a general rule, to build 3rd party modules for Cygwin, since it provides a fairly unix-y view of the system.

    A few other things work better in Activestate, and AS also provides the ppm system, which lets you access binary versions of many modules.

    For most uses, either one will do fine for you, I'd think.


    Mike

      This is a really good summary of the situation. Like RMGir said, for most uses either is fine. You won't get to a point where you say "Oh I wish I had used Y because it has X feature!"

      If the use is very casual, you just need to write a bit of Perl, I'd lean towards Activestate. Installation, integration, grabbing modules off of ppm, all of these tasks are very quick and painless.

Re: Preferred Windows Perl?
by technojosh (Priest) on Aug 24, 2007 at 15:05 UTC
      Thanks! I didn't manage to turn that one up when I looked.
Re: Preferred Windows Perl?
by mr_mischief (Monsignor) on Aug 24, 2007 at 16:06 UTC
    You might be interested in checking out http://win32.perl.org/, especially the Distributions, the Win32 Modules, and the Win32-friendly modules.

    Personally, I've tried ActiveState, Cygwin perl, XAMPP+perl, and some other free no-install Apache+MySQL+SQLite+PHP+Perl for Windows that will run from CD (for which I cannot remember nor find a name, but its Perl is based on AS anyway).

    Of all of these, I have a copy of ActiveState lying around, and I'm using a modified version of the no-install one I can't remember the name of for a couple of CD-based projects. I use Cygwin perl when I'm actually in Cygwin, which turns out not to be often because I have a Linux box and a Windows box both at the same desk each with their own keyboard and monitor. Cywin perl theoretically has the advantage that while within Cygwin, CPAN might work better and perl itself might behave closer to expectations since Cygwin is a saner approximation of POSIX than bare Windows. Mostly I use Strawberry Perl for the last several months.

    Despite Strawberry Perl being called alpha, I've never had any stability problems. Most modules install via CPAN just fine, including many with XS binary portions. It's possible to get the command-line PPM working with it. I have done so, but I remember that was a bit of a pain. PPM can be important for a few modules that just don't install right with CPAN.pm yet. Most of the modules with which you might have problems are covered by the Vanilla Perl Problem Modules (Strawberry Perl is a superset, basically, of Vanilla Perl), and many have workarounds, patches, or at least more information about the issues. Most of the Win32 distributions have such a section of modules, some larger and some smaller. YMMV.

    Update: fixed a typo

      and some other free no-install Apache+MySQL+SQLite+PHP+Perl for Windows
      IndigoPerl?

        No, unfortunately I know it's not Indigo nor Stunnix, but I can't remember the name. It's some German project I found once upon a Google.

        It's not PHPProject or CDSite, either. I found those just now searching for it, and those aren't it.

        Ah, here it is: Server2Go. It doesn't seem to have Perl in its default distribution. There are additional things one can download for it, and some of it is "donation required". I'm wondering if that's where Perl support is. The version info for my copy indeed says it's ActiveState's perl. It's seems it's just repackaged and such, so it should really file under ActivePerl for all indents and porpoises.

        BTW, the repackaging effort to make installation not required and to make the servers autostart from a CD didn't end up working well for me anyway, and I rewrote most of that. I'd recommend against the specific package, as there appear to be lots of other options for the same needs without even rolling your own.

Re: Preferred Windows Perl?
by girarde (Friar) on Aug 24, 2007 at 16:31 UTC
    I use AS, because so much of what I do involves either Windows sysad (for which the AS Win32 modules are invaluable), MSSQL, for which Cygwin offers no particular advantage that I know of, or the AS perl that the prime contractor has put in the product whose development I support (the last is a very small part).

    If I came from a real Unix background I might do things differently.

Re: Preferred Windows Perl?
by pemungkah (Priest) on Aug 24, 2007 at 19:42 UTC
    You might also be interested in Strawberry Perl - http://win32.perl.org/wiki/index.php?title=Strawberry_Perl - its motivation is to provide a Perl that "just works" on Windows, including a compile chain to build XS modules. Currently it's
    • Perl 5.8.8
    • Mingw GCC C/C++ compiler
    • Dmake "make" tool
    • ExtUtils::CBuilder and ExtUtils::ParseXS
    • Bundle::CPAN (including Perl modules that largely eliminate the need for external helper programs like gzip and tar)
    • Bundle::LWP (providing more reliable http CPAN repository support)
    • Additional Perl modules that enhance the stability of core Perl for the Win32 platform
    Disclaimer: I'm not a Windows guy, so you'd have to try it and see what you think. It gives, I think, the advantages of Cygwin without the full Cygwin load of other stuff.
      I'm not a Windows guy either, I just had what I thought was a Linux Perl project suddenly turn into a Windows Perl project on me. My initial leanings were towards cygwin, since it's got the fuller POSIX environment, but this and the other referenced thread have convinced me that AS is probably the better choice of the two big players. I'll also definitely take a look at Strawberry Perl before making a final decision, though. Thanks for mentioning it.
      I use strawberry-perl on my Windows XP system at home, and overall, I am very pleased with it. There are several modules that have not been converted to PPM files, so it is simply easier to use the CPAN shell to download and build them yourself.

      TStanley
      --------
      People sleep peaceably in their beds at night only because rough men stand ready to do violence on their behalf. -- George Orwell
Re: Preferred Windows Perl?
by goibhniu (Hermit) on Aug 24, 2007 at 19:56 UTC

    I honestly don't spend alot of time in Cygwin, though it's always faithfully run my Perl.

    I use ActiveState and have no complaints. It hooks nicely into the scripting engine and does all the COM / ISAPI stuff if that's what you want. Installation from the msi is straightforward. I haven't used their package manager stuff much.

    I don't have a lot of experience with anything else.


    I humbly seek wisdom.
      I haven't used their package manager stuff much.

      I have, and it is very nice indeed.

Re: Preferred Windows Perl?
by beryan (Scribe) on Aug 24, 2007 at 22:29 UTC
    I have been using ppm (their package manager) and all I can say is that is a great tool and smart. Activestate doc compilation is nice too. Inside, the power you get is the same as other perls.
Re: Preferred Windows Perl?
by bart (Canon) on Aug 25, 2007 at 00:41 UTC
    The list is quite a bit longer: For the complete list, see the Perl-Win32 wiki

    Which to choose? Well, if you don't have a good reason to choose for another distribution, I'd go for either ActivePerl or Strawberry Perl. Both can use MinGW to install XS modules which are (partly) written in C. The latter actually even comes with MinGW, but installing MinGW for use with ActivePerl is actually dead easy these days. It used to be a lot worse.

Re: Preferred Windows Perl?
by mrpeabody (Friar) on Aug 25, 2007 at 05:20 UTC
    They're really two different things. Activestate is a win32 Perl distribution, while Cygwin is a unixy environment that happens to run Perl.

    Cygwin is a bit more work to set up, but you get a lot more (bash, vim, gcc, etc). You can compile most XS modules straight from CPAN.

    Activestate is easier to set up. It has its own package management system with precompiled binaries for the most common modules.

    If all you need is "Perl on Windows", Activestate is probably your first choice. Of course, there's nothing stopping you from installing both.

Re: Preferred Windows Perl?
by Anonymous Monk on Aug 27, 2007 at 06:36 UTC
    If you are already a long-time or comfortable Perl programmer on Unix, then Strawberry Perl is going to be the most comfortable Perl for you. It's the closest thing there is to Perl on Unix.

    Of course, I'm utterly biased in that regard. So instead I'll blatantly name drop.

    Larry Wall uses Strawberry Perl when on Win32.

    Audrey Tang uses Strawberry Perl when on Win32.

    Simon Cozens uses Strawberry Perl when on Win32.

    The biggest caveat is that Strawberry doesn't need binary packages, it just installs everything from CPAN like on Unix.

    This means that in the limited situation you REALLY need a module that's tricky to get working on Win32 from source, the work done to package the module into a binary package will be very useful.
      Strawberry Perl is only about one year old
Re: Preferred Windows Perl?
by Argel (Prior) on Aug 29, 2007 at 00:17 UTC
    Some Pros/Cons off the top of my head:

    ActivePerl

    • Pro: Quick and easy to install. Corproate friendly because it comes in Microsoft Installer format.
    • Pro: Comes with Windows specific modules so much better suited for Windows specific developement.
    • Pro: Can integrate with Windows Scripting Host (WSH) and IIS. And the .pl extension can be associated with perl.exe.
    • Pro: ActiveState provides additional modules in PPM format. Think of them as binary distributions of the modules. These can easly be downloaded using the PPM tool that comes with ActivePerl.
    • Con: Harder to add modules that are not in PPM format since Windows does not come with a Make utility or a compiler. I think Microsft's make utiltiy is nmake.exe and you can probably track that down fairly easily so adding pure Perl modules should not be too difficult. However, adding ones with C code will be a lot harder.

    For Cygwin, you get a UNIX like environment which makes cross-platform development easier and since it comes with GCC it is a lot easer to install additional Perl modules.

    Also, I have not seen any benchmarks, but since Cygwin adds an extra abstraction layer I would expect ActivePerl to outperform it if performance really matters to you.

    Of course, there's nothing to preclude you from installing both....

    Update: fixed several typos.

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: perlquestion [id://634889]
Approved by Joost
Front-paged by Old_Gray_Bear
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others examining the Monastery: (6)
As of 2014-09-19 01:34 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    How do you remember the number of days in each month?











    Results (129 votes), past polls