【发布时间】:2018-01-29 06:20:16
【问题描述】:
我想创建一个依赖于 github 存储库的 RPM 包。
如果我单独运行此命令:
yum localinstall https://github.com/matthewmueller/giftbox/blob/master/rpm/monit.rpm
它会工作得很好。但是,如果我尝试使其成为 RPM 包的依赖项(使用 FPM),则会出错:
--> Processing Dependency: https://github.com/matthewmueller/giftbox/raw/release-2017-08-21-08-33/rpm/monit.rpm for package: giftbox-2017_08_21_08_33-1.x86_64
--> Finished Dependency Resolution
Error: Package: giftbox-2017_08_21_08_33-1.x86_64 (/giftbox)
Requires: https://github.com/matthewmueller/giftbox/raw/release-2017-08-21-08-33/rpm/monit.rpm
You could try using --skip-broken to work around the problem
You could try running: rpm -Va --nofiles --nodigest
这是我正在运行以生成 RPM 包的命令:
@fpm \
--input-type=dir \
--output-type=rpm \
--name $(NAME) \
--version $(VERSION) \
--architecture x86_64 \
--package "$(DIR)/rpm/$(NAME)-$(VERSION).rpm" \
--rpm-os linux \
--template-scripts \
--after-install "$(DIR)/postinstall.sh" \
--after-upgrade "$(DIR)/postupgrade.sh" \
--before-remove "$(DIR)/preremove.sh" \
--depends "procps" \
--depends "util-linux" \
--depends "initscripts" \
--depends "$(GHBASE)/monit.rpm" \
--force \
"$(DIR)/init.sh"="/etc/init.d/giftbox"
任何帮助将不胜感激。谢谢!
【问题讨论】:
-
您能否尝试使用 --skip-broken 安装软件包。它将排除损坏的包裹。我不确定,但检查一次。
-
我得到了这个:
Packages skipped because of dependency problems: giftbox-2017_08_21_08_33-1.x86_64 from /giftbox这表明它没有安装软件包。 FWIW,软件包没有损坏,它会用 yum localinstall 安装好。似乎 localinstall 正在做一些额外的解决方案。 -
你可以通过谷歌搜索来检查这个包的任何依赖项是否缺失?请确认您尝试安装的天气版本与其他一些软件包一起崩溃。
-
抱歉,这不是包依赖问题。我正在尝试将 rpm 包的 github 链接解析为依赖项。