IDE for Strawberry Perl for Windows

Padre makes a great IDE for Strawberry Perl.

[Originally posted 2016 May 8, updated 2019 March 13]

I had been looking for a Perl IDE to use with Strawberry Perl on my main Windows machine. Years ago I had used Eclipse PDE, but I was looking for something else. Padre seemed ideal, but the installation was based on its own perl environment, whereas I already had Strawberry Perl installed. Fortunately I found some alternative instructions for this.

http://padre.perlide.org/download/strawberryperl.html

Unfortunately installation did have some challenges as neither the Padre website or cpan modules have been updated since 2013.

https://metacpan.org/changes/distribution/Padre

(through there are recent bug fixes at the official Padre Github)

https://github.com/PadreIDE/Padre

First install Strawberry Perl for Windows (currently v5.28.1)

http://strawberryperl.com/

Install the Padre prerequisites. This will take a long time, so be patient. I found that some of them would not install as some of their tests failed; using the force option bypassed these.

C:\> cpanm Alien::wxWidgets 
C:\> cpanm Wx --force
C:\> cpanm ORLite::Migrate --force

Install Padre

c:\> cpanm Padre --force

There are a few known issues with the version in cpan.

Test run using

C:\strawberry\perl\site\bin\padre.bat
Malformed UTF-8 character: \xe0\x20\x6c (unexpected non-continuation byte 0x20, immediately after start byte 0xe0; need 3 bytes, got 1) at C:/Apps/Strawberry/perl/site/lib/Padre/Wx/Main.pm line 5564. 
Malformed UTF-8 character (fatal) at C:/Apps/Strawberry/perl/site/lib/Padre/Wx/Main.pm line 5564.
Compilation failed in require at C:/Apps/Strawberry/perl/site/lib/Padre/Wx/App.pm line 58.
Perl exited with active threads:
1 running and unjoined
0 finished and unjoined
0 running and detached

This is fixed by commit a3df4d7b8a765f1d0303410cdc686d4bf8adabdc

https://github.com/PadreIDE/Padre/commit/a3df4d7b8a765f1d0303410cdc686d4bf8adabdc

In C:\Strawberry\perl\site\lib\Padre\Wx\Main.pm, remove the Read-Only file attribute and change line 5564 which contains an invalid Uni-code character (à). Change this to a regular character (a).

Join current line with next one (à la B<vi> with C<Ctrl+J>). No return value.

Testing again gives

DBD::SQLite::db do failed: Safety level may not be changed inside a transaction at (eval 1954) line 37. 
Perl exited with active threads:
1 running and unjoined
0 finished and unjoined
0 running and detached

This is a known problem fixed by commit a9fb73f6b0ba76370f60300edfaf03f50e8326e0

https://stackoverflow.com/questions/34787579/padre-complains-about-an-sqlite-database-issue

https://github.com/DBD-SQLite/DBD-SQLite/issues/10

https://github.com/PadreIDE/Padre/commit/a9fb73f6b0ba76370f60300edfaf03f50e8326e0#diff-13b15178914b37760864cbbc3c935b6d

In C:\Strawberry\perl\site\lib\Padre\Locker.pm, remove the Read-Only file attribute and move line 105 after line 113.

sub db_increment {
my $self = shift;
unless ( $self->{db_depth}++ ) {
Padre::DB->begin;
# ...
Padre::DB->pragma( synchronous => 0 );
}
return;
}

to:

sub db_increment {
my $self = shift;
unless ( $self->{db_depth}++ ) {
#...
Padre::DB->pragma( synchronous => 0 );
Padre::DB->begin;
}
return;
}

Create a desktop shortcut with

Target: C:\Strawberry\perl\site\bin\padre.exe
Start in: C:\Strawberry\perl\site\bin

The IDE should now start by double clicking the shortcut.

Happy coding.

2,092 views

Need help? Let me take care of your IT issues.

Share this page

Scroll to Top