GNOME Bugzilla – Bug 739338
Preparatory work for building SDK/Platform in gnome-continuos
Last modified: 2021-06-05 16:29:53 UTC
This is a set of patches needed for my work with using continuos to build a gnome platform. The major change is in how we define what components go to a target, as they are now based on a generic grouping, rather than strict hiearchies. This is needed as the platform doesn't need some low-level hw/boot things that the other targets need. Then there are some other minor additions/changes.
Created attachment 289566 [details] [review] Wrap python trigger in shell The platform component doesn't have python, so starting python directly from the systemd trigger fails. However, it also doesn't need systemd, so we wrap it in a shellscript that checks for the existance of python first.
Created attachment 289567 [details] [review] fileutils: Support enumerating directories if matchDirs is true This is needed as i want to use walkDir to clean up stuff, including directories.
Created attachment 289568 [details] [review] Use groups to pick components for different targets Right now we're using a single-value "component" property to pick what targets to put each component in. Then there is some hardcoded logic to pick which of these to put in each target. In order to handle the hwtest and the runtime sharing packages a "minial" component was introduced to allow some components to be in multiple targets. However, such a setup requires a strict hierarchical definition of all components, which scales badly with adding more targets with different subsets. Instead we switch to a groups based system, where all the components which previously had "component = minimal" now have "groups = runtime, hwtest" and the other components just keeps the old component as the single group. We also define a "targets" toplevel item that lists the targets to compose and which groups each should contain, and which subtrees to use when composing. This doesn't change what is built or how, but it makes things more flexible when adding more targets in the future.
Created attachment 289569 [details] [review] Add keep-only component property If this is set then only the listed files will be part of the component. Everything else will be deleted. This is needed to create a simple libudev package from the systemd sources, as it can't (easily) install libudev only.
Review of attachment 289566 [details] [review]: Ok.
Review of attachment 289567 [details] [review]: Is it intentional the matches don't apply to the subdir too? For example if matchName doesn't match when matchDirs, we still do the callback? If so, maybe call the parameter "directoryCallbacks" or something?
Review of attachment 289568 [details] [review]: This is very much superior to what we had before, thanks =)
Review of attachment 289569 [details] [review]: ::: src/js/tasks/task-build.js @@ +454,3 @@ + } + } + GSystem.file_unlink(filePath, cancellable); This leaves empty directories around, no? Maybe that doesn't matter too much in most cases, but e.g. I'd not expect there to be a /usr/lib/systemd/system in the SDK. This might also be an appropriate place for regexps instead of string prefix matches (maybe...globs would be annoying to implement).
gnome-continuous is not under active development anymore. Its codebase has been archived: https://gitlab.gnome.org/Archive/gnome-continuous Closing all its open tickets as part of housekeeping.