**** BEGIN LOGGING AT Thu Jan 21 02:59:57 2021 Jan 21 07:00:30 Morning! Jan 21 07:57:28 Morning! Jan 21 07:59:35 Morning! Jan 21 08:18:17 Herrie: so I think I'll reactivate the VNDK variables, and try to put in place this "vndk_light" thing to allow more paths for the linker to search into Jan 21 08:18:55 that should solve the issues for targets like tissot where the blobs are still linked with libraries in system/lib Jan 21 08:26:17 OK Jan 21 08:26:27 Sounds like something that might work Jan 21 08:26:37 I guess trial and error Jan 21 08:54:28 when I look at the modifications done to make tissot "treble compatible", it looks like the guys had to edit the blobs themselves Jan 21 08:55:09 fwiw, we can keep a non-treble image, fine with me :) Jan 21 09:36:13 Yeah also with me Jan 21 09:36:20 Editing blobs is not a lot of fun ;) Jan 21 09:36:25 And prone to errors, I'm sure Jan 21 10:28:48 and in the end, you get a DMCA and all go to trash :( Jan 21 11:46:28 so, the flag PRODUCT_USE_VNDK_OVERRIDE works: "ro.vndk.lite=true" Jan 21 11:46:41 now, how to write that ld.config override :p Jan 21 13:15:24 Tofe: Would this be for libhybris or on Android side? Jan 21 13:15:36 For libhybris we could conditionally patch for certain targets this file: https://github.com/Halium/libhybris/blob/master/hybris/common/o/linker.cpp Jan 21 13:57:17 Herrie: for android, to let us define a ld.config.vndk-lite file Jan 21 13:58:12 If we have issues with the libhybris side, yes, we have also this possiblity (and it's much easier :p ) Jan 21 13:58:46 we could also add a patch to halium-9.0 , but I'd like to stay on the "official" patches unless really unavoidable Jan 21 16:44:26 Herrie: I think I understand: we have a pre-O ld.config.txt, and for this version the "vndk" folders just didn't exist... so it's not looking there. We should find a more up-to-date ld.config.txt, and maybe that'll be enough. Jan 21 16:44:48 Ah ok Jan 21 16:45:21 just really not sure what generates it Jan 21 16:46:20 https://github.com/MotorolaMobilityLLC/system-core-pie/blob/master/rootdir/etc/ld.config.vndk_lite.txt here's something a bit more recent Jan 21 16:46:45 but we probably can find something relevant in the treble forks for tissot Jan 21 16:50:06 ok so actually, in system/core/rootdir/etc/, there's ld.config.legacy.txt ld.config.txt ld.config.vndk_lite.txt Jan 21 16:50:20 then there must be a flag selecting which one we use Jan 21 16:55:46 For VNDK enforced devices that have defined BOARD_VNDK_VERSION, use "ld.config.txt" as a source file. Other treblized devices, that have not defined BOARD_VNDK_VERSION or that have set BOARD_VNDK_RUNTIME_DISABLE to true, use "ld.config.vndk_lite.txt". If the device is not treblized, use "ld.config.legacy.txt" ==> so why do we end up with the legacy one ? Jan 21 17:10:13 ahah, ok, understood. looks like we need either PRODUCT_TREBLE_LINKER_NAMESPACES or SANITIZE_TARGET... Jan 21 17:10:35 the documentation is incorrect then. Great. Jan 21 17:13:15 nope, still not enough... how should we read "ifeq ($(PRODUCT_TREBLE_LINKER_NAMESPACES)|$(SANITIZE_TARGET),true|)" , it looks incomplete Jan 21 17:31:08 ok I understand; and we have to set "PRODUCT_TREBLE_LINKER_NAMESPACES_OVERRIDE := true" with the _OVERRIDE, otherwise it takes the value of PRODUCT_FULL_TREBLE... great. Ok, solved, let's see now what we get... Jan 21 17:44:37 ok, it's not much better, in the sense that we get things like /system/lib/vndk-28/android.hardware.radio.deprecated@1.0.so which are looked for in /vendor/lib/vndk-28 (if I read correctly the new ld.config file I get) Jan 21 17:58:42 ... which I didn't read carefully enough. It should look into /system/lib/vndk-28 . Jan 21 18:24:05 Tofe: Android build system is such a mess Jan 21 18:33:37 yup Jan 21 18:33:43 and I just understood a bit more Jan 21 18:34:11 we have "vendor -> /system/vendor" symlink here Jan 21 18:34:29 this doesn't go well with treble's linker rules Jan 21 18:35:04 all that you'll launch in /vendor, like /vendor/bin/hw/qcrild , will be seen as /system/vendor/.... so under system Jan 21 18:36:48 there's probably a magical variable to disable that symlink :p Jan 21 18:37:23 and we could probably handle a bind mount somewhere Jan 21 18:57:17 it's not very easy: either we define BOARD_USES_VENDORIMAGE and then we'll have /system/vendor -> /vendor plus probably tons of errors about installing stuff in /system/vendor , or we keep it like today and it will create the other symlink Jan 21 18:59:05 let me try a little trick with the ld.config file Jan 21 19:02:35 yes, the trick works Jan 21 19:03:48 (I've inserted "dir.vendor = /system/vendor/bin/" at the beginning of the ld.config file, which means that paths like this will be associated to the "vendor" namespace, which is the goal) **** ENDING LOGGING AT Fri Jan 22 02:59:58 2021