Added condition to do not install php if it's already installed. Added condition to skip pear upgrade if current version is higher than required.
Added preferred_state attribute to pear installation method.