Bug 916917 - uninitialized constant ApplicationState

* Wrong module used to address constant.
* Missing test coverage added
Remove parsing version from cartridge-name
Adding back PHP cart.
Changing to php-5.3 to get rhc app create working.
Updated tests.
Updated feature test.
WIP Cartridge Refactor - Add OPENSHIFT_{CartridgeShortName}_DIR

* Create environment variable when creating cartridge instance
Add simple v2 app builds
Add test for v2 tidy
Temporarily removing new php cart
Merge pull request #1504 from jwhonce/wip/master

Merged by openshift-bot
Merge pull request #1506 from pmorie/dev/cartridge_refactor

Merged by openshift-bot
Merge branch 'master' into scl-fixes-1