Implements conventions established by both tools::package_dependencies()
and pkgdepends::as_pkg_dependencies(), following
pkgdepends::as_pkg_dependencies() return type structure of a list
including $direct and $indirect dependency types. Reimplemented to
avoid dependence on pkgdepends compilation requirements.