# How to install OS/X remotely

*The following was passed to me verbatim by a professor in my area.*   
*I haven’t tried it yet myself.*

How to install <span class="caps">OSX</span> software remotely:

- [http://www.hmug.org/HowTos/RemoteInstall.html](http://www.hmug.org/HowTos/RemoteInstall.html)

To update <span class="caps">OSX</span> remotely:

- [http://www.hmug.org/HowTos/RemoteSysUpdate.html](http://www.hmug.org/HowTos/RemoteSysUpdate.html)

For example, how to install xcode and perl remotely on <span class="caps">OSX</span>:

1\. <span class="caps">GCC</span>

If you need to build several programs from source, you need a compiler.  
On <span class="caps">OSX</span>, the development environment is called xcode and can be  
downloaded from [http://developer.apple.com/tools/download/](http://developer.apple.com/tools/download/) — I had to  
sign up for a free account first. To install the dmg remotely (see  
detailed instructions at [http://www.hmug.org/HowTos/RemoteInstall.html](http://www.hmug.org/HowTos/RemoteInstall.html)),  
log on to the <span class="caps">OSX</span> machine and issue

hdiutil mount xcode\_2.4.1\_8m1910\_6936315.dmgcd /Volumes/Xcode\\ Toolssudo installer -verbose -pkg XcodeTools.mpkg -target /cdhdiutil unmount /Volumes/X\*You now have a build environment with gcc (3.3 and 4.0 in my case).

2\. Perl

If you need a more recent verson of perl than what is included in <span class="caps">OSX</span>,  
you can get the latest stable version, currently 5.8.8 (cf.  
[http://www.perl.com/download.csp):](http://www.perl.com/download.csp):)

mkdir -p ~/src/perl (tilde comes before /src/perl)cd ~/src/perl (tilde comes before /src/perl)wget [http://www.perl.com/](http://www.perl.com/)<span class="caps" id="bkmrk-cpan">CPAN</span>/src/stable.tar.gztar zxvf stable.tar.gzcd perl-5.8.8./configureThis is a lengthy process — select defaults where possible, and say yes  
to “Use the PerlIO abstraction layer.” I also said yes to threading, but  
this may not be advisable. I accepted the default prefix, /usr/local.  
Once configured,

makemake testIf it checks out (I got a syslog error, likely because <span class="caps">OSX</span> uses  
/var/log/system.log, which I ignored), you may want to switch to root  
user before you install:

sudo bashmake installNext, if you’re using the bash shell, edit /etc/profile and add  
/usr/local/bin to the <span class="caps">PATH</span> before /usr/bin. Issue

source /etc/profileor, if you’re on the <span class="caps">OSX</span> machine, exit your user and log back in. Verify  
that your default perl is your freshly compiled one:

which perlshould give you “/usr/local/bin/perl” and not “/usr/bin/perl”.

Incidentally, one problem with installing stuff remotely on <span class="caps">OSX</span> is that  
the system keeps going to sleep on you; I use the wakeonlan program in  
Linux to keep it awake.