The repo bootstrap logic has worked well enough in the initial systemd
bringup. But we have decided to replace the approach of building
packages multiple times during the repo_bootstrap with building each
package only once and adding -stage0 packages where necessary (currently
only a systemd-stage0 package).
Advantages:
* Replace the often breaking repo_bootstrap logic with something less
fragile (repo_bootstrap is currently broken again).
* Can get rid of the whole bootstrap logic in pmaports.cfg, pmbootstrap,
build.postmarketos.org. This will make pmbootstrap and bpo easier to
maintain.
* Fix problems we have seen when upgrading two or more of (systemd,
dbus, linux-pam-pmos) at once: it doesn't pass in CI and it doesn't
pass in BPO
* You don't need to do a whole bootstrap at once, it is again broken
down by package. This means if building one package fails (locally or
in bpo), we don't need to do the whole thing again, just start at the
package that failed. This also means it is much easier to optimize
e.g. the stage0 packages to build faster.
* Fixes some specific bugs we currently have (abuild twice in pmaports,
bpo tests disabled because of that, ...)
Part-of: https://gitlab.postmarketos.org/postmarketOS/pmbootstrap/-/merge_requests/2588
Add a new environment variable that disables apk's caching feature for
space constrained environments such as the bpo image build jobs.
Currently we have a workaround in place in bpo: the apk cache is moved
to a tmpfs. But this is fragile and just disabling the apk cache is a
more elegant solution.
I've decided to make this an env var instead of a full pmbootstrap
option since this option is not relevant for normal users, only for CI
jobs in space constrained environments. Also we already have another
`PMB_APK_` env var.
Related: bpo issue 136
Part-of: https://gitlab.postmarketos.org/postmarketOS/pmbootstrap/-/merge_requests/2553
Now that systemd was merged into master, it is extra-repos/systemd
instead of staging/systemd.
As of writing, the repository is not published yet but this will happen
soon.
Related: https://postmarketos.org/edge/2025/01/09/systemd-soon/
I tried my best to get the right author based on git commit history, but
in the case of code being moved from one file to make another I might
have gotten something wrong.
Add module that provides utilities and information related to localization.
Initial implementation includes code to generate keyboard configs
for locale set by user.
Fix the following:
WARNING: Failed to import pmb.commands.kconfig_check.
WARNING: Failed to import pmb.commands.kconfig_edit.
WARNING: Failed to import pmb.core.crosstool.
Crosstool has been dropped and kconfig_check/_edit code has been merged
into a kconfig module.
* Make sure all Python modules are documented by adding a bit of shell
to .ci/docs.sh
* Remove non-existing module references from .rst
* Fix various warnings from sphinx by adjusting Python docstrings
* Add class member docs to ApkindexBlock
Remove arguments to set postmarketOS and Alpine mirrors.
The current implementation is broken with the way the mirrors are now
configured: The current implementation fills a list, but the mirror
configuration code expects a string. It is not longer possible to set
an arbitrary amount of mirrors for the postmarketOS mirror. The benefit
is that we don't have comma separated values in the config file anymore
but instead just simple strings. Now it is possible to have one proper
mirror for aports, pmaports and pmaports_systemd, and one _custom one
to override each of these.
We already have too many options in "pmbootstrap -h", and changing a
mirror is more of a base configuration that you do once and maybe change
a few times, but don't need to be able to set it with each pmbootstrap
run. Users are not going to write this out manually on their
command-lines, it only makes sense in scripts and wrappers for
pmbootstrap, and there you could as well use another method (as now
described in docs/mirrors.md) to set the mirrors.
Less important, but another reason is that using "-mp" (two letters as
short argument) isn't really elegant.
Let's write all new documentation in markdown, and convert existing ones
at some point. I think we are all much more familiar with markdown than
with the rst format.
Move all kconfig rules from pmb.config to a separate toml file
pmb/data/kconfigcheck.toml. This is a fallback, pmbootstrap now prefers
loading kconfigcheck.toml from the currently checked out pmaports branch
if it exists.
This finally allows having separate kconfig check rules per pmaports
branch and makes the workflow of adjusting these rules much more
pleasant as the rules and kernel configs can just be adjusted at the
same time in pmaports!
This patch also moves the definition of what rules should be checked for
community and main devices, those that have pmb:kconfigcheck-community
in their linux APKBUILD, to the new kconfigcheck.toml. This should make
it much more intuitive, previously one needed to find the place in the
pmbootstrap source and edit it there.
Furthermore the "enforce_check" logic is removed. Previously pmbootstrap
would print warnings for failed config checks in some cases, but not
exit with error which was very confusing. Now exit 0 means all checks
passed and exit 1 means, that there is at least one error.
Use toml for the file, as discussed in pmbootstrap issue 2165. Python
3.11 has a native toml reader, use tomli for previous Python versions
for compatibility.
Python 3.9 was required in pmb/__init__.py already, but some references
still said 3.8 and 3.7.
Co-Developed-By: Oliver Smith <ollieparanoid@postmarketos.org>