Is PERL available on MAC OS ?

First, I don’t even have a MAC. I don’t know anything about MACs and how they can get access to additional software.

I’m working on a project that involves writing some code in PERL which is supposed to run on a MAC and do basic serial I/O. I suppose I could install PERL modules with CPAN as usual. I don’t have physical access to it and do my coding on linux.

In case PERL is not already part of mac os, how would I go about installing it ? Or more precisely how would I explain ‘the other guy’ how to load PERL on his machine ?

AFAIK, yes, modern apple os's come packaged with perl. The install may be broken, however... =)

http://www.theregister.co.uk/2009/02/16/apple_update_perl_breakage/

!c

imac:~ jdw$ which perl
/usr/bin/perl
imac:~ jdw$

It's standard equipment, and it works fine for me.

-j

Super!

Then not much can go wrong :-)

There is also a "package manager" for Mac called "Fink" (and a GUI "Fink Commander") that allows you to install (from source or binaries) many linux/unix open source software packages on Mac. (You probably first have to install the "development tools", which are free from Apple...)

If you want to install CPAN stuff, you will need the (free) developer tools (called XCode) from Apple. I don't think I've used CPAN on OS X, and if I did it was a few years ago on OS X server anyway...

-j

So let me ask another MAC-noob question:

would it be fair to assume that installing the whole xcode package (or whatever it is called in the MAC world) included essentials like “make”, “gcc” and all the C libs ?

I’ve had a little chat with the guy I’m supposed to help out and it seems he so far has not had any contact with console work or coding. So I’ll have to know all the tricks on MAC OS, but I really don’t.

So far I told him to get the compiler working (install Xcode from DVD) and test if cpan starts properly and can install Device::SerialPort without errors. Fortunately PERL is already there.

Have him enable remote login so you can SSH in. :slight_smile:

Yes, Xcode provides gcc, make, and friends.

-j

"all the C libraries" == infintity But XCode provides most of the basics, and all the Mac-specific stuff. (it is notably missing the libraries used do implement pc-like GUI programs under linux, like the GNome libraries and the stuff that those are dependent on. That shouldn't be a surprise. Installing GUI apps can be an exercise in dependency hell, as some innocent-seeming inclusion sucks in all of Ghostscript or TeX or whatever. But you can usually get things to work eventually.)