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
Support Software Rendering for X11 by allowing to disable GLX #4782
Comments
The problem seems to be that on ARM we are picking GLES, while we should pick GL for Mac M* hardware when inside a docker container. |
I don't know if this is a daft question but why are you running a GUI app in a docker container? All our tooling is designed to build native apps for each platform. P.s. If you want to build a GUI for docker won't it need to be a Linux app not a macOS app? |
Does it help to build with |
This might also be an effect related to the fact that you might not have all the necessary graphics drivers installed in the Docker container. I do most of my development in a Fedora Toolbox container on Fedora Silverblue and that requires some extra driver packages to be installed for things to work as expected (see containers/toolbox#1023 (comment)) |
Not a daft question, and for the record the project compiles flawlessly on MacOS with just XCode and Go installed. However I'm trying to make a coding screen for interviewees and wanted to make then environment as simple and non-invasive for them to use as possible, so I was hoping to provide a devcontainer they could just checkout and use without having to install a bunch of dependencies on their computers they may not need to use. In the past I've done this with apps that either don't have GUIs or use the web, but we are a Go shop and I thought this would be a good platform. As an aside, I tried to use the web target as another work around and downgraded go to 1.19 to use gopherjs's 1.19 beta, but one of the dependencies my project has uses generics. I tried
I get the same result with or without the
I installed |
A fyne app has no runtime dependencies, so hopefully this is not a build issue.
You could use the |
How would I do this? I tried |
Never try to go get github.com/fyne-io/fyne/v2. You should still use fyne.io like usual |
@Jacalz in that case how do I use the develop branch? Or should I just not try that?
|
These two commands ought to work:
|
Ah, ok that works, thanks. When I do that I get:
is that something I'm doing wrong or a temporary hiccup with the develop branch? Sorry, I realize this is veering off topic from the original issue request but it is potentially more directly addressing my primary goal. |
Ah, sorry, that's just how you get fyne from the develop branch. You also need to use the new fyne command: https://github.com/fyne-io/tools/blob/main/cmd/fyne/main.go
|
Thank you @Jacalz ! That got me going and the app works for me now. I have a small problem which is that it loads into a black screen - I think this is because of Chrome's anti-autoplay of audio policy and my app loads ebitengine to play audio, but that's a separate issue. The specific problem I created this ticket for isn't solved but I have an even better work around, so thank you everyone who chimed in. |
Checklist
Describe the bug
I am trying to develop a Fyne application in a devcontainer on Mac OS. The challenge with this is that with the new M1/M2/M3 Macs there is no GPU acceleration in Docker, so their is only the software renderer in MESA available.
When I run my application I get a crash like this:
with a bit of searching I found that you can give GLFW the window hint
GLFW_EGL_CONTEXT_API
to disable using GLX API calls, which I think would fix my problem, but I don't see a way to do that within Fyne.My usecase is sort of esoteric but there are probably other uses of using Fyne with software rendering.
How to reproduce
Here is my Dockerfile:
within that docker container, run a minimal Fyne application and the GUI will not appear.
Screenshots
No response
Example code
Fyne version
2.4.4
Go compiler version
1.22
Operating system and version
MacOS host, Debian 11 dev container
Additional Information
No response
The text was updated successfully, but these errors were encountered: