!lymvtcwDJ7ZA9Npq:lix.systems

Lix Development

415 Members
(Technical) development of Lix, the package manager, a Nix implementation. Please be mindful of ongoing technical conversations in this channel.139 Servers

Load older messages


SenderMessageTime
28 Jul 2025
@emilazy:matrix.orgemilyyes20:51:05
@emilazy:matrix.orgemilyit's very deprecated20:51:06
@raitobezarius:matrix.orgraitobezariusif you teach me how to replace it, i'm glad20:51:13
@emilazy:matrix.orgemily sorry I'm missing context I just saw -flat_namespace and started twitching 20:51:24
@raitobezarius:matrix.orgraitobezariusbut right now i'm trying to understand why linux and darwin differs on giving a certificate to curl20:51:26
@emilazy:matrix.orgemilyso many headaches have resulted20:51:28
@raitobezarius:matrix.orgraitobezarius
In reply to @emilazy:matrix.org
sorry I'm missing context I just saw -flat_namespace and started twitching
it's ok, i'm ranting here to summon darwin expertise
20:51:40
@raitobezarius:matrix.orgraitobezariusand "don't do X or Y"20:51:43
@emilazy:matrix.orgemily(I wish Linux had two-level namespaces)20:51:46
@raitobezarius:matrix.orgraitobezariusand hopefully suggestions on how to do better20:51:48
@emilazy:matrix.orgemilyif you are trying to do preload type stuff I am not sure what the correct solution is (it may be "don't do that")20:52:11
@emilazy:matrix.orgemily but maybe you can install_name_tool to adjust the internal name 20:52:40
@emilazy:matrix.orgemily with -id or such 20:52:48
@raitobezarius:matrix.orgraitobezariuswhat i'm seeing is20:53:06
@raitobezarius:matrix.orgraitobezarius (a) if i set -flat_namespace, static initializers seems to run 20:53:15
@raitobezarius:matrix.orgraitobezarius(b) if i don't, they don't20:53:18
@raitobezarius:matrix.orgraitobezariusso how can I get static initializers to run in plugins on macOS? :D20:53:33
@raitobezarius:matrix.orgraitobezarius install_name_tool is not even a thing at this step I suppose? 20:53:46
@raitobezarius:matrix.orgraitobezariusor meson should do it for me?20:53:51
@raitobezarius:matrix.orgraitobezariusbut if removing flat_namespace means moving everything to lazy initialization in the C++ codebase20:54:16
@raitobezarius:matrix.orgraitobezariusi'm not going to do that cleanup20:54:19
@raitobezarius:matrix.orgraitobezariusi'd rather take this or disable the entire plugin feature for macOS20:54:26
@emilazy:matrix.orgemilyI believe the static initializers should run before any other code in the loaded library20:56:44
@emilazy:matrix.orgemilythough after a quick Google, it may be that you are doing the linking a bit wrong20:57:06
@emilazy:matrix.orgemilye.g. https://github.com/ziglang/zig/issues/13319 https://issues.chromium.org/issues/4027645620:57:21
@emilazy:matrix.orgemily (I haven't tried using static initializers in a dlopen()ed library myself so I have no particular expertise here) 20:57:31
@emilazy:matrix.orgemily (my guess is that if -flat_namespace fixes it it's a cursed side effect) 20:57:51
@raitobezarius:matrix.orgraitobezarius
Static initializers in Rust are not supported and do not work
correctly on Apple platforms, failing compilation and even crashing
lld on iOS.

Replace the Rust-side static initializer with the use of linkme to
collect the registration functions and use a C++ static initializer
to do the registration of the Rust tests.
20:59:14
@raitobezarius:matrix.orgraitobezariuspromising20:59:15
@raitobezarius:matrix.orgraitobezarius

Dyld sees the first padding nulllptr and stops processing initializers further.

21:00:00

Show newer messages


Back to Room ListRoom Version: 10