search for: app2_version

Displaying 20 results from an estimated 25 matches for "app2_version".

2019 Jan 30
1
[PATCH v3] v2v: linux: use NEVR for querying RPM packages (RHBZ#1669395)
...86_64 is not installed + * Fedora 20 (rpm 4.11.2): + * $ rpm -q tar-2:1.26-30.fc20.x86_64 + * tar-1.26-30.fc20.x86_64 *) + let is_rpm_lt_4_11 () = + let ver = + try + let ver = List.find_map ( + function + | { G.app2_name = name; G.app2_version = version } + when name = "rpm" -> Some version + | _ -> None + ) inspect.i_apps in + if PCRE.matches re_version ver then + (int_of_string (PCRE.sub 1), int_of_string (PCRE.sub 2)) + else + (0, 0) + wi...
2019 Jan 30
1
[PATCH v2] v2v: linux: use NEVR for querying RPM packages (RHBZ#1669395)
...rpm -q tar-2:1.23-11.el6.x86_64 + * package tar-2:1.23-11.el6.x86_64 is not installed + * Fedora 20 (rpm 4.11.2): + * $ rpm -q tar-2:1.26-30.fc20.x86_64 + * tar-1.26-30.fc20.x86_64 *) - let pkg_name = - sprintf "%s-%s-%s" app.G.app2_name - app.G.app2_version app.G.app2_release in - let pkg_name = - if app.G.app2_epoch > 0_l then ( - (* RHEL 3/4 'rpm' does not support using the epoch prefix. - * (RHBZ#1170685). - *) - let is_rhel_lt_5 = - match inspect with - | { i_type = "linux&quo...
2019 Jan 29
2
[PATCH] v2v: linux: use NEVR for querying RPM packages (RHBZ#1669395)
...4 + * package tar-2:1.23-11.el6.x86_64 is not installed + * Fedora 20 (rpm 4.11.2): + * $ rpm -q tar-2:1.26-30.fc20.x86_64 + * tar-1.26-30.fc20.x86_64 *) + let rpm_major, rpm_minor = + let ver = List.find_map ( + function + | { G.app2_name = name; G.app2_version = version } + when name = "rpm" -> Some version + | _ -> None + ) inspect.i_apps in + match String.nsplit "." ver with + | [major] -> int_of_string major, 0 + | major :: minor :: _ -> int_of_string major, int_of_string minor +...
2019 Jan 30
0
Re: [PATCH] v2v: linux: use NEVR for querying RPM packages (RHBZ#1669395)
...6_64 is not installed > + * Fedora 20 (rpm 4.11.2): > + * $ rpm -q tar-2:1.26-30.fc20.x86_64 > + * tar-1.26-30.fc20.x86_64 > *) > + let rpm_major, rpm_minor = > + let ver = List.find_map ( > + function > + | { G.app2_name = name; G.app2_version = version } > + when name = "rpm" -> Some version > + | _ -> None > + ) inspect.i_apps in This has the nasty side effect of Not_found exception escaping if for some reason we can't find the rpm version. I think you should catch that case and ass...
2012 Nov 01
4
[PATCH v2 0/3] New inspect_list_applications2 API
Here's the new API method and update to virt-inspector. I still need to implement app_arch for debian and windows (if applicable), for now they just return empty strings. New in v2: incorporated feedback from v1, also added patch #3 which updates the documentation where it references the deprecated API. Take it or leave it.
2018 Oct 04
0
[PATCH v2 3/4] inspector: Use libxml writer macros.
....app2_display_name)); - - if (apps->val[i].app2_epoch != 0) { - char buf[32]; - - snprintf (buf, sizeof buf, "%d", apps->val[i].app2_epoch); - - XMLERROR (-1, - xmlTextWriterWriteElement (xo, BAD_CAST "epoch", BAD_CAST buf)); + if (apps->val[i].app2_version && apps->val[i].app2_version[0]) + single_element ("version", "%s", apps->val[i].app2_version); + if (apps->val[i].app2_release && apps->val[i].app2_release[0]) + single_element ("release", "%s", apps->v...
2016 May 12
0
[PATCH 11/11] v2v: improve initrd search
...vert ~keep_serial_console (g : G.guestfs) inspect source rcaps = try g#statns vmlinuz with G.Error _ -> raise Not_found in (* Get/construct the version. XXX Read this from kernel file. *) - let version = - sprintf "%s-%s" app.G.app2_version app.G.app2_release in + let prefix_len = String.length "/lib/modules/" in + let version = String.sub modpath prefix_len ((String.length modpath) - prefix_len) in (* Find the initramfs which corresponds to the kernel. * Since the initr...
2016 May 18
0
[PATCH v2 11/11] v2v: improve initrd search
...nction | { G.app2_name = name } as app @@ -158,7 +158,8 @@ let rec convert ~keep_serial_console (g : G.guestfs) inspect source rcaps = (* Get/construct the version. XXX Read this from kernel file. *) let version = - sprintf "%s-%s" app.G.app2_version app.G.app2_release in + let prefix_len = String.length "/lib/modules/" in + String.sub modpath prefix_len (String.length modpath - prefix_len) in (* Find the initramfs which corresponds to the kernel. * Since the initramfs is buil...
2018 Nov 02
7
[PATCH v3 0/4] common/utils: Move libxml2 writer macros to a common header file.
v1 was here: https://www.redhat.com/archives/libguestfs/2018-October/msg00047.html v2 was here: https://www.redhat.com/archives/libguestfs/2018-October/msg00051.html v3: - Back to using string/string_format and attribute/attribute_format. - Add both single_element and single_element_format. - Rebased and retested. Rich.
2018 Oct 04
2
[PATCH 0/2] Use common macros to help with libxml2 writer.
Consolidate and extend the use of funky start_element() etc macros. Rich.
2018 Oct 04
6
[PATCH v2 0/4] common/utils: Move libxml2 writer macros to a common header file.
v1 was here: https://www.redhat.com/archives/libguestfs/2018-October/msg00047.html However it was broken in a few ways. First of all the documentation was broken because "/**" enhanced comments were not permitted on macros. This is fixed in the new 1/4 patch. Secondly we didn't use single_element() everywhere possible, which is fixed in the new 4/4 patch. Lastly I've
2019 Jan 29
1
[PATCH] v2v: Fix kernel disambiguation by dropping Epoch field (RHBZ#1669395).
...m" -> (* Since RPM allows multiple packages installed with the same - * name, always check the full ENVR here (RHBZ#1161250). + * name, always check the full NVR here (RHBZ#1161250). *) let pkg_name = sprintf "%s-%s-%s" app.G.app2_name app.G.app2_version app.G.app2_release in - let pkg_name = - if app.G.app2_epoch > 0_l then ( - (* RHEL 3/4 'rpm' does not support using the epoch prefix. - * (RHBZ#1170685). - *) - let is_rhel_lt_5 = - match inspect with - | { i_type = "linux&quo...
2016 May 18
21
[PATCH v2 00/11] Getting it work with SLES / openSUSE
Hi all, v2 includes all comments from Pino and Richard. I also removed the mkdir /run/lvm in the init since it only failed in one case and couldn't reproduce it anymore. Cédric Bosdonnat (11): v2v: also search for windows virtio drivers in symlinks Update packagelist for SLES and openSUSE customize: fix windows firstboot script customize: change windows firstboot path customize:
2016 May 12
24
[PATCH 00/11] Getting it work with SLES / openSUSE
Hi there! I know it's been a while since I posted my first version of some patches. But here I have rebased them on top of Roman's work and added a few other ones. Cédric Bosdonnat (11): v2v: also search for windows virtio drivers in symlinks Update packagelist for SLES customize: fix windows firstboot script customize: change windows firstboot path customize: add support for
2015 Oct 05
0
[PATCH 2/2] Fix whitespace.
...) snprintf (buf, sizeof buf, "%d", apps->val[i].app2_epoch); XMLERROR (-1, - xmlTextWriterWriteElement (xo, BAD_CAST "epoch", BAD_CAST buf)); + xmlTextWriterWriteElement (xo, BAD_CAST "epoch", BAD_CAST buf)); } if (apps->val[i].app2_version && apps->val[i].app2_version[0]) XMLERROR (-1, - xmlTextWriterWriteElement (xo, BAD_CAST "version", - BAD_CAST apps->val[i].app2_version)); + xmlTextWriterWriteElement (xo, BAD_CAST "version", + BAD_CAST apps-...
2015 Oct 06
0
[PATCH 5/5] mllib: Replace various ad hoc string_* functions with String.*
...) files in (* Check vmlinuz & modpath exist. *) @@ -173,12 +173,12 @@ let rec convert ~keep_serial_console (g : G.guestfs) inspect source = let files = List.filter ( fun n -> - string_find n app.G.app2_version >= 0 && - string_find n app.G.app2_release >= 0 + String.find n app.G.app2_version >= 0 && + String.find n app.G.app2_release >= 0 ) files in (* Don't consider kdump ini...
2019 Feb 25
0
[PATCH 3/3] v2v: add -o json output mode
...; + + push_optional_int display "port" d.s_port; + + List.push_back doc ("display", JSON.Dict !display) + ); + + let inspect_dict = + let apps = + List.map ( + fun { G.app2_name = name; app2_display_name = display_name; + app2_epoch = epoch; app2_version = version; + app2_release = release; app2_arch = arch; } -> + JSON.Dict [ + "name", JSON.String name; + "display-name", JSON.String display_name; + "epoch", JSON.Int (Int64.of_int32 epoch); + "ve...
2019 Mar 29
0
[PATCH v2 3/3] v2v: add -o json output mode
...; + + push_optional_int display "port" d.s_port; + + List.push_back doc ("display", JSON.Dict !display) + ); + + let inspect_dict = + let apps = + List.map ( + fun { G.app2_name = name; app2_display_name = display_name; + app2_epoch = epoch; app2_version = version; + app2_release = release; app2_arch = arch; } -> + JSON.Dict [ + "name", JSON.String name; + "display-name", JSON.String display_name; + "epoch", JSON.Int (Int64.of_int32 epoch); + "ve...
2015 Oct 29
7
[PATCH 0/7] v2v: Miscellaneous refactorings.
Just refactoring. Rich.
2015 Oct 06
10
[PATCH 0/5] mllib: Hide bad String functions and miscellaneous refactoring.
Hide/prevent the use of bad string functions like String.lowercase. These are replaced by safe functions that won't break UTF-8 strings. Other miscellaneous refactoring. Rich.