note
kcott
<p>G'day [elef],</p>
<blockquote><em>
"... they may require some other software or installing a different version of perl instead of using the preinstalled version."
</em></blockquote>
<p>
Firstly, don't modify the Mac OS X System Perl in any way.
Apple installs its own version of Perl for its own use.
Any changes you make can interfere with how this works;
any updates to the Mac can interfere with whatever you've done.
</p>
<p>
I started using a Mac a couple of years ago and asked "[924320|Are there any major Perl issues with Mac OS X Lion?]".
That may be a little dated now and you could be working on a different version;
however, I believe the basic information is still sound.
I chose the <c>perlbrew</c> option: it's worked without problems with many versions of Perl.
See [http://search.cpan.org/perldoc?App%3A%3Aperlbrew|App::perlbrew] for installation and [http://search.cpan.org/perldoc?perlbrew|perlbrew] for command details.
</p>
<blockquote><em>
"The big question is whether the same thing can be done on OS X."
</em></blockquote>
<p>
I'm using Perl v5.18.1 and have [http://search.cpan.org/dist/Tk/|Tk] v804.031 installed (the latest versions in both cases).
I just installed [http://search.cpan.org/~rschupp/PAR-Packer-1.015/lib/PAR/Packer.pm|PAR::Packer v1.015] without incident.
</p>
<p>
I wrote this short test script (<c>pm_test_pp_tk.pl</c>) and tested it successfully:
</p>
<code>
#!/usr/bin/env perl
use strict;
use warnings;
use Tk;
my $mw = MainWindow->new;
my $frame = $mw->Frame->pack;
$frame->Label(-text => 'Hello, world!')->pack;
$frame->Button(-text => 'Quit', -command => sub { exit })->pack;
MainLoop;
</code>
<p>I then used [http://search.cpan.org/perldoc?pp|pp]:</p>
<code>
$ pp -o pm_test_pp_tk.exe pm_test_pp_tk.pl
</code>
<p>I successfully tested <c>pm_test_pp_tk.exe</c>.</p>
<p>You may already be aware that there's a substantial difference in the sizes of those files:</p>
<code>
$ ls -l pm_test_pp_tk.*
-rwxr-xr-x 1 ken staff 6893413 22 Nov 12:13 pm_test_pp_tk.exe
-rwxr-xr-x 1 ken staff 238 22 Nov 12:10 pm_test_pp_tk.pl
</code>
<p>
I leave testing with [http://search.cpan.org/perldoc?DBI|DBI], and any other modules you might need, as an exercise for your good self.
</p>
<!-- Node text goes above. Div tags should contain sig only -->
<div class="pmsig"><div class="pmsig-861371">
<p>-- Ken</p>
</div></div>
1063705
1063705