#
…

2024-08-22

00:13chadmed_do sam_ or leio have any thoughts about packaing the fex thunks?
00:29chadmed_chaos_princess: you reckon we just package fmt and ditch the vendored dep too?
00:29chadmed_same with catch2
00:29chadmed_both of which could probably be upstreamed into ::gentoo quick-smart after some incubation time in ::asahi
02:04abbe has joined #asahi-alt
02:20ipatch has joined #asahi-alt
03:02jeisom has quit [Ping timeout: 480 seconds]
03:57chadmed_ has quit [Remote host closed the connection]
04:08dcavalca85 has joined #asahi-alt
04:08dcavalca8 has quit [Read error: Connection reset by peer]
06:33xal has quit [Quit: bye]
06:33xal has joined #asahi-alt
06:42chaos_princesschadmed: at least for now, fmt must be vendored, it already is in ::gentoo, but iirc it is not slotted and the version that fex wants breaks dolphin.
06:49sam_chaos_princess: chaos_princess: sorry, brief me on fex thunks
06:49sam_means nothing to me
06:49sam_uh chadmed * too
06:58chaos_princessWe need a x86 compiler on arm64 host to compile them
07:07sam_start earlier than that please :)
07:07sam_what are they, why do we want them, ...
07:09chaos_princessA set of libraries that allow redirecting calls into x86 libraries to arm64 ones
07:10chaos_princesswe want them because running native arm code is faster than emulating x86 versions of system libraries
07:10sam_for what purpose?
07:10sam_games (dolphin)?
07:11chaos_princessFex is a x86 emulator for arm, the main purpose is games, but not neccessarily
07:11sam_so the main issue is "how do we nicely package an x86 compiler so building fex works"?
07:12chaos_princessPretty much.
07:13sam_the answer is to copy mingw64-toolchain/bpf-toolchain
07:13sam_they're all-in-one ebuilds that do binutils+gcc (and mingw64-runtime in the case of mgwt)
07:13sam_this avoids users having to run crossdev
07:13sam_do you really need glibc too?
07:14sam_it can be done i think but the existing examples didn't
07:14sam_but it should be fine to add that in
07:14chaos_princessNot super sure about fex, but i am making another thing that needs an x86 compiler and that one does need glibc
07:14sam_you should copy mingw64-toolchain if needing that runtime component (as it has an equivalent, whereas we didn't need that for bpf)
07:48chaos_princessguess i will try building them with clang since that is an option and fex requires clang anyway
08:09n3ph has joined #asahi-alt
08:22leiochadmed: I don't know what fex thunks are. We still owe you some PR merges too, I think?
08:23leiooh, need to continue reading, it was explained to sam after :)
08:56n3ph has quit [Quit: WeeChat 4.3.4]
08:56n3ph has joined #asahi-alt
09:03n3ph has quit [Quit: WeeChat 4.3.4]
09:05n3ph has joined #asahi-alt
09:11zerdox has joined #asahi-alt
09:17chaos_princess has quit [Quit: chaos_princess]
09:18chaos_princess has joined #asahi-alt
09:25n3ph has joined #asahi-alt
09:25n3ph has quit [Quit: WeeChat 4.3.4]
09:31n3ph has quit [Quit: WeeChat 4.3.4]
09:31n3ph has joined #asahi-alt
10:05n3ph has quit [Ping timeout: 480 seconds]
10:12n3ph has joined #asahi-alt
10:21zerdox has quit [Ping timeout: 480 seconds]
10:27noisycoil has joined #asahi-alt
10:28noisycoil has left #asahi-alt [#asahi-alt]
10:37chadmedchaos_princess: that was going to be my third less-gross option. just enforce LLVM_TARGETS: AMD64 X86 (or whatever we need) and pass --target=x86_64-unknown-linux-gnu to clang and let it do it
10:38chadmedi did the reverse for distcc when i had an amd64 build host and pissant arm64 SBCs and it worked a treat
10:39chadmedpretty sure LLVM_TARGETS is basically non-negotiable these days right?
10:40chadmedyeah it is lmfao im just overriding it with profile/package.use.force
10:40chaos_princessyes, and also llvm_targets has an amazing footgun for people who use clang as system compiler
10:41chaos_princessso, just do not touch it
10:41chadmed*/* LLVM_TARGETS: -AMDGPU -ARM -ARC -AVR -Hexagon -Lanai -LoongArch -MSP430 -Mips -NVPTX -PowerPC -RISCV -Sparc -SystemZ -WebAssembly -VE -X86 -XCore
10:41chadmedtoo late :)
10:41chadmedbut on a normal system not maintained by a moronic goon we can expect AMD64 and X86 to be there so no worries
10:44sam_yeah if the software needs clang already then it's less of an issue
10:48chadmedleio: i think sam closed the asahi-sources PR that i had open so all good :)
10:48chadmedtherell be another one soon though
10:49chadmedand chaos_princess might have to fix tiny-dfr to deal with the new cargo.eclass stuff unless that got dealt with as part of that series
10:49chadmeduhhh no sorry asahi-nvram
10:49sam_I think Chewi tried to fix everything obvious in tree
10:49sam_he might have missed some
10:50chaos_princessdo i need too? i do not have any special code in src_install, so the eclass should just work (tm)?
10:51chadmedyeah if you dont do anything special in a makefile it should be fine
10:53chadmeddo we bootstrap llvm/clang by default these days?
10:53chadmedjust thinking about possible runtime abnormalities that might arise from using gcc-built clang to build the thunks
10:53chadmedor is that not really a thing anymore
10:58jeisom has joined #asahi-alt
10:58sam_no, we don't
10:58sam_we perhaps should but might have riots
10:59sam_pretty much nobody does it for clang anyway
10:59sam_it would be more palatable to the users if we could fix the LLVM_TARGETS mess
11:00chadmedhow come that ended up being forced btw? i missed that lore when it happened
11:02sam_some automagic bs with rust or something
11:02sam_i don't fully remembe tbh
11:02sam_i think it was worse back when lld wasn't slotted
11:02sam_but there were definitely a bunch of LLVM consumers who were greedily using all targets via CMake
11:02sam_I think it is all fixable, just about having someone with time & interest to do it
11:03chaos_princessits something involving rust, and also if you drop a llvm_target, and your main compiler is clang, it just straight up breaks your compiler
11:03sam_it sucks pretty hard because most people obviously dont need anything but the native target but there were definitely some things which were using anything available, or even *needing* everything (like zig?) and disabling it broke
11:04chadmedthat seems like something that is both really silly and could be fixed by those projects
11:05sam_agreed
11:05sam_it will become worse over time as llvm grows
11:05sam_it's already pretty bad
11:05sam_i mean, the impact of the current workaround, not necessarily the problem itself
11:05sam_the problem might even be gone (not sure how likely that is, but y'know
11:05sam_it is harder for the case chaos_princess mentions
11:06sam_(I consider the two as slightly different but maybe they're really the same cause as well, I don't know, I just never looked into it)
11:07j`eychadmed: that was annoying when I built zig recently on my air, had to rebuild LLVM because zig needs all targets
11:07chaos_princessthe second one is slightly worse, since it is not fixed by the current approach. right now some extra exotic stuff like xtensa is not enabled, and if you enable and then disable it, rip clang
11:08chadmedso stupid
11:08sam_oh that's terrible lol
11:08chadmedoh well i guess its kinda good for the issue at hand but less than ideal
11:09chadmedwe have a path forward that doesnt involve me hosting anything on my jank ass residential connection
11:09chaos_princesswhat exactly do you want to host
11:10chaos_princessand how much are you willing to abuse free^W vc-funded infra?
11:10chadmedwell like i said this morning i was considering a fex-thunks-bin package
11:10chadmedwherein i would build the thunks on my server and host them
11:11chaos_princesswrap the build in a docker container, upload it to ghcr.io, pull only the final layer's tarball in the ebuild
11:12* sam_kill
11:13chadmedthanks i have a migraine now
11:15n3phhint: there is `docker-squash` to merge layers
11:17sam_i dare say that somehow misses the point
11:17chadmedtired: getting a ups and paying my isp for an SLA
11:18chadmedwired: docker
11:18chaos_princessi've heard that back in the day people put pirated movies in a docker container and used docker's registry to distribute them, so my idea is comparatively tame
11:19chadmedokay thats pretty baller
11:59n3phsam_: I was anticipating.. 🙄
12:34jeisom has quit [Quit: Leaving]
12:35jeisom has joined #asahi-alt
12:45jeisom has quit [Remote host closed the connection]
12:46jeisom has joined #asahi-alt
12:58jeisom has quit [Remote host closed the connection]
13:04jeisom has joined #asahi-alt
13:07r0ni has joined #asahi-alt
13:34jeisom_ has joined #asahi-alt
13:34jeisom has quit [Read error: Connection reset by peer]
14:08john-cabaj has joined #asahi-alt
14:46n3ph has quit [Ping timeout: 480 seconds]
15:24JayBeeFOSS has quit [Ping timeout: 480 seconds]
15:25JayBeeFOSS has joined #asahi-alt
17:12mps has quit [Quit: leaving]
17:14mps has joined #asahi-alt
17:31jeisom_ has quit [Ping timeout: 480 seconds]
18:36zerdox has joined #asahi-alt
19:22psykose has quit [Remote host closed the connection]
19:24psykose has joined #asahi-alt
20:19jeisom_ has joined #asahi-alt
21:31n3ph has joined #asahi-alt
22:23chaos_princessmispaste, ignore me
22:41MichaelLong has quit [Remote host closed the connection]
22:42MichaelLong has joined #asahi-alt
23:06zerdox has quit [Remote host closed the connection]
…