Results 1 to 1 of 1
Hi,
I am creating a binary RPM and I have a requirement of printing custom messages to STDOUT in case when there is a package dependency check failure.
1. I ...
- 09-22-2008 #1Just Joined!
- Join Date
- Sep 2008
- Posts
- 1
RPM: Package dependency check failure
Hi,
I am creating a binary RPM and I have a requirement of printing custom messages to STDOUT in case when there is a package dependency check failure.
1. I used “Requires: ” tag which successfully verifies the given package
availability and exits with standard “Failed dependency” error messages in
case of verification failure.
Is there a way to print my custom messages along with RPM error msgs in
this scenario?
2. Alternatively, I wrote a script which performs the package dependency
verification (functionally similar to Requires tag) and print the custom
message in case of dependency failure. The problem is, the RPM
installation does not ABORT/exit when package dependency check fails. It
proceeds with RPM installation. I am using bash “exit 0 or exit” in the
script. This script is placed in “%pre” of RPM spec file.
3. In case when “exit 1” <or any non-zero> is used, the installation aborts,
but with following un-desirable RPM error is written to STDOUT
error: %pre(grs-1.2a-1.i586) scriptlet failed, exit status 0
error: install: %pre scriptlet failed (2), skipping grs-1.2a
Is there a way to gracefully abort the RPM installation without having printed the RPM error messages?
Linux Distro :SUSE
RPM Version: RPM version 4.X
Request for help.
Thank you,
Shridhar


Reply With Quote