<samueldr>
as long as the kernel and udev can see the storage, and makes the by-label symlink, it should be able to mount it
<Darkmatter66_>
that's great so the same as PMOS and x86 boot setup
<samueldr>
I'm succeeding right now at reducing all devices to operating generally the same way
<samueldr>
some differences in the boot process, but it mounts the main system the same way
<Darkmatter66_>
by the way I tried booting just the boot image without the system image and it just stuck on the logo, maybe it should display something indicating that it couldn't find the rootfs?
<samueldr>
quick note, currently if you build the system there is no useful stage-2, you'll stay stuck on the boot splash
<samueldr>
yes
<samueldr>
there are two somewhat related issues
<samueldr>
(1) there is no timeout handling for tasks, it continues waiting for the device to appear
<samueldr>
(2) if you cross-compile a system image, it's an empty useless image that will look like it hung
<samueldr>
the issue with (2) is that cross-compilation in Nixpkgs is a work-in-progress, so you need to build a native system image to have a useful system
<Darkmatter66_>
hmm I'm cross compiling using archlinux x86 as host, so i should interrupt it :(
<samueldr>
and even then, you'd need to build the system image from e.g. examples/demo
<samueldr>
yeah, sorry :/
<samueldr>
I do have a working task soon to at least make that useless system uselessly say "it worked! but the princess is in another castle" at the end
<samueldr>
(or something more useful maybe)
<Darkmatter66_>
so if i built it on an aarch64 device will i be able to boot ? why do I need to build example/demo?
<Darkmatter66_>
I'm very new to nixos and don't know anything about its structure
<samueldr>
cross-compiling stage-1 should work, and will continue working, even if you do a native compile for stage-2
<samueldr>
stage-1/stage-2 is the name for initramfs (stage-1) and the running system we pivot into (stage-2)
<samueldr>
ugh, switch_root into :)
<Darkmatter66_>
yes I understood that part, I meant if i built the rootfs (stage-2) natively why can't it switch to it
<samueldr>
so you can view these as two complementary bits with Mobile NixOS
<samueldr>
if you build it natively, it'll work
<Darkmatter66_>
aha, that's great will build it now
<samueldr>
though build examples/demo, as otherwise there's no system configured and it's left to you to do :)
<Darkmatter66_>
right now I used this nix-build --argstr device xiaomi-lavender -A build.rootfs to build
<samueldr>
Mobile NixOS does not intend to build a fully integrated system, but allow selection of environments, just like NixOS does on desktop
<Darkmatter66_>
what do you mean by enviroment ? isn't nixos provided as an iso image for desktop?
FRidh2 has quit [Quit: Konversation terminated!]
<samueldr>
you can configure which DE/WM you use through the configuration
<samueldr>
so it's not like NixOS sets up one integrated DE/WM like e.g. elementary does
<samueldr>
in the same vein, at one point in the future Mobile NixOS will be able to run the different mobile "desktop" environments
<samueldr>
(once packaged)
<Darkmatter66_>
that's fine by me, so if i built through the command i gave above, It will boot to command line only mode ?
<samueldr>
"yes", but there's no drivers in the OEM kernel to show the virtual console
<samueldr>
so it'll be as useless
<samueldr>
$ nix-build examples/demo/ --argstr device asus-z00t -A build.rootfs
<samueldr>
this is how you can build an example system which will be more useful
<Darkmatter66_>
ok will try it
<samueldr>
(you can switch asus-z00t to xiaomi-lavender, obviously :))
<Darkmatter66_>
and how can I get the boot selection gui that you added
<samueldr>
(though currently the system image is universal, the same image can be flashed to any aarch64 device)
<Darkmatter66_>
is it included in the initramfs ? or do I need something else
<samueldr>
two ways (1) flash the recovery image to recovery, boot to recovery (2) once the boot process has started, but before it switch_roots, hold a volume key
<samueldr>
for (2), it's probably fine at any time after it's too late for (1) to happen
<samueldr>
we don't have a "real" recovery image (by design), the recovery image is the same as the boot image, but with a configuration option telling it to unconditionally go to the recovery menu
<samueldr>
it's by design, because of how some targets don't havea recovery/normal boot split (e.g. depthcharge, pinephone)
<samueldr>
and because of boot_as_recovery stuff from recent android systems
<Darkmatter66_>
will it work if i just used `fastboot boot result` or it's mandatory that it boots from internal ?
<Darkmatter66_>
also does it matter what volume key ? or anyone will do
<samueldr>
I have had issues with `fastboot boot` and xiaomi-lavender at some point, not sure if it's still an issue
<samueldr>
any volume key will do
<Darkmatter66_>
alex on PMOS also couldn't boot using `fastboot boot` but I tested PMOS and it works fine, i told him to update to the latest xbl maybe they fixed the issues(because I was using a newer version than him)
<samueldr>
I assumed it might be something like that
<Darkmatter66_>
I didn't get an update from him whether it fixed it or not
<samueldr>
so I assume in your case the same rules apply
<samueldr>
does `oem getlog` work for you?
tilpner has quit [Remote host closed the connection]
<samueldr>
I think it didn't for alex, looking at the wiki page on postmarketOS
tilpner has joined #nixos-aarch64
<samueldr>
nice, there is UART info now
<Darkmatter66_>
`fastboot oem getlog 2>&1` works for me yes
<samueldr>
nice to know
<samueldr>
I didn't know if it was something related to me never having updated from the shipped bootloader
<Darkmatter66_>
I updated to the latest miui (fastboot rom), so I guess they fixed some issues in the xbl bootloader
<Darkmatter66_>
by the way fastboot boot is still not working consistently
<Darkmatter66_>
just now I ran `fastboot boot result` and it just hangs at "Sending 'boot.img' (30712 KB)" I'll have to reboot to get it to work again
<samueldr>
yeah, that's why I always wrote the image to the boot partition, I couldn't deal with having to make the port work, AND fastboot being flaky :)
<Darkmatter66_>
I just booted and pressed the volume button and nothing happened
<Darkmatter66_>
still stuck on splash
<samueldr>
sorry, should have thought about it, it needs to find the root partition before it can show it (for now)
<Darkmatter66_>
is it possible to disable the splash and get kmsg output on the screen instead
<samueldr>
not directly, because of how OEM kernels don't have virtual consoles working
<Darkmatter66_>
ahh, that's fine I'll build a rootfs now
<samueldr>
at one point fbterm was working, mostly, but I think I didn't fix it to work with the new init
akegalj has joined #nixos-aarch64
zupo has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]