Are you looking for my non-technical blog?

This is now my technical-only blog, my non-technical blog is here.

20 January 2013

MacPorts FTW

Being new to Mac OS X, I am still struggling to memorize its different keyboard shortcuts and to make my fingers tell the difference between the command and control button. However, another thing I have been struggling with lately is, installing my favourite python modules on it. I had some problems installing Scipy and Scikit-learn in particular. I gave Homebrew a try among other things, but it came out that MacPorts was the only way to install those modules successfully.

It's simple and straight forward.

Download and install the MacPorts package for your system here.

On the command line, type the following commands
$ sudo port install python
$ sudo port install py-scipy
etc...
You may aso specify a specific version for python to use, so, type 'python27' and 'py27-scipy' instead. For sure you can use it to download hundreds of other packages, see the list here.

If you, like me, messed a bit with your system paths, make sure to have a look at your '.bash_profile', or whatever shell you use, to see if any other paths set by brew are taking precedence or something.

There is also 'sudo port selfupdate' to make sure all you packages are up-to-date. Check the guide for other useful commands here.

No comments:

Post a Comment