From 5dff78f54553f064eb93bb42841b4afca4649dbf Mon Sep 17 00:00:00 2001 From: Josh Peterson Date: Tue, 30 Jun 2026 08:26:08 -0400 Subject: [PATCH] Stage libDeviceContextGlobals alongside the mojo runtime libs libAsyncRTMojoBindings now carries a runtime NEEDED on libDeviceContextGlobals (the virtual-device state was split into its own shared library so a process holds exactly one copy of it). The mojo toolchain stages a fixed set of support libraries next to every compiled mojo binary; libDeviceContextGlobals was missing from that set, so mojo binaries failed to load with "libDeviceContextGlobals.so: cannot open shared object file" once the runtime started depending on it. Add it to the glob. The glob keeps allow_empty=False over the whole list, so older mojo packages that don't ship the library still resolve (the pattern simply matches nothing) and nothing depends on it there. --- mojo/private/toolchain.BUILD | 1 + 1 file changed, 1 insertion(+) diff --git a/mojo/private/toolchain.BUILD b/mojo/private/toolchain.BUILD index d5ecfcb..8edbb3f 100644 --- a/mojo/private/toolchain.BUILD +++ b/mojo/private/toolchain.BUILD @@ -13,6 +13,7 @@ _INTERNAL_LIBRARIES = [ # Globbed to allow .so or .dylib "lib/libAsyncRTMojoBindings.*", "lib/libAsyncRTRuntimeGlobals.*", + "lib/libDeviceContextGlobals.*", "lib/libKGENCompilerRTShared.*", "lib/libMSupportGlobals.*", ],