Merge 1.9 to 1.x

I had to resolve conflicts in:
 - engine/classes/ElggUpgrade.php
 - engine/lib/upgrades/2013010400-1.9.0_dev-comments_to_entities-faba94768b055b08.php
 - engine/lib/upgrades/2013022000-1.9.0-datadir_dates_to_guids-efb02ff11b9d6444.php
 - engine/lib/upgrades/2014050600-1.9.0_dev-replies_to_entities-094ea0e36bc027d3.php
 - engine/start.php
 - engine/tests/phpunit/ElggUpgradeTest.php