add support for pkg file require, Fix #7