mirror of
https://github.com/NixOS/nixpkgs.git
synced 2025-07-14 06:00:33 +03:00
nixos/limine: fix the install script
This commit is contained in:
parent
2cc1d33489
commit
1a830fe9d9
1 changed files with 8 additions and 7 deletions
|
@ -189,7 +189,7 @@ def find_mounted_device(path: str) -> str:
|
||||||
while not os.path.ismount(path):
|
while not os.path.ismount(path):
|
||||||
path = os.path.dirname(path)
|
path = os.path.dirname(path)
|
||||||
|
|
||||||
devices = [x for x in psutil.disk_partitions(all=True) if x.mountpoint == path]
|
devices = [x for x in psutil.disk_partitions() if x.mountpoint == path]
|
||||||
|
|
||||||
assert len(devices) == 1
|
assert len(devices) == 1
|
||||||
return devices[0].device
|
return devices[0].device
|
||||||
|
@ -399,11 +399,12 @@ def main():
|
||||||
|
|
||||||
if config('forceMbr'):
|
if config('forceMbr'):
|
||||||
limine_deploy_args += '--force-mbr'
|
limine_deploy_args += '--force-mbr'
|
||||||
try:
|
|
||||||
subprocess.run(limine_deploy_args)
|
try:
|
||||||
except:
|
subprocess.run(limine_deploy_args)
|
||||||
raise Exception(
|
except:
|
||||||
'Failed to deploy BIOS stage 1 Limine bootloader!\n' +
|
raise Exception(
|
||||||
'You might want to try enabling the `boot.loader.limine.forceMbr` option.')
|
'Failed to deploy BIOS stage 1 Limine bootloader!\n' +
|
||||||
|
'You might want to try enabling the `boot.loader.limine.forceMbr` option.')
|
||||||
|
|
||||||
main()
|
main()
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue