Commit Graph

87 Commits

Author SHA1 Message Date
Martin Weinelt
85c0bd6f57
scripts/check_site.lua: add table_keys() helper 2018-03-20 17:23:48 +01:00
Matthias Schiffer
1a7d93a2b9
scripts/check_site.lua: add support for alternative checks 2018-03-20 17:15:55 +01:00
Matthias Schiffer
6ae067cb37
gluon-core: add domain aliases and pretty name
Based-on-patch-by: lemoer <git@irrelefant.net>
2018-01-26 12:32:47 +01:00
Matthias Schiffer
8cb0388416
scripts/check_site.lua: enable in_site()/in_domain() checks 2018-01-26 12:32:47 +01:00
Matthias Schiffer
51c0ceeb55
scripts/check_site.lua: merge site and domains for validation
Each domain is validated separately, preferring domain values to site
values.

Based-on-patch-by: lemoer <git@irrelefant.net>
2018-01-26 12:32:46 +01:00
Matthias Schiffer
24a085a542
gluon-site: add default domain and check for it
This does not do anything yet, as this_domain() is not implemented yet.

Based-on-patch-by: lemoer <git@irrelefant.net>
2018-01-26 12:32:46 +01:00
Matthias Schiffer
8b44d09963
scripts/generate_manifest.sh: fix filesize for symlinks
scripts/filesize.sh doesn't follow symlinks.

Fixes #1316
2018-01-24 09:49:21 +01:00
Matthias Schiffer
775028475b
check_site: move site loading logic to check_site_lib (which is renamed to check_site.lua) 2018-01-19 12:33:52 +01:00
Matthias Schiffer
43628c1679
scripts/check_site_lib.lua: improve display of invalid values 2018-01-19 11:02:33 +01:00
Matthias Schiffer
7ccdacd294
treewide: rework check_site_lib.lua
In addition to significant internal differences in check_site_lib.lua (in
particular unifying error handling to a single place for the upcoming
multi-domain support), this changes the way fields are addressed in site
check scripts: rather than providing a string like 'next_node.ip6', the
path is passed as an array {'next_node', 'ip6'}.

Other changes in site check scripts:
* need_array and need_table now pass the full path to the sub fields to the
subcheck instead of the key and value
* Any check referring to a field inside a table implies that all higher
levels must be tables if they exist: a check for {'next_node', 'ip6'} adds
an implicit (optional) check for {'next_node'}, which allows to remove many
explicit checks for such tables
2018-01-19 10:12:43 +01:00
Matthias Schiffer
020afc856f
gluon-site: install domain configs
The domain configs are not checked yet, and not used for anything.

Based-on-patch-by: lemoer <git@irrelefant.net>
2018-01-19 05:44:25 +01:00
Matthias Schiffer
8d8d4fa0c3
scripts/check_site_lib.lua: introduce in_site() and in_domain() helpers
These helpers are no-ops for now, until the actual multi-domain support is
added.
2018-01-19 03:30:50 +01:00
Matthias Schiffer
21b3dd3259
build: add file size field to manifest lines
We would like to check the file size instead of downloading indefinitely.
The file size is added in another copy of the manifest lines, which is
ignored by older autoupdater implementations.
2017-12-28 22:57:37 +01:00
Matthias Schiffer
87c741b45e
scripts: run feeds.sh with bash like the other scripts handling modules
Fixes #1262
2017-11-23 17:44:46 +01:00
Matthias Schiffer
becc90d818
build: delete lede/tmp on module updates
LEDE doesn't always notice that the metadata needs to be refreshed.
2017-10-29 18:44:30 +01:00
Matthias Schiffer
08cbbf9925
build: move all generic config generation to targets/generic
As the default package list is now handled using the 'packages' directive,
explicit wpad-mini removals in target definitions can be dropped.
2017-09-07 03:21:42 +02:00
Matthias Schiffer
587c5016cb
build: handle generic and target-specific config in the same run of target_config{,_check}.sh
This, together with a new try_config directive, will allow checking the
generic config and make it more flexible.
2017-09-07 00:17:57 +02:00
Matthias Schiffer
6ca841bad5
build: introduce GLUON_FEATURES
To reduce the number of packages that need to be listed in
GLUON_SITE_PACKAGES, this adds a new variable GLUON_FEATURES. Sets of
packages are enabled automatically based on the combination of listed
feature flags.

