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

EGL contexts in GRDirectContext.MakeGL, mark2 #303

Open
wants to merge 15 commits into
base: main
Choose a base branch
from

Conversation

HinTak
Copy link
Collaborator

@HinTak HinTak commented Jan 13, 2025

Tidied up, identical to and replaces #294 . @Swarzox

I don't think this should be merged as is, mainly for its additional dependency which most linux users don't need, as well as the fact that ideally, EGL builds should be built on the platform against the GPU vendor's libEGL libraries provided.

That said, since I added a CI stanza for building and testing on EGL headless fedora, I probably can make a mark 3 and just provide the difference as a patch, patch it in just before testing, and maintain such a patch indefinitely (until the skia folks change the surrounding GL code...).

So some of this might end up in m134 or later, just not in this form.

HinTak added 14 commits January 13, 2025 21:30
See
python/cpython#128161
"Defining iterator in a separate class no longer works in 3.13"

We have iterator for SkTextBlob defined by SkTextBlob::Iter(textblob),
which is the c++/pybind11 equivalent of the same situation.
Following the suggestion:
python/cpython#128161 (comment)

Also see actions/runner-images#11241

Fixes kyamagu#295
Comments about recovering from auditwheel repair

changing the checksums to match current build
…L contexts with EGL

There are two ways of enabling EGL support on Linux AFAIK: `skia_use_egl=true` switches over
to X11 completely. Or we just add `GrGLInterfaces::MakeEGL` to GLX builds. This
is the 2nd approach. `skia_use_egl=true` is simpler, but modifies existing X11 behavior.

Fixes kyamagu#287
gn is really written for clang. Later version of gn has this fixed, but won't
build on older g++ (12) for another problem. Sigh. Staying in this version
of gn for the main builds.

Fedora ships gn actually, though it is a lot more change to adapt to this.
On EL7, EGL/egl.h is in mesa-libEGL-devel instead of libglvnd-devel (later Redhat)

Missing GLES2/gl2.h - in mesa-libGLES-devel

It is not likely that the runtime (libgGL*) libraries are missing if the devel are installed, but you never know.
Include them also.
Move the EGL test before the others to avoid messing the others up
@HinTak
Copy link
Collaborator Author

HinTak commented Feb 13, 2025

Opencv has a setup for headless builds: https://github.com/opencv/opencv-python/blob/255564a37c4a23275485e827abbe19031347d458/.github/workflows/build_wheels_linux.yml#L129 - maybe we can do something similar.

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