Commit graph

11 commits

Author SHA1 Message Date
Kyle Brenneman a7bb6f4d19 Remove extra paragraph from license text.
Remove the "If only executable code is distributed..." paragraph from
the license text. Everything now uses a normal MIT license.

The only code from Khronos that's included in libglvnd is the EGL/GL
header and XML files, which do not contain that paragraph.

Fixes https://gitlab.freedesktop.org/glvnd/libglvnd/-/issues/221
2021-09-30 09:21:34 -06:00
Kyle Brenneman aeb905d8a7 util: Remove the executable allocation functions.
Remove all of the functions related to allocating executable memory, since
they're no longer needed.
2019-11-22 15:58:11 -07:00
Kyle Brenneman 1cd6a43122 Factor out some common extension string functions.
Moved the UnionExtensionStrings and IntersectionExtensionStrings functions from
EGL to utils_misc.c.

Changed libGLX to use the common UnionExtensionStrings and IsTokenInString
functions instead of its own versions of them.

Moved ParseClientVersionString to libglx.c near where it's used, and deleted
libglxstring.c and libglxstring.h.
2016-10-13 13:22:13 -06:00
Kyle Brenneman 82c37ca46b util: Add functions for splitting a string into tokens. 2016-06-22 16:13:20 -06:00
Kyle Brenneman fc61f5488f util: Add a local implementation of vsprintf(3). 2016-06-14 15:39:11 -06:00
Damien Leone 66f478867c libglvnd: Add support for ARMv7
This commit adds static and dynamic TSD stubs generation support for ARMv7.

Testing coverage includes all ARM / Thumb mode combinations between
libglvnd and a vendor implementation.
2015-07-29 13:16:14 -07:00
Kyle Brenneman cce5479b75 utils: Try using O_TMPFILE to create a temp file in AllocExecPages.
In AllocExecPages and OpenTempFile, it will first try creating a temp file by
calling open(2) with the O_TMPFILE flag. If that doesn't work, then it'll fall
back to using mkstemp.
2015-07-16 15:42:13 -06:00
Kyle Brenneman 6a3791f808 utils: Don't use any environment variables in a setuid process.
In a setuid process, GetTempDirs will only return /tmp, ignoring the TMPDIR and
HOME environment variables.
2015-07-16 13:53:54 -06:00
Kyle Brenneman 46753980cc Changed AllocExecPages to create separate writable and executable mappings.
AllocExecPages will now try to create a temp file and map it twice, once
writable and once executable. This will allow it to work on systems that don't
allow the same page to be writable and executable.

Issue #37
2015-07-15 18:05:54 -06:00
Kyle Brenneman e930f443b7 Add a new functions for allocating executable memory.
Added two new functions, AllocExecPages and FreeExecPages, for allocating
executable memory for generating stub functions.

It uses a single mmap right now, but it's set up to return two pointers, so it
will be able to return separate writable and executable mappings. That will let
it work on systems that don't allow pages to be both writable and executable.

The new functions are in utils_misc.c, since it will be needed in both libGLX
and libGLXdispatch.
2015-07-15 13:58:18 -06:00
Kyle Brenneman f7a918130d Moved glvnd_asprintf to src/util/utils_misc.c.
Moved the function glvnd_asprintf to a new file, src/util/utils_misc.c, so that
it can be used from other components besides libGLX.
2015-07-10 15:41:48 -06:00