Created attachment 127822 [details] [review]
Version 13.0 of mesa doesn't build on GNU/Hurd any more because of new occurrences of PATH_MAX, which hurd-i386 doesn't define since it doesn't have such
Here is a patch to fix this.
Please send this to mesa-dev.
As Ken mentioned please follow the instructions . Also consider the most obvious suggestion/counter-proposal - can we have a local define with reasonable default for the platform ;-)
I liked Samuel's approach of allocating the name to be the correct length, but opted to use asprintf rather than trying to manually compute that length.
Author: Kenneth Graunke <email@example.com>
Date: Tue Nov 15 11:53:33 2016 -0800
mesa: Drop PATH_MAX usage.
GNU/Hurd does not define PATH_MAX since it doesn't have such arbitrary
limitation, so this failed to compile. Apparently glibc does not
enforce PATH_MAX restrictions anyway, so it's kind of a hoax:
MSVC uses a different name (_MAX_PATH) as well, which is annoying.
We don't really need it. We can simply asprintf() the filenames.
If the filename exceeds an OS path limit, presumably fopen() will
fail, and we already check that. (We actually use ralloc_asprintf
because Mesa provides that everywhere, and it doesn't look like we've
provided an implementation of GNU's asprintf() for all platforms.)
Fixes the build on GNU/Hurd.
Cc: "13.0" <firstname.lastname@example.org>
Signed-off-by: Samuel Thibault <email@example.com>
Signed-off-by: Kenneth Graunke <firstname.lastname@example.org>
Reviewed-by: Emil Velikov <email@example.com>
on Jan 17, 2017 at 08:49:53.
(provided by the Example extension).