Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix bcsave-related deprecation warnings on macOS #618

Merged
merged 1 commit into from
Jan 7, 2025

Conversation

rdw-software
Copy link
Member

Currently the runtime is compiled in Objective C compatibility mode because of glfw3webgpu, which unfortunately still hasn't been merged upstream yet (see 43dbf1e for context). LuaJIT bytecode objects are passed as C files to the linker, but the runtime is of course a C++ executable - hence the warning.

This was previously changed in 8e0af2e when adding support for M1 builds, because the generated bytecode objects were misaligned. I don't know if the alignment issues are still present, but there's only one way to find out...

Currently the runtime is compiled in Objective C compatibility mode because of glfw3webgpu, which unfortunately still hasn't been merged upstream yet (see 43dbf1e for context). LuaJIT bytecode objects are passed as C files to the linker, but the runtime is of course a C++ executable - hence the warning.

This was previously changed in 8e0af2e when adding support for M1 builds, because the generated bytecode objects were misaligned. I don't know if the alignment issues are still present, but there's only one way to find out...
@rdw-software rdw-software merged commit 69ca177 into main Jan 7, 2025
10 checks passed
@rdw-software
Copy link
Member Author

Well, this clearly broke the M1 build (#623). But why did the CI pass? Maybe it's time to remove ccache...

@rdw-software
Copy link
Member Author

Update: The warning would technically go away if compiling the bytecode objects as .cc, but that isn't possible because luautf8 doesn't build as C++ and the runtime includes it directly right now. That's a bit of a hack and should probably be fixed, but in order to fix M1 builds it's easiest to just revert to .c objects for now (and clean ObjC builds up later).

The failure wasn't detected because CI ran on main instead of the target branch - clearly it's a bad idea to tinker with GHA and the build system when tired... However, this PR itself isn't to blame here - it "should" be a harmless change.

@rdw-software rdw-software deleted the objc-deprecation-warnings branch January 7, 2025 21:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant