fix some compile issue emergence and modify the Makefile

Signed-off-by: Le Min <lemin9538@gmail.com>