genericv2 | How can i define droid_target_aarch64? Added "%define droid_target_aarch64" to both "droid-configs/rpm/droid-config-sagit.spec" and "droid-hal-version-sagit/rpm/droid-hal-version-sagit.spec" but it didin't worked. Maybe a stupid question | 02:40 |
---|---|---|
genericv2 | Okay i figured it out now | 02:49 |
genericv2 | still fails :))))) | 02:55 |
genericv2 | https://paste.opensuse.org/pastes/83e0488bfb7a Where am i supposed to enable these? They already exist in my defconfig, i am confused. | 10:07 |
genericv2 | Is there any chance of it not finding the correct defconfig or something? | 10:09 |
mal | genericv2: the "%define droid_target_aarch64 1" goes only to droid-hal-$DEVICE.spec | 10:19 |
mal | make sure you add it to correct place in the file, "%include rpm/dhd/droid-hal-device.inc" has to be the last line in the file, add any changes to earlier lines in the file | 10:20 |
genericv2 | ah i fixed that yesterday, after logging out. this is another error. | 10:21 |
mal | check the whole droid-hal-sagit.log for all of the defconfig errors | 10:21 |
genericv2 | There is a lot errors (and warning) there. I'll correct them. | 10:23 |
mal | errors are the important ones | 10:24 |
genericv2 | Most of errors are already defined in my defconfig file. | 10:46 |
genericv2 | hm | 10:46 |
genericv2 | Fixed all errors in defconfig (again), it still gives these errors, | 10:57 |
mal | are you sure you edit the correct defconfig? arch/arm64/configs/sagit_defconfig | 11:01 |
genericv2 | I am sure. Also tree uses "sagit_defconfig" so it must be okay\ | 11:01 |
mal | and you run make hybris-hal (or just make hybris-boot) before checking again? | 11:03 |
genericv2 | I always do "make hybris-boot" after editing defconfig. | 11:03 |
mal | show list of all defconfig errors you see in droid-hal-sagit.log | 11:04 |
genericv2 | droid-hal-sagit.log: https://paste.opensuse.org/pastes/bd8dd7def43d | 11:06 |
genericv2 | For an exapmle it says CONFIG_VT is unset, but it is set. https://paste.opensuse.org/pastes/ec87e5d4fba2 | 11:07 |
mal | "Can't open /home/kita/hadk/out/target/product/sagit/obj/*/.config:" can you check what paths you have in there | 11:09 |
mal | so it's can't find the kernel config output file which explains why it complains about the errors, I think I should have a look to make that error critical so people actually notice that | 11:10 |
genericv2 | Oh i missed that. Saw it now. Probably i made a mistake while setting up the environment | 11:11 |
mal | is that path correct? | 11:12 |
mal | or did you somehow define ANDROID_ROOT to wrong path or something like that? | 11:12 |
genericv2 | ANDROID_ROOT is set to /home/kita/hadk, which is correct | 11:13 |
mal | and is the out/ folder there? | 11:13 |
mal | check what you have in out/target/product/ | 11:14 |
genericv2 | Okay found the issue now, "$ANDROID_ROOT/out/' is soft linked to "/parentroot/parentroot/mnt/out" (Which is my hdd). It works on ubuntu chroot but it's broken on sfos sdk. I'll correct that symlink now. | 11:15 |
mal | I do some bind mount magic in .hadk file to get android root to external disk | 11:19 |
genericv2 | Yeah bind mount is a better alternative to symlink for this. I first tried to bind mount actually but it didin't work for some reason😄 | 11:27 |
mal | I have the whole android root in external disk and in .hadk like this: ANDROID_ROOT="$HOME/some_path" and 'sudo mount --bind /parentroot/real_android_root_path "$HOME/some_path"' | 11:31 |
mal | just to note that I use ubuntu on host and only use HABUILD_SDK when building very old android versions which might have issues with new ubuntu environments, mostly I build hybris-hal directly in host | 11:33 |
mal | probably building on host can work also on other distros for reasonably new android bases | 11:34 |
genericv2 | Now this is happening: https://paste.opensuse.org/pastes/0630b15fe214 | 11:54 |
genericv2 | Oh okay my mistake | 11:56 |
genericv2 | sh files and selinux thingies are okay now, but i am not sure about "absolute symlink' errors, | 11:59 |
genericv2 | Fixed it. | 12:11 |
genericv2 | PlatformSDK [kita@suse hadk]$ rpm/dhd/helpers/build_packages.sh --configs | 12:11 |
genericv2 | * Installing ccache... | 12:11 |
genericv2 | !! can't install ccache | 12:11 |
genericv2 | what 😠| 12:12 |
genericv2 | Error: Subprocess failed. Error: RPM failed: warning: /home/.zypp-cache/packages/jolla/oss/aarch64/ccache-3.1.9-1.5.3.jolla.aarch64.rpm: Header V3 RSA/SHA256 Signature, key ID 47394f23: NOKEY | 12:13 |
genericv2 | error: bdb error(-30971) from dbenv->open: DB_VERSION_MISMATCH: Database environment version mismatch | 12:13 |
genericv2 | Something is wrong with repositories i think? | 12:14 |
genericv2 | Fixed that. And hopefully this is the last error: https://paste.opensuse.org/pastes/260662f32d89 | 12:36 |
mal | which package is missing, check the droid-local-repo folder | 12:41 |
genericv2 | There is droid-config-sagit but err says droid-config is missing. Same with others "droid-config-sagit-pulseaudio-settings" exist but it's searching for "droid-config-pulseaudio-settings" | 12:48 |
mal | check all of the packages in that list | 12:50 |
mal | also check the log file, maybe it explains the issue | 12:50 |
genericv2 | There is a file conflict. https://paste.opensuse.org/pastes/5d1652e4a22a So it can't install package droid-config-sagit | 12:53 |
mal | add these 4 lines to your droid-config spec https://github.com/mer-hybris/droid-config-sony-lena/blob/master/droid-config-common.inc#L12C1-L15C32 and then build_packages.sh -c | 12:55 |
genericv2 | Another error, about bluez now: https://paste.opensuse.org/pastes/3d260b0f6518 | 13:00 |
genericv2 | conflict* | 13:01 |
mal | sb2 -t $VENDOR-$DEVICE-$PORT_ARCH -R -m sdk-install zypper in droid-local-repo/sagit/droid-config-sagit-bluez5-1-202402031300.aarch64.rpm -bluez5-configs-mer | 13:02 |
T42_ | <elros34> you know all or most of these erorrs are known and you can find solution in either channel logs or even hadk pdf/hot/faq. You don't have to wait for somebody advice | 13:12 |
genericv2 | you are right, sorry | 13:16 |
genericv2 | I got "Failed to extract filesystem!" while sideloading the image via recovery, great. | 14:48 |
genericv2 | i'll try to install it manually | 14:51 |
genericv2 | Stuck on Mi logo. Now i can't even telnet to it. It simply disconnects after 3 seconds | 15:10 |
genericv3 | I am checking udevadm, phone connects as usb0 and disconnects after 3 SECONDS. | 15:21 |
genericv3 | tried with another cable, same | 15:22 |
genericv3 | Also it's not connecting as 'mer', it's connecting as 'MI 6' | 15:24 |
mal | didn't you have working kernel earlier? | 15:29 |
T42_ | <elros34> https://sailfishos.wiki/link/20#bkmrk-%C2%A0%C2%A0%C2%A0%C2%A0%C2%A0%C2%A0%C2%A0-%2A-if-your-de-1 | 15:29 |
genericv3 | The kernel must work, it was okay without rootfs. | 15:30 |
genericv3 | i'll wait for the battery to drain. | 15:30 |
T42_ | <elros34> reset to fastboot, flash kernel and check again. IF device reboots few times it can switch to other slot or something | 15:31 |
genericv3 | I can't reset right now, my power button is broken, but no problem i will wait for it to power off. | 15:35 |
genericv3 | We did fix the kernel with mal, i could connect to the device with telnet before flashing the rootfs. | 15:35 |
genericv3 | Right now it's stuck at 'MI' logo. when i plug it into my pc it connects as 'Mi 6', shows up as usb0 in 'ip l' command and disconnects after 3 seconds. I'll check logs in '/data/.stowaways/sailfishos' after it turns off, and continue debugging on low battery. | 15:35 |
T42_ | <elros34> doesn't it reboots after this 3 seconds? press some volume key and enter to recovery | 15:37 |
mal | if it reboots can't you boot to fastboot or recovery using some volume key? | 15:37 |
genericv3 | No it's just stuck. It does not reboot, kernel is alive. | 15:38 |
genericv3 | It just can't keep a usb connection | 15:38 |
genericv3 | https://paste.opensuse.org/pastes/90cb8d102716 | 15:41 |
mal | maybe droid-hal-init did something to usb which makes it fail | 15:46 |
T42_ | <elros34> I do not see this idProduct=0a02 in https://github.com/LineageOS/android_device_xiaomi_msm8998-common/blob/lineage-20/rootdir/etc/init.qcom.usb.rc | 15:48 |
genericv3 | i modified init-debug script to make the device reboot automatically in a minute no matter what. | 19:16 |
mal | did you try to get into the second telnet at port 2323 using the /init_enter_debug2 ? | 19:20 |
T42_ | <elros34> How did you modify it and replace files in kerne or rootfs? Better create what mal suggest. Did you check for init.log to confirm that your device boots correctly? | 19:29 |
mal | also good to enable persistent journal logs in rootfs | 19:31 |
genericv3 | it tried to serve telnet server on 2323 but it failed with an error, saw this on init.log. i sent that error to here but it probably dodin't reached here, my irc client bugged for a moment. | 19:32 |
genericv3 | adb pull /data/.stowaways/sailfishos/init-debug, i edited it and pushed. But it's not working right now probably. i am checking things. | 19:34 |
T42_ | <elros34> yeah you probably mess it up like that, either internally or permissions | 19:35 |
genericv3 | Yeah xD i messed it up. Currently the phone reboots after 8 seconds (without my high-tech auto reboot script) | 19:37 |
T42_ | <elros34> remove init.log, reboot, and check whether is recreated. This is simple way to see if your /init-debug is even executed | 19:38 |
genericv3 | init-debug got executed now, removed init.log and set init-debug's permissions to 777. Now it's stuck at Mi logo again, which causes the real error. | 19:41 |
genericv3 | That error was something like "Failed to create /some/path/android0/iSerial: Permission denied | 19:42 |
T42_ | <elros34> probably irrelevant, did you finally create init_enter_debug2? | 19:42 |
genericv3 | Created it now, do i need to do anything else? | 20:19 |
genericv3 | Okaay i am in | 20:24 |
genericv3 | At port 2323 now | 20:24 |
genericv3 | What i must check now | 20:28 |
mal | for example enabling persistent journal and then continue boot, you could also mask droid-hal-init and usb-moded and then continue which would probably prevent anything messing with usb | 20:30 |
genericv3 | Enabled persistent logging and rebooted. | 20:42 |
genericv3 | Waiting for phone to power off again | 20:44 |
genericv3 | Got a journal file. | 20:52 |
genericv3 | Failed to start droid-hal-init | 20:52 |
mal | show the whole log | 20:53 |
genericv3 | i was searching for more errors, i'll save it to a file and send. Another err: can't execute /sbin/droid-hal-init | 20:54 |
genericv3 | https://paste.opensuse.org/pastes/cc62e14dbc7a | 21:00 |
mal | check what is mounted in /system in telnet 2323 | 21:03 |
mal | which version of droid-configs submodule do you use? | 21:05 |
genericv3 | Nothing is mount on system, did i do something wrong. | 21:06 |
genericv3 | i am not sure, i need to check | 21:08 |
mal | ah, sorry, it's mounted later | 21:09 |
mal | so try masking droid-hal-init and usb-moded and then continue | 21:09 |
T42_ | <elros34> is that system-as-root? check what you have in /system/ | 21:15 |
genericv3 | Masking droid-hal-init and usb-moded made init continue without breaking telnet | 21:16 |
mal | ok, now check what is in /system | 21:16 |
genericv3 | sde43 is mounted at /system, it's the correct partition | 21:17 |
genericv3 | Everything is okay inside, lineage system partition | 21:17 |
mal | it's possible you have wrong submodule version | 21:18 |
T42_ | <elros34> I doubt it's correct, show 'ls -al /system/' | 21:19 |
genericv3 | it is. Also i am on my laptop right now, my desktop is busy. Can we fix it without rebuilding things for now? | 21:20 |
mal | @elros34 I mean if the build didn't use android13 branch for droid-config submodule it would have wrong version of droid-hal-init.service | 21:21 |
mal | genericv3: check the file /usr/lib/systemd/system/droid-hal-init.service does it have lines like "ProtectSystem=full" | 21:22 |
T42_ | <elros34> side note: be aware that you built not latest sfos release | 21:23 |
genericlinks | https://paste.opensuse.org/pastes/a057ea36b94b | 21:23 |
T42_ | <elros34> so its not correct, https://sailfishos.wiki/link/20#bkmrk-%C2%A0system-as-root%3A-htt | 21:24 |
genericv3 | mal yes it have that line | 21:25 |
genericv3 | i am not supposed to build the lastest sfos version? i didin't knew that | 21:25 |
mal | ok, so now you have two issues, incorrect /system mount and incorrect droid-hal-init.service | 21:26 |
mal | for latter issue replace the file manually with content of https://raw.githubusercontent.com/mer-hybris/droid-hal-configs/android13/sparse-13/usr/lib/systemd/system/droid-hal-init.service | 21:26 |
genericv3 | What about sfos release, i built the lastest one | 21:26 |
mal | latest is 4.5.0.24 | 21:27 |
mal | but that sfos version is not critical right now, just something to note for next image you build | 21:27 |
mal | it's possible to fix the /system mount manually on device but that needs some editing of mount service files | 21:29 |
genericv3 | Replaced droid-hal-init.service now | 21:31 |
T42_ | <elros34> mal: I guess these reboot_on_failure in custom apexd.rc you have added are some safety feature but this will not ease debugging. If that service will fail most probably ueventd will start and mess everything/reboot unless something changed since previous android release | 21:32 |
mal | @elros34 I didn't add anything like that there, the only reason for custom apexd.rc is to use the patched apexd from libexec | 21:34 |
genericv3 | Now what to do for /system | 21:34 |
mal | genericv3: also copy/replace the files in /usr/libexec/droid-hybris/system/etc/init with these https://github.com/mer-hybris/droid-hal-configs/tree/android13/sparse-13/usr/libexec/droid-hybris/system/etc/init | 21:36 |
mal | make sure you copy the content correctly from raw view of the files | 21:36 |
mal | @elros34 probably would make sense to remove the reboot stuff from the apexd.rc | 21:37 |
T42_ | <elros34> I think so at least from apex-bootstrap which is first thing which like to fail. Better would be probably preventing ueventd from starting not matter what but I do not remember details anymore | 21:41 |
mal | yeah, ueventd is annoying | 21:41 |
T42_ | <elros34> I think critical or shutdown critical cause this issue https://android.googlesource.com/platform/system/core/+/refs/heads/android10-c2f2-s1-release/rootdir/init.rc | 21:43 |
mal | genericv3: for system mount issue, you need to rename the file system.mount to system_root.mount in /usr/lib/systemd/system and replace the Where=/system with Where=/system_root and also add new system.mount file with content https://pastebin.com/jUeqtugK | 21:50 |
mal | you also need symlink for the new mount service in /etc/systemd/system/local-fs.target.wants (run "ln -s /usr/lib/systemd/system/system_root.service" in that folder) | 21:52 |
genericv3 | my laptop decided to kill its wlan adapter for no reason, i am trying to fix it right now | 21:56 |
genericv3 | Okay rc files are done, continuing on /system | 22:01 |
genericv3 | Aa, pastebin is banned in my country (🥰), Can you share that file with suse paste | 22:03 |
genericv3 | did everything, rebooting | 22:07 |
mal | did you get the file somehow already? | 22:08 |
genericv3 | Except that file* | 22:09 |
T42_ | <elros34> most important:) | 22:09 |
mal | https://paste.opensuse.org/pastes/4588ace01865 | 22:09 |
genericlinks | hehe, sorry xD | 22:10 |
genericlinks | hmm | 22:22 |
genericlinks | it crashed after doing everything | 22:22 |
genericlinks | ill check logs | 22:23 |
genericlinks | it's rebooting after making init continue booting | 22:24 |
genericlinks | we talked about this i think | 22:25 |
genericlinks | nope iits okay rn | 22:28 |
genericlinks | /usr/sbin/dummy_compositor: unrecognized option '--hwc-restart' | 22:28 |
genericlinks | . /system seems okay now | 22:30 |
mal | remove files /usr/lib/systemd/user/lipstick.service.d/50-compositor.conf, /usr/lib/systemd/user/jolla-actdead-charging.service.d/50-compositor.conf and /usr/lib/systemd/user/jolla-startupwizard-pre-user-session.service.d/50-compositor.conf | 22:34 |
genericv3 | Looks better now (it's fun to watch journalctl -f) There is no much errors right now, just "Device /dev/sailfish/home does not exist or access denied" Could this block boot? | 22:39 |
genericv3 | WAIT IT DID VOOT4 | 22:41 |
genericv3 | BOOT* | 22:41 |
genericv3 | it's still stuck on mi logo but it says "DIM", "POWER_DOWN" as current display state . And i can wake the screen by tapping to home button, these dont actually make something of course journalctl is just logging these. | 22:43 |
genericv3 | hadk-hot time | 22:44 |
genericv3 | there is some missing libraries tho | 22:45 |
mal | that /dev/sailfish/home is not a problem | 22:52 |
mal | what missing libraries, forgot one thing, did you build "make libui_compat_layer" when building hybris-hal | 22:54 |
mal | which means do you have libui_compat_layer.so in out/target/product/sagit/system/lib64/ in your android_root | 22:55 |
mal | or on your device in /usr/libexec/droid-hybris/system/lib64 | 22:56 |
genericv3 | oops, no i didint | 22:59 |
genericv3 | There is only libui.so | 22:59 |
mal | you'll need that to get UI working | 22:59 |
mal | but at least there was some progress already | 23:00 |
genericv3 | can i stole it from somewhere for now? Actually i can turn on my pc right now, i can build that library and push it to the phone, right? | 23:00 |
genericv3 | yeah we made a lot of progress, thanks to you guys :) | 23:01 |
T42_ | <b100dian> Which Android base? Sorry if you already written | 23:11 |
T42_ | <b100dian> Missing libraries could be linked from /odm to be found, or betyer, bind mounted | 23:12 |
genericv3 | lineage-20 | 23:13 |
genericv3 | built that library now by the way | 23:13 |
mal | you can copy it to the location I mentioned | 23:16 |
genericv3 | copied | 23:17 |
genericv3 | There is some errors about libGLESv2_afreno too, this is also a problem ig | 23:18 |
genericv3 | yeah its stuck again | 23:19 |
genericv3 | probably cuz of that library | 23:19 |
T42_ | <elros34> check logcat now | 23:20 |
genericv3 | hm, any chances of /system still being broken? "/system/bin/logcat: not found" | 23:21 |
genericv3 | But i can ls to it | 23:21 |
genericv3 | also same with bin/bootanimation etc. | 23:22 |
T42_ | <b100dian> /usr/libexec/droid-hybris/system/bin/logcat | 23:22 |
T42_ | <b100dian> but it might just fail because droid-hal-init fails | 23:23 |
T42_ | <b100dian> so you need to run it as soon as possible after droid-hal-init | 23:23 |
genericv3 | it says not found again | 23:23 |
T42_ | <elros34> do you check this after booting or while you are in init script? | 23:24 |
genericv3 | After booting | 23:24 |
T42_ | <elros34> so droid-hal-init works or not? | 23:24 |
genericv3 | oh, no it doesnt work. it's currently masked. i can interact with the device via screen | 23:26 |
T42_ | <elros34> it's essential part of android adaptation, you need it | 23:26 |
genericv3 | So we need to fix that, gonna check whats wrong with it i forget it. | 23:27 |
T42_ | <elros34> there is nothing to fix, just unmask it and follow logs | 23:28 |
genericv3 | droid-hal-init.service: Service lacks both ExecStart= and ExecStop= setting. Refusing | 23:30 |
genericv3 | ill check its service file | 23:30 |
genericv3 | it's empty, i made a mistake | 23:32 |
genericv3 | https://raw.githubusercontent.com/mer-hybris/droid-hal-configs/android13/sparse-13/usr/lib/systemd/system/droid-hal-init.service (sendung here to quickly grab it from my laptop) | 23:34 |
genericv3 | https://raw.githubusercontent.com/mer-hybris/droid-hal-configs/android13/sparse-13/usr/lib/systemd/system/droid-hal-init.service | 23:34 |
genericv3 | xD | 23:35 |
genericv3 | https://raw.githubusercontent.com/mer-hybris/droid-hal-configs/android13/sparse-13/usr/lib/systemd/system/droid-hal-init.service | 23:35 |
genericv3 | it failed to start as excepted. | 23:43 |
genericv3 | Wha | 23:43 |
genericv3 | phone reeboted itself to fastboot | 23:43 |
genericv3 | Journalctl catched some partition mount issues | 23:43 |
T42_ | <b100dian> maybe changed sides A/B because of no succesful boot | 23:44 |
genericv3 | My phone don't have project treble | 23:45 |
T42_ | <b100dian> sorry, I don't know which device. Can you show logs of the partition mount issues? | 23:45 |
T42_ | <b100dian> lineage-20 w/o treble, interesting :) | 23:46 |
genericv3 | No problem. I'll take logs again, if it could boot of course | 23:46 |
genericv3 | yeah😅 it was running crdroid 10 actually (which is android 14) | 23:46 |
genericv3 | Flashed lineage 20 for sfos | 23:47 |
genericv3 | i'll reboot from fastboot, i hope there is no big problem | 23:47 |
genericv3 | not sure if this chipset can survive a hard brick | 23:47 |
T42_ | <elros34> remember these apexd.rc file you added? Remove reboot_on_failure lines from it | 23:47 |
T42_ | <elros34> @b100dian yeah it had even lineage-15 or 16 specific bug in kernel | 23:49 |
genericv3 | Okaay, i'll telnet to it. seems like there is no problem right now | 23:49 |
genericv3 | yeah i am in, that was just a temporary problem | 23:50 |
genericv3 | Done, no more reboot on failure | 23:51 |
genericv3 | There is so much apex errors (no such file or directory) | 23:53 |
genericv3 | droid-hal-init failed too | 23:53 |
genericv3 | 😎😎😎everything is going fine | 23:53 |
T42_ | <b100dian> @elros34 so a new software / old hw combo | 23:53 |
T42_ | <b100dian> genericv3: logcat as early as possible? | 23:54 |
genericv3 | Does journalctl count? Couldn't launch logcat on previous attempt. | 23:54 |
T42_ | <elros34> both apexd services works? | 23:55 |
genericv3 | there is a lot of apex errors as i said, but i didin't saw the service exiting, i think.. | 23:56 |
T42_ | <elros34> then search why droid-hal-init fails | 23:57 |
mal | hmm, did I add those cetain apex patches to that base, the ones needed for non-updatable apexes or something | 23:59 |
Generated by irclog2html.py 2.17.1 by Marius Gedminas - find it at https://mg.pov.lt/irclog2html/!