summaryrefslogtreecommitdiff
path: root/image.sh
blob: e15f4ca020d0afb5b50a1e10ff91344c3f0a6b36 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
#!/usr/bin/env bash

imagefile=uefi.img
loaderfile=loader/loader.efi
kernelfile=kernel/kernel.os

if [[ ! -f ${imagefile} ]]; then
    dd if=/dev/zero of=${imagefile} bs=1024 count=1440
    mformat -i uefi.img -f1440 ::
fi

mcopy -i ${imagefile} -Do ${loaderfile} ::
mmd -i ${imagefile} -Do ::adasoft
mmd -i ${imagefile} -Do ::adasoft/sophia
mcopy -i ${imagefile} ${kernelfile} -Do ::adasoft/sophia