Site-specified package feeds can provide their own feature flag
definitions.
2017-07-09 02:31:38 +02:00
Matthias Schiffer
62132a590f
scripts: add support for manifest-only model aliases 2017-06-13 12:21:03 +02:00
Matthias Schiffer
ad91ab1be7
build: don't copy packages to output directory for targets without opkg
Fixes #1126
2017-05-15 23:23:02 +02:00
Matthias Schiffer
afc2e0c03d
build: scripts/target_config_check.sh: output all relevant errors
Don't stop after the first error, as later error messages may make the
cause of the error much clearer in some cases.
2017-05-02 17:05:55 +02:00
Matthias Schiffer
9e6cfaee0d
scripts: generate SHA256 manifest lines in addition to SHA512
The current autoupdater will only respect the last line for a given model
name, so we can add SHA256 checksums as long as they occur before the
corresponding SHA512 line.
2017-02-25 00:38:50 +01:00
kb-light
c9563cdebd scripts: check_site_lib: introduce need_string_array_match() (#1016) 2017-02-21 09:45:33 +01:00
Matthias Schiffer
2e6d457ec1
scripts/update.sh: don't hide errors because of invalid commit IDs 2017-02-12 08:03:46 +01:00
kb-light
f606e0ee8a scripts: fix manifest generation 2017-01-28 10:48:42 +01:00
Matthias Schiffer
3d1860e092
build: allow using DEVICES variable for sysupgrade_image/factory_image images
Setting DEVICES will also suppress cleaning the package directory,
improving incremental build speed.
2017-01-27 01:30:47 +01:00
Matthias Schiffer
70b116fd61
build: apply model-specific site packages at the end of the package list 2017-01-19 18:00:46 +01:00
Matthias Schiffer
78b2775eec
Use LEDE as base for Gluon 2017-01-18 17:21:43 +01:00
Matthias Schiffer
62ac802d4a
scripts/update-patches: include unabbreviated object IDs in patch files
The default abbreviation length depends on factors like user configuration,
git version and number of repository objects. Use unabbreviates IDs to make
patch generation more reproducible.
2016-12-20 01:08:11 +01:00
Matthias Schiffer
f1c23b3b3c
scripts/sha512sum.sh: output error message to stderr 2016-10-10 06:18:18 +02:00
Jan-Tarek Butt
0f3e660842
scripts: improve variable escaping 2016-10-10 05:57:35 +02:00
Matthias Schiffer
b2473f05cb
scripts/update.sh: don't disable commit signing for modules 2016-08-27 21:31:54 +02:00
kb-light
4d98fbb1bb scripts: update need_string_array() to work as expected 2016-08-26 23:28:26 +02:00
kb-light
21e033213c scripts: add functions need_one_of and need_array_of to check_site_lib.lua
need_one_of(varname, array, required) checks weather the value of the specified variable is part of given array.
need_array_of(varname, array, required) is similar to need_one_of() but assume that varname points to an array.
2016-08-26 23:28:26 +02:00
Matthias Schiffer
0eac102971
scripts/update.sh: fix checkout of correct base commit after fetching 2016-08-12 09:23:07 +02:00
Matthias Schiffer
bb3db1795b
update/patch: avoid applying patches directly in build repos
Switching branches and applying patches in the build repos will
unnecessarily touch many files, causing rebuilds of packages that didn't
really change; furthermore, it is filling the reflog with many entries.

Don't ever switch to base branch in the build repos and apply patches in
a temporary clone to avoid these issues.

In addition, GPG signing is generally disabled in the build repos to
override potential global configuration (as signing doesn't make sense and
will slow down rebases).
2016-08-09 03:41:52 +02:00
Matthias Schiffer
e678ab140e
scripts/update-patches: disable rename detection
git 2.9 enables rename detection by default, changing the content of some
of our patch files. Explicitly disable it.
2016-07-01 13:22:09 +02:00
Matthias Schiffer
efc004abf2
scripts/patch: never GPG-sign automated commits, regardless of the default configuration 2016-05-28 16:04:40 +02:00
Matthias Schiffer
d5f5ce74e8 build: add module separators/headings to patch/update/update-patches scripts
Suggested-by: Steffen Möller <steffen_moeller@gmx.de>
2016-03-26 00:03:04 +01:00
Matthias Schiffer
33d028783f build: remove rather useless "patch" and "unpatch" make targets 2016-03-25 23:57:15 +01:00
Johannes Rudolph
13658879e5 git submodules
Possibility to work with git submodules
2016-03-06 03:09:09 +01:00
Matthias Schiffer
ec1c82566a scripts/patch.sh: add --committer-date-is-author-date to git am
This option will make the generated commit IDs deterministic, greatly
reducing the number of repository objects created when calling `make
update` repeatedly.
2016-02-28 03:30:14 +01:00
Matthias Schiffer
f23e024787 Convert site.conf to JSON during build
This will allow us to use its content from other languages than Lua as
well.
2016-01-02 23:49:25 +01:00
Matthias Schiffer
05f146f817 Validate section names from site.conf in various packages 2015-10-11 19:34:14 +02:00
Matthias Schiffer
0f91fa6fa8 scripts/patch.sh: apply patches in a loop instead of a single git am command
Using a loop makes the script a bit nicer, and it works around a git bug
corrupting patch dates when multiple patches are applied at once.
2015-10-08 23:11:44 +02:00
Nils Schneider
56e7753035 check_site: allow subcheck to be nil in need_table() 2015-07-25 21:02:24 +02:00
Matthias Schiffer
63059c7e8f Switch to new reduced gluon package module 2015-04-22 21:07:31 +02:00
Matthias Schiffer
267831b04d Remove now unused md5sum.sh script 2015-03-19 19:08:41 +01:00
Matthias Schiffer
1c6e52c9b6 Allow running make update without git identity configuration 2015-01-21 17:37:41 +01:00
Matthias Schiffer
b67f094138 Fix site modules 2015-01-13 21:56:54 +01:00