configure: Automaticaly detect the default xorg-module-dir.

The module directory has changed to a per ABI folder.
Now the default value of `xorg-module-dir` will be detected from the 'moduledir' variable in xorg-server.pc.

Signed-off-by: b-aaz <b-aazbsd.proton.me>
This commit is contained in:
b-aaz
2025-07-03 21:32:30 +00:00
committed by Enrico Weigelt
parent 3a407a34c4
commit 1557374b26

View File

@@ -45,9 +45,12 @@ LT_INIT([disable-static])
AH_TOP([#include "xorg-server.h"])
# Define a configure option for an alternate module directory
AC_ARG_WITH(xorg-module-dir, [ --with-xorg-module-dir=DIR ],
[ moduledir="$withval" ],
[ moduledir="$libdir/xorg/modules" ])
PKG_PROG_PKG_CONFIG([0.25])
AC_ARG_WITH(xorg-module-dir,
AS_HELP_STRING([--with-xorg-module-dir=DIR],
[Default xorg module directory]),
[moduledir="$withval"],
[moduledir=`$PKG_CONFIG --variable=moduledir xorg-server`])
AC_SUBST(moduledir)