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.
as_pkg_dependencies(x)A logical scalar, character string of "all", "most",
"hard" or "soft", NA or a vector of dependency types.