Enables to find the first package in the path hierarchy.