Slash Boxes
NOTE: use Perl; is on undef hiatus. You can read content, but you can't post it. More info will be forthcoming forthcomingly.

All the Perl that's Practical to Extract and Report

use Perl Log In

Log In

[ Create a new account ]

bart (450)

Journal of bart (450)

Wednesday October 28, 2009
03:56 AM

Strawberry Perl and the nightmare of installing Padre

[ #39812 ]

Yesterday evening I felt like it was time for something new, and I decided to install Strawberry Perl and Padre. So I grabbed the MSI installer file from Strawberry Perl's website, and ran it. Soon enough it finished, and I felt simply lost. Was that it?

I glanced in the Start Menu, and I found a few links to docs, 2 to CPAN, and one to the help channel on IRC. I've never used IRC in my life, I don't even have IRC software, so that didn't feel welcoming. No welcome message, no introduction message "What now?", nothing. I'm an experienced Perl user, and as I felt lost, I can't imagine what kind of hell it must feel like to people who are new to Perl.

So I opened a command line window, and I typed "perl -v". Wow! At least that was something: apparently Strawberry Perl had put itself in my PATH, and in front of my default Perl install. (The reason for that is because my default perl is in the user environment variable PATH, and Strawberry put itself in the system environment variable PATH, and the latter comes in front of the former. It doesn't feel right to me, but at least, it's a annoyance caused by Windows.)

But I had, half and half, expected that Padre would have been there. It wasn't. So I went to the win32 Wiki (following the link in the Start Menu and initially ending up in the wrong place), and tried to find a "What now?" page. Still nothing. There's a (very incomplete) page on editors usable for Perl (I can name, off the top of my head, 3 free Windows text editors that aren't listed). I needed an editor, this is a fresh Windows install and there's no editor there yet apart from Notepad.

I decided to grab Padre anyway. So I dropped down to the command line window, and typed "CPAN", followed by "install Padre". That should go swiftly, shouldn't it? It didn't. I got all sorts of weird errors, most of them relating to "missing prerequisite", at least most due to a module that failed to install, due to a "missing file" error message. Say what??

So I decided to figure out which module failed to install, and installed, by hand, the first one that produced such an error: IPC::Run. Hmm, that installed without glitch. But "install Padre" still doesn't work. So, digging down, I decided to try "install Wx" first. Big mistake. After a very long compilation time, Wx appears to exist out of trillions of little C files, it still failed to install successfully. Again, it appears the reason is because of prerequisites that failed to install.

So I dug further down, installing module after module by hand: starting up with the huge ones like PPI, and ending up in really tiny ones, like Class::Accessor. Eventually, they all installed.

So what was the culprit? Nothing. They all installed. But I get the distinct impression CPAN throws away part of the build before it even finishes, and therefore, installing huge dependency trees fails. You have to split it up in smaller chunks and install them one at a time.

Seriously, I can't expect somebody new to perl and CPAN to get this far. From installing Strawberry Perl to finishing installing Padre through CPAN took over 2 hours.

So after everything installed fine, I sighed a sigh of relief, and typed "padre" at the command line. A spinning cursor for 1 second, and the command line prompt was back. That was it. No error, no error message. Nothing.

After a pause of more than an hour, I decided to tackle the problem, and started by the most likely culprit: Wx, which I had more or less forced to install. I dropped back to the CPAN command line and entered "test Wx". Again, some mysterious error message about a missing file (something like "can't copy file ... to ...: file does not exist). "look Wx", in order to unpack the distro, died with the same error. After trying a few times, it finally worked, as it seems CPAN had decided to start afresh. This reinforces the idea that CPAN is the culprit, apparently cleaning up before it even completes building. Eventually, after going through "perl Makefile.PL" and "dmake" manually, "dmake test"... succeeded? So, back in the CPAN shell, I installed it again. I dropped out of CPAN, hopefully typed "padre" and... still nothing.

So I tried one more module: Wx::Demo. (Seriously, guys, the docs of that demo module are seriously lacking. You run the demo through the script it installs:, but I really had to browse the repository to figure that out.) Anyway: the demos all worked. (One demo looks like shit: "WxComboCtrl", but that's a problem for another day.)

Back to "padre": still nothing. Okay, debugging time. "perl -x -S padre.bat". Huh, I get an editor window?? "padre"... It works??

It no longer fails. It all works.

Okay, the nightmare is over. It took me nearly 3 hours to get this far. This is not something you want to make everybody go through. And the fault is, most likely, in the module CPAN.

p.s. This post was written using Markdown using Showdown and posted after conversion to HTML.

The Fine Print: The following comments are owned by whoever posted them. We are not responsible for them in any way.
More | Login | Reply
Loading... please wait.
  • So firstly, no guarentees if you have more than one Perl installed... no Perls really live together well.

    Secondly, there's known issues in

    I recommend uninstalling the July strawberry and trying again with the new October release. []

    This has a new (dev) CPAN release that might fix your problem, and some updated Perl modules and C libraries that should (hopefully) make the installation much easier.

    Finally, yes, newbies are not REALL

    • I submit that almost anyone installing strawberry already has a perl, and likely more than 1.

      When I install strawberry, I have activestate, cygwin, and I tried building my own. And after that, I have an old strawberry in front of the new strawberry.

      A prominent set of warnings seems appropriate.

      • The way I solved that is as follows:

        I removed the Strawberry specific paths from the PATH environment variable. I then added an icon in the start menu to launch a console shell (cmd.exe), after prepending these paths to PATH first.

        One easy way to do that, is by making a BAT file with the following contents:

        @echo off
        path C:\strawberry\c\bin;C:\strawberry\perl\bin;%path%

        But an IMHO nicer alternative is to just create a shortcut with this as the target:

        cmd.exe /k PATH=C:\strawberry\c\bin;C:\strawberry\pe

        • I just found there's a padre.exe file in the perl\bin directory, with the same modification time as padre.bat. Apparently they were built together. So that's why it doesn't need a console window...

        • Thanks much! I think I understand, and I will try that.

          In a previous version of strawberry (last one?), when padre tried to update, for me things choked due to failures in the toolchain of padre. Does this likely have to do with the path during the update of padre? (I think that happened before I have the opportunity to intervene...)

          It would be lovely for such advice as yours to be obvious to strawberry perl installers who encounter such problems.

          Thanks again! I love perl, though it can be trying at time

      • One of the things that I ran out of time for in October is checking the path for other perl interpreters and putting up warnings if neccessary ... I'm hoping to get it done for January.

        As for the PATH thing - we put ourselves in the system path because it is an "all-users" installation. (another thing for January that needs to be discussed is the possibility of making "all-users/current-user" selectable.) We DO try to be polite and put ourselves at the end of the system path (and the proposed "current-user"

        The new Strawberry Perl for Windows has been released! Check for it.
        • All this information is good. And thanks for your work on SP, I love the idea.

          But the most important thing I am saying, is when I install SP, it should make obvious some of these issues, right in the faces of the novice installers (like me). I don't use IRC, but I do lurk on useperl.

          Maybe in the last install window, an "open install notes from c:\strawberry\INSTALL_strawberry.txt" checkbox with default checked...

    • It's good to see honest feedback with warts and all and a reasoned response. It's shows good maturity - it would be so easy to fly off the handle with a post like this.

      -- "It's not magic, it's work..."
    • Almost every Windows server I use at work has three Perls installed - Activestate (which we run our code against), Oracle's Perl, and an HP version that comes with its server software. It appears mostly seemless, but it in the bad old days (probably 7-8 years ago), an upgrade of Oracle meant that it's Perl took preference over Activestate's and our code crashed and burned. I'm not sure if this is still an issue.
  • Just to add a little sweetness and light: I haven't used Windows in anger for almost ten years, but logged on to a Vista virtual instance, downloaded the all-in-one Padre+Strawberry msi installer, and everything was up and running in around 5 minutes, complete with a handy shortcut in the Start menu.

    I then typed

    use v10.5;
    say "hello world";

    saved the file, hit F5, and out came the, err "put". Beautiful...

    Congrats, from this perspective, to all involved.

    Now I have to remember how to coax CPAN on Windows to tra