Add init.d support and CyanogenMod support