PHP 5.3 compatibility for install script

`self` isn't available in closures until >=5.4