zng-ui / zng

Cross-platform GUI framework.
Apache License 2.0
47 stars 0 forks source link

Fix `"view_prebuilt"` linking on macOS #437

Closed SamRodri closed 1 month ago

SamRodri commented 1 month ago

Fixes #435

Issue is macOS system linker "optimizing" away the zng-view-prebuilt crate because it is only used via a linkme reference. See upstream issue dtolnay/linkme#61.

To workaround I added a bogus reference to view-prebuilt that never actually runs and cannot be optimized away.

SamRodri commented 1 month ago

Tested on an old macOS, I get error from the downloaded prebuilt:

dyld: cannot load 'my_program' (load command 0x80000034 is unknown)

I believe this is unrelated, because a local prebuild made on the same machine works, this new bug is tracked in #438