forked from DGNum/liminix
fix(zyxel/nwa50ax): ubi cannot run on phram
Discovered the hard way. Signed-off-by: Raito Bezarius <masterancpp@gmail.com>
This commit is contained in:
parent
85bfe94429
commit
c1e61d6af5
5 changed files with 42 additions and 24 deletions
|
@ -13,6 +13,7 @@ in {
|
|||
liminix = {
|
||||
builders = {
|
||||
squashfs = callPackage ./liminix-tools/builders/squashfs.nix {};
|
||||
jffs2 = callPackage ./liminix-tools/builders/jffs2.nix {};
|
||||
dtb = callPackage ./kernel/dtb.nix {};
|
||||
uimage = callPackage ./kernel/uimage.nix {};
|
||||
kernel = callPackage ./kernel {};
|
||||
|
|
17
pkgs/liminix-tools/builders/jffs2.nix
Normal file
17
pkgs/liminix-tools/builders/jffs2.nix
Normal file
|
@ -0,0 +1,17 @@
|
|||
{
|
||||
stdenv
|
||||
, busybox
|
||||
, buildPackages
|
||||
, callPackage
|
||||
, pseudofile
|
||||
, runCommand
|
||||
, writeText
|
||||
} : { eraseBlockSize, bootableRootDirectory }:
|
||||
let
|
||||
endian = if stdenv.isBigEndian then "--big-endian" else "--little-endian";
|
||||
in runCommand "frob-jffs2" {
|
||||
depsBuildBuild = [ buildPackages.mtdutils ];
|
||||
} ''
|
||||
tree=${bootableRootDirectory}
|
||||
(cd $tree && mkfs.jffs2 --compression-mode=size ${endian} -e ${toString eraseBlockSize} --enable-compressor=lzo --pad --root . --output $out --squash --faketime)
|
||||
''
|
Loading…
Add table
Add a link
Reference in a new issue