1、在ports中查找:
方法,进入ports中相应的目录后,然后执行下面的命令:
make run-depends-list : 查看运行时的依赖包
make build-depends-list : 编译时的依赖包
make all-depends-list : 列出所有的依赖包,包含依赖包的依赖包,以及依赖包的依赖包的依赖包……
例:
hu@mm:/usr/ports/devel/php53-json % make all-depends-list
/usr/ports/lang/php53
/usr/ports/devel/autoconf
/usr/ports/devel/pcre
/usr/ports/textproc/libxml2
/usr/ports/devel/m4
/usr/ports/misc/help2man
/usr/ports/devel/gmake
/usr/ports/lang/perl5.14
/usr/ports/devel/autoconf-wrapper
/usr/ports/devel/pkgconf
/usr/ports/converters/libiconv
/usr/ports/devel/p5-Locale-gettext
/usr/ports/devel/gettext
hu@mm:/usr/ports/devel/php53-json % make build-depends-list
/usr/ports/devel/autoconf
/usr/ports/lang/php53
hu@mm:/usr/ports/devel/php53-json % make run-depends-list
/usr/ports/lang/php53
hu@mm:/usr/ports/devel/php53-json %
2、pkg info法(FreeBSD10.0以上)
pkg info查看包依赖,必须是已经安装的包,没有安装的不能查看
# pkg info -d php53-json
php53-json-5.3.28:
php53-5.3.28
3、pkg query(FreeBSD10.0以上)
# pkg query "%dn-%dv" php53-json
php53-5.3.28
总结:详细的依赖,特别是看依赖的依赖,最好还是到ports中吧。
该贴被wulcan编辑于2014-7-22 20:25:14
该贴由hui.chen转至本版2014-11-5 17:04:56