packaging: use 'git am' instead of 'git apply' and 'git commit'.

Signed-off-by: Zhao Chao <zhaochao1984@gmail.com>