pmb.qemu package

Submodules

pmb.qemu.run module

pmb.qemu.run.command_qemu(args: PmbArgs, config: Config, arch: Arch, img_path, img_path_2nd=None)

Generate the full qemu command with arguments to run postmarketOS

pmb.qemu.run.create_gdk_loader_cache(args: PmbArgs) Path

Create a gdk loader cache that can be used for running GTK UIs outside of the chroot.

pmb.qemu.run.create_second_storage(args: PmbArgs, device: str)

Generate a second storage image if it does not exist.

Returns:

path to the image or None

pmb.qemu.run.install_depends(args: PmbArgs, arch: Arch)

Install any necessary qemu dependencies in native chroot

pmb.qemu.run.resize_image(img_size_new, img_path)

Truncates an image to a specific size. The value must be larger than the current image size, and it must be specified in MiB or GiB units (powers of 1024).

Parameters:
  • img_size_new – new image size in M or G

  • img_path – the path to the image

pmb.qemu.run.run(args: PmbArgs)

Run a postmarketOS image in qemu

pmb.qemu.run.sigterm_handler(number, frame)
pmb.qemu.run.system_image(device: str)

Returns path to rootfs for specified device. In case that it doesn’t exist, raise and exception explaining how to generate it.

pmb.qemu.run.which_qemu(arch: Arch)

Finds the qemu executable or raises an exception otherwise

Module contents