Skip to content

Fix macOS build - #6

Merged
h4lfheart merged 1 commit into
h4lfheart:mainfrom
UnrealPowerz:macos-build-support
Jun 2, 2026
Merged

Fix macOS build#6
h4lfheart merged 1 commit into
h4lfheart:mainfrom
UnrealPowerz:macos-build-support

Conversation

@UnrealPowerz

Copy link
Copy Markdown
Contributor

A few fixes to make builds work on macOS

  1. Some headers are not transitively pulled in on macOS, they have to be included explicitly
  2. localtime is different on macOS, same on Linux I believe
  3. Need to explicitly request an openGL 3.3 context, or macOS gives you an old one that does not have all the functions you need
  4. The audio system needs more time to shut down on macOS. I had Claude figure this out. The gist of it is that macOS CoreAudio is callback based, and sink->stop() does not synchronize with the OS-owned audio thread. So when sink gets immediately torn down by QT, in-flight audio callbacks can arrive on a partially torn-down thread, leading to segfault.
  5. The changes to the teardown fix a warning on shutdown that QTimers can only be stopped by the thread they live on.

@h4lfheart
h4lfheart merged commit da61c3f into h4lfheart:main Jun 2, 2026
1 check passed
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.

2 participants