Monday, 2021-05-03

riniguspiggz: did it work last night?05:59
DeckedHello everyone, I've been having some trouble porting SailfishOS to an old  LG G2, is this the right place to ask?07:02
DeckedI'm not sure if this is even working, I've never used IRC to begin with07:02
T42<Herrie1982> @Decked [I'm not sure if this is even working, I've nev …], It is working, yes this should be the right place07:10
DeckedGreat, thanks.07:11
T42<Herrie1982> G2 is quite similar to Nexus 5 in terms of specs07:11
T42<Herrie1982> There might be something done for it already07:11
DeckedI see, can I ask a small thing anyway?07:13
T42<Herrie1982> Sure you can ask, I'm not an expert on SFOS porting, but might be able to give you an answer, otherwise the other people here could.07:17
DeckedSo I was trying to port Sailfish os from Lineage 17.1, but I'm now stuck on part "7.2.1 Building the droid-hal-device packages". When I use the command `rpm/dhd/helpers/build_packages.sh --gg` the script can't build gst-droid.spec because it says it's missing gstreamer-photography-1.0. I've checked and it's gstreamer1.0-plugins-bad is already installed on both the PlatformSDK and on the The Target_SDK07:20
DeckedI tried removing the dependency on meson.build since I'm sure it's already installed but it fails somewhere else because there is still the dependency defined somewhere else07:22
T42<Herrie1982> I'm not sure how well 17.1 is working for SFOS port. For most other OS-es (UBPorts, LuneOS, Mobian etc) using Halium project) they're using either a 12.1, 14.1 or 16.0 based CM/LOS). I haven't done any SFOS ports myself, so cannot really help you there.07:23
DeckedI'm pretty new on SailfishOS but I saw that they added Android 10 support as of lately so I thought to give it a chance. From my understanding this problem isn't even related to the Android base and I can't find anything on the FAQs or IRC logs07:26
DeckedAnyways, thanks a lot either way, I'm sorry to trouble you07:29
rinigusDecked: I wonder whether you use too new gst-droid. check the version that you try to build against sfos 4.0.1 changelog07:30
DeckedHmm other than the fact that Gstreamer will be replaced by MW I can't find anything. I'll try building it without it and report back07:37
rinigusDecked: the repos are checked out under hybris/mw/, so see the version of gst-droid over there. for sony tama, I had to build gst-droid manually, without using -gg07:51
DeckedLooks to me as 1.0.008:00
riniguscheck with git log08:01
rinigusI am using 0.20210304.008:01
DeckedI see 0.20210430.008:01
rinigusthat could be too new. checkout older version and build using rpm/dhd/helpers/build_packages.sh --build=hybris/mw/gst-droid08:03
rinigusDecked: otherwise it will checkout the newest version again.08:04
DeckedSeems to have worked! thanks a lot08:06
rinigusmaybe this will help a bit - https://github.com/sailfishos-sony-tama/main/blob/hybris-10/hadk-sony-xz2.md . grep for gst- and there is an instruction next for gmp-. those replace -gg build08:06
DeckedYou suggestion worked perfectly, I changed to configuration to exclude gstreamer1.0-droid, ran --gg, after that I included it again and built gst-droid on 0.20210304.0 as you suggested08:09
DeckedI'm now building the rootfs (I think)08:10
DeckedFor some reason my PC is complaining about my Wacom Tablet being disconnected and reconnected when building it O.o but alright08:10
DeckedTime to see if it boots08:12
DeckedUgh failed to extract filesystem, what now08:15
rinigusDecked: maybe someone can chip in with fs extraction, my port is not based on lineageos and has different mic packing08:17
rinigusI suggest to get a log with the error, paste on pastebin-type site and send URL over here. maybe someone can look and help you08:18
DeckedI'm using the lineageos recovery, could that be the reason?08:18
Decked[  268.902183] tar: exec bunzip2: No such file or directory08:24
DeckedHere's the problem08:24
rinigusDecked: you mean to flash it? no idea, we used to use twrp for lineageos based ports... don't know how it is now08:26
DeckedYeah, I might try flashing TWRP first08:27
DeckedOh this is a problem08:42
DeckedTWRP worked but got out of memory before finishing08:42
T42<b100dian> Decked: I don't have bunzip2 in twrp either. I am flashing the boot img with fastboot or with twrp then use something along these lines for pushing the unbzipped tar and exctracting it on device https://pastebin.ubuntu.com/p/4sFnxbnZGS/08:49
DeckedWell my TWRP has bunzip2 installed with it but now the installation fails because the phone runs out of memory08:52
DeckedUsing tar manually on adb shell also fails because it runs out of memory09:03
T42<Herrie1982> We had some issues with tar on LuneOS from TWRP09:23
T42<Herrie1982> I think we use the busybox one now to do the unpacking09:23
T42<Herrie1982> @Herrie1982 [I think we use the busybox one now to do the u …], Yes see https://github.com/webOS-ports/android-update-package/commit/ad157df224ddc6ece8d641309c8c4b606c7650b409:30
DeckedI see09:33
DeckedReplacing busybox in TWRP did the trick thanks a lot09:51
T42<Herrie1982> Some of these funny quirks...09:57
DeckedHmm the phone won't boot after flashing, something something boot verification failed.10:02
T42<elros34> Decked, I guess you are booting android now. Follow 2 kernel related points from: collabedit.com/kr9xx. That wont be enough to get gui on 17 base but maybe at least telnet.10:25
Decked@elros34 sorry for the late reply, I'm not booting from Android, it's the phone itself that refuses to boot anything after flashing boot.img12:43
T42<elros34> If You didnt follow advices mentioned in that url then your are probably missing sailfish specific initramfs in hybris-boot.img and your kernel might be trying to boot from /system partition so you are basically booting android12:46
T42<elros34> also flashing boot.img is wrong, you must use hybris-boot.img12:47
DeckedYeah I did that12:47
DeckedSorry I mispelled12:48
DeckedBut I'm 90% sure I'm not booting android, in fact I don't think I'm booting anything at all12:48
DeckedWith the phone in that state plugging it via USB shows me the various MMC partitions as if I'd plugged in an hard drive and the recovery is unaccessable anymore12:49
T42<elros34> most important is to check how device shows in host dmesg: as android or mer boat loader12:50
Decked[ 6735.911416] scsi 6:0:0:0: Direct-Access     Qualcomm MMC Storage      1.00 PQ: 0 ANSI: 212:53
DeckedNothing else12:53
Deckedlsusb shows Bus 001 Device 019: ID 05c6:9006 Qualcomm, Inc. QHSUSB__BULK12:54
T42<elros34> is that first messega after you flashed hybris-boot or several reboots later?12:54
DeckedAfter I flashed hybris-boot, but the phone refuses to boot it whatsoever12:54
DeckedI'm 100% sure that the kernel didn't even load12:55
Deckednor the bootloader12:55
T42<elros34> so did you needed to revert skip_initramfs12:55
T42<elros34> ?12:55
DeckedThe phone is a LG G2 from 2013 so I skipped that part12:56
DeckedI don't think that applies to it12:56
T42<elros34> so it doesn't use system as root?12:56
DeckedI don't know, I know it uses a separate recovery partition though12:58
T42<elros34> check in fstab where system partition is mounted, in / or in /system12:59
DeckedFrom android right?13:00
T42<elros34> in device repo you will find fstab13:00
DeckedSorry about my ignorance but I don't follow you13:02
DeckedI don't have any fstab files other for the ones for the initramfs13:04
T42<elros34> https://github.com/LineageOS/android_device_lge_g2-common/blob/lineage-17.1/rootdir/etc/fstab.g2#L1413:05
DeckedOh my bad I searched for fstab only13:06
T42<elros34> maybe vbmeta then, don't you have such a partition?13:08
DeckedHmm the phone is basically bricked at this point let me try to fix it and I'll get back to you13:10
DeckedOk managed to get into the recovery, there's no vbmeta partition13:11
DeckedDDR         cache       dbibak      fota        grow        modem       mpt         pad2        recovery    sbl1        ssd         tz13:12
Deckedaboot       cust        drm         fsc         laf         modemst1    pad         persist     rpm         sns         system      tzbak13:12
Deckedboot        dbi         encrypt     fsg         misc        modemst2    pad1        rct         rpmbak      spare       tombstones  userdata13:12
DeckedRealistically I should have tried to port Sailfish from an older LineageOS version13:13
piggzrinigus: why would tbuilder not auto install a deb that is available?15:31
piggzhttps://paste.mozilla.org/GSRcf9WC15:31
riniguspiggz: it caches the available dependencies. remove caches in the build folder15:33
riniguslet me write it into the docs as well15:33
riniguspiggz: caches described in the updated readme of tbuilder15:42
piggzrinigus: now another issue finding some packages15:47
piggzrinigus: ah, failed to install because of sig verification15:50
piggzyou must have had that? a workaround?15:52
riniguspiggz: you could either add repo with an option to disable sig check out run zypper refresh manually in target (not snapshot) and accept non signed repo16:06
piggzrinigus: now, a funky file path is missing Cannot find file: /parentroot/data/piggz/mer/android/tbuilder/amazfish-build/src/harbour-amazfish/parentroot/data/piggz/mer/android/tbuilder/amazfish-build/build/SailfishOS-4.0.1.48-armv7hl/harbour-amazfish.spec.16:15
piggzthis folder exists and is the source /parentroot/data/piggz/mer/android/tbuilder/amazfish-build/src/harbour-amazfish/16:16
piggzbut there shouldnt be a parentroot/ in there16:16
riniguspiggz: ohhh, that's something unexpected16:19
rinigusdo you compile with "shadow_builds"?16:20
piggzshadow_builds:16:21
piggz  - harbour-amazfish.spec16:21
piggzi just copied that from the example16:21
riniguswould you mind to try without?16:21
rinigusjust remove that option. not sure if it will help16:22
piggzrinigus: yeah, that seems to be building now16:23
rinigusto see where that issue came, please check how symlink was defined in spec. ls -l spec?16:24
piggzlrwxrwxrwx 1 piggz piggz 49 May  2 20:12 harbour-amazfish.spec -> ../src/harbour-amazfish/rpm/harbour-amazfish.spec16:34
piggzlooks ok16:34
riniguspiggz: it does look fine, indeed16:43
riniguspiggz: but I wonder where is this /parentroot sneaking in? let me find check if I can reproduce it16:46
T42Tz %lastname% was added by: Tz %lastname%16:59
T42<Tz %lastname%> https://t.me/joinchat/2l_0GNGNKwtkOWY017:30
riniguspiggz: just in case - is src/harbour-amazfish folder or a link somewhere further?17:51
T42<adampigg> A folder17:52
rinigus@adampigg: I tried to reproduce it with /parentroot/tmp/test and a project under it, but no luck. no such weird path.18:29
riniguswould you mind to paste build.log for failing case? just define using shadow_builds as before and touch the spec to start the rebuild18:29
riniguswould also help to have `pwd` from the shell where you run tbuilder18:30
T42<adampigg> rinigus: i warn you, my path is a funny one (tho it has always worked)18:57
riniguspiggz: not sure about "always", let me grep the logs18:58
rinigus:)18:58
T42<adampigg> PlatformSDK [piggz@linux-f1uu amazfish-build]$ pwd18:59
T42<adampigg> /home/piggz/mer2/android/tbuilder/amazfish-build18:59
T42<adampigg> the funny bit:18:59
T42<adampigg> PlatformSDK [piggz@linux-f1uu amazfish-build]$ file /home/piggz/mer218:59
T42<adampigg> /home/piggz/mer2: symbolic link to /parentroot/data/piggz/mer/18:59
riniguspiggz: OK, I will try with something similar. let's see19:02
rinigusif I can reproduce19:02
piggzrinigus: background....19:03
piggzall my builds happen on my spinning disk, as it has space, mounted in /data, in /data/piggz/mer19:03
piggzall the scripts/docs usually use ~/mer as a folder, so i made that a symlink19:04
piggzbut, once in the sdk, that symlink doesnt work, so, i made another mer2 which works from within the sdk19:04
piggzANDROID_ROOT uses that one19:05
rinigusYeah, I used to use something like it, but ended up settling with just home. Let me see if I can reproduce it with symlinks in the path19:12
riniguspiggz: nope, it still works here as well. if I make ~/tmp/test -> /parentroot/tmp/test and use ~/tmp/test/subdir as a project dir, all seems to be resolved fine19:28
rinigusit detects that build should be done in /parentroot/tmp/test/subdir/build/SailfishOS-4.0.1.48-aarch64/yamui.spec (which will fail, but for other reasons). no double parentroot in the path19:29
rinigusas you have19:30
piggzok, i just wont use shadow build19:30
piggzfor now, until i can be bothered debugging19:30
riniguslet's stick with that :)19:30
rinigusmany packages don't support it anyway, so it is easier to do without. I can build few of my own with the shadow builds, but not the port19:32
UmeaboyHi! Is there a fix for the python error when running the repo init command for hybris-17.1 ?21:09
T42<b100dian> You can run repo commands outside of the platformsdk shell21:10
UmeaboyI OK.21:11
T42<elros34> or use python2 compatible repo from same site you have downloaded python3 one21:11
UmeaboyThe HABUILD_SDK python version is 3.4 and 3.5+ is needed.21:16
UmeaboyIsn't it time to update the chroot to a newer version of Ubuntu ?21:17
UmeaboyIt would get rid of this issue as the python version would be more correct.21:18
UmeaboyJust saying.21:21
T42<elros34> for older devices is good to have old ubuntu chroot for compability reasons, for newer device you just don't need to use chroot at all21:23
T42<b100dian> I was also wondering, so one could just build the android bits in the host system and call it a day?21:28
T42<b100dian> So, I now have different crashing services (other than servicemanager) since i added LD_PRELOAD here https://github.com/b100dian/droid-config-tucana/commit/53536e2cc4861556d69b846d0d0599158ae2fddb for servicemanager.rc and then added the cheesburger init files (parent commit). Here is the sys/fs/pstore output: https://pastebin.ubuntu21:38
T42.com/p/qBMsQ9Nfz3/21:38
T42<b100dian> Maybe you can help with any of the questions:21:38
T42<b100dian> Q1: `drv2604_firmware_load, ERROR!! firmware not found` at about 12th second: this is not built as a module, however systemd seems to run the mounts before that, wondering why it doesnt find the firmware.21:38
T42<b100dian> Q2: There are now other services crashing, do they also need the LD_PRELOAD patch? Or do they need listing in disabled_services.rc? (grep for `>>>`. Example: /system/bin/hw/android.system.suspend@1.0-service)21:38
T42<b100dian> Q3: Reboot at second 88: `adsp subsystem failure reason: err_qdi.c:450:EF:sensor_process:1:dog_virtual_user.c:240:USER-PD DOG detects stalled initialization, triage with IMAGE OWNER.` Does this sound familiar? I've recently switched audio and wlan to modules, but they seem to not be loaded automatically from rootfs's /lib/modules, in21:38
T42 fact, some "disagrees about version of symbol module_layout" messages are around second 41 which indicate modules are loaded from .. /vendor/lib maybe? (the untouched vendor partition..)21:38
*** Sellerie3 is now known as Sellerie21:38
Umeaboyelros34: Would you happen to know how it works to patch a newer release of Lineage once it's released? I'm curious about how it works. I know we can see all the commits, but I mean, what decides that that file should be patched so that the Hybris image can be built? My phone uses a unofficial version of Lineage 18.0, but the latest official version of Lineage is 18.121:45
T42coddato was added by: coddato21:49
T42<coddato> Hi Is there a build for herolte ?21:50
T42<elros34> Umeaboy: latest patches are for lineage-17 not 18. Preparing patches for lineage 18 is not trivial so without having some knowledge and spend a lot of time you will not be able to do this. I only patched some vendor sdk android sources once using existing patches for older base and even that wasn't piece of cake21:55
Umeaboycoddato: Yes: https://forum.xda-developers.com/t/sailfish-os-for-the-samsung-galaxy-s7.3745646/21:56
T42<elros34> @b100dian I am wondering why do you add hybris-16 rc files if you are using hybris-17?22:04
T42<elros34> dmesg is not enough to figure out  what is wrong, you should check logcat and journal.22:04
T42<b100dian> Not that clever, right? Just trying everything I did not try. So you're saying i should back off the cheesburger init stuff because it was lineage-16 specific22:05
T42<elros34> I thinks you should follow hybris17 device repos: xperia x10 II, fp3 and probably some other devices22:06
T42<elros34> here is another device (no idea whether this one works): https://github.com/SailfishOS-sagit/droid-config-sagit22:10
T42<b100dian> Thanks, I'll try to look more into those. The xiaomi sagit seems promising:) - I know you said you dont' know if it works, just cheering that I recognize some patterns22:20

Generated by irclog2html.py 2.17.1 by Marius Gedminas - find it at https://mg.pov.lt/irclog2html/!