livemedia-creator: Check for mkfs.hfsplus

mkfs.hfsplus may not be installed so instead of crashing near the end of
the install check for it and print a useful error message.

Resolves: rhbz#1969743
This commit is contained in:
Brian C. Lane 2021-06-09 15:48:35 -07:00
parent bcf1a491da
commit 5fa949a423
1 changed files with 3 additions and 0 deletions

View File

@ -147,6 +147,9 @@ def main():
if opts.arch != None:
errors.append("RHEL9 only support virt for the host arch.")
if opts.domacboot and not os.path.exists("/usr/sbin/mkfs.hfsplus"):
errors.append("mkfs.hfsplus is missing. Install hfsplus-tools, or pass --nomacboot")
if os.getuid() != 0:
errors.append("You need to run this as root")