File tree Expand file tree Collapse file tree 2 files changed +26
-1
lines changed Expand file tree Collapse file tree 2 files changed +26
-1
lines changed Original file line number Diff line number Diff line change 7
7
variant = config . hardware . subtarget ;
8
8
packagesArch = config . hardware . arch ;
9
9
feedsSha256 = config . feedsHash ;
10
+ kmodsSha256 = config . kmodsHash ;
10
11
sha256 = config . sumsFileHash ;
11
12
} ) variantFiles profiles expandDeps corePackages packagesByFeed allPackages ;
12
13
Original file line number Diff line number Diff line change 4
4
latestRelease = import ../latest-release.nix ;
5
5
6
6
releaseHashesFile = ../hashes/${ config . release } .nix ;
7
- releaseHashes =
7
+ releaseHashes =
8
8
if ( builtins . pathExists releaseHashesFile )
9
9
then import releaseHashesFile
10
10
else builtins . throw "No hashed information found about OpenWRT ${ config . release } " ;
11
11
hashedTarget = releaseHashes . targets . ${ config . hardware . target } . ${ config . hardware . subtarget } or
12
12
( builtins . throw "No hashed information for OpenWRT ${ config . release } found for ${ config . hardware . target } /${ config . hardware . subtarget } " ) ;
13
13
hashedFeeds = releaseHashes . packages . ${ config . hardware . arch } or
14
14
( builtins . throw "No hashed information for OpenWRT ${ config . release } about packages found for ${ config . hardware . arch } architecture" ) ;
15
+ kmodsFeeds =
16
+ if ( lib . versionAtLeast config . release "24" )
17
+ then releaseHashes . kmods . ${ config . hardware . target } . ${ config . hardware . subtarget } or
18
+ ( builtins . throw "No hashed information for OpenWRT ${ config . release } about Kmods found for ${ config . hardware . target } /${ config . hardware . subtarget } " )
19
+ else { } ;
15
20
16
21
defaultSumsFileHash = hashedTarget . sha256 ;
17
22
235
240
'' ;
236
241
} ;
237
242
243
+ kmodsHash = lib . mkOption {
244
+ type = lib . types . attrsOf lib . types . raw ;
245
+ default = kmodsFeeds ;
246
+ example = lib . options . literalExpression ''
247
+ {
248
+ "6.6.67-1-a19d0a45cee591b95352ac365f8a784b".sha256 = "sha256-23n2qV9PDubOeGEf43i29o+qL5B9ZU4wQOYoanfPFSQ=";
249
+ "6.6.67-1-316f788de839e861f7fea23702a4776b".sha256 = "sha256-cM1S2NLATkxL3TzPzkCD1fEe36xf5C7sF4TPVPDIBGc=";
250
+ }
251
+ '' ;
252
+ internal = true ;
253
+ description = ''
254
+ A "feed", where each key is a kernel version and each value is a `sha256` sum of `Packages`.
255
+
256
+ :::{.warning}
257
+ Must be created per target + subtarget combination.
258
+ :::
259
+ '' ;
260
+ } ;
261
+
238
262
build = {
239
263
extraDerivationArgs = lib . mkOption {
240
264
type = lib . types . raw ;
You can’t perform that action at this time.
0 commit comments