Summary: | src/egl/main/egldisplay.c: In function '_eglGetNativePlatform': error: '_EGL_PLATFORM_' undeclared | ||
---|---|---|---|
Product: | Mesa | Reporter: | Rolf Eike Beer <eb> |
Component: | EGL | Assignee: | Tapani Pälli <lemody> |
Status: | RESOLVED FIXED | QA Contact: | mesa-dev |
Severity: | normal | ||
Priority: | medium | ||
Version: | 19.0 | ||
Hardware: | ARM | ||
OS: | Linux (All) | ||
Whiteboard: | |||
i915 platform: | i915 features: | ||
Attachments: | add check for empty egl_platform |
Description
Rolf Eike Beer
2019-06-18 09:04:50 UTC
Can you include also information how did you configure the meson build? I think you should get this to work by at least having one platform defined, as example by setting "-Dplatforms=x11". meson --cross-file /opt/emlix/master/etc/meson-cross-file.txt --buildtype debugoptimized --prefix=/usr --sysconfdir=/etc -Ddri-drivers=swrast -Dgallium-drivers= -Dllvm=false -Dopengl=true -Dplatforms=,drm,x11 ../xorg.Mesa3 Right, it's the empty option given there: "-Dplatforms=,drm,x11", remove the first ',' and that should fix your issue. It happens because of the leading ',' in platforms, which did not create a problem until now. I still think this should be caught instead of generating an invalid setup. (In reply to Rolf Eike Beer from comment #4) > It happens because of the leading ',' in platforms, which did not create a > problem until now. I still think this should be caught instead of generating > an invalid setup. I don't see why someone would do that as it's not how we document at https://www.mesa3d.org/meson.html. But fair enough, I guess the build could error out if such given. It was the result of an automatic selection step that went slightly wrong, i.e. it was a variable containing " x11 drm" and the replaced all spaces with ',' without trimming first. Why it does not error is that platforms list 'choices' includes empty string '' (meson_options.txt), I'm not sure if there's a good reason for that. We could alternatively remove the '' from choices or add explicit check that the first platform is not empty. Created attachment 144586 [details] [review] add check for empty egl_platform Here's a fix proposal. Comment on attachment 144586 [details] [review] add check for empty egl_platform LGTM I wonder if the check should not be the other way round: it should check that the default platform is in a list of platforms known to work, that way it would also catch typos that could lead to equally strange messages. (In reply to Rolf Eike Beer from comment #10) > I wonder if the check should not be the other way round: it should check > that the default platform is in a list of platforms known to work, that way > it would also catch typos that could lead to equally strange messages. I thought of that but that case is actually handled already, you can test this my putting some bogus platform name there. Meson automatically checks which choices are possible for the option, see 'choices' in meson_options.txt. FWIW the empty string thing is a know issue that will be fixed once we bump our requirement to meson 0.47; the MR has been around for a while: https://gitlab.freedesktop.org/mesa/mesa/merge_requests/386 But yeah, until we can do that it's not a bad idea to add extra checks for these empty values like the one Tapani suggested 👍 I sent a bit different fix here: https://gitlab.freedesktop.org/mesa/mesa/merge_requests/1139 --- 8< --- commit ff77b0415bf8a6540ec29663e093171aaeab18a3 Author: Tapani Pälli <tapani.palli@intel.com> Date: Tue Jun 18 13:50:52 2019 +0300 meson: error out if platforms contains empty string Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=110939 Signed-off-by: Tapani Pälli <tapani.palli@intel.com> Reviewed-by: Eric Engestrom <eric@engestrom.ch> |
Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.