add recipe2buildtype function, use it in expanddeps