Merge pull request #100078 from mdevlamynck/fix-grub-kbdcomp
grub2: fix grub-kbdcomp
This commit is contained in:
commit
b62f1a10ce
@ -1,10 +1,12 @@
|
|||||||
{ lib, stdenv, fetchgit, flex, bison, python3, autoconf, automake, gnulib, libtool
|
{ lib, stdenv, fetchgit, flex, bison, python3, autoconf, automake, gnulib, libtool
|
||||||
, gettext, ncurses, libusb-compat-0_1, freetype, qemu, lvm2, unifont, pkg-config
|
, gettext, ncurses, libusb-compat-0_1, freetype, qemu, lvm2, unifont, pkg-config
|
||||||
, fuse # only needed for grub-mount
|
, fuse # only needed for grub-mount
|
||||||
|
, runtimeShell
|
||||||
, zfs ? null
|
, zfs ? null
|
||||||
, efiSupport ? false
|
, efiSupport ? false
|
||||||
, zfsSupport ? false
|
, zfsSupport ? false
|
||||||
, xenSupport ? false
|
, xenSupport ? false
|
||||||
|
, kbdcompSupport ? false, ckbcomp
|
||||||
}:
|
}:
|
||||||
|
|
||||||
with lib;
|
with lib;
|
||||||
@ -53,6 +55,13 @@ stdenv.mkDerivation rec {
|
|||||||
./fix-bash-completion.patch
|
./fix-bash-completion.patch
|
||||||
];
|
];
|
||||||
|
|
||||||
|
postPatch = if kbdcompSupport then ''
|
||||||
|
sed -i util/grub-kbdcomp.in -e 's@\bckbcomp\b@${ckbcomp}/bin/ckbcomp@'
|
||||||
|
'' else ''
|
||||||
|
echo '#! ${runtimeShell}' > util/grub-kbdcomp.in
|
||||||
|
echo 'echo "Compile grub2 with { kbdcompSupport = true; } to enable support for this command."' >> util/grub-kbdcomp.in
|
||||||
|
'';
|
||||||
|
|
||||||
nativeBuildInputs = [ bison flex python3 pkg-config autoconf automake ];
|
nativeBuildInputs = [ bison flex python3 pkg-config autoconf automake ];
|
||||||
buildInputs = [ ncurses libusb-compat-0_1 freetype gettext lvm2 fuse libtool ]
|
buildInputs = [ ncurses libusb-compat-0_1 freetype gettext lvm2 fuse libtool ]
|
||||||
++ optional doCheck qemu
|
++ optional doCheck qemu
|
||||||
|
Loading…
x
Reference in New Issue
Block a user