gluon/scripts
Matthias Schiffer 9e23534ec3
build: rework config generation
So far, we were using a sort operation on the generated .config to
implement precedence of =y packages over =m, and =m over unset.
Unfortunately, this sort not only used for packages, but for all config
lines. This made it impossible to override settings from targets/generic
in a target config when the new setting was sorted before the generic
setting.

To fix this, track configurations by their keys, so we can properly
override config keys that were set before. Value-based precedence is
only preserved for package configuration.

The config() and try_config() calls always take key and value as
separate arguments now. Strings are quoted automatically; the values
true, nil and false map to y, m and unset for tristate options. config()
can take an optional third argument to override the error message to
display when the setting fails to apply.

All existing target configs generate the same .config with the old and the
new code. The new code is also a bit faster on targets with many devices.
2020-05-31 02:20:58 +02:00
..
check_site.lua scripts: check_site: add need_number_range check 2020-04-30 01:54:35 +02:00
clean_output.lua scripts: avoid global variables in target handler scripts 2019-06-18 01:34:45 +02:00
copy_output.lua build: move package list generation to target_config_lib.lua, fix precedence 2020-05-03 22:05:20 +02:00
default_feeds.sh build: ignore deactivated feeds 2020-05-12 19:46:36 +02:00
domain_aliases.lua gluon-core: add domain aliases and pretty name 2018-01-26 12:32:47 +01:00
features.sh treewide: solve shellcheck warnings 2019-12-14 18:35:11 +01:00
feeds.sh build: allow overriding the base feed list 2020-04-09 14:30:44 +02:00
filesize.sh treewide: solve shellcheck warnings 2019-12-14 18:35:11 +01:00
generate_manifest.lua scripts/target_lib.lua: reorganize images into per-device lists 2020-04-25 21:35:44 +02:00
lint-lua.sh build: add make targets lint, lint-sh, lint-lua 2019-12-29 15:18:50 +01:00
lint-sh.sh build: add make targets lint, lint-sh, lint-lua 2019-12-29 15:18:50 +01:00
modules.sh treewide: solve shellcheck warnings 2019-12-14 18:35:11 +01:00
patch.sh treewide: solve shellcheck warnings 2019-12-14 18:35:11 +01:00
rfc3339date.lua scripts/rfc3339date.lua: fix pattern validity 2014-07-21 03:44:53 +02:00
sha256sum.sh treewide: solve shellcheck warnings 2019-12-14 18:35:11 +01:00
sha512sum.sh treewide: solve shellcheck warnings 2019-12-14 18:35:11 +01:00
site_config.lua Switch to Lua for target definitions 2019-06-15 23:34:07 +02:00
target_config_check.lua build: rework config generation 2020-05-31 02:20:58 +02:00
target_config_lib.lua build: rework config generation 2020-05-31 02:20:58 +02:00
target_config.lua build: rework config generation 2020-05-31 02:20:58 +02:00
target_lib.lua build: rework config generation 2020-05-31 02:20:58 +02:00
update-patches.sh scripts: update-patches: fix shellcheck 0.7.1 lint 2020-05-25 01:10:18 +02:00
update.sh treewide: solve shellcheck warnings 2019-12-14 18:35:11 +01:00