applypatch and updater from cm-10.2

Change-Id: Id7befb2cbab4bc752f021c86cfaf582ff3c07b45