On 17 November 2015 at 19:13, Gabriel Laskar gabriel@lse.epita.fr wrote:
On Tue, 17 Nov 2015 11:08:12 +0000 Emil Velikov emil.l.velikov@gmail.com wrote:
With the above said:
- I was thinking about hiding the UAPI ones, although Dave suggested
against it.
- Doing s|drm/drm.h|drm.h| will break compilation:
- for the kernel - as we don't add the foo/drm/ to the include directive,
- for any hacked up userspace - very unlikely that they have the
include, considering that things work without it.
We are not suggesting doing s|drm/drm.h|drm.h| but by replacing
#include <drm/drm.h>
by
#include "drm.h"
The header will be picked-up correclty in kernel, and in userland.
Missed out completely on the <> vs "" side. Imho using the latter the kernel will be ok, although for userspace that's not a good idea. What will happen if there is a drm.h next to the .c files (I know bad programmer) ?
Imho it seems quite fragile although if people refer it so be it. I'm just going to chip-in "I told you so" as we get the above case :-)
Is it possible to also resynchronize both headers, in order for them to be the same in libdrm and the kernel ?
Of course, it's perfectly doable. First steps towards it are here (people like yourself and Mikko that want things fixed). We need just a couple more steps.
Regards, Emil