configure: add helper for setting xserver directory
With this the X server directory can become independent from the
installation prefix set by autoconf.
Signed-off-by: Tiago Vignatti <tiago.vignatti@intel.com>
diff --git a/configure.ac b/configure.ac
index 228b527..f19c4e7 100644
--- a/configure.ac
+++ b/configure.ac
@@ -37,6 +37,11 @@
if test x$enable_xserver_launcher == xyes; then
PKG_CHECK_MODULES([XSERVER_LAUNCHER], xcb)
AC_DEFINE([BUILD_XSERVER_LAUNCHER], [1], [Build the X server launcher])
+
+ AC_ARG_WITH(xserver-path, AS_HELP_STRING([--with-xserver-path=PATH],
+ [Path to X server]), [XSERVER_PATH="$withval"],
+ [XSERVER_PATH="$bindir/Xorg"])
+ AC_SUBST([XSERVER_PATH])
fi