From 134ac97d22065224e200d6cd72231d116b45f054 Mon Sep 17 00:00:00 2001 From: Pino Toscano Date: Tue, 3 Jun 2014 14:48:51 +0200 Subject: [PATCH] daemon: retire the augeas feature Augeas has been a mandatory dependency of libguestfs for quite some time, so the aug_* functions could have been always called (without even checking the augeas feature). Thus retire the feature, marking it as always available with no more functions depending on it. --- daemon/augeas.c | 6 ------ generator/actions.ml | 16 ---------------- generator/optgroups.ml | 1 + 3 files changed, 1 insertion(+), 22 deletions(-) diff --git a/daemon/augeas.c b/daemon/augeas.c index 04faac9ae..e31cab4e3 100644 --- a/daemon/augeas.c +++ b/daemon/augeas.c @@ -29,12 +29,6 @@ #include "actions.h" #include "optgroups.h" -int -optgroup_augeas_available (void) -{ - return 1; -} - /* The Augeas handle. We maintain a single handle per daemon, which * is all that is necessary and reduces the complexity of the API * considerably. diff --git a/generator/actions.ml b/generator/actions.ml index ed65c6e1e..3bd41f041 100644 --- a/generator/actions.ml +++ b/generator/actions.ml @@ -3472,7 +3472,6 @@ of the L command. The \"full\" version includes all fields." }; name = "aug_init"; style = RErr, [Pathname "root"; Int "flags"], []; proc_nr = Some 16; - optional = Some "augeas"; tests = [ InitBasicFS, Always, TestResultString ( [["mkdir"; "/etc"]; @@ -3538,7 +3537,6 @@ To find out more about Augeas, see L." }; name = "aug_close"; style = RErr, [], []; proc_nr = Some 26; - optional = Some "augeas"; shortdesc = "close the current Augeas handle"; longdesc = "\ Close the current Augeas handle and free up any resources @@ -3550,7 +3548,6 @@ Augeas functions." }; name = "aug_defvar"; style = RInt "nrnodes", [String "name"; OptString "expr"], []; proc_nr = Some 17; - optional = Some "augeas"; shortdesc = "define an Augeas variable"; longdesc = "\ Defines an Augeas variable C whose value is the result @@ -3564,7 +3561,6 @@ C<0> if C evaluates to something which is not a nodeset." }; name = "aug_defnode"; style = RStruct ("nrnodescreated", "int_bool"), [String "name"; String "expr"; String "val"], []; proc_nr = Some 18; - optional = Some "augeas"; shortdesc = "define an Augeas node"; longdesc = "\ Defines a variable C whose value is the result of @@ -3582,7 +3578,6 @@ if a node was created." }; name = "aug_get"; style = RString "val", [String "augpath"], []; proc_nr = Some 19; - optional = Some "augeas"; shortdesc = "look up the value of an Augeas path"; longdesc = "\ Look up the value associated with C. If C @@ -3592,7 +3587,6 @@ matches exactly one node, the C is returned." }; name = "aug_set"; style = RErr, [String "augpath"; String "val"], []; proc_nr = Some 20; - optional = Some "augeas"; tests = [ InitBasicFS, Always, TestResultString ( [["mkdir"; "/etc"]; @@ -3614,7 +3608,6 @@ C call." }; name = "aug_insert"; style = RErr, [String "augpath"; String "label"; Bool "before"], []; proc_nr = Some 21; - optional = Some "augeas"; tests = [ InitBasicFS, Always, TestResultString ( [["mkdir"; "/etc"]; @@ -3642,7 +3635,6 @@ with a bracketed index C<[N]>." }; name = "aug_rm"; style = RInt "nrnodes", [String "augpath"], []; proc_nr = Some 22; - optional = Some "augeas"; shortdesc = "remove an Augeas path"; longdesc = "\ Remove C and all of its children. @@ -3653,7 +3645,6 @@ On success this returns the number of entries which were removed." }; name = "aug_mv"; style = RErr, [String "src"; String "dest"], []; proc_nr = Some 23; - optional = Some "augeas"; shortdesc = "move Augeas node"; longdesc = "\ Move the node C to C. C must match exactly @@ -3663,7 +3654,6 @@ one node. C is overwritten if it exists." }; name = "aug_match"; style = RStringList "matches", [String "augpath"], []; proc_nr = Some 24; - optional = Some "augeas"; shortdesc = "return Augeas nodes which match augpath"; longdesc = "\ Returns a list of paths which match the path expression C. @@ -3674,7 +3664,6 @@ exactly one node in the current tree." }; name = "aug_save"; style = RErr, [], []; proc_nr = Some 25; - optional = Some "augeas"; shortdesc = "write all pending Augeas changes to disk"; longdesc = "\ This writes all pending changes to disk. @@ -3686,7 +3675,6 @@ how files are saved." }; name = "aug_load"; style = RErr, [], []; proc_nr = Some 27; - optional = Some "augeas"; shortdesc = "load files into the tree"; longdesc = "\ Load files into the tree. @@ -3698,7 +3686,6 @@ details." }; name = "aug_ls"; style = RStringList "matches", [String "augpath"], []; proc_nr = Some 28; - optional = Some "augeas"; tests = [ InitBasicFS, Always, TestResult ( [["mkdir"; "/etc"]; @@ -8252,7 +8239,6 @@ group." }; name = "aug_clear"; style = RErr, [String "augpath"], []; proc_nr = Some 239; - optional = Some "augeas"; shortdesc = "clear Augeas path"; longdesc = "\ Set the value associated with C to C. This @@ -11757,7 +11743,6 @@ See also C." }; name = "aug_setm"; style = RInt "nodes", [String "base"; OptString "sub"; String "val"], []; proc_nr = Some 411; - optional = Some "augeas"; tests = [ InitBasicFS, Always, TestResultString ( [["mkdir"; "/etc"]; @@ -11781,7 +11766,6 @@ This returns the number of nodes modified." }; name = "aug_label"; style = RString "label", [String "augpath"], []; proc_nr = Some 412; - optional = Some "augeas"; tests = [ InitBasicFS, Always, TestResultString ( [["mkdir"; "/etc"]; diff --git a/generator/optgroups.ml b/generator/optgroups.ml index d13d79463..1c5bd91a1 100644 --- a/generator/optgroups.ml +++ b/generator/optgroups.ml @@ -27,6 +27,7 @@ open Actions * list of functions. *) let optgroups_retired = [ + "augeas"; "realpath"; ]