From d9b4d60317c33dc2bd7ca330aed33acf73f02be3 Mon Sep 17 00:00:00 2001 From: "Richard W.M. Jones" Date: Thu, 20 Jun 2024 12:36:08 +0100 Subject: [PATCH] Remove bundled ocaml-augeas resolves: RHEL-32142 --- ...d-Remove-bundled-copy-of-ocaml-augea.patch | 1686 ----------------- ...atch => 0010-update-common-submodule.patch | 2 +- ...M-inspection-test-rename-VGs-and-LVs.patch | 2 +- ...ection-test-test-dev-mapper-VG-LV-tr.patch | 2 +- ...0013-Replace-Pervasives.-with-Stdlib.patch | 6 +- ...on-t-call-fclose-NULL-on-error-paths.patch | 2 +- ...lose-test-collect-all-currently-unre.patch | 2 +- ...d-enter-leave_blocking_section-calls.patch | 2 +- ...se-runtime-lock-around-guestfs_close.patch | 2 +- ...onally-acquire-the-lock-in-callbacks.patch | 2 +- ...fs_065_implicit_close.ml-for-OCaml-5.patch | 2 +- ...tate_opt-in-preference-to-caml_state.patch | 2 +- ...-Add-chown-option-for-virt-customize.patch | 2 +- ...ve-guestfs_int_cmd_clear_close_files.patch | 2 +- ...ix-broken-link-in-the-guestfs-manual.patch | 2 +- ...24-docs-clarify-sockdir-s-separation.patch | 2 +- ..._int_create_socketname-from-launch.c.patch | 2 +- ...ize-Add-new-StringTriplet-for-use-by.patch | 2 +- ...verse-device-name-translation-on-pvs.patch | 2 +- ...-ruby-Replace-MiniTest-with-Minitest.patch | 2 +- ...t-rid-of-old-Test-Unit-compatibility.patch | 2 +- ...irt-customize-options-into-alphabeti.patch | 2 +- ...-new-virt-customize-tar-in-operation.patch | 2 +- ... 0032-New-mailing-list-email-address.patch | 2 +- ...ch => 0033-New-mailing-list-archives.patch | 10 +- ...de-libxml-parser.h-for-xmlReadMemory.patch | 2 +- ...Gc.finalise-instead-of-a-C-finalizer.patch | 2 +- ...stom-block-before-releasing-runtime-.patch | 2 +- ...atch => 0037-Update-common-submodule.patch | 2 +- ...ts-Test-guestfish-key-all-.-selector.patch | 2 +- ...ize.ml-Split-chown-parameter-on-char.patch | 2 +- ...int-field-we-are-extracting-in-error.patch | 2 +- ...python-Fix-exception-name-in-example.patch | 2 +- ...uestfs-release-notes-historical-to-g.patch | 2 +- ...-translate-and-sed-commands-separate.patch | 2 +- ...atch => 0044-Update-common-submodule.patch | 2 +- ...ure-guestmount.1-depends-on-includes.patch | 2 +- libguestfs.spec | 82 +- 38 files changed, 84 insertions(+), 1768 deletions(-) delete mode 100644 0010-RHEL-Revert-build-Remove-bundled-copy-of-ocaml-augea.patch rename 0011-update-common-submodule.patch => 0010-update-common-submodule.patch (99%) rename 0012-LUKS-on-LVM-inspection-test-rename-VGs-and-LVs.patch => 0011-LUKS-on-LVM-inspection-test-rename-VGs-and-LVs.patch (98%) rename 0013-LUKS-on-LVM-inspection-test-test-dev-mapper-VG-LV-tr.patch => 0012-LUKS-on-LVM-inspection-test-test-dev-mapper-VG-LV-tr.patch (96%) rename 0014-Replace-Pervasives.-with-Stdlib.patch => 0013-Replace-Pervasives.-with-Stdlib.patch (96%) rename 0015-fuse-Don-t-call-fclose-NULL-on-error-paths.patch => 0014-fuse-Don-t-call-fclose-NULL-on-error-paths.patch (96%) rename 0016-ocaml-implicit_close-test-collect-all-currently-unre.patch => 0015-ocaml-implicit_close-test-collect-all-currently-unre.patch (95%) rename 0017-ocaml-Replace-old-enter-leave_blocking_section-calls.patch => 0016-ocaml-Replace-old-enter-leave_blocking_section-calls.patch (97%) rename 0018-ocaml-Release-runtime-lock-around-guestfs_close.patch => 0017-ocaml-Release-runtime-lock-around-guestfs_close.patch (93%) rename 0019-ocaml-Conditionally-acquire-the-lock-in-callbacks.patch => 0018-ocaml-Conditionally-acquire-the-lock-in-callbacks.patch (97%) rename 0020-ocaml-Fix-guestfs_065_implicit_close.ml-for-OCaml-5.patch => 0019-ocaml-Fix-guestfs_065_implicit_close.ml-for-OCaml-5.patch (96%) rename 0021-ocaml-Use-Caml_state_opt-in-preference-to-caml_state.patch => 0020-ocaml-Use-Caml_state_opt-in-preference-to-caml_state.patch (93%) rename 0022-generator-Add-chown-option-for-virt-customize.patch => 0021-generator-Add-chown-option-for-virt-customize.patch (99%) rename 0023-lib-remove-guestfs_int_cmd_clear_close_files.patch => 0022-lib-remove-guestfs_int_cmd_clear_close_files.patch (98%) rename 0024-docs-fix-broken-link-in-the-guestfs-manual.patch => 0023-docs-fix-broken-link-in-the-guestfs-manual.patch (95%) rename 0025-docs-clarify-sockdir-s-separation.patch => 0024-docs-clarify-sockdir-s-separation.patch (98%) rename 0026-lib-move-guestfs_int_create_socketname-from-launch.c.patch => 0025-lib-move-guestfs_int_create_socketname-from-launch.c.patch (98%) rename 0027-generator-customize-Add-new-StringTriplet-for-use-by.patch => 0026-generator-customize-Add-new-StringTriplet-for-use-by.patch (99%) rename 0028-daemon-lvm-Do-reverse-device-name-translation-on-pvs.patch => 0027-daemon-lvm-Do-reverse-device-name-translation-on-pvs.patch (96%) rename 0029-ruby-Replace-MiniTest-with-Minitest.patch => 0028-ruby-Replace-MiniTest-with-Minitest.patch (99%) rename 0030-ruby-Get-rid-of-old-Test-Unit-compatibility.patch => 0029-ruby-Get-rid-of-old-Test-Unit-compatibility.patch (99%) rename 0031-generator-Sort-virt-customize-options-into-alphabeti.patch => 0030-generator-Sort-virt-customize-options-into-alphabeti.patch (96%) rename 0032-generator-Add-new-virt-customize-tar-in-operation.patch => 0031-generator-Add-new-virt-customize-tar-in-operation.patch (99%) rename 0033-New-mailing-list-email-address.patch => 0032-New-mailing-list-email-address.patch (99%) rename 0034-New-mailing-list-archives.patch => 0033-New-mailing-list-archives.patch (98%) rename 0035-lib-Include-libxml-parser.h-for-xmlReadMemory.patch => 0034-lib-Include-libxml-parser.h-for-xmlReadMemory.patch (91%) rename 0036-ocaml-Use-Gc.finalise-instead-of-a-C-finalizer.patch => 0035-ocaml-Use-Gc.finalise-instead-of-a-C-finalizer.patch (98%) rename 0037-ocaml-Nullify-custom-block-before-releasing-runtime-.patch => 0036-ocaml-Nullify-custom-block-before-releasing-runtime-.patch (94%) rename 0038-Update-common-submodule.patch => 0037-Update-common-submodule.patch (98%) rename 0039-tests-Test-guestfish-key-all-.-selector.patch => 0038-tests-Test-guestfish-key-all-.-selector.patch (94%) rename 0040-generator-customize.ml-Split-chown-parameter-on-char.patch => 0039-generator-customize.ml-Split-chown-parameter-on-char.patch (96%) rename 0041-daemon-parted-Print-field-we-are-extracting-in-error.patch => 0040-daemon-parted-Print-field-we-are-extracting-in-error.patch (92%) rename 0042-python-Fix-exception-name-in-example.patch => 0041-python-Fix-exception-name-in-example.patch (93%) rename 0043-po-docs-Rename-guestfs-release-notes-historical-to-g.patch => 0042-po-docs-Rename-guestfs-release-notes-historical-to-g.patch (93%) rename 0044-po-docs-Run-po4a-translate-and-sed-commands-separate.patch => 0043-po-docs-Run-po4a-translate-and-sed-commands-separate.patch (95%) rename 0045-Update-common-submodule.patch => 0044-Update-common-submodule.patch (96%) rename 0046-po-docs-Make-sure-guestmount.1-depends-on-includes.patch => 0045-po-docs-Make-sure-guestmount.1-depends-on-includes.patch (95%) diff --git a/0010-RHEL-Revert-build-Remove-bundled-copy-of-ocaml-augea.patch b/0010-RHEL-Revert-build-Remove-bundled-copy-of-ocaml-augea.patch deleted file mode 100644 index c21130e..0000000 --- a/0010-RHEL-Revert-build-Remove-bundled-copy-of-ocaml-augea.patch +++ /dev/null @@ -1,1686 +0,0 @@ -From 73061a7feafcc0a527d00f6e1e2dee3dc84bc044 Mon Sep 17 00:00:00 2001 -From: "Richard W.M. Jones" -Date: Thu, 2 Mar 2023 10:12:19 +0000 -Subject: [PATCH] RHEL: Revert "build: Remove bundled copy of ocaml-augeas" - -This is temporarily reverted in RHEL 9.3 only until this bug can be -actioned: - - https://bugzilla.redhat.com/show_bug.cgi?id=2168634 - "Request for new RHEL 9.3 package: ocaml-augeas" - -This reverts commit fbf7fe87933ac24dd78362a16117c42e40da4c0f. ---- - .gitignore | 1 + - Makefile.am | 5 +- - bundled/ocaml-augeas/COPYING.LIB | 515 +++++++++++++++++++++++++ - bundled/ocaml-augeas/Makefile.am | 82 ++++ - bundled/ocaml-augeas/augeas-c.c | 579 +++++++++++++++++++++++++++++ - bundled/ocaml-augeas/augeas.README | 8 + - bundled/ocaml-augeas/augeas.ml | 99 +++++ - bundled/ocaml-augeas/augeas.mli | 164 ++++++++ - configure.ac | 1 + - daemon/Makefile.am | 7 +- - docs/guestfs-building.pod | 5 - - docs/guestfs-hacking.pod | 14 + - m4/guestfs-ocaml.m4 | 8 - - ocaml-dep.sh.in | 1 + - 14 files changed, 1472 insertions(+), 17 deletions(-) - create mode 100644 bundled/ocaml-augeas/COPYING.LIB - create mode 100644 bundled/ocaml-augeas/Makefile.am - create mode 100644 bundled/ocaml-augeas/augeas-c.c - create mode 100644 bundled/ocaml-augeas/augeas.README - create mode 100644 bundled/ocaml-augeas/augeas.ml - create mode 100644 bundled/ocaml-augeas/augeas.mli - -diff --git a/.gitignore b/.gitignore -index 00e59fb3..ee5ea74d 100644 ---- a/.gitignore -+++ b/.gitignore -@@ -61,6 +61,7 @@ Makefile.in - /build-aux/snippet/ - /build-aux/test-driver - /build-aux/ylwrap -+/bundled/ocaml-augeas/.depend - /compile - /config.cache - /config.guess -diff --git a/Makefile.am b/Makefile.am -index 59370440..e0a7f084 100644 ---- a/Makefile.am -+++ b/Makefile.am -@@ -35,6 +35,7 @@ SUBDIRS += include lib docs examples - - # The daemon and the appliance. - SUBDIRS += common/mlutils -+SUBDIRS += bundled/ocaml-augeas - SUBDIRS += common/mlpcre - if ENABLE_DAEMON - SUBDIRS += daemon -@@ -214,7 +215,7 @@ dist-hook: docs/C_SOURCE_FILES po/POTFILES - docs/C_SOURCE_FILES: configure.ac - rm -f $@ $@-t - find $(DIST_SUBDIRS) -name '*.[ch]' | \ -- grep -v -E '^(builder/index-parse\.|builder/index-scan\.|examples/|gobject/|java/com_redhat_et_libguestfs|perl/|php/extension/config\.h|ruby/ext/guestfs/extconf\.h|tests/|test-data/)' | \ -+ grep -v -E '^(builder/index-parse\.|builder/index-scan\.|examples/|gobject/|java/com_redhat_et_libguestfs|perl/|php/extension/config\.h|ruby/ext/guestfs/extconf\.h|tests/|test-data/|bundled/)' | \ - grep -v -E '/(guestfs|rc)_protocol\.' | \ - grep -v -E '.*/errnostring\.' | \ - grep -v -E '.*-gperf\.' | \ -@@ -227,7 +228,7 @@ po/POTFILES: configure.ac - rm -f $@ $@-t - cd $(srcdir); \ - find $(DIST_SUBDIRS) -name '*.c' | \ -- grep -v -E '^(examples|perl/(blib|examples)|po-docs|tests|test-data)/' | \ -+ grep -v -E '^(examples|perl/(blib|examples)|po-docs|tests|test-data|bundled)/' | \ - grep -v -E '/((guestfs|rc)_protocol\.c|dummy\.c)$$' | \ - grep -v -E '^python/utils\.c$$' | \ - grep -v -E '^perl/lib/Sys/Guestfs\.c$$' | \ -diff --git a/bundled/ocaml-augeas/COPYING.LIB b/bundled/ocaml-augeas/COPYING.LIB -new file mode 100644 -index 00000000..ba2be481 ---- /dev/null -+++ b/bundled/ocaml-augeas/COPYING.LIB -@@ -0,0 +1,515 @@ -+ -+ GNU LESSER GENERAL PUBLIC LICENSE -+ Version 2.1, February 1999 -+ -+ Copyright (C) 1991, 1999 Free Software Foundation, Inc. -+ 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA -+ Everyone is permitted to copy and distribute verbatim copies -+ of this license document, but changing it is not allowed. -+ -+[This is the first released version of the Lesser GPL. It also counts -+ as the successor of the GNU Library Public License, version 2, hence -+ the version number 2.1.] -+ -+ Preamble -+ -+ The licenses for most software are designed to take away your -+freedom to share and change it. By contrast, the GNU General Public -+Licenses are intended to guarantee your freedom to share and change -+free software--to make sure the software is free for all its users. -+ -+ This license, the Lesser General Public License, applies to some -+specially designated software packages--typically libraries--of the -+Free Software Foundation and other authors who decide to use it. You -+can use it too, but we suggest you first think carefully about whether -+this license or the ordinary General Public License is the better -+strategy to use in any particular case, based on the explanations -+below. -+ -+ When we speak of free software, we are referring to freedom of use, -+not price. Our General Public Licenses are designed to make sure that -+you have the freedom to distribute copies of free software (and charge -+for this service if you wish); that you receive source code or can get -+it if you want it; that you can change the software and use pieces of -+it in new free programs; and that you are informed that you can do -+these things. -+ -+ To protect your rights, we need to make restrictions that forbid -+distributors to deny you these rights or to ask you to surrender these -+rights. These restrictions translate to certain responsibilities for -+you if you distribute copies of the library or if you modify it. -+ -+ For example, if you distribute copies of the library, whether gratis -+or for a fee, you must give the recipients all the rights that we gave -+you. You must make sure that they, too, receive or can get the source -+code. If you link other code with the library, you must provide -+complete object files to the recipients, so that they can relink them -+with the library after making changes to the library and recompiling -+it. And you must show them these terms so they know their rights. -+ -+ We protect your rights with a two-step method: (1) we copyright the -+library, and (2) we offer you this license, which gives you legal -+permission to copy, distribute and/or modify the library. -+ -+ To protect each distributor, we want to make it very clear that -+there is no warranty for the free library. Also, if the library is -+modified by someone else and passed on, the recipients should know -+that what they have is not the original version, so that the original -+author's reputation will not be affected by problems that might be -+introduced by others. -+^L -+ Finally, software patents pose a constant threat to the existence of -+any free program. We wish to make sure that a company cannot -+effectively restrict the users of a free program by obtaining a -+restrictive license from a patent holder. Therefore, we insist that -+any patent license obtained for a version of the library must be -+consistent with the full freedom of use specified in this license. -+ -+ Most GNU software, including some libraries, is covered by the -+ordinary GNU General Public License. This license, the GNU Lesser -+General Public License, applies to certain designated libraries, and -+is quite different from the ordinary General Public License. We use -+this license for certain libraries in order to permit linking those -+libraries into non-free programs. -+ -+ When a program is linked with a library, whether statically or using -+a shared library, the combination of the two is legally speaking a -+combined work, a derivative of the original library. The ordinary -+General Public License therefore permits such linking only if the -+entire combination fits its criteria of freedom. The Lesser General -+Public License permits more lax criteria for linking other code with -+the library. -+ -+ We call this license the "Lesser" General Public License because it -+does Less to protect the user's freedom than the ordinary General -+Public License. It also provides other free software developers Less -+of an advantage over competing non-free programs. These disadvantages -+are the reason we use the ordinary General Public License for many -+libraries. However, the Lesser license provides advantages in certain -+special circumstances. -+ -+ For example, on rare occasions, there may be a special need to -+encourage the widest possible use of a certain library, so that it -+becomes -+a de-facto standard. To achieve this, non-free programs must be -+allowed to use the library. A more frequent case is that a free -+library does the same job as widely used non-free libraries. In this -+case, there is little to gain by limiting the free library to free -+software only, so we use the Lesser General Public License. -+ -+ In other cases, permission to use a particular library in non-free -+programs enables a greater number of people to use a large body of -+free software. For example, permission to use the GNU C Library in -+non-free programs enables many more people to use the whole GNU -+operating system, as well as its variant, the GNU/Linux operating -+system. -+ -+ Although the Lesser General Public License is Less protective of the -+users' freedom, it does ensure that the user of a program that is -+linked with the Library has the freedom and the wherewithal to run -+that program using a modified version of the Library. -+ -+ The precise terms and conditions for copying, distribution and -+modification follow. Pay close attention to the difference between a -+"work based on the library" and a "work that uses the library". The -+former contains code derived from the library, whereas the latter must -+be combined with the library in order to run. -+^L -+ GNU LESSER GENERAL PUBLIC LICENSE -+ TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION -+ -+ 0. This License Agreement applies to any software library or other -+program which contains a notice placed by the copyright holder or -+other authorized party saying it may be distributed under the terms of -+this Lesser General Public License (also called "this License"). -+Each licensee is addressed as "you". -+ -+ A "library" means a collection of software functions and/or data -+prepared so as to be conveniently linked with application programs -+(which use some of those functions and data) to form executables. -+ -+ The "Library", below, refers to any such software library or work -+which has been distributed under these terms. A "work based on the -+Library" means either the Library or any derivative work under -+copyright law: that is to say, a work containing the Library or a -+portion of it, either verbatim or with modifications and/or translated -+straightforwardly into another language. (Hereinafter, translation is -+included without limitation in the term "modification".) -+ -+ "Source code" for a work means the preferred form of the work for -+making modifications to it. For a library, complete source code means -+all the source code for all modules it contains, plus any associated -+interface definition files, plus the scripts used to control -+compilation -+and installation of the library. -+ -+ Activities other than copying, distribution and modification are not -+covered by this License; they are outside its scope. The act of -+running a program using the Library is not restricted, and output from -+such a program is covered only if its contents constitute a work based -+on the Library (independent of the use of the Library in a tool for -+writing it). Whether that is true depends on what the Library does -+and what the program that uses the Library does. -+ -+ 1. You may copy and distribute verbatim copies of the Library's -+complete source code as you receive it, in any medium, provided that -+you conspicuously and appropriately publish on each copy an -+appropriate copyright notice and disclaimer of warranty; keep intact -+all the notices that refer to this License and to the absence of any -+warranty; and distribute a copy of this License along with the -+Library. -+ -+ You may charge a fee for the physical act of transferring a copy, -+and you may at your option offer warranty protection in exchange for a -+fee. -+ -+ 2. You may modify your copy or copies of the Library or any portion -+of it, thus forming a work based on the Library, and copy and -+distribute such modifications or work under the terms of Section 1 -+above, provided that you also meet all of these conditions: -+ -+ a) The modified work must itself be a software library. -+ -+ b) You must cause the files modified to carry prominent notices -+ stating that you changed the files and the date of any change. -+ -+ c) You must cause the whole of the work to be licensed at no -+ charge to all third parties under the terms of this License. -+ -+ d) If a facility in the modified Library refers to a function or a -+ table of data to be supplied by an application program that uses -+ the facility, other than as an argument passed when the facility -+ is invoked, then you must make a good faith effort to ensure that, -+ in the event an application does not supply such function or -+ table, the facility still operates, and performs whatever part of -+ its purpose remains meaningful. -+ -+ (For example, a function in a library to compute square roots has -+ a purpose that is entirely well-defined independent of the -+ application. Therefore, Subsection 2d requires that any -+ application-supplied function or table used by this function must -+ be optional: if the application does not supply it, the square -+ root function must still compute square roots.) -+ -+These requirements apply to the modified work as a whole. If -+identifiable sections of that work are not derived from the Library, -+and can be reasonably considered independent and separate works in -+themselves, then this License, and its terms, do not apply to those -+sections when you distribute them as separate works. But when you -+distribute the same sections as part of a whole which is a work based -+on the Library, the distribution of the whole must be on the terms of -+this License, whose permissions for other licensees extend to the -+entire whole, and thus to each and every part regardless of who wrote -+it. -+ -+Thus, it is not the intent of this section to claim rights or contest -+your rights to work written entirely by you; rather, the intent is to -+exercise the right to control the distribution of derivative or -+collective works based on the Library. -+ -+In addition, mere aggregation of another work not based on the Library -+with the Library (or with a work based on the Library) on a volume of -+a storage or distribution medium does not bring the other work under -+the scope of this License. -+ -+ 3. You may opt to apply the terms of the ordinary GNU General Public -+License instead of this License to a given copy of the Library. To do -+this, you must alter all the notices that refer to this License, so -+that they refer to the ordinary GNU General Public License, version 2, -+instead of to this License. (If a newer version than version 2 of the -+ordinary GNU General Public License has appeared, then you can specify -+that version instead if you wish.) Do not make any other change in -+these notices. -+^L -+ Once this change is made in a given copy, it is irreversible for -+that copy, so the ordinary GNU General Public License applies to all -+subsequent copies and derivative works made from that copy. -+ -+ This option is useful when you wish to copy part of the code of -+the Library into a program that is not a library. -+ -+ 4. You may copy and distribute the Library (or a portion or -+derivative of it, under Section 2) in object code or executable form -+under the terms of Sections 1 and 2 above provided that you accompany -+it with the complete corresponding machine-readable source code, which -+must be distributed under the terms of Sections 1 and 2 above on a -+medium customarily used for software interchange. -+ -+ If distribution of object code is made by offering access to copy -+from a designated place, then offering equivalent access to copy the -+source code from the same place satisfies the requirement to -+distribute the source code, even though third parties are not -+compelled to copy the source along with the object code. -+ -+ 5. A program that contains no derivative of any portion of the -+Library, but is designed to work with the Library by being compiled or -+linked with it, is called a "work that uses the Library". Such a -+work, in isolation, is not a derivative work of the Library, and -+therefore falls outside the scope of this License. -+ -+ However, linking a "work that uses the Library" with the Library -+creates an executable that is a derivative of the Library (because it -+contains portions of the Library), rather than a "work that uses the -+library". The executable is therefore covered by this License. -+Section 6 states terms for distribution of such executables. -+ -+ When a "work that uses the Library" uses material from a header file -+that is part of the Library, the object code for the work may be a -+derivative work of the Library even though the source code is not. -+Whether this is true is especially significant if the work can be -+linked without the Library, or if the work is itself a library. The -+threshold for this to be true is not precisely defined by law. -+ -+ If such an object file uses only numerical parameters, data -+structure layouts and accessors, and small macros and small inline -+functions (ten lines or less in length), then the use of the object -+file is unrestricted, regardless of whether it is legally a derivative -+work. (Executables containing this object code plus portions of the -+Library will still fall under Section 6.) -+ -+ Otherwise, if the work is a derivative of the Library, you may -+distribute the object code for the work under the terms of Section 6. -+Any executables containing that work also fall under Section 6, -+whether or not they are linked directly with the Library itself. -+^L -+ 6. As an exception to the Sections above, you may also combine or -+link a "work that uses the Library" with the Library to produce a -+work containing portions of the Library, and distribute that work -+under terms of your choice, provided that the terms permit -+modification of the work for the customer's own use and reverse -+engineering for debugging such modifications. -+ -+ You must give prominent notice with each copy of the work that the -+Library is used in it and that the Library and its use are covered by -+this License. You must supply a copy of this License. If the work -+during execution displays copyright notices, you must include the -+copyright notice for the Library among them, as well as a reference -+directing the user to the copy of this License. Also, you must do one -+of these things: -+ -+ a) Accompany the work with the complete corresponding -+ machine-readable source code for the Library including whatever -+ changes were used in the work (which must be distributed under -+ Sections 1 and 2 above); and, if the work is an executable linked -+ with the Library, with the complete machine-readable "work that -+ uses the Library", as object code and/or source code, so that the -+ user can modify the Library and then relink to produce a modified -+ executable containing the modified Library. (It is understood -+ that the user who changes the contents of definitions files in the -+ Library will not necessarily be able to recompile the application -+ to use the modified definitions.) -+ -+ b) Use a suitable shared library mechanism for linking with the -+ Library. A suitable mechanism is one that (1) uses at run time a -+ copy of the library already present on the user's computer system, -+ rather than copying library functions into the executable, and (2) -+ will operate properly with a modified version of the library, if -+ the user installs one, as long as the modified version is -+ interface-compatible with the version that the work was made with. -+ -+ c) Accompany the work with a written offer, valid for at -+ least three years, to give the same user the materials -+ specified in Subsection 6a, above, for a charge no more -+ than the cost of performing this distribution. -+ -+ d) If distribution of the work is made by offering access to copy -+ from a designated place, offer equivalent access to copy the above -+ specified materials from the same place. -+ -+ e) Verify that the user has already received a copy of these -+ materials or that you have already sent this user a copy. -+ -+ For an executable, the required form of the "work that uses the -+Library" must include any data and utility programs needed for -+reproducing the executable from it. However, as a special exception, -+the materials to be distributed need not include anything that is -+normally distributed (in either source or binary form) with the major -+components (compiler, kernel, and so on) of the operating system on -+which the executable runs, unless that component itself accompanies -+the executable. -+ -+ It may happen that this requirement contradicts the license -+restrictions of other proprietary libraries that do not normally -+accompany the operating system. Such a contradiction means you cannot -+use both them and the Library together in an executable that you -+distribute. -+^L -+ 7. You may place library facilities that are a work based on the -+Library side-by-side in a single library together with other library -+facilities not covered by this License, and distribute such a combined -+library, provided that the separate distribution of the work based on -+the Library and of the other library facilities is otherwise -+permitted, and provided that you do these two things: -+ -+ a) Accompany the combined library with a copy of the same work -+ based on the Library, uncombined with any other library -+ facilities. This must be distributed under the terms of the -+ Sections above. -+ -+ b) Give prominent notice with the combined library of the fact -+ that part of it is a work based on the Library, and explaining -+ where to find the accompanying uncombined form of the same work. -+ -+ 8. You may not copy, modify, sublicense, link with, or distribute -+the Library except as expressly provided under this License. Any -+attempt otherwise to copy, modify, sublicense, link with, or -+distribute the Library is void, and will automatically terminate your -+rights under this License. However, parties who have received copies, -+or rights, from you under this License will not have their licenses -+terminated so long as such parties remain in full compliance. -+ -+ 9. You are not required to accept this License, since you have not -+signed it. However, nothing else grants you permission to modify or -+distribute the Library or its derivative works. These actions are -+prohibited by law if you do not accept this License. Therefore, by -+modifying or distributing the Library (or any work based on the -+Library), you indicate your acceptance of this License to do so, and -+all its terms and conditions for copying, distributing or modifying -+the Library or works based on it. -+ -+ 10. Each time you redistribute the Library (or any work based on the -+Library), the recipient automatically receives a license from the -+original licensor to copy, distribute, link with or modify the Library -+subject to these terms and conditions. You may not impose any further -+restrictions on the recipients' exercise of the rights granted herein. -+You are not responsible for enforcing compliance by third parties with -+this License. -+^L -+ 11. If, as a consequence of a court judgment or allegation of patent -+infringement or for any other reason (not limited to patent issues), -+conditions are imposed on you (whether by court order, agreement or -+otherwise) that contradict the conditions of this License, they do not -+excuse you from the conditions of this License. If you cannot -+distribute so as to satisfy simultaneously your obligations under this -+License and any other pertinent obligations, then as a consequence you -+may not distribute the Library at all. For example, if a patent -+license would not permit royalty-free redistribution of the Library by -+all those who receive copies directly or indirectly through you, then -+the only way you could satisfy both it and this License would be to -+refrain entirely from distribution of the Library. -+ -+If any portion of this section is held invalid or unenforceable under -+any particular circumstance, the balance of the section is intended to -+apply, and the section as a whole is intended to apply in other -+circumstances. -+ -+It is not the purpose of this section to induce you to infringe any -+patents or other property right claims or to contest validity of any -+such claims; this section has the sole purpose of protecting the -+integrity of the free software distribution system which is -+implemented by public license practices. Many people have made -+generous contributions to the wide range of software distributed -+through that system in reliance on consistent application of that -+system; it is up to the author/donor to decide if he or she is willing -+to distribute software through any other system and a licensee cannot -+impose that choice. -+ -+This section is intended to make thoroughly clear what is believed to -+be a consequence of the rest of this License. -+ -+ 12. If the distribution and/or use of the Library is restricted in -+certain countries either by patents or by copyrighted interfaces, the -+original copyright holder who places the Library under this License -+may add an explicit geographical distribution limitation excluding those -+countries, so that distribution is permitted only in or among -+countries not thus excluded. In such case, this License incorporates -+the limitation as if written in the body of this License. -+ -+ 13. The Free Software Foundation may publish revised and/or new -+versions of the Lesser General Public License from time to time. -+Such new versions will be similar in spirit to the present version, -+but may differ in detail to address new problems or concerns. -+ -+Each version is given a distinguishing version number. If the Library -+specifies a version number of this License which applies to it and -+"any later version", you have the option of following the terms and -+conditions either of that version or of any later version published by -+the Free Software Foundation. If the Library does not specify a -+license version number, you may choose any version ever published by -+the Free Software Foundation. -+^L -+ 14. If you wish to incorporate parts of the Library into other free -+programs whose distribution conditions are incompatible with these, -+write to the author to ask for permission. For software which is -+copyrighted by the Free Software Foundation, write to the Free -+Software Foundation; we sometimes make exceptions for this. Our -+decision will be guided by the two goals of preserving the free status -+of all derivatives of our free software and of promoting the sharing -+and reuse of software generally. -+ -+ NO WARRANTY -+ -+ 15. BECAUSE THE LIBRARY IS LICENSED FREE OF CHARGE, THERE IS NO -+WARRANTY FOR THE LIBRARY, TO THE EXTENT PERMITTED BY APPLICABLE LAW. -+EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR -+OTHER PARTIES PROVIDE THE LIBRARY "AS IS" WITHOUT WARRANTY OF ANY -+KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE -+IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR -+PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE -+LIBRARY IS WITH YOU. SHOULD THE LIBRARY PROVE DEFECTIVE, YOU ASSUME -+THE COST OF ALL NECESSARY SERVICING, REPAIR OR CORRECTION. -+ -+ 16. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN -+WRITING WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY -+AND/OR REDISTRIBUTE THE LIBRARY AS PERMITTED ABOVE, BE LIABLE TO YOU -+FOR DAMAGES, INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR -+CONSEQUENTIAL DAMAGES ARISING OUT OF THE USE OR INABILITY TO USE THE -+LIBRARY (INCLUDING BUT NOT LIMITED TO LOSS OF DATA OR DATA BEING -+RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD PARTIES OR A -+FAILURE OF THE LIBRARY TO OPERATE WITH ANY OTHER SOFTWARE), EVEN IF -+SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH -+DAMAGES. -+ -+ END OF TERMS AND CONDITIONS -+^L -+ How to Apply These Terms to Your New Libraries -+ -+ If you develop a new library, and you want it to be of the greatest -+possible use to the public, we recommend making it free software that -+everyone can redistribute and change. You can do so by permitting -+redistribution under these terms (or, alternatively, under the terms -+of the ordinary General Public License). -+ -+ To apply these terms, attach the following notices to the library. -+It is safest to attach them to the start of each source file to most -+effectively convey the exclusion of warranty; and each file should -+have at least the "copyright" line and a pointer to where the full -+notice is found. -+ -+ -+ -+ Copyright (C) -+ -+ This library is free software; you can redistribute it and/or -+ modify it under the terms of the GNU Lesser General Public -+ License as published by the Free Software Foundation; either -+ version 2 of the License, or (at your option) any later version. -+ -+ This library is distributed in the hope that it will be useful, -+ but WITHOUT ANY WARRANTY; without even the implied warranty of -+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -+ Lesser General Public License for more details. -+ -+ You should have received a copy of the GNU Lesser General Public -+ License along with this library; if not, write to the Free Software -+ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA -+ -+Also add information on how to contact you by electronic and paper -+mail. -+ -+You should also get your employer (if you work as a programmer) or -+your -+school, if any, to sign a "copyright disclaimer" for the library, if -+necessary. Here is a sample; alter the names: -+ -+ Yoyodyne, Inc., hereby disclaims all copyright interest in the -+ library `Frob' (a library for tweaking knobs) written by James -+Random Hacker. -+ -+ , 1 April 1990 -+ Ty Coon, President of Vice -+ -+That's all there is to it! -+ -+ -diff --git a/bundled/ocaml-augeas/Makefile.am b/bundled/ocaml-augeas/Makefile.am -new file mode 100644 -index 00000000..b6122eab ---- /dev/null -+++ b/bundled/ocaml-augeas/Makefile.am -@@ -0,0 +1,82 @@ -+# libguestfs OCaml tools common code -+# Copyright (C) 2011-2020 Red Hat Inc. -+# -+# This program is free software; you can redistribute it and/or modify -+# it under the terms of the GNU General Public License as published by -+# the Free Software Foundation; either version 2 of the License, or -+# (at your option) any later version. -+# -+# This program is distributed in the hope that it will be useful, -+# but WITHOUT ANY WARRANTY; without even the implied warranty of -+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -+# GNU General Public License for more details. -+# -+# You should have received a copy of the GNU General Public License -+# along with this program; if not, write to the Free Software -+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. -+ -+include $(top_srcdir)/subdir-rules.mk -+ -+EXTRA_DIST = \ -+ $(SOURCES_MLI) \ -+ $(SOURCES_ML) \ -+ $(SOURCES_C) \ -+ augeas.README -+ -+SOURCES_MLI = \ -+ augeas.mli -+ -+SOURCES_ML = \ -+ augeas.ml -+ -+SOURCES_C = \ -+ augeas-c.c -+ -+# We pretend that we're building a C library. automake handles the -+# compilation of the C sources for us. At the end we take the C -+# objects and OCaml objects and link them into the OCaml library. -+# This C library is never used. -+ -+noinst_LIBRARIES = libmlaugeas.a -+ -+if !HAVE_OCAMLOPT -+MLAUGEAS_CMA = mlaugeas.cma -+else -+MLAUGEAS_CMA = mlaugeas.cmxa -+endif -+ -+noinst_DATA = $(MLAUGEAS_CMA) -+ -+libmlaugeas_a_SOURCES = $(SOURCES_C) -+libmlaugeas_a_CPPFLAGS = \ -+ -DCAML_NAME_SPACE \ -+ -I. \ -+ -I$(top_builddir) \ -+ -I$(shell $(OCAMLC) -where) -+libmlaugeas_a_CFLAGS = \ -+ $(WARN_CFLAGS) $(NO_SNV_CFLAGS) $(NO_UM_CFLAGS) $(WERROR_CFLAGS) \ -+ $(AUGEAS_CFLAGS) $(LIBXML2_CFLAGS) \ -+ -fPIC -+ -+BOBJECTS = $(SOURCES_ML:.ml=.cmo) -+XOBJECTS = $(BOBJECTS:.cmo=.cmx) -+ -+OCAMLPACKAGES = -+OCAMLFLAGS = $(OCAML_FLAGS) $(OCAML_WARN_ERROR) -ccopt '$(CFLAGS)' -+ -+if !HAVE_OCAMLOPT -+OBJECTS = $(BOBJECTS) -+else -+OBJECTS = $(XOBJECTS) -+endif -+ -+libmlaugeas_a_DEPENDENCIES = $(OBJECTS) -+ -+$(MLAUGEAS_CMA): $(OBJECTS) libmlaugeas.a -+ $(OCAMLFIND) mklib $(OCAMLPACKAGES) \ -+ $(OBJECTS) $(libmlaugeas_a_OBJECTS) -cclib -laugeas -o mlaugeas -+ -+# Dependencies. -+.depend: $(srcdir)/*.mli $(srcdir)/*.ml -+ $(top_builddir)/ocaml-dep.sh $^ -+-include .depend -diff --git a/bundled/ocaml-augeas/augeas-c.c b/bundled/ocaml-augeas/augeas-c.c -new file mode 100644 -index 00000000..679bcb50 ---- /dev/null -+++ b/bundled/ocaml-augeas/augeas-c.c -@@ -0,0 +1,579 @@ -+/* Augeas OCaml bindings -+ * Copyright (C) 2008-2017 Red Hat Inc., Richard W.M. Jones -+ * -+ * This library is free software; you can redistribute it and/or -+ * modify it under the terms of the GNU Lesser General Public -+ * License as published by the Free Software Foundation; either -+ * version 2 of the License, or (at your option) any later version. -+ * -+ * This library is distributed in the hope that it will be useful, -+ * but WITHOUT ANY WARRANTY; without even the implied warranty of -+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -+ * Lesser General Public License for more details. -+ * -+ * You should have received a copy of the GNU Lesser General Public -+ * License along with this library; if not, write to the Free Software -+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA -+ * -+ * $Id: augeas_c.c,v 1.1 2008/05/06 10:48:20 rjones Exp $ -+ */ -+ -+#include "config.h" -+ -+#include -+ -+#include -+#include -+#include -+#include -+#include -+#include -+ -+#include -+ -+#ifdef __GNUC__ -+ #define NORETURN __attribute__ ((noreturn)) -+#else -+ #define NORETURN -+#endif -+ -+extern CAMLprim value ocaml_augeas_create (value rootv, value loadpathv, value flagsv); -+extern CAMLprim value ocaml_augeas_close (value tv); -+extern CAMLprim value ocaml_augeas_defnode (value tv, value namev, value exprv, value valv); -+extern CAMLprim value ocaml_augeas_defvar (value tv, value namev, value exprv); -+extern CAMLprim value ocaml_augeas_get (value tv, value pathv); -+extern CAMLprim value ocaml_augeas_exists (value tv, value pathv); -+extern CAMLprim value ocaml_augeas_insert (value tv, value beforev, value pathv, value labelv); -+extern CAMLprim value ocaml_augeas_label (value tv, value pathv); -+extern CAMLprim value ocaml_augeas_mv (value tv, value srcv, value destv); -+extern CAMLprim value ocaml_augeas_rm (value tv, value pathv); -+extern CAMLprim value ocaml_augeas_match (value tv, value pathv); -+extern CAMLprim value ocaml_augeas_count_matches (value tv, value pathv); -+extern CAMLprim value ocaml_augeas_save (value tv); -+extern CAMLprim value ocaml_augeas_load (value tv); -+extern CAMLprim value ocaml_augeas_set (value tv, value pathv, value valuev); -+extern CAMLprim value ocaml_augeas_setm (value tv, value basev, value subv, value valv); -+extern CAMLprim value ocaml_augeas_transform (value tv, value lensv, value filev, value modev); -+extern CAMLprim value ocaml_augeas_source (value tv, value pathv) -+#ifndef HAVE_AUG_SOURCE -+ NORETURN -+#endif -+; -+ -+typedef augeas *augeas_t; -+ -+/* Map C aug_errcode_t to OCaml error_code. */ -+static const int error_map[] = { -+ /* AugErrInternal */ AUG_EINTERNAL, -+ /* AugErrPathX */ AUG_EPATHX, -+ /* AugErrNoMatch */ AUG_ENOMATCH, -+ /* AugErrMMatch */ AUG_EMMATCH, -+ /* AugErrSyntax */ AUG_ESYNTAX, -+ /* AugErrNoLens */ AUG_ENOLENS, -+ /* AugErrMXfm */ AUG_EMXFM, -+ /* AugErrNoSpan */ AUG_ENOSPAN, -+ /* AugErrMvDesc */ AUG_EMVDESC, -+ /* AugErrCmdRun */ AUG_ECMDRUN, -+ /* AugErrBadArg */ AUG_EBADARG, -+ /* AugErrLabel */ AUG_ELABEL, -+ /* AugErrCpDesc */ AUG_ECPDESC, -+}; -+static const int error_map_len = sizeof error_map / sizeof error_map[0]; -+ -+/* Raise an Augeas.Error exception, and optionally close the -+ * specified handle. -+ */ -+static void -+raise_error_and_maybe_close (augeas_t t, const char *msg, bool close_handle) -+{ -+ const value *exn = caml_named_value ("Augeas.Error"); -+ value args[5]; -+ const int code = aug_error (t); -+ const char *aug_err_msg; -+ const char *aug_err_minor; -+ const char *aug_err_details; -+ int ocaml_code = -1; -+ int i; -+ -+ if (code == AUG_ENOMEM) { -+ if (close_handle) -+ aug_close (t); -+ caml_raise_out_of_memory (); -+ } -+ -+ aug_err_msg = aug_error_message (t); -+ aug_err_minor = aug_error_minor_message (t); -+ aug_err_details = aug_error_details (t); -+ -+ for (i = 0; i < error_map_len; ++i) -+ if (error_map[i] == code) { -+ ocaml_code = i; -+ break; -+ } -+ -+ if (ocaml_code != -1) -+ args[0] = Val_int (ocaml_code); -+ else { -+ args[0] = caml_alloc (1, 0); -+ Store_field (args[0], 0, Val_int (code)); -+ } -+ args[1] = caml_copy_string (msg); -+ args[2] = caml_copy_string (aug_err_msg); -+ args[3] = caml_copy_string (aug_err_minor ? : ""); -+ args[4] = caml_copy_string (aug_err_details ? : ""); -+ -+ if (close_handle) -+ aug_close (t); -+ -+ caml_raise_with_args (*exn, 5, args); -+} -+#define raise_error(t, msg) raise_error_and_maybe_close(t, msg, false) -+ -+static void -+raise_init_error (const char *msg) -+{ -+ const value *exn = caml_named_value ("Augeas.Error"); -+ value args[5]; -+ -+ args[0] = caml_alloc (1, 0); -+ Store_field (args[0], 0, Val_int (-1)); -+ args[1] = caml_copy_string (msg); -+ args[2] = caml_copy_string ("aug_init failed"); -+ args[3] = caml_copy_string ("augeas initialization failed"); -+ args[4] = caml_copy_string (""); -+ -+ caml_raise_with_args (*exn, 5, args); -+} -+ -+static const char * -+Optstring_val (value strv) -+{ -+ if (strv == Val_int (0)) /* None */ -+ return NULL; -+ else /* Some string */ -+ return String_val (Field (strv, 0)); -+} -+ -+/* Map OCaml flags to C flags. */ -+static const int flag_map[] = { -+ /* AugSaveBackup */ AUG_SAVE_BACKUP, -+ /* AugSaveNewFile */ AUG_SAVE_NEWFILE, -+ /* AugTypeCheck */ AUG_TYPE_CHECK, -+ /* AugNoStdinc */ AUG_NO_STDINC, -+ /* AugSaveNoop */ AUG_SAVE_NOOP, -+ /* AugNoLoad */ AUG_NO_LOAD, -+ /* AugNoModlAutoload */ AUG_NO_MODL_AUTOLOAD, -+ /* AugEnableSpan */ AUG_ENABLE_SPAN, -+ /* AugNoErrClose */ AUG_NO_ERR_CLOSE, -+ /* AugTraceModuleLoading */ AUG_TRACE_MODULE_LOADING, -+}; -+ -+/* Wrap and unwrap augeas_t handles, with a finalizer. */ -+#define Augeas_t_val(rv) (*(augeas_t *)Data_custom_val(rv)) -+ -+static void -+augeas_t_finalize (value tv) -+{ -+ augeas_t t = Augeas_t_val (tv); -+ if (t) aug_close (t); -+} -+ -+static struct custom_operations custom_operations = { -+ (char *) "augeas_t_custom_operations", -+ augeas_t_finalize, -+ custom_compare_default, -+ custom_hash_default, -+ custom_serialize_default, -+ custom_deserialize_default, -+ custom_compare_ext_default, -+}; -+ -+static value Val_augeas_t (augeas_t t) -+{ -+ CAMLparam0 (); -+ CAMLlocal1 (rv); -+ /* We could choose these so that the GC can make better decisions. -+ * See 18.9.2 of the OCaml manual. -+ */ -+ const int used = 0; -+ const int max = 1; -+ -+ rv = caml_alloc_custom (&custom_operations, -+ sizeof (augeas_t), used, max); -+ Augeas_t_val(rv) = t; -+ -+ CAMLreturn (rv); -+} -+ -+#pragma GCC diagnostic ignored "-Wmissing-prototypes" -+ -+/* val create : string -> string option -> flag list -> t */ -+CAMLprim value -+ocaml_augeas_create (value rootv, value loadpathv, value flagsv) -+{ -+ CAMLparam1 (rootv); -+ const char *root = String_val (rootv); -+ const char *loadpath = Optstring_val (loadpathv); -+ int flags = 0, i; -+ augeas_t t; -+ -+ /* Convert list of flags to C. */ -+ for (; flagsv != Val_int (0); flagsv = Field (flagsv, 1)) { -+ i = Int_val (Field (flagsv, 0)); -+ flags |= flag_map[i]; -+ } -+ -+ /* Pass AUG_NO_ERR_CLOSE so we raise a detailed Augeas.Error. */ -+ t = aug_init (root, loadpath, flags | AUG_NO_ERR_CLOSE); -+ -+ if (t == NULL) -+ raise_init_error ("Augeas.create"); -+ -+ if (aug_error (t) != AUG_NOERROR) { -+ raise_error_and_maybe_close (t, "Augeas.init", true); -+ } -+ -+ CAMLreturn (Val_augeas_t (t)); -+} -+ -+/* val close : t -> unit */ -+CAMLprim value -+ocaml_augeas_close (value tv) -+{ -+ CAMLparam1 (tv); -+ augeas_t t = Augeas_t_val (tv); -+ -+ if (t) { -+ aug_close (t); -+ Augeas_t_val(tv) = NULL; /* So the finalizer doesn't double-free. */ -+ } -+ -+ CAMLreturn (Val_unit); -+} -+ -+/* val defnode : t -> string -> string -> string option -> int * bool */ -+CAMLprim value -+ocaml_augeas_defnode (value tv, value namev, value exprv, value valv) -+{ -+ CAMLparam4 (tv, namev, exprv, valv); -+ CAMLlocal2 (optv, v); -+ augeas_t t = Augeas_t_val (tv); -+ const char *name = String_val (namev); -+ const char *expr = String_val (exprv); -+ const char *val = Optstring_val (valv); -+ int r, created; -+ -+ r = aug_defnode (t, name, expr, val, &created); -+ if (r == -1) { -+ raise_error (t, "Augeas.defnode"); -+ } -+ -+ v = caml_alloc (2, 0); -+ Store_field (v, 0, Val_int (r)); -+ Store_field (v, 1, Val_bool (created)); -+ -+ CAMLreturn (v); -+} -+ -+/* val defvar : t -> string -> string option -> int option */ -+CAMLprim value -+ocaml_augeas_defvar (value tv, value namev, value exprv) -+{ -+ CAMLparam3 (tv, namev, exprv); -+ CAMLlocal2 (optv, v); -+ augeas_t t = Augeas_t_val (tv); -+ const char *name = String_val (namev); -+ const char *expr = Optstring_val (exprv); -+ int r; -+ -+ r = aug_defvar (t, name, expr); -+ if (r > 0) { /* Return Some val */ -+ v = Val_int (r); -+ optv = caml_alloc (1, 0); -+ Field (optv, 0) = v; -+ } else if (r == 0) /* Return None */ -+ optv = Val_int (0); -+ else if (r == -1) /* Error or multiple matches */ -+ raise_error (t, "Augeas.defvar"); -+ else -+ caml_failwith ("Augeas.defvar: bad return value"); -+ -+ CAMLreturn (optv); -+} -+ -+/* val get : t -> path -> value option */ -+CAMLprim value -+ocaml_augeas_get (value tv, value pathv) -+{ -+ CAMLparam2 (tv, pathv); -+ CAMLlocal2 (optv, v); -+ augeas_t t = Augeas_t_val (tv); -+ const char *path = String_val (pathv); -+ const char *val; -+ int r; -+ -+ r = aug_get (t, path, &val); -+ if (r == 1 && val) { /* Return Some val */ -+ v = caml_copy_string (val); -+ optv = caml_alloc (1, 0); -+ Field (optv, 0) = v; -+ } else if (r == 0 || !val) /* Return None */ -+ optv = Val_int (0); -+ else if (r == -1) /* Error or multiple matches */ -+ raise_error (t, "Augeas.get"); -+ else -+ caml_failwith ("Augeas.get: bad return value"); -+ -+ CAMLreturn (optv); -+} -+ -+/* val exists : t -> path -> bool */ -+CAMLprim value -+ocaml_augeas_exists (value tv, value pathv) -+{ -+ CAMLparam2 (tv, pathv); -+ CAMLlocal1 (v); -+ augeas_t t = Augeas_t_val (tv); -+ const char *path = String_val (pathv); -+ int r; -+ -+ r = aug_get (t, path, NULL); -+ if (r == 1) /* Return true. */ -+ v = Val_int (1); -+ else if (r == 0) /* Return false */ -+ v = Val_int (0); -+ else if (r == -1) /* Error or multiple matches */ -+ raise_error (t, "Augeas.exists"); -+ else -+ caml_failwith ("Augeas.exists: bad return value"); -+ -+ CAMLreturn (v); -+} -+ -+/* val insert : t -> ?before:bool -> path -> string -> unit */ -+CAMLprim value -+ocaml_augeas_insert (value tv, value beforev, value pathv, value labelv) -+{ -+ CAMLparam4 (tv, beforev, pathv, labelv); -+ augeas_t t = Augeas_t_val (tv); -+ const char *path = String_val (pathv); -+ const char *label = String_val (labelv); -+ int before; -+ -+ before = beforev == Val_int (0) ? 0 : Int_val (Field (beforev, 0)); -+ -+ if (aug_insert (t, path, label, before) == -1) -+ raise_error (t, "Augeas.insert"); -+ -+ CAMLreturn (Val_unit); -+} -+ -+/* val label : t -> path -> string option */ -+CAMLprim value -+ocaml_augeas_label (value tv, value pathv) -+{ -+ CAMLparam2 (tv, pathv); -+ CAMLlocal2 (optv, v); -+ augeas_t t = Augeas_t_val (tv); -+ const char *path = String_val (pathv); -+ const char *val; -+ int r; -+ -+ r = aug_label (t, path, &val); -+ if (r == 1 && val) { /* Return Some val */ -+ v = caml_copy_string (val); -+ optv = caml_alloc (1, 0); -+ Field (optv, 0) = v; -+ } else if (r == 0 || !val) /* Return None */ -+ optv = Val_int (0); -+ else if (r == -1) /* Error or multiple matches */ -+ raise_error (t, "Augeas.label"); -+ else -+ caml_failwith ("Augeas.label: bad return value"); -+ -+ CAMLreturn (optv); -+} -+ -+/* val mv : t -> path -> path -> unit */ -+CAMLprim value -+ocaml_augeas_mv (value tv, value srcv, value destv) -+{ -+ CAMLparam3 (tv, srcv, destv); -+ augeas_t t = Augeas_t_val (tv); -+ const char *src = String_val (srcv); -+ const char *dest = String_val (destv); -+ -+ if (aug_mv (t, src, dest) == -1) -+ raise_error (t, "Augeas.mv"); -+ -+ CAMLreturn (Val_unit); -+} -+ -+/* val rm : t -> path -> int */ -+CAMLprim value -+ocaml_augeas_rm (value tv, value pathv) -+{ -+ CAMLparam2 (tv, pathv); -+ augeas_t t = Augeas_t_val (tv); -+ const char *path = String_val (pathv); -+ int r; -+ -+ r = aug_rm (t, path); -+ if (r == -1) -+ raise_error (t, "Augeas.rm"); -+ -+ CAMLreturn (Val_int (r)); -+} -+ -+/* val matches : t -> path -> path list */ -+CAMLprim value -+ocaml_augeas_match (value tv, value pathv) -+{ -+ CAMLparam2 (tv, pathv); -+ CAMLlocal3 (rv, v, cons); -+ augeas_t t = Augeas_t_val (tv); -+ const char *path = String_val (pathv); -+ char **matches; -+ int r, i; -+ -+ r = aug_match (t, path, &matches); -+ if (r == -1) -+ raise_error (t, "Augeas.matches"); -+ -+ /* Copy the paths to a list. */ -+ rv = Val_int (0); -+ for (i = 0; i < r; ++i) { -+ v = caml_copy_string (matches[i]); -+ free (matches[i]); -+ cons = caml_alloc (2, 0); -+ Field (cons, 1) = rv; -+ Field (cons, 0) = v; -+ rv = cons; -+ } -+ -+ free (matches); -+ -+ CAMLreturn (rv); -+} -+ -+/* val count_matches : t -> path -> int */ -+CAMLprim value -+ocaml_augeas_count_matches (value tv, value pathv) -+{ -+ CAMLparam2 (tv, pathv); -+ augeas_t t = Augeas_t_val (tv); -+ const char *path = String_val (pathv); -+ int r; -+ -+ r = aug_match (t, path, NULL); -+ if (r == -1) -+ raise_error (t, "Augeas.count_matches"); -+ -+ CAMLreturn (Val_int (r)); -+} -+ -+/* val save : t -> unit */ -+CAMLprim value -+ocaml_augeas_save (value tv) -+{ -+ CAMLparam1 (tv); -+ augeas_t t = Augeas_t_val (tv); -+ -+ if (aug_save (t) == -1) -+ raise_error (t, "Augeas.save"); -+ -+ CAMLreturn (Val_unit); -+} -+ -+/* val load : t -> unit */ -+CAMLprim value -+ocaml_augeas_load (value tv) -+{ -+ CAMLparam1 (tv); -+ augeas_t t = Augeas_t_val (tv); -+ -+ if (aug_load (t) == -1) -+ raise_error (t, "Augeas.load"); -+ -+ CAMLreturn (Val_unit); -+} -+ -+/* val set : t -> -> path -> value option -> unit */ -+CAMLprim value -+ocaml_augeas_set (value tv, value pathv, value valuev) -+{ -+ CAMLparam3 (tv, pathv, valuev); -+ augeas_t t = Augeas_t_val (tv); -+ const char *path = String_val (pathv); -+ const char *val = Optstring_val (valuev); -+ -+ if (aug_set (t, path, val) == -1) -+ raise_error (t, "Augeas.set"); -+ -+ CAMLreturn (Val_unit); -+} -+ -+/* val setm : t -> path -> string option -> value option -> int */ -+CAMLprim value -+ocaml_augeas_setm (value tv, value basev, value subv, value valv) -+{ -+ CAMLparam4 (tv, basev, subv, valv); -+ augeas_t t = Augeas_t_val (tv); -+ const char *base = String_val (basev); -+ const char *sub = Optstring_val (subv); -+ const char *val = Optstring_val (valv); -+ int r; -+ -+ r = aug_setm (t, base, sub, val); -+ if (r == -1) -+ raise_error (t, "Augeas.setm"); -+ -+ CAMLreturn (Val_int (r)); -+} -+ -+/* val transform : t -> string -> string -> transform_mode -> unit */ -+CAMLprim value -+ocaml_augeas_transform (value tv, value lensv, value filev, value modev) -+{ -+ CAMLparam4 (tv, lensv, filev, modev); -+ augeas_t t = Augeas_t_val (tv); -+ const char *lens = String_val (lensv); -+ const char *file = String_val (filev); -+ const int excl = Int_val (modev) == 1 ? 1 : 0; -+ -+ if (aug_transform (t, lens, file, excl) == -1) -+ raise_error (t, "Augeas.transform"); -+ -+ CAMLreturn (Val_unit); -+} -+ -+/* val source : t -> path -> path option */ -+CAMLprim value -+ocaml_augeas_source (value tv, value pathv) -+{ -+#ifdef HAVE_AUG_SOURCE -+ CAMLparam2 (tv, pathv); -+ CAMLlocal2 (optv, v); -+ augeas_t t = Augeas_t_val (tv); -+ const char *path = String_val (pathv); -+ char *file_path; -+ int r; -+ -+ r = aug_source (t, path, &file_path); -+ if (r == 0) { -+ if (file_path) { /* Return Some file_path */ -+ v = caml_copy_string (file_path); -+ optv = caml_alloc (1, 0); -+ Field (optv, 0) = v; -+ free (file_path); -+ } else /* Return None */ -+ optv = Val_int (0); -+ } -+ else /* Error */ -+ raise_error (t, "Augeas.source"); -+ -+ CAMLreturn (optv); -+#else -+ caml_failwith ("Augeas.source: function not implemented"); -+#endif -+} -diff --git a/bundled/ocaml-augeas/augeas.README b/bundled/ocaml-augeas/augeas.README -new file mode 100644 -index 00000000..938dfd25 ---- /dev/null -+++ b/bundled/ocaml-augeas/augeas.README -@@ -0,0 +1,8 @@ -+The files augeas-c.c, augeas.ml and augeas.mli come from the -+ocaml-augeas library: -+ -+ http://git.annexia.org/?p=ocaml-augeas.git -+ -+which is released under a compatible license. We try to keep them -+identical, so if you make changes to these files then you must also -+submit the changes to ocaml-augeas, and vice versa. -\ No newline at end of file -diff --git a/bundled/ocaml-augeas/augeas.ml b/bundled/ocaml-augeas/augeas.ml -new file mode 100644 -index 00000000..aa5a1822 ---- /dev/null -+++ b/bundled/ocaml-augeas/augeas.ml -@@ -0,0 +1,99 @@ -+(* Augeas OCaml bindings -+ * Copyright (C) 2008 Red Hat Inc., Richard W.M. Jones -+ * -+ * This library is free software; you can redistribute it and/or -+ * modify it under the terms of the GNU Lesser General Public -+ * License as published by the Free Software Foundation; either -+ * version 2 of the License, or (at your option) any later version. -+ * -+ * This library is distributed in the hope that it will be useful, -+ * but WITHOUT ANY WARRANTY; without even the implied warranty of -+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -+ * Lesser General Public License for more details. -+ * -+ * You should have received a copy of the GNU Lesser General Public -+ * License along with this library; if not, write to the Free Software -+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA -+ * -+ * $Id: augeas.ml,v 1.2 2008/05/06 10:48:20 rjones Exp $ -+ *) -+ -+type t -+ -+type flag = -+ | AugSaveBackup -+ | AugSaveNewFile -+ | AugTypeCheck -+ | AugNoStdinc -+ | AugSaveNoop -+ | AugNoLoad -+ | AugNoModlAutoload -+ | AugEnableSpan -+ | AugNoErrClose -+ | AugTraceModuleLoading -+ -+type error_code = -+ | AugErrInternal -+ | AugErrPathX -+ | AugErrNoMatch -+ | AugErrMMatch -+ | AugErrSyntax -+ | AugErrNoLens -+ | AugErrMXfm -+ | AugErrNoSpan -+ | AugErrMvDesc -+ | AugErrCmdRun -+ | AugErrBadArg -+ | AugErrLabel -+ | AugErrCpDesc -+ | AugErrUnknown of int -+ -+type transform_mode = -+ | Include -+ | Exclude -+ -+exception Error of error_code * string * string * string * string -+ -+type path = string -+ -+type value = string -+ -+external create : string -> string option -> flag list -> t -+ = "ocaml_augeas_create" -+external close : t -> unit -+ = "ocaml_augeas_close" -+external defnode : t -> string -> string -> string option -> int * bool -+ = "ocaml_augeas_defnode" -+external defvar : t -> string -> string option -> int option -+ = "ocaml_augeas_defvar" -+external get : t -> path -> value option -+ = "ocaml_augeas_get" -+external exists : t -> path -> bool -+ = "ocaml_augeas_exists" -+external insert : t -> ?before:bool -> path -> string -> unit -+ = "ocaml_augeas_insert" -+external label : t -> path -> string option -+ = "ocaml_augeas_label" -+external rm : t -> path -> int -+ = "ocaml_augeas_rm" -+external matches : t -> path -> path list -+ = "ocaml_augeas_match" -+external count_matches : t -> path -> int -+ = "ocaml_augeas_count_matches" -+external save : t -> unit -+ = "ocaml_augeas_save" -+external load : t -> unit -+ = "ocaml_augeas_load" -+external mv : t -> path -> path -> unit -+ = "ocaml_augeas_mv" -+external set : t -> path -> value option -> unit -+ = "ocaml_augeas_set" -+external setm : t -> path -> string option -> value option -> int -+ = "ocaml_augeas_setm" -+external transform : t -> string -> string -> transform_mode -> unit -+ = "ocaml_augeas_transform" -+external source : t -> path -> path option -+ = "ocaml_augeas_source" -+ -+let () = -+ Callback.register_exception "Augeas.Error" (Error (AugErrInternal, "", "", "", "")) -diff --git a/bundled/ocaml-augeas/augeas.mli b/bundled/ocaml-augeas/augeas.mli -new file mode 100644 -index 00000000..8cbeae18 ---- /dev/null -+++ b/bundled/ocaml-augeas/augeas.mli -@@ -0,0 +1,164 @@ -+(** Augeas OCaml bindings *) -+(* Copyright (C) 2008 Red Hat Inc., Richard W.M. Jones -+ * -+ * This library is free software; you can redistribute it and/or -+ * modify it under the terms of the GNU Lesser General Public -+ * License as published by the Free Software Foundation; either -+ * version 2 of the License, or (at your option) any later version. -+ * -+ * This library is distributed in the hope that it will be useful, -+ * but WITHOUT ANY WARRANTY; without even the implied warranty of -+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -+ * Lesser General Public License for more details. -+ * -+ * You should have received a copy of the GNU Lesser General Public -+ * License along with this library; if not, write to the Free Software -+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA -+ * -+ * $Id: augeas.mli,v 1.2 2008/05/06 10:48:20 rjones Exp $ -+ *) -+ -+type t -+ (** Augeas library handle. *) -+ -+type flag = -+ | AugSaveBackup (** Rename original with .augsave *) -+ | AugSaveNewFile (** Save changes to .augnew *) -+ | AugTypeCheck (** Type-check lenses *) -+ | AugNoStdinc -+ | AugSaveNoop -+ | AugNoLoad -+ | AugNoModlAutoload -+ | AugEnableSpan -+ | AugNoErrClose -+ | AugTraceModuleLoading -+ (** Flags passed to the {!create} function. *) -+ -+type error_code = -+ | AugErrInternal (** Internal error (bug) *) -+ | AugErrPathX (** Invalid path expression *) -+ | AugErrNoMatch (** No match for path expression *) -+ | AugErrMMatch (** Too many matches for path expression *) -+ | AugErrSyntax (** Syntax error in lens file *) -+ | AugErrNoLens (** Lens lookup failed *) -+ | AugErrMXfm (** Multiple transforms *) -+ | AugErrNoSpan (** No span for this node *) -+ | AugErrMvDesc (** Cannot move node into its descendant *) -+ | AugErrCmdRun (** Failed to execute command *) -+ | AugErrBadArg (** Invalid argument in funcion call *) -+ | AugErrLabel (** Invalid label *) -+ | AugErrCpDesc (** Cannot copy node into its descendant *) -+ | AugErrUnknown of int -+ (** Possible error codes. *) -+ -+type transform_mode = -+ | Include -+ | Exclude -+ (** The operation mode for the {!transform} function. *) -+ -+exception Error of error_code * string * string * string * string -+ (** This exception is thrown when the underlying Augeas library -+ returns an error. The tuple represents: -+ - the Augeas error code -+ - the ocaml-augeas error string -+ - the Augeas error message -+ - the human-readable explanation of the Augeas error, if available -+ - a string with details of the Augeas error -+ *) -+ -+type path = string -+ (** A path expression. -+ -+ Note in future we may replace this with a type-safe path constructor. *) -+ -+type value = string -+ (** A value. *) -+ -+val create : string -> string option -> flag list -> t -+ (** [create root loadpath flags] creates an Augeas handle. -+ -+ [root] is a file system path describing the location -+ of the configuration files. -+ -+ [loadpath] is an optional colon-separated list of directories -+ which are searched for schema definitions. -+ -+ [flags] is a list of flags. *) -+ -+val close : t -> unit -+ (** [close handle] closes the handle. -+ -+ You don't need to close handles explicitly with this function: -+ they will be finalized eventually by the garbage collector. -+ However calling this function frees up any resources used by the -+ underlying Augeas library immediately. -+ -+ Do not use the handle after closing it. *) -+ -+val defnode : t -> string -> string -> string option -> int * bool -+ (** [defnode t name expr value] defines [name] whose value is the -+ result of evaluating [expr], which is a nodeset. *) -+ -+val defvar : t -> string -> string option -> int option -+ (** [defvar t name expr] defines [name] whose value is the result -+ of evaluating [expr], replacing the old value if existing. -+ [None] as [expr] removes the variable [name]. *) -+ -+val get : t -> path -> value option -+ (** [get t path] returns the value at [path], or [None] if there -+ is no value. *) -+ -+val exists : t -> path -> bool -+ (** [exists t path] returns true iff there is a value at [path]. *) -+ -+val insert : t -> ?before:bool -> path -> string -> unit -+ (** [insert t ?before path label] inserts [label] as a sibling -+ of [path]. By default it is inserted after [path], unless -+ [~before:true] is specified. *) -+ -+val label : t -> path -> string option -+ (** [label t path] gets the label of [path]. -+ -+ Returns [Some value] when [path] matches only one node, and -+ that has an associated label. *) -+ -+val rm : t -> path -> int -+ (** [rm t path] removes all nodes matching [path]. -+ -+ Returns the number of nodes removed (which may be 0). *) -+ -+val matches : t -> path -> path list -+ (** [matches t path] returns a list of path expressions -+ of all nodes matching [path]. *) -+ -+val mv : t -> path -> path -> unit -+ (** [mv t src dest] moves a node. *) -+ -+val count_matches : t -> path -> int -+ (** [count_matches t path] counts the number of nodes matching -+ [path] but does not return them (see {!matches}). *) -+ -+val save : t -> unit -+ (** [save t] saves all pending changes to disk. *) -+ -+val load : t -> unit -+ (** [load t] loads files into the tree. *) -+ -+val set : t -> path -> value option -> unit -+ (** [set t path] sets [value] as new value at [path]. *) -+ -+val setm : t -> path -> string option -> value option -> int -+ (** [setm t base sub value] sets [value] as new value for all the -+ nodes under [base] that match [sub] (or all, if [sub] is -+ [None]). -+ -+ Returns the number of nodes modified. *) -+ -+val transform : t -> string -> string -> transform_mode -> unit -+ (** [transform t lens file mode] adds or removes (depending on -+ [mode]) the transformation of the specified [lens] for [file]. *) -+ -+val source : t -> path -> path option -+ (** [source t path] returns the path to the node representing the -+ file to which [path] belongs, or [None] if [path] does not -+ represent any file. *) -diff --git a/configure.ac b/configure.ac -index 0db21297..d1397f63 100644 ---- a/configure.ac -+++ b/configure.ac -@@ -195,6 +195,7 @@ AC_CONFIG_FILES([run], - AC_CONFIG_FILES([Makefile - appliance/Makefile - bash/Makefile -+ bundled/ocaml-augeas/Makefile - common/errnostring/Makefile - common/edit/Makefile - common/mlpcre/Makefile -diff --git a/daemon/Makefile.am b/daemon/Makefile.am -index bb2e58d0..bd1920c6 100644 ---- a/daemon/Makefile.am -+++ b/daemon/Makefile.am -@@ -215,9 +215,9 @@ guestfsd_SOURCES = \ - guestfsd_LDFLAGS = \ - -L$(shell $(OCAMLC) -where) \ - -L$(shell $(OCAMLFIND) query hivex) \ -- -L$(shell $(OCAMLFIND) query augeas) \ - -L../common/mlutils \ - -L../common/mlstdutils \ -+ -L../bundled/ocaml-augeas \ - -L../common/mlpcre - guestfsd_LDADD = \ - camldaemon.o \ -@@ -353,7 +353,8 @@ BOBJECTS = $(SOURCES_ML:.ml=.cmo) - XOBJECTS = $(BOBJECTS:.cmo=.cmx) - - OCAMLPACKAGES = \ -- -package str,unix,augeas,hivex \ -+ -package str,unix,hivex \ -+ -I $(top_builddir)/bundled/ocaml-augeas \ - -I $(top_builddir)/common/mlstdutils \ - -I $(top_builddir)/common/mlutils \ - -I $(top_builddir)/common/utils/.libs \ -@@ -384,6 +385,7 @@ camldaemon.o: $(OBJECTS) - $(OCAMLFIND) $(BEST) -output-obj -o $@ \ - $(OCAMLFLAGS) $(OCAMLPACKAGES) \ - -linkpkg \ -+ mlaugeas.$(MLARCHIVE) \ - mlpcre.$(MLARCHIVE) \ - mlstdutils.$(MLARCHIVE) \ - mlcutils.$(MLARCHIVE) \ -@@ -442,6 +444,7 @@ OCAMLLINKFLAGS = \ - mlpcre.$(MLARCHIVE) \ - mlstdutils.$(MLARCHIVE) \ - mlcutils.$(MLARCHIVE) \ -+ mlaugeas.$(MLARCHIVE) \ - $(LINK_CUSTOM_OCAMLC_ONLY) - - daemon_utils_tests_DEPENDENCIES = \ -diff --git a/docs/guestfs-building.pod b/docs/guestfs-building.pod -index 5a7fa40f..b9bc885a 100644 ---- a/docs/guestfs-building.pod -+++ b/docs/guestfs-building.pod -@@ -172,11 +172,6 @@ I. - - I. - --=item ocaml-augeas -- --I. These are the OCaml bindings for Augeas, found at: --L -- - =item xz - - I. -diff --git a/docs/guestfs-hacking.pod b/docs/guestfs-hacking.pod -index e1b47ec1..68cf8292 100644 ---- a/docs/guestfs-hacking.pod -+++ b/docs/guestfs-hacking.pod -@@ -71,6 +71,20 @@ Various build scripts used by autotools. - - L command and documentation. - -+=item F -+ -+Embedded copies of other libraries, mostly for convenience (and the embedded -+library is not widespread enough). -+ -+=over 4 -+ -+=item F -+ -+Bindings for the Augeas library. These come from the ocaml-augeas -+library L -+ -+=back -+ - =item F - - The L, L, L, -diff --git a/m4/guestfs-ocaml.m4 b/m4/guestfs-ocaml.m4 -index 85020717..51072c1a 100644 ---- a/m4/guestfs-ocaml.m4 -+++ b/m4/guestfs-ocaml.m4 -@@ -132,14 +132,6 @@ AS_IF([test "x$have_Hivex_OPEN_UNSAFE" = "xno"],[ - ]) - AC_SUBST([HIVEX_OPEN_UNSAFE_FLAG]) - --if test "x$enable_daemon" = "xyes"; then -- OCAML_PKG_augeas=no -- AC_CHECK_OCAML_PKG(augeas) -- if test "x$OCAML_PKG_augeas" = "xno"; then -- AC_MSG_ERROR([the OCaml module 'augeas' is required]) -- fi --fi -- - # oUnit is optional, used by some tests in common/mlstdutils (that we - # should replace with regular tests one day). If used, oUnit >= 2 is - # required. -diff --git a/ocaml-dep.sh.in b/ocaml-dep.sh.in -index 385a1e6e..c9e9e3e6 100755 ---- a/ocaml-dep.sh.in -+++ b/ocaml-dep.sh.in -@@ -33,6 +33,7 @@ set -e - # directories must have unique names (eg. not ‘Utils’) else - # dependencies don't get built right. - include_dirs=" -+bundled/ocaml-augeas - common/mlgettext - common/mlpcre - common/mlstdutils diff --git a/0011-update-common-submodule.patch b/0010-update-common-submodule.patch similarity index 99% rename from 0011-update-common-submodule.patch rename to 0010-update-common-submodule.patch index 01696ec..3609a0f 100644 --- a/0011-update-common-submodule.patch +++ b/0010-update-common-submodule.patch @@ -1,4 +1,4 @@ -From 194a48aef32367c45c555a4d93fb1a3375b0dead Mon Sep 17 00:00:00 2001 +From 9094eba0abb614e962157ff3399fe6f203676bc7 Mon Sep 17 00:00:00 2001 From: Laszlo Ersek Date: Fri, 19 May 2023 16:08:47 +0200 Subject: [PATCH] update common submodule diff --git a/0012-LUKS-on-LVM-inspection-test-rename-VGs-and-LVs.patch b/0011-LUKS-on-LVM-inspection-test-rename-VGs-and-LVs.patch similarity index 98% rename from 0012-LUKS-on-LVM-inspection-test-rename-VGs-and-LVs.patch rename to 0011-LUKS-on-LVM-inspection-test-rename-VGs-and-LVs.patch index b35742b..c0ea8ee 100644 --- a/0012-LUKS-on-LVM-inspection-test-rename-VGs-and-LVs.patch +++ b/0011-LUKS-on-LVM-inspection-test-rename-VGs-and-LVs.patch @@ -1,4 +1,4 @@ -From c95b3086bdbdf840de8d3b24c3ae5e9b847bf588 Mon Sep 17 00:00:00 2001 +From 1cbe833c756d4e8bf4507319f086e7acbc5c15cb Mon Sep 17 00:00:00 2001 From: Laszlo Ersek Date: Fri, 19 May 2023 16:08:48 +0200 Subject: [PATCH] LUKS-on-LVM inspection test: rename VGs and LVs diff --git a/0013-LUKS-on-LVM-inspection-test-test-dev-mapper-VG-LV-tr.patch b/0012-LUKS-on-LVM-inspection-test-test-dev-mapper-VG-LV-tr.patch similarity index 96% rename from 0013-LUKS-on-LVM-inspection-test-test-dev-mapper-VG-LV-tr.patch rename to 0012-LUKS-on-LVM-inspection-test-test-dev-mapper-VG-LV-tr.patch index 715e658..7f35a93 100644 --- a/0013-LUKS-on-LVM-inspection-test-test-dev-mapper-VG-LV-tr.patch +++ b/0012-LUKS-on-LVM-inspection-test-test-dev-mapper-VG-LV-tr.patch @@ -1,4 +1,4 @@ -From 15cc20d1f5e0413c1af26c683437995886146eb6 Mon Sep 17 00:00:00 2001 +From 03151a1e315e8e7a52a330254bd1486776fb5add Mon Sep 17 00:00:00 2001 From: Laszlo Ersek Date: Fri, 19 May 2023 16:08:49 +0200 Subject: [PATCH] LUKS-on-LVM inspection test: test /dev/mapper/VG-LV diff --git a/0014-Replace-Pervasives.-with-Stdlib.patch b/0013-Replace-Pervasives.-with-Stdlib.patch similarity index 96% rename from 0014-Replace-Pervasives.-with-Stdlib.patch rename to 0013-Replace-Pervasives.-with-Stdlib.patch index ae3711f..00fcf60 100644 --- a/0014-Replace-Pervasives.-with-Stdlib.patch +++ b/0013-Replace-Pervasives.-with-Stdlib.patch @@ -1,4 +1,4 @@ -From 54a9e48e5e1088a1b781c30b49bce695007e12fc Mon Sep 17 00:00:00 2001 +From 6db883aa6b9982964de19ab73f9f3baa1ec370f8 Mon Sep 17 00:00:00 2001 From: "Richard W.M. Jones" Date: Mon, 22 May 2023 16:40:21 +0100 Subject: [PATCH] Replace Pervasives.* with Stdlib.* @@ -65,7 +65,7 @@ index 62f387ee..087b5031 100644 with exn -> diff --git a/docs/guestfs-building.pod b/docs/guestfs-building.pod -index b9bc885a..33703a96 100644 +index 5a7fa40f..2c084521 100644 --- a/docs/guestfs-building.pod +++ b/docs/guestfs-building.pod @@ -119,7 +119,7 @@ virt tools which are still written in Perl. @@ -100,7 +100,7 @@ index d7e6eba3..ed6e9372 100644 (* Is the new file different from the current file? *) if Sys.file_exists filename && files_equal filename filename_new then diff --git a/m4/guestfs-ocaml.m4 b/m4/guestfs-ocaml.m4 -index 51072c1a..e850fb8c 100644 +index 85020717..39a8346f 100644 --- a/m4/guestfs-ocaml.m4 +++ b/m4/guestfs-ocaml.m4 @@ -38,10 +38,10 @@ AC_ARG_ENABLE([ocaml], diff --git a/0015-fuse-Don-t-call-fclose-NULL-on-error-paths.patch b/0014-fuse-Don-t-call-fclose-NULL-on-error-paths.patch similarity index 96% rename from 0015-fuse-Don-t-call-fclose-NULL-on-error-paths.patch rename to 0014-fuse-Don-t-call-fclose-NULL-on-error-paths.patch index 963b36e..e68f0db 100644 --- a/0015-fuse-Don-t-call-fclose-NULL-on-error-paths.patch +++ b/0014-fuse-Don-t-call-fclose-NULL-on-error-paths.patch @@ -1,4 +1,4 @@ -From 1cdc22fa656a44320e9c53401130e98f536c9759 Mon Sep 17 00:00:00 2001 +From 51d6b17cdd054b96fc83c09541620ffb2f20919e Mon Sep 17 00:00:00 2001 From: "Richard W.M. Jones" Date: Mon, 22 May 2023 17:15:39 +0100 Subject: [PATCH] fuse: Don't call fclose(NULL) on error paths diff --git a/0016-ocaml-implicit_close-test-collect-all-currently-unre.patch b/0015-ocaml-implicit_close-test-collect-all-currently-unre.patch similarity index 95% rename from 0016-ocaml-implicit_close-test-collect-all-currently-unre.patch rename to 0015-ocaml-implicit_close-test-collect-all-currently-unre.patch index 8ad4455..c4684a4 100644 --- a/0016-ocaml-implicit_close-test-collect-all-currently-unre.patch +++ b/0015-ocaml-implicit_close-test-collect-all-currently-unre.patch @@ -1,4 +1,4 @@ -From feb17e93b4e58131cf6875c4ae638a791a875a22 Mon Sep 17 00:00:00 2001 +From dc076916ebaa4b70441d54a09d725dd3c349e740 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=BCrgen=20H=C3=B6tzel?= Date: Sat, 27 May 2023 15:32:36 +0200 Subject: [PATCH] ocaml/implicit_close test: collect all currently unreachable diff --git a/0017-ocaml-Replace-old-enter-leave_blocking_section-calls.patch b/0016-ocaml-Replace-old-enter-leave_blocking_section-calls.patch similarity index 97% rename from 0017-ocaml-Replace-old-enter-leave_blocking_section-calls.patch rename to 0016-ocaml-Replace-old-enter-leave_blocking_section-calls.patch index 3eeb410..8b25e17 100644 --- a/0017-ocaml-Replace-old-enter-leave_blocking_section-calls.patch +++ b/0016-ocaml-Replace-old-enter-leave_blocking_section-calls.patch @@ -1,4 +1,4 @@ -From dd58abc40175f735f6fe2669c34c67e6190e557d Mon Sep 17 00:00:00 2001 +From 4a43ae5779424e8b175cfc8d0671378d68afbe9c Mon Sep 17 00:00:00 2001 From: "Richard W.M. Jones" Date: Tue, 27 Jun 2023 10:17:58 +0100 Subject: [PATCH] ocaml: Replace old enter/leave_blocking_section calls diff --git a/0018-ocaml-Release-runtime-lock-around-guestfs_close.patch b/0017-ocaml-Release-runtime-lock-around-guestfs_close.patch similarity index 93% rename from 0018-ocaml-Release-runtime-lock-around-guestfs_close.patch rename to 0017-ocaml-Release-runtime-lock-around-guestfs_close.patch index 034dafd..29a5106 100644 --- a/0018-ocaml-Release-runtime-lock-around-guestfs_close.patch +++ b/0017-ocaml-Release-runtime-lock-around-guestfs_close.patch @@ -1,4 +1,4 @@ -From e2110f72069f184c87df348247e8f3106c81d44a Mon Sep 17 00:00:00 2001 +From 73045a40a9bc3b556eb3893872b4c39ec3161f99 Mon Sep 17 00:00:00 2001 From: "Richard W.M. Jones" Date: Tue, 27 Jun 2023 11:36:55 +0100 Subject: [PATCH] ocaml: Release runtime lock around guestfs_close diff --git a/0019-ocaml-Conditionally-acquire-the-lock-in-callbacks.patch b/0018-ocaml-Conditionally-acquire-the-lock-in-callbacks.patch similarity index 97% rename from 0019-ocaml-Conditionally-acquire-the-lock-in-callbacks.patch rename to 0018-ocaml-Conditionally-acquire-the-lock-in-callbacks.patch index 65d0723..f892b9e 100644 --- a/0019-ocaml-Conditionally-acquire-the-lock-in-callbacks.patch +++ b/0018-ocaml-Conditionally-acquire-the-lock-in-callbacks.patch @@ -1,4 +1,4 @@ -From e42cd859265c34d2013a45b742d4c36bb7617445 Mon Sep 17 00:00:00 2001 +From 18b4d4bf5fed0af96a0924cc3e65d5434d4b4aaa Mon Sep 17 00:00:00 2001 From: "Richard W.M. Jones" Date: Tue, 27 Jun 2023 12:09:12 +0100 Subject: [PATCH] ocaml: Conditionally acquire the lock in callbacks diff --git a/0020-ocaml-Fix-guestfs_065_implicit_close.ml-for-OCaml-5.patch b/0019-ocaml-Fix-guestfs_065_implicit_close.ml-for-OCaml-5.patch similarity index 96% rename from 0020-ocaml-Fix-guestfs_065_implicit_close.ml-for-OCaml-5.patch rename to 0019-ocaml-Fix-guestfs_065_implicit_close.ml-for-OCaml-5.patch index 2bd8857..b01de21 100644 --- a/0020-ocaml-Fix-guestfs_065_implicit_close.ml-for-OCaml-5.patch +++ b/0019-ocaml-Fix-guestfs_065_implicit_close.ml-for-OCaml-5.patch @@ -1,4 +1,4 @@ -From 7ceafac98d3eb28d25195622cb6dc1158e9c1c2f Mon Sep 17 00:00:00 2001 +From 69c86200b3e8ea730be1d6ef81c0f0a07097f611 Mon Sep 17 00:00:00 2001 From: "Richard W.M. Jones" Date: Tue, 27 Jun 2023 16:20:49 +0100 Subject: [PATCH] ocaml: Fix guestfs_065_implicit_close.ml for OCaml 5 diff --git a/0021-ocaml-Use-Caml_state_opt-in-preference-to-caml_state.patch b/0020-ocaml-Use-Caml_state_opt-in-preference-to-caml_state.patch similarity index 93% rename from 0021-ocaml-Use-Caml_state_opt-in-preference-to-caml_state.patch rename to 0020-ocaml-Use-Caml_state_opt-in-preference-to-caml_state.patch index c0c7648..fb3d0bc 100644 --- a/0021-ocaml-Use-Caml_state_opt-in-preference-to-caml_state.patch +++ b/0020-ocaml-Use-Caml_state_opt-in-preference-to-caml_state.patch @@ -1,4 +1,4 @@ -From d4fabae17001702894526084bf0ab516de3599d5 Mon Sep 17 00:00:00 2001 +From db11cccf232bce357a3b9699fb5d1111723cdc25 Mon Sep 17 00:00:00 2001 From: "Richard W.M. Jones" Date: Tue, 27 Jun 2023 16:31:55 +0100 Subject: [PATCH] ocaml: Use Caml_state_opt in preference to caml_state diff --git a/0022-generator-Add-chown-option-for-virt-customize.patch b/0021-generator-Add-chown-option-for-virt-customize.patch similarity index 99% rename from 0022-generator-Add-chown-option-for-virt-customize.patch rename to 0021-generator-Add-chown-option-for-virt-customize.patch index df841df..898c0c3 100644 --- a/0022-generator-Add-chown-option-for-virt-customize.patch +++ b/0021-generator-Add-chown-option-for-virt-customize.patch @@ -1,4 +1,4 @@ -From 64c1716c4120e8dc69d0106b6ebcf6ccb9d4fc24 Mon Sep 17 00:00:00 2001 +From b96428396bafb05adaaeae5e4da99ca257d56230 Mon Sep 17 00:00:00 2001 From: "Richard W.M. Jones" Date: Thu, 29 Jun 2023 13:33:04 +0100 Subject: [PATCH] generator: Add --chown option for virt-customize diff --git a/0023-lib-remove-guestfs_int_cmd_clear_close_files.patch b/0022-lib-remove-guestfs_int_cmd_clear_close_files.patch similarity index 98% rename from 0023-lib-remove-guestfs_int_cmd_clear_close_files.patch rename to 0022-lib-remove-guestfs_int_cmd_clear_close_files.patch index d7fe99e..a87d6d3 100644 --- a/0023-lib-remove-guestfs_int_cmd_clear_close_files.patch +++ b/0022-lib-remove-guestfs_int_cmd_clear_close_files.patch @@ -1,4 +1,4 @@ -From 6c63f5cd8b43448f4847d550ad313d950d6b8520 Mon Sep 17 00:00:00 2001 +From 23e34435b2bc4cbb40ad383658e03a7ba78b50f2 Mon Sep 17 00:00:00 2001 From: Laszlo Ersek Date: Tue, 11 Jul 2023 13:39:06 +0200 Subject: [PATCH] lib: remove guestfs_int_cmd_clear_close_files() diff --git a/0024-docs-fix-broken-link-in-the-guestfs-manual.patch b/0023-docs-fix-broken-link-in-the-guestfs-manual.patch similarity index 95% rename from 0024-docs-fix-broken-link-in-the-guestfs-manual.patch rename to 0023-docs-fix-broken-link-in-the-guestfs-manual.patch index 7ddefc8..1b7d8bf 100644 --- a/0024-docs-fix-broken-link-in-the-guestfs-manual.patch +++ b/0023-docs-fix-broken-link-in-the-guestfs-manual.patch @@ -1,4 +1,4 @@ -From f8e8aef7e9e8334db19529aa46bd28a209436b50 Mon Sep 17 00:00:00 2001 +From cdc81e3491c93ab23884e072ef63803af1fb23da Mon Sep 17 00:00:00 2001 From: Laszlo Ersek Date: Fri, 14 Jul 2023 15:22:09 +0200 Subject: [PATCH] docs: fix broken link in the guestfs manual diff --git a/0025-docs-clarify-sockdir-s-separation.patch b/0024-docs-clarify-sockdir-s-separation.patch similarity index 98% rename from 0025-docs-clarify-sockdir-s-separation.patch rename to 0024-docs-clarify-sockdir-s-separation.patch index 9fd3553..6f71765 100644 --- a/0025-docs-clarify-sockdir-s-separation.patch +++ b/0024-docs-clarify-sockdir-s-separation.patch @@ -1,4 +1,4 @@ -From cde50cb9d71ffa418f45868aa0d4b874847b989a Mon Sep 17 00:00:00 2001 +From 8545c612beba2e3bc8b89664ef74c9ee9e22b8e6 Mon Sep 17 00:00:00 2001 From: Laszlo Ersek Date: Fri, 14 Jul 2023 15:22:10 +0200 Subject: [PATCH] docs: clarify sockdir's separation diff --git a/0026-lib-move-guestfs_int_create_socketname-from-launch.c.patch b/0025-lib-move-guestfs_int_create_socketname-from-launch.c.patch similarity index 98% rename from 0026-lib-move-guestfs_int_create_socketname-from-launch.c.patch rename to 0025-lib-move-guestfs_int_create_socketname-from-launch.c.patch index f5153f7..742765f 100644 --- a/0026-lib-move-guestfs_int_create_socketname-from-launch.c.patch +++ b/0025-lib-move-guestfs_int_create_socketname-from-launch.c.patch @@ -1,4 +1,4 @@ -From 986f5d8b1110b461d37d044c7a8052ed7ba27f87 Mon Sep 17 00:00:00 2001 +From bd8c3bd5262b3446f699731ef00dfa62b6fdd8df Mon Sep 17 00:00:00 2001 From: Laszlo Ersek Date: Fri, 14 Jul 2023 15:22:11 +0200 Subject: [PATCH] lib: move guestfs_int_create_socketname() from "launch.c" to diff --git a/0027-generator-customize-Add-new-StringTriplet-for-use-by.patch b/0026-generator-customize-Add-new-StringTriplet-for-use-by.patch similarity index 99% rename from 0027-generator-customize-Add-new-StringTriplet-for-use-by.patch rename to 0026-generator-customize-Add-new-StringTriplet-for-use-by.patch index 9389253..9672025 100644 --- a/0027-generator-customize-Add-new-StringTriplet-for-use-by.patch +++ b/0026-generator-customize-Add-new-StringTriplet-for-use-by.patch @@ -1,4 +1,4 @@ -From 6e3d91681c7dffdfdf291a809d6773691a2a7bda Mon Sep 17 00:00:00 2001 +From ee2ed1cd009f02e44d137fc78e11bd553f62dcc5 Mon Sep 17 00:00:00 2001 From: "Richard W.M. Jones" Date: Sat, 15 Jul 2023 16:33:18 +0100 Subject: [PATCH] generator: customize: Add new StringTriplet for use by diff --git a/0028-daemon-lvm-Do-reverse-device-name-translation-on-pvs.patch b/0027-daemon-lvm-Do-reverse-device-name-translation-on-pvs.patch similarity index 96% rename from 0028-daemon-lvm-Do-reverse-device-name-translation-on-pvs.patch rename to 0027-daemon-lvm-Do-reverse-device-name-translation-on-pvs.patch index 634ee30..2a08c2e 100644 --- a/0028-daemon-lvm-Do-reverse-device-name-translation-on-pvs.patch +++ b/0027-daemon-lvm-Do-reverse-device-name-translation-on-pvs.patch @@ -1,4 +1,4 @@ -From ec56c62c90d2230e8edcfaaad4517be63f5e2183 Mon Sep 17 00:00:00 2001 +From 7052506cbfdb071c0d89c7ef6a14c1b17de9b208 Mon Sep 17 00:00:00 2001 From: "Richard W.M. Jones" Date: Thu, 20 Jul 2023 11:15:26 +0100 Subject: [PATCH] daemon: lvm: Do reverse device name translation on pvs_full diff --git a/0029-ruby-Replace-MiniTest-with-Minitest.patch b/0028-ruby-Replace-MiniTest-with-Minitest.patch similarity index 99% rename from 0029-ruby-Replace-MiniTest-with-Minitest.patch rename to 0028-ruby-Replace-MiniTest-with-Minitest.patch index 8e2b970..e3be86c 100644 --- a/0029-ruby-Replace-MiniTest-with-Minitest.patch +++ b/0028-ruby-Replace-MiniTest-with-Minitest.patch @@ -1,4 +1,4 @@ -From a55474caa5029c8356957afe36908ee45484ffde Mon Sep 17 00:00:00 2001 +From e22e511b1f2e5010ef889171ea7ba57519f39a39 Mon Sep 17 00:00:00 2001 From: "Richard W.M. Jones" Date: Thu, 21 Sep 2023 15:16:51 +0100 Subject: [PATCH] ruby: Replace MiniTest with Minitest diff --git a/0030-ruby-Get-rid-of-old-Test-Unit-compatibility.patch b/0029-ruby-Get-rid-of-old-Test-Unit-compatibility.patch similarity index 99% rename from 0030-ruby-Get-rid-of-old-Test-Unit-compatibility.patch rename to 0029-ruby-Get-rid-of-old-Test-Unit-compatibility.patch index a592cc0..61dec29 100644 --- a/0030-ruby-Get-rid-of-old-Test-Unit-compatibility.patch +++ b/0029-ruby-Get-rid-of-old-Test-Unit-compatibility.patch @@ -1,4 +1,4 @@ -From e22e17704988b606e24e76160495626552d0845f Mon Sep 17 00:00:00 2001 +From 6272924b7cf2320d5d89c6b5a0e1bd169a0caac2 Mon Sep 17 00:00:00 2001 From: "Richard W.M. Jones" Date: Thu, 21 Sep 2023 15:20:55 +0100 Subject: [PATCH] ruby: Get rid of old Test::Unit compatibility diff --git a/0031-generator-Sort-virt-customize-options-into-alphabeti.patch b/0030-generator-Sort-virt-customize-options-into-alphabeti.patch similarity index 96% rename from 0031-generator-Sort-virt-customize-options-into-alphabeti.patch rename to 0030-generator-Sort-virt-customize-options-into-alphabeti.patch index 7c82ec3..e3b895c 100644 --- a/0031-generator-Sort-virt-customize-options-into-alphabeti.patch +++ b/0030-generator-Sort-virt-customize-options-into-alphabeti.patch @@ -1,4 +1,4 @@ -From 205e2219b977e70c97ea4b55153d94dc3df91c28 Mon Sep 17 00:00:00 2001 +From 57f2fa619d238778f1cd8e38b014b1b6a4e32058 Mon Sep 17 00:00:00 2001 From: "Richard W.M. Jones" Date: Thu, 26 Oct 2023 21:06:21 +0100 Subject: [PATCH] generator: Sort virt-customize options into alphabetical diff --git a/0032-generator-Add-new-virt-customize-tar-in-operation.patch b/0031-generator-Add-new-virt-customize-tar-in-operation.patch similarity index 99% rename from 0032-generator-Add-new-virt-customize-tar-in-operation.patch rename to 0031-generator-Add-new-virt-customize-tar-in-operation.patch index 7091730..4292be0 100644 --- a/0032-generator-Add-new-virt-customize-tar-in-operation.patch +++ b/0031-generator-Add-new-virt-customize-tar-in-operation.patch @@ -1,4 +1,4 @@ -From 055c43fa60c7cefbe3baf32b21cfe8ffae09bf0f Mon Sep 17 00:00:00 2001 +From 4be6e5f426270550ab24c612502dfe74217db51b Mon Sep 17 00:00:00 2001 From: "Richard W.M. Jones" Date: Thu, 26 Oct 2023 19:44:03 +0100 Subject: [PATCH] generator: Add new virt-customize --tar-in operation diff --git a/0033-New-mailing-list-email-address.patch b/0032-New-mailing-list-email-address.patch similarity index 99% rename from 0033-New-mailing-list-email-address.patch rename to 0032-New-mailing-list-email-address.patch index 5a1b812..e60283e 100644 --- a/0033-New-mailing-list-email-address.patch +++ b/0032-New-mailing-list-email-address.patch @@ -1,4 +1,4 @@ -From 0c1d7af8fdbf272f33ccd572ed34923ab094d695 Mon Sep 17 00:00:00 2001 +From 0834340ed9995ce29f037a8a93fa17ea4721f5a7 Mon Sep 17 00:00:00 2001 From: "Richard W.M. Jones" Date: Thu, 16 Nov 2023 10:38:59 +0000 Subject: [PATCH] New mailing list email address diff --git a/0034-New-mailing-list-archives.patch b/0033-New-mailing-list-archives.patch similarity index 98% rename from 0034-New-mailing-list-archives.patch rename to 0033-New-mailing-list-archives.patch index 5e8873c..9c3a382 100644 --- a/0034-New-mailing-list-archives.patch +++ b/0033-New-mailing-list-archives.patch @@ -1,4 +1,4 @@ -From d5a52e1004b7b151a1df286a72e49e9766ade2c8 Mon Sep 17 00:00:00 2001 +From 0836003f9f7f9ccbd803388d1b716d0cdb70ae6d Mon Sep 17 00:00:00 2001 From: "Richard W.M. Jones" Date: Thu, 16 Nov 2023 10:52:11 +0000 Subject: [PATCH] New mailing list archives @@ -43,10 +43,10 @@ index 40a7267e..b350edb5 100644 To find out how to build libguestfs from source, read: diff --git a/configure.ac b/configure.ac -index d1397f63..f8e5e9bb 100644 +index 0db21297..74f6d20b 100644 --- a/configure.ac +++ b/configure.ac -@@ -322,7 +322,7 @@ echo "If any optional component is configured 'no' when you expected 'yes'" +@@ -321,7 +321,7 @@ echo "If any optional component is configured 'no' when you expected 'yes'" echo "then you should check the preceding messages." echo echo "Please report bugs back to the mailing list:" @@ -87,10 +87,10 @@ index 1e83a9c5..3a03282f 100644 into the libguestfs project. diff --git a/docs/guestfs-hacking.pod b/docs/guestfs-hacking.pod -index 68cf8292..f0bac9f2 100644 +index e1b47ec1..987697b2 100644 --- a/docs/guestfs-hacking.pod +++ b/docs/guestfs-hacking.pod -@@ -818,7 +818,7 @@ examining the F log files carefully. +@@ -804,7 +804,7 @@ examining the F log files carefully. =head2 SUBMITTING PATCHES Submit patches to the mailing list: diff --git a/0035-lib-Include-libxml-parser.h-for-xmlReadMemory.patch b/0034-lib-Include-libxml-parser.h-for-xmlReadMemory.patch similarity index 91% rename from 0035-lib-Include-libxml-parser.h-for-xmlReadMemory.patch rename to 0034-lib-Include-libxml-parser.h-for-xmlReadMemory.patch index 1b8ee36..5121fdc 100644 --- a/0035-lib-Include-libxml-parser.h-for-xmlReadMemory.patch +++ b/0034-lib-Include-libxml-parser.h-for-xmlReadMemory.patch @@ -1,4 +1,4 @@ -From 64a928f631bc79d885d9822a3022c382cbd5fd55 Mon Sep 17 00:00:00 2001 +From 769a5fe0d135ec7181416475e89571b6d0a55d0e Mon Sep 17 00:00:00 2001 From: "Richard W.M. Jones" Date: Mon, 27 Nov 2023 14:04:33 +0000 Subject: [PATCH] lib: Include for xmlReadMemory diff --git a/0036-ocaml-Use-Gc.finalise-instead-of-a-C-finalizer.patch b/0035-ocaml-Use-Gc.finalise-instead-of-a-C-finalizer.patch similarity index 98% rename from 0036-ocaml-Use-Gc.finalise-instead-of-a-C-finalizer.patch rename to 0035-ocaml-Use-Gc.finalise-instead-of-a-C-finalizer.patch index 909722c..9a67b8c 100644 --- a/0036-ocaml-Use-Gc.finalise-instead-of-a-C-finalizer.patch +++ b/0035-ocaml-Use-Gc.finalise-instead-of-a-C-finalizer.patch @@ -1,4 +1,4 @@ -From 27aca404cfbfdf9b3d155fa0794f86936525f40c Mon Sep 17 00:00:00 2001 +From 2fc136404619b2d2161326d1ca1ce3715728f04f Mon Sep 17 00:00:00 2001 From: "Richard W.M. Jones" Date: Wed, 13 Dec 2023 22:50:56 +0000 Subject: [PATCH] ocaml: Use Gc.finalise instead of a C finalizer diff --git a/0037-ocaml-Nullify-custom-block-before-releasing-runtime-.patch b/0036-ocaml-Nullify-custom-block-before-releasing-runtime-.patch similarity index 94% rename from 0037-ocaml-Nullify-custom-block-before-releasing-runtime-.patch rename to 0036-ocaml-Nullify-custom-block-before-releasing-runtime-.patch index 20ee83c..04f65b6 100644 --- a/0037-ocaml-Nullify-custom-block-before-releasing-runtime-.patch +++ b/0036-ocaml-Nullify-custom-block-before-releasing-runtime-.patch @@ -1,4 +1,4 @@ -From 9f52ab7794bf54169139995c5296aa5f39e47706 Mon Sep 17 00:00:00 2001 +From e9ef90e37334453a8ce7cf28665fd7b2ea354b82 Mon Sep 17 00:00:00 2001 From: "Richard W.M. Jones" Date: Thu, 14 Dec 2023 08:33:10 +0000 Subject: [PATCH] ocaml: Nullify custom block before releasing runtime lock diff --git a/0038-Update-common-submodule.patch b/0037-Update-common-submodule.patch similarity index 98% rename from 0038-Update-common-submodule.patch rename to 0037-Update-common-submodule.patch index 4ec3781..d3b1d7e 100644 --- a/0038-Update-common-submodule.patch +++ b/0037-Update-common-submodule.patch @@ -1,4 +1,4 @@ -From d015c300eb0d6ac1d366cf02b15b7aade7e3063a Mon Sep 17 00:00:00 2001 +From 52fb4507fee2a2e261515576d9b130c892e539d7 Mon Sep 17 00:00:00 2001 From: "Richard W.M. Jones" Date: Thu, 14 Dec 2023 09:03:49 +0000 Subject: [PATCH] Update common submodule diff --git a/0039-tests-Test-guestfish-key-all-.-selector.patch b/0038-tests-Test-guestfish-key-all-.-selector.patch similarity index 94% rename from 0039-tests-Test-guestfish-key-all-.-selector.patch rename to 0038-tests-Test-guestfish-key-all-.-selector.patch index 7cf5487..9381831 100644 --- a/0039-tests-Test-guestfish-key-all-.-selector.patch +++ b/0038-tests-Test-guestfish-key-all-.-selector.patch @@ -1,4 +1,4 @@ -From 335642539772cfee442989f56f1b5d7803e4111c Mon Sep 17 00:00:00 2001 +From 84da41bab6f93b2091f23602e276cc7fb62778e3 Mon Sep 17 00:00:00 2001 From: "Richard W.M. Jones" Date: Thu, 14 Dec 2023 09:15:08 +0000 Subject: [PATCH] tests: Test guestfish --key all:... selector diff --git a/0040-generator-customize.ml-Split-chown-parameter-on-char.patch b/0039-generator-customize.ml-Split-chown-parameter-on-char.patch similarity index 96% rename from 0040-generator-customize.ml-Split-chown-parameter-on-char.patch rename to 0039-generator-customize.ml-Split-chown-parameter-on-char.patch index 441a954..2b9e85e 100644 --- a/0040-generator-customize.ml-Split-chown-parameter-on-char.patch +++ b/0039-generator-customize.ml-Split-chown-parameter-on-char.patch @@ -1,4 +1,4 @@ -From 62e0172825304e3abe8e917d12bc5e5cb45b76cd Mon Sep 17 00:00:00 2001 +From ad473ca6b681170da08c170c869fa6f61d5934e4 Mon Sep 17 00:00:00 2001 From: "Richard W.M. Jones" Date: Fri, 19 Jan 2024 13:18:00 +0000 Subject: [PATCH] generator/customize.ml: Split --chown parameter on ':' diff --git a/0041-daemon-parted-Print-field-we-are-extracting-in-error.patch b/0040-daemon-parted-Print-field-we-are-extracting-in-error.patch similarity index 92% rename from 0041-daemon-parted-Print-field-we-are-extracting-in-error.patch rename to 0040-daemon-parted-Print-field-we-are-extracting-in-error.patch index f52170d..fcfc6ed 100644 --- a/0041-daemon-parted-Print-field-we-are-extracting-in-error.patch +++ b/0040-daemon-parted-Print-field-we-are-extracting-in-error.patch @@ -1,4 +1,4 @@ -From fad637f859e89a8110c353fe26029de818d369f1 Mon Sep 17 00:00:00 2001 +From fc34a457be847e8a36704c23b5119f2cfaa4d4ee Mon Sep 17 00:00:00 2001 From: "Richard W.M. Jones" Date: Thu, 7 Mar 2024 14:17:45 +0000 Subject: [PATCH] daemon: parted: Print field we are extracting in error diff --git a/0042-python-Fix-exception-name-in-example.patch b/0041-python-Fix-exception-name-in-example.patch similarity index 93% rename from 0042-python-Fix-exception-name-in-example.patch rename to 0041-python-Fix-exception-name-in-example.patch index 84f2936..170d263 100644 --- a/0042-python-Fix-exception-name-in-example.patch +++ b/0041-python-Fix-exception-name-in-example.patch @@ -1,4 +1,4 @@ -From 25adec46d2b2042aa8c58b8c6103a9aa195d046a Mon Sep 17 00:00:00 2001 +From 1438bf8a356303f8545f2beb89aa97b71f0b1ded Mon Sep 17 00:00:00 2001 From: "Richard W.M. Jones" Date: Tue, 12 Mar 2024 14:08:03 +0000 Subject: [PATCH] python: Fix exception name in example diff --git a/0043-po-docs-Rename-guestfs-release-notes-historical-to-g.patch b/0042-po-docs-Rename-guestfs-release-notes-historical-to-g.patch similarity index 93% rename from 0043-po-docs-Rename-guestfs-release-notes-historical-to-g.patch rename to 0042-po-docs-Rename-guestfs-release-notes-historical-to-g.patch index 6ee29b5..9145fcf 100644 --- a/0043-po-docs-Rename-guestfs-release-notes-historical-to-g.patch +++ b/0042-po-docs-Rename-guestfs-release-notes-historical-to-g.patch @@ -1,4 +1,4 @@ -From 21d7687521e611a243f9f217b8de799452dff260 Mon Sep 17 00:00:00 2001 +From c33f35c9d82d7e35de85544ec11696c47764c83c Mon Sep 17 00:00:00 2001 From: "Richard W.M. Jones" Date: Thu, 4 Apr 2024 09:28:43 +0100 Subject: [PATCH] po-docs: Rename guestfs-release-notes-historical to diff --git a/0044-po-docs-Run-po4a-translate-and-sed-commands-separate.patch b/0043-po-docs-Run-po4a-translate-and-sed-commands-separate.patch similarity index 95% rename from 0044-po-docs-Run-po4a-translate-and-sed-commands-separate.patch rename to 0043-po-docs-Run-po4a-translate-and-sed-commands-separate.patch index 8b27607..bf3f069 100644 --- a/0044-po-docs-Run-po4a-translate-and-sed-commands-separate.patch +++ b/0043-po-docs-Run-po4a-translate-and-sed-commands-separate.patch @@ -1,4 +1,4 @@ -From e1ee1fb65798777287ae7722b9391969623da97f Mon Sep 17 00:00:00 2001 +From db04f9adc4e03ac32a303e9414acbdc215c521f2 Mon Sep 17 00:00:00 2001 From: "Richard W.M. Jones" Date: Thu, 4 Apr 2024 09:38:28 +0100 Subject: [PATCH] po-docs: Run po4a-translate and sed commands separately diff --git a/0045-Update-common-submodule.patch b/0044-Update-common-submodule.patch similarity index 96% rename from 0045-Update-common-submodule.patch rename to 0044-Update-common-submodule.patch index a1c2183..4d978e6 100644 --- a/0045-Update-common-submodule.patch +++ b/0044-Update-common-submodule.patch @@ -1,4 +1,4 @@ -From 55810672dedbabf40938519eb37d7a470c28ea6a Mon Sep 17 00:00:00 2001 +From d3f1b35aadb15500985b401b15571f5406f2aedf Mon Sep 17 00:00:00 2001 From: "Richard W.M. Jones" Date: Wed, 24 Apr 2024 12:23:34 +0100 Subject: [PATCH] Update common submodule diff --git a/0046-po-docs-Make-sure-guestmount.1-depends-on-includes.patch b/0045-po-docs-Make-sure-guestmount.1-depends-on-includes.patch similarity index 95% rename from 0046-po-docs-Make-sure-guestmount.1-depends-on-includes.patch rename to 0045-po-docs-Make-sure-guestmount.1-depends-on-includes.patch index 53052e0..fd07880 100644 --- a/0046-po-docs-Make-sure-guestmount.1-depends-on-includes.patch +++ b/0045-po-docs-Make-sure-guestmount.1-depends-on-includes.patch @@ -1,4 +1,4 @@ -From 5efc6ee4723c828655c4ea2b56f40c0156536762 Mon Sep 17 00:00:00 2001 +From 406be1f7489326083f6d8bb532a0c65c667da825 Mon Sep 17 00:00:00 2001 From: "Richard W.M. Jones" Date: Wed, 24 Apr 2024 22:15:16 +0100 Subject: [PATCH] po-docs: Make sure guestmount.1 depends on includes diff --git a/libguestfs.spec b/libguestfs.spec index e35264d..5ddffa7 100644 --- a/libguestfs.spec +++ b/libguestfs.spec @@ -45,7 +45,7 @@ Summary: Access and modify virtual machine disk images Name: libguestfs Epoch: 1 Version: 1.50.1 -Release: 9%{?dist} +Release: 10%{?dist} License: LGPLv2+ # Build only for architectures that have a kernel @@ -100,43 +100,42 @@ Patch0006: 0006-RHEL-Disable-unsupported-remote-drive-protocols-RHBZ.patch Patch0007: 0007-RHEL-Reject-use-of-libguestfs-winsupport-features-ex.patch Patch0008: 0008-Remove-virt-dib.patch Patch0009: 0009-lib-Choose-q35-machine-type-for-x86-64.patch -Patch0010: 0010-RHEL-Revert-build-Remove-bundled-copy-of-ocaml-augea.patch -Patch0011: 0011-update-common-submodule.patch -Patch0012: 0012-LUKS-on-LVM-inspection-test-rename-VGs-and-LVs.patch -Patch0013: 0013-LUKS-on-LVM-inspection-test-test-dev-mapper-VG-LV-tr.patch -Patch0014: 0014-Replace-Pervasives.-with-Stdlib.patch -Patch0015: 0015-fuse-Don-t-call-fclose-NULL-on-error-paths.patch -Patch0016: 0016-ocaml-implicit_close-test-collect-all-currently-unre.patch -Patch0017: 0017-ocaml-Replace-old-enter-leave_blocking_section-calls.patch -Patch0018: 0018-ocaml-Release-runtime-lock-around-guestfs_close.patch -Patch0019: 0019-ocaml-Conditionally-acquire-the-lock-in-callbacks.patch -Patch0020: 0020-ocaml-Fix-guestfs_065_implicit_close.ml-for-OCaml-5.patch -Patch0021: 0021-ocaml-Use-Caml_state_opt-in-preference-to-caml_state.patch -Patch0022: 0022-generator-Add-chown-option-for-virt-customize.patch -Patch0023: 0023-lib-remove-guestfs_int_cmd_clear_close_files.patch -Patch0024: 0024-docs-fix-broken-link-in-the-guestfs-manual.patch -Patch0025: 0025-docs-clarify-sockdir-s-separation.patch -Patch0026: 0026-lib-move-guestfs_int_create_socketname-from-launch.c.patch -Patch0027: 0027-generator-customize-Add-new-StringTriplet-for-use-by.patch -Patch0028: 0028-daemon-lvm-Do-reverse-device-name-translation-on-pvs.patch -Patch0029: 0029-ruby-Replace-MiniTest-with-Minitest.patch -Patch0030: 0030-ruby-Get-rid-of-old-Test-Unit-compatibility.patch -Patch0031: 0031-generator-Sort-virt-customize-options-into-alphabeti.patch -Patch0032: 0032-generator-Add-new-virt-customize-tar-in-operation.patch -Patch0033: 0033-New-mailing-list-email-address.patch -Patch0034: 0034-New-mailing-list-archives.patch -Patch0035: 0035-lib-Include-libxml-parser.h-for-xmlReadMemory.patch -Patch0036: 0036-ocaml-Use-Gc.finalise-instead-of-a-C-finalizer.patch -Patch0037: 0037-ocaml-Nullify-custom-block-before-releasing-runtime-.patch -Patch0038: 0038-Update-common-submodule.patch -Patch0039: 0039-tests-Test-guestfish-key-all-.-selector.patch -Patch0040: 0040-generator-customize.ml-Split-chown-parameter-on-char.patch -Patch0041: 0041-daemon-parted-Print-field-we-are-extracting-in-error.patch -Patch0042: 0042-python-Fix-exception-name-in-example.patch -Patch0043: 0043-po-docs-Rename-guestfs-release-notes-historical-to-g.patch -Patch0044: 0044-po-docs-Run-po4a-translate-and-sed-commands-separate.patch -Patch0045: 0045-Update-common-submodule.patch -Patch0046: 0046-po-docs-Make-sure-guestmount.1-depends-on-includes.patch +Patch0010: 0010-update-common-submodule.patch +Patch0011: 0011-LUKS-on-LVM-inspection-test-rename-VGs-and-LVs.patch +Patch0012: 0012-LUKS-on-LVM-inspection-test-test-dev-mapper-VG-LV-tr.patch +Patch0013: 0013-Replace-Pervasives.-with-Stdlib.patch +Patch0014: 0014-fuse-Don-t-call-fclose-NULL-on-error-paths.patch +Patch0015: 0015-ocaml-implicit_close-test-collect-all-currently-unre.patch +Patch0016: 0016-ocaml-Replace-old-enter-leave_blocking_section-calls.patch +Patch0017: 0017-ocaml-Release-runtime-lock-around-guestfs_close.patch +Patch0018: 0018-ocaml-Conditionally-acquire-the-lock-in-callbacks.patch +Patch0019: 0019-ocaml-Fix-guestfs_065_implicit_close.ml-for-OCaml-5.patch +Patch0020: 0020-ocaml-Use-Caml_state_opt-in-preference-to-caml_state.patch +Patch0021: 0021-generator-Add-chown-option-for-virt-customize.patch +Patch0022: 0022-lib-remove-guestfs_int_cmd_clear_close_files.patch +Patch0023: 0023-docs-fix-broken-link-in-the-guestfs-manual.patch +Patch0024: 0024-docs-clarify-sockdir-s-separation.patch +Patch0025: 0025-lib-move-guestfs_int_create_socketname-from-launch.c.patch +Patch0026: 0026-generator-customize-Add-new-StringTriplet-for-use-by.patch +Patch0027: 0027-daemon-lvm-Do-reverse-device-name-translation-on-pvs.patch +Patch0028: 0028-ruby-Replace-MiniTest-with-Minitest.patch +Patch0029: 0029-ruby-Get-rid-of-old-Test-Unit-compatibility.patch +Patch0030: 0030-generator-Sort-virt-customize-options-into-alphabeti.patch +Patch0031: 0031-generator-Add-new-virt-customize-tar-in-operation.patch +Patch0032: 0032-New-mailing-list-email-address.patch +Patch0033: 0033-New-mailing-list-archives.patch +Patch0034: 0034-lib-Include-libxml-parser.h-for-xmlReadMemory.patch +Patch0035: 0035-ocaml-Use-Gc.finalise-instead-of-a-C-finalizer.patch +Patch0036: 0036-ocaml-Nullify-custom-block-before-releasing-runtime-.patch +Patch0037: 0037-Update-common-submodule.patch +Patch0038: 0038-tests-Test-guestfish-key-all-.-selector.patch +Patch0039: 0039-generator-customize.ml-Split-chown-parameter-on-char.patch +Patch0040: 0040-daemon-parted-Print-field-we-are-extracting-in-error.patch +Patch0041: 0041-python-Fix-exception-name-in-example.patch +Patch0042: 0042-po-docs-Rename-guestfs-release-notes-historical-to-g.patch +Patch0043: 0043-po-docs-Run-po4a-translate-and-sed-commands-separate.patch +Patch0044: 0044-Update-common-submodule.patch +Patch0045: 0045-po-docs-Make-sure-guestmount.1-depends-on-includes.patch %if 0%{patches_touch_autotools} BuildRequires: autoconf, automake, libtool, gettext-devel @@ -155,8 +154,7 @@ BuildRequires: perl(Pod::Man) BuildRequires: /usr/bin/pod2text BuildRequires: po4a BuildRequires: augeas-devel >= 1.7.0 -# Waiting for https://bugzilla.redhat.com/show_bug.cgi?id=2168634 -#BuildRequires: ocaml-augeas-devel >= 0.6 +BuildRequires: ocaml-augeas-devel >= 0.6 BuildRequires: readline-devel BuildRequires: xorriso BuildRequires: libxml2-devel @@ -1150,6 +1148,10 @@ rm ocaml/html/.gitignore %changelog +* Thu Jun 20 2024 Richard W.M. Jones - 1:1.50.1-10 +- Remove bundled ocaml-augeas + resolves: RHEL-32142 + * Wed Apr 24 2024 Richard W.M. Jones - 1:1.50.1-9 - Add support for nbd+unix:// URIs resolves: RHEL-33851