mirror of
https://github.com/libguestfs/libguestfs.git
synced 2026-03-21 22:53:37 +00:00
daemon: Make gdisk into an optional dependency and optgroup.
Also document that gdisk is a dependency at all.
This fixes commit 956e30effa.
This commit is contained in:
3
README
3
README
@@ -118,6 +118,9 @@ For basic functionality and the C tools:
|
||||
- yajl >= 2 (optional)
|
||||
JSON parser, needed to handle the output of ldmtool.
|
||||
|
||||
- gdisk (optional)
|
||||
For managing some aspects of GPT disks.
|
||||
|
||||
- netpbm, icoutils (optional)
|
||||
These programs are used to render icons from guests.
|
||||
|
||||
|
||||
@@ -27,6 +27,7 @@
|
||||
|
||||
#include "daemon.h"
|
||||
#include "actions.h"
|
||||
#include "optgroups.h"
|
||||
|
||||
GUESTFSD_EXT_CMD(str_parted, parted);
|
||||
GUESTFSD_EXT_CMD(str_sfdisk, sfdisk);
|
||||
@@ -804,6 +805,12 @@ do_part_set_mbr_id (const char *device, int partnum, int idbyte)
|
||||
return 0;
|
||||
}
|
||||
|
||||
int
|
||||
optgroup_gdisk_available (void)
|
||||
{
|
||||
return prog_exists (str_sgdisk);
|
||||
}
|
||||
|
||||
int
|
||||
do_part_set_gpt_type(const char *device, int partnum, const char *guid)
|
||||
{
|
||||
|
||||
@@ -10650,6 +10650,7 @@ group with GUID <diskgroup>." };
|
||||
name = "part_set_gpt_type";
|
||||
style = RErr, [Device "device"; Int "partnum"; String "guid"], [];
|
||||
proc_nr = Some 392;
|
||||
optional = Some "gdisk";
|
||||
tests = [];
|
||||
shortdesc = "set the type GUID of a GPT partition";
|
||||
longdesc = "\
|
||||
@@ -10664,6 +10665,7 @@ for a useful list of type GUIDs." };
|
||||
name = "part_get_gpt_type";
|
||||
style = RString "guid", [Device "device"; Int "partnum"], [];
|
||||
proc_nr = Some 393;
|
||||
optional = Some "gdisk";
|
||||
tests = [
|
||||
InitGPT, Always, TestOutput (
|
||||
[["part_set_gpt_type"; "/dev/sda"; "1";
|
||||
|
||||
Reference in New Issue
Block a user