Skip to content

Some CoreGraphics functions are only available on macOS#617

Merged
not-fl3 merged 1 commit intonot-fl3:masterfrom
Pewnack:ios_coregraphics_limitations
Apr 6, 2026
Merged

Some CoreGraphics functions are only available on macOS#617
not-fl3 merged 1 commit intonot-fl3:masterfrom
Pewnack:ios_coregraphics_limitations

Conversation

@Pewnack
Copy link
Copy Markdown
Contributor

@Pewnack Pewnack commented Apr 4, 2026

This is a fix for #561

Apple's CoreGraphics framework functions CGDisplayPixelsHigh and CGMainDisplayID are only available on macOS. They do not exist on iOS.

If you compile your miniquad code as a static library and link it to your iOS App, the build on Xcode fails with the following errors:

Undefined symbol: _CGDisplayPixelsHigh
Undefined symbol: _CGMainDisplayID
Linker command failed with exit code 1 (use -v to see invocation)

Modified framework.rs to make sure, they're only included on macOS.

@Pewnack
Copy link
Copy Markdown
Contributor Author

Pewnack commented Apr 4, 2026

@not-fl3 sorry for the PR spamming. Had some time on my hands. Figured I'd try to help out. You can also just ignore them 😄

@not-fl3
Copy link
Copy Markdown
Owner

not-fl3 commented Apr 6, 2026

Thanks for PR!

I very much appreaciate your work, I do not have any Mac hardware, so without your PRs Mac bugs would never be fixed :)

@not-fl3 not-fl3 merged commit 3ba5082 into not-fl3:master Apr 6, 2026
11 checks passed
@Pewnack
Copy link
Copy Markdown
Contributor Author

Pewnack commented Apr 7, 2026

Thanks for merging!

@Pewnack Pewnack deleted the ios_coregraphics_limitations branch April 7, 2026 15:38
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