Added the support of extension with dependencies in the compile script