Generate delayed_job executable based on ActiveSupport version.

* Rails 4 compatibility.
* Refactored version switching into Delayed::Compatibility.