1
0
mirror of git://sourceware.org/git/lvm2.git synced 2025-01-02 01:18:26 +03:00

configure: add --with-modulesdir

Add configurable path for directory with kernel modules.
Following patch will use this directory to lookup:
/lib/modules/`uname -r`/modules.builtin
This commit is contained in:
Zdenek Kabelac 2024-02-08 14:58:16 +01:00
parent 55937f9c8e
commit 1453ccd5b8
4 changed files with 40 additions and 0 deletions

View File

@ -1,5 +1,6 @@
Version 2.03.24 - Version 2.03.24 -
================== ==================
Add configure --with-modulesdir to select kernel modules directory.
Support creation of thin-pool with VDO use for its data volume. Support creation of thin-pool with VDO use for its data volume.
Version 2.03.23 - 21st November 2023 Version 2.03.23 - 21st November 2023

24
configure vendored
View File

@ -655,6 +655,7 @@ udev_prefix
udevdir udevdir
tmpfilesdir tmpfilesdir
tmpdir tmpdir
modulesdir
missingkernel missingkernel
kernelvsn kernelvsn
kerneldir kerneldir
@ -1009,6 +1010,7 @@ with_udev_prefix
with_udevdir with_udevdir
with_systemdsystemunitdir with_systemdsystemunitdir
with_tmpfilesdir with_tmpfilesdir
with_modulesdir
with_dmeventd_pidfile with_dmeventd_pidfile
with_dmeventd_path with_dmeventd_path
with_dmeventd_exit_on_path with_dmeventd_exit_on_path
@ -1820,6 +1822,8 @@ Optional Packages:
--with-tmpfilesdir=DIR install configuration files for management of --with-tmpfilesdir=DIR install configuration files for management of
volatile files and directories in DIR volatile files and directories in DIR
[PREFIX/lib/tmpfiles.d] [PREFIX/lib/tmpfiles.d]
--with-modulesdir=DIR Dir to look for file `uname -r`/modules.builtin
[/lib/modules]
--with-dmeventd-pidfile=PATH --with-dmeventd-pidfile=PATH
dmeventd pidfile [PID_DIR/dmeventd.pid] dmeventd pidfile [PID_DIR/dmeventd.pid]
--with-dmeventd-path=PATH --with-dmeventd-path=PATH
@ -15468,6 +15472,25 @@ else $as_nop
tmpfilesdir='${prefix}/lib/tmpfiles.d' tmpfilesdir='${prefix}/lib/tmpfiles.d'
fi fi
################################################################################
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for kernel modules directory" >&5
printf %s "checking for kernel modules directory... " >&6; }
# Check whether --with-modulesdir was given.
if test ${with_modulesdir+y}
then :
withval=$with_modulesdir; modulesdir=$withval
else $as_nop
modulesdir="/lib/modules"
fi
printf "%s\n" "#define MODULES_PATH \"$modulesdir\"" >>confdefs.h
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $modulesdir" >&5
printf "%s\n" "$modulesdir" >&6; }
################################################################################ ################################################################################
if test "$READLINE" = "yes" if test "$READLINE" = "yes"
then : then :
@ -16288,6 +16311,7 @@ AIO_LIBS=${AIO_LIBS:--laio}
################################################################################ ################################################################################

View File

@ -1615,6 +1615,17 @@ AC_ARG_WITH(tmpfilesdir,
AS_HELP_STRING([--with-tmpfilesdir=DIR], AS_HELP_STRING([--with-tmpfilesdir=DIR],
[install configuration files for management of volatile files and directories in DIR [PREFIX/lib/tmpfiles.d]]), [install configuration files for management of volatile files and directories in DIR [PREFIX/lib/tmpfiles.d]]),
tmpfilesdir=$withval, tmpfilesdir='${prefix}/lib/tmpfiles.d') tmpfilesdir=$withval, tmpfilesdir='${prefix}/lib/tmpfiles.d')
################################################################################
dnl - Where to look for modules.builtin file for a kernel - most typically in /lib/modules/
AC_MSG_CHECKING([for kernel modules directory])
AC_ARG_WITH(modulesdir,
AS_HELP_STRING([--with-modulesdir=DIR],
[Dir to look for file `uname -r`/modules.builtin [/lib/modules]]),
[modulesdir=$withval], [modulesdir="/lib/modules"])
AC_DEFINE_UNQUOTED(MODULES_PATH, ["$modulesdir"], [The path to kernel modules.])
AC_MSG_RESULT([$modulesdir])
################################################################################ ################################################################################
dnl -- Ensure additional headers required dnl -- Ensure additional headers required
AS_IF([test "$READLINE" = "yes"], [ AS_IF([test "$READLINE" = "yes"], [
@ -1946,6 +1957,7 @@ AC_SUBST(kerneldir)
AC_SUBST(kernelvsn) AC_SUBST(kernelvsn)
AC_SUBST(libexecdir) AC_SUBST(libexecdir)
AC_SUBST(missingkernel) AC_SUBST(missingkernel)
AC_SUBST(modulesdir)
AC_SUBST(systemdsystemunitdir) AC_SUBST(systemdsystemunitdir)
AC_SUBST(systemdutildir) AC_SUBST(systemdutildir)
AC_SUBST(tmpdir) AC_SUBST(tmpdir)

View File

@ -621,6 +621,9 @@
/* The path to 'modprobe', if available. */ /* The path to 'modprobe', if available. */
#undef MODPROBE_CMD #undef MODPROBE_CMD
/* The path to kernel modules. */
#undef MODULES_PATH
/* Define to 1 to include code that uses dbus notification. */ /* Define to 1 to include code that uses dbus notification. */
#undef NOTIFYDBUS_SUPPORT #undef NOTIFYDBUS_SUPPORT