summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorThierry Reding <treding@nvidia.com>2014-05-07 14:09:35 +0200
committerKristian Høgsberg <krh@bitplanet.net>2014-05-12 10:55:01 -0700
commit6b27878559fd863023681042800ccc723a3a249e (patch)
treed6cd8ad441d6760326bd72af5a3717ee02e98f84
parent3e007aef2fc1b8f1e5a4d4367f03d2497f1301e9 (diff)
Do not distribute generated headers
The wayland-server-protocol.h and wayland-client-protocol.h headers are currently being shipped in tarballs created using make dist. This causes out-of-tree builds to fail since make will detect that the headers exist by looking at the source directory (via VPATH) and not regenerate them. But as opposed to ${top_builddir}/protocol, ${top_srcdir}/protocol is not part of the include path and therefore the shipped files can't be found during compilation. Two solutions exist to this problem: 1) add ${top_srcdir}/protocol to the include path to allow shipped files to be used if available or 2) don't ship these generated files in release tarballs. The latter seems the most appropriate. wayland-scanner is already a prerequisite in order to generate wayland-protocol.c, so it is either built as part of the package or provided externally. Generating all files from the protocol definition at build time also ensures that they don't get out of sync. Both of the generated headers are already listed in Makefile.am as nodist_*_SOURCES, but at the same time they appear in include_HEADERS, which will cause them to be added to the list of distributable files after all. To prevent that, split them off into nodist_include_HEADERS. Note that this problem will be hidden if a previous version of wayland has been installed, since these files will exist in /usr/include and be included from there. So this build error will only show for out-of-tree builds on systems that don't have wayland installed yet. Signed-off-by: Thierry Reding <treding@nvidia.com>
-rw-r--r--Makefile.am6
1 files changed, 4 insertions, 2 deletions
diff --git a/Makefile.am b/Makefile.am
index ee9f29e..c15d8b8 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -20,13 +20,15 @@ noinst_LTLIBRARIES = libwayland-util.la
include_HEADERS = \
src/wayland-util.h \
- protocol/wayland-server-protocol.h \
src/wayland-server.h \
- protocol/wayland-client-protocol.h \
src/wayland-client.h \
src/wayland-egl.h \
src/wayland-version.h
+nodist_include_HEADERS = \
+ protocol/wayland-server-protocol.h \
+ protocol/wayland-client-protocol.h
+
libwayland_util_la_SOURCES = \
src/connection.c \
src/wayland-util.c \