1
0
mirror of https://gitlab.com/libvirt/libvirt.git synced 2024-12-23 21:34:54 +03:00

Fix missing char dev lock path case in configure

configure check for character devices lock path calls
AC_DEFINE_UNQUOTED for VIR_CHRDEV_LOCK_FILE_PATH even if
$with_chrdev_lock_files = "no".

So the locking code in conf/virchrdev.c:

 #ifdef VIR_CHRDEV_LOCK_FILE_PATH

is compiled in even if it shouldn't, because VIR_CHRDEV_LOCK_FILE_PATH
is defined as "no", so it tries to create lock files with strange
lock path like 'no/LCK..'.

Fix that by calling AC_DEFINE_UNQUOTED only if $with_chrdev_lock_files
is not 'no'.
This commit is contained in:
Roman Bogorodskiy 2014-03-05 19:23:14 +04:00
parent 3e04d65a07
commit 2c4870d04f

View File

@ -1401,8 +1401,10 @@ if test "$with_chrdev_lock_files" != "no"; then
AC_MSG_ERROR([You must specify path for the lock files on this AC_MSG_ERROR([You must specify path for the lock files on this
platform]) platform])
fi fi
AC_DEFINE_UNQUOTED([VIR_CHRDEV_LOCK_FILE_PATH], "$with_chrdev_lock_files", if test "$with_chrdev_lock_files" != "no"; then
[path to directory containing UUCP device lock files]) AC_DEFINE_UNQUOTED([VIR_CHRDEV_LOCK_FILE_PATH], "$with_chrdev_lock_files",
[path to directory containing UUCP device lock files])
fi
fi fi
AM_CONDITIONAL([VIR_CHRDEV_LOCK_FILE_PATH], [test "$with_chrdev_lock_files" != "no"]) AM_CONDITIONAL([VIR_CHRDEV_LOCK_FILE_PATH], [test "$with_chrdev_lock_files" != "no"])