search for: quoted_list

Displaying 8 results from an estimated 8 matches for "quoted_list".

2014 Nov 24
5
[PATCH] rpm: use librpm's rpmvercmp
Bind and use rpmvercmp to compare versions of packages when sorting them, instead of an own string-based comparison function. --- src/librpm-c.c | 12 ++++++++++++ src/librpm.ml | 1 + src/librpm.mli | 1 + src/rpm.ml | 2 +- 4 files changed, 15 insertions(+), 1 deletion(-) diff --git a/src/librpm-c.c b/src/librpm-c.c index 1ae3bad..fc847d6 100644 --- a/src/librpm-c.c +++
2014 Nov 24
0
[PATCH] rpm: improve dnf invocation
.../rpm.ml b/src/rpm.ml index 771022e..46954c8 100644 --- a/src/rpm.ml +++ b/src/rpm.ml @@ -308,8 +308,14 @@ let rec fedora_download_all_packages pkgs dir = let rpms = pkgs_as_NA_rpms pkgs in let cmd = - sprintf "%s download --destdir %s %s" - Config.dnf (quote tdir) (quoted_list rpms) in + sprintf "%s download%s%s --destdir %s %s" + Config.dnf + (if !settings.debug >= 1 then " -v" else " -q") + (match !settings.packager_config with + | None -> "" + | Some filename -> sprintf " -c...
2016 Oct 31
5
[PATCH 0/4] supermin: use dnf on Mageia
Hi, as pointed out by Neal Gompa, Mageia recently introduced dnf in the distribution (currently only in Cauldron, which is the future Mageia 6), and most probably it will replace urpmi in the future. As such, on Mageia make supermin prefer dnf over urpmi when found, using the same code already used for Fedora. Related change: make test-harder.sh work explicitly also on Mageia
2014 Mar 15
5
A few easy dpkg optimizations for supermin
I have done some printf profiling and found that supermin's calls to dpkg for individual packages are quite expensive. Here are some patches that gather all information on demand where possible. On my Debian/unstable-based workstation at home, preparing a minimal appliance using $ ./supermin --use-installed --prepare bash -o supermin.d now takes ~3.5s (previously ~15s). Turning that
2014 Sep 17
4
[PATCH 0/2] supermin: use librpm for rpm support
Hi, this work makes supermin use the rpm library instead of invoking rpm directly. This, together with a needed refactoring of the dependency resolution, should help in make supermin faster on rpm-based systems. Surely the patches will still need polishing, especially for behaviours of newly added stuff, but at least it's a good starting point. Noting that you need rpm-devel on most of rpm
2016 Feb 18
0
[PATCH 3/3] Add and use an helper error function
...%s\n" (Printexc.to_string exn); - exit 1 + error "exception: %s" (Printexc.to_string exn) diff --git a/src/utils.ml b/src/utils.ml index 87c9cf7..4223be4 100644 --- a/src/utils.ml +++ b/src/utils.ml @@ -28,6 +28,13 @@ let (//) = Filename.concat let quote = Filename.quote let quoted_list names = String.concat " " (List.map quote names) +let error ?(exit_code = 1) fs = + let display str = + prerr_endline (sprintf "supermin: %s" str); + exit exit_code + in + ksprintf display fs + let dir_exists name = try (stat name).st_kind = S_DIR with Unix_err...
2016 Feb 18
4
[PATCH 0/3] supermin: miscellaneous cleanups
Hi, few cleanups in the supermin codebase; no actual functional change. Thanks, -- Pino Toscano (3): ext2: simplify tracking of visited modules utils: remove unused run_python function Add and use an helper error function src/build.ml | 20 +++++----------- src/dpkg.ml | 4 +--- src/ext2_initrd.ml | 10 ++++---- src/kernel.ml | 27
2014 Feb 25
2
[PATCH supermin v4] Supermin 5 rewrite.
...+ rpm.name + +let rpm_get_all_requires pkgs = + let get pkgs = + let cmd = sprintf "\ + rpm -qR %s | + awk '{print $1}' | + xargs rpm -q --qf '%%{name}\\n' --whatprovides | + grep -v 'no package provides' | + sort -u" + (quoted_list (List.map rpm_package_to_string + (PackageSet.elements pkgs))) in + let lines = run_command_get_lines cmd in + let lines = filter_map rpm_package_of_string lines in + PackageSet.union pkgs (package_set_of_list lines) + in + (* The command above only gets one level of...