mirror of
https://gitlab.com/libvirt/libvirt.git
synced 2024-12-22 13:45:38 +00:00
meson: add chrdev_lock_files build option
Signed-off-by: Pavel Hrdina <phrdina@redhat.com> Reviewed-by: Peter Krempa <pkrempa@redhat.com> Reviewed-by: Neal Gompa <ngompa13@gmail.com>
This commit is contained in:
parent
32ba7fea0a
commit
6700b5d54f
@ -104,7 +104,6 @@ dnl
|
|||||||
LIBVIRT_ARG_DTRACE
|
LIBVIRT_ARG_DTRACE
|
||||||
LIBVIRT_ARG_NUMAD
|
LIBVIRT_ARG_NUMAD
|
||||||
LIBVIRT_ARG_INIT_SCRIPT
|
LIBVIRT_ARG_INIT_SCRIPT
|
||||||
LIBVIRT_ARG_CHRDEV_LOCK_FILES
|
|
||||||
LIBVIRT_ARG_LOADER_NVRAM
|
LIBVIRT_ARG_LOADER_NVRAM
|
||||||
LIBVIRT_ARG_LOGIN_SHELL
|
LIBVIRT_ARG_LOGIN_SHELL
|
||||||
LIBVIRT_ARG_HOST_VALIDATE
|
LIBVIRT_ARG_HOST_VALIDATE
|
||||||
@ -115,7 +114,6 @@ LIBVIRT_ARG_SYSCTL_CONFIG
|
|||||||
LIBVIRT_CHECK_DTRACE
|
LIBVIRT_CHECK_DTRACE
|
||||||
LIBVIRT_CHECK_NUMAD
|
LIBVIRT_CHECK_NUMAD
|
||||||
LIBVIRT_CHECK_INIT_SCRIPT
|
LIBVIRT_CHECK_INIT_SCRIPT
|
||||||
LIBVIRT_CHECK_CHRDEV_LOCK_FILES
|
|
||||||
LIBVIRT_CHECK_LOADER_NVRAM
|
LIBVIRT_CHECK_LOADER_NVRAM
|
||||||
LIBVIRT_CHECK_LOGIN_SHELL
|
LIBVIRT_CHECK_LOGIN_SHELL
|
||||||
LIBVIRT_CHECK_HOST_VALIDATE
|
LIBVIRT_CHECK_HOST_VALIDATE
|
||||||
@ -200,7 +198,6 @@ AC_MSG_NOTICE([])
|
|||||||
LIBVIRT_RESULT_DTRACE
|
LIBVIRT_RESULT_DTRACE
|
||||||
LIBVIRT_RESULT_NUMAD
|
LIBVIRT_RESULT_NUMAD
|
||||||
LIBVIRT_RESULT_INIT_SCRIPT
|
LIBVIRT_RESULT_INIT_SCRIPT
|
||||||
LIBVIRT_RESULT_CHRDEV_LOCK_FILES
|
|
||||||
LIBVIRT_RESULT_LOADER_NVRAM
|
LIBVIRT_RESULT_LOADER_NVRAM
|
||||||
LIBVIRT_RESULT_LOGIN_SHELL
|
LIBVIRT_RESULT_LOGIN_SHELL
|
||||||
LIBVIRT_RESULT_HOST_VALIDATE
|
LIBVIRT_RESULT_HOST_VALIDATE
|
||||||
|
@ -1,52 +0,0 @@
|
|||||||
dnl The locaton of UUCP style lock files
|
|
||||||
dnl
|
|
||||||
dnl Copyright (C) 2016 Red Hat, Inc.
|
|
||||||
dnl
|
|
||||||
dnl This library is free software; you can redistribute it and/or
|
|
||||||
dnl modify it under the terms of the GNU Lesser General Public
|
|
||||||
dnl License as published by the Free Software Foundation; either
|
|
||||||
dnl version 2.1 of the License, or (at your option) any later version.
|
|
||||||
dnl
|
|
||||||
dnl This library is distributed in the hope that it will be useful,
|
|
||||||
dnl but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
||||||
dnl MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
|
||||||
dnl Lesser General Public License for more details.
|
|
||||||
dnl
|
|
||||||
dnl You should have received a copy of the GNU Lesser General Public
|
|
||||||
dnl License along with this library. If not, see
|
|
||||||
dnl <http://www.gnu.org/licenses/>.
|
|
||||||
dnl
|
|
||||||
|
|
||||||
AC_DEFUN([LIBVIRT_ARG_CHRDEV_LOCK_FILES], [
|
|
||||||
LIBVIRT_ARG_WITH([CHRDEV_LOCK_FILES],
|
|
||||||
[location for UUCP style lock files for character devices ]
|
|
||||||
[(use auto for default paths on some platforms)],
|
|
||||||
[auto])
|
|
||||||
])
|
|
||||||
|
|
||||||
AC_DEFUN([LIBVIRT_CHECK_CHRDEV_LOCK_FILES], [
|
|
||||||
if test "$with_chrdev_lock_files" != "no"; then
|
|
||||||
case $with_chrdev_lock_files in
|
|
||||||
yes | auto)
|
|
||||||
dnl Default locations for platforms, or disable if unknown
|
|
||||||
if test "$with_linux" = "yes"; then
|
|
||||||
with_chrdev_lock_files=/var/lock
|
|
||||||
elif test "$with_chrdev_lock_files" = "auto"; then
|
|
||||||
with_chrdev_lock_files=no
|
|
||||||
fi
|
|
||||||
;;
|
|
||||||
esac
|
|
||||||
if test "$with_chrdev_lock_files" = "yes"; then
|
|
||||||
AC_MSG_ERROR([You must specify path for the lock files on this platform])
|
|
||||||
fi
|
|
||||||
if test "$with_chrdev_lock_files" != "no"; then
|
|
||||||
AC_DEFINE_UNQUOTED([VIR_CHRDEV_LOCK_FILE_PATH], "$with_chrdev_lock_files",
|
|
||||||
[path to directory containing UUCP device lock files])
|
|
||||||
fi
|
|
||||||
fi
|
|
||||||
AM_CONDITIONAL([VIR_CHRDEV_LOCK_FILE_PATH], [test "$with_chrdev_lock_files" != "no"])
|
|
||||||
])
|
|
||||||
|
|
||||||
AC_DEFUN([LIBVIRT_RESULT_CHRDEV_LOCK_FILES], [
|
|
||||||
LIBVIRT_RESULT([Char device locks], [$with_chrdev_lock_files])
|
|
||||||
])
|
|
12
meson.build
12
meson.build
@ -2067,6 +2067,17 @@ if use_storage
|
|||||||
endif
|
endif
|
||||||
|
|
||||||
|
|
||||||
|
# build feature options
|
||||||
|
|
||||||
|
chrdev_lock_files = get_option('chrdev_lock_files')
|
||||||
|
if chrdev_lock_files == '' and host_machine.system() == 'linux'
|
||||||
|
chrdev_lock_files = '/var/lock'
|
||||||
|
endif
|
||||||
|
if chrdev_lock_files != ''
|
||||||
|
conf.set_quoted('VIR_CHRDEV_LOCK_FILE_PATH', chrdev_lock_files)
|
||||||
|
endif
|
||||||
|
|
||||||
|
|
||||||
# define top include directory
|
# define top include directory
|
||||||
|
|
||||||
top_inc_dir = include_directories('.')
|
top_inc_dir = include_directories('.')
|
||||||
@ -2184,6 +2195,7 @@ summary(test_summary, section: 'Test suite', bool_yn: true)
|
|||||||
misc_summary = {
|
misc_summary = {
|
||||||
'Use -Werror': cc_flags.contains('-Werror'),
|
'Use -Werror': cc_flags.contains('-Werror'),
|
||||||
'Warning Flags': supported_cc_flags,
|
'Warning Flags': supported_cc_flags,
|
||||||
|
'Char device locks': chrdev_lock_files,
|
||||||
}
|
}
|
||||||
summary(misc_summary, section: 'Miscellaneous', bool_yn: true, list_sep: ' ')
|
summary(misc_summary, section: 'Miscellaneous', bool_yn: true, list_sep: ' ')
|
||||||
|
|
||||||
|
@ -88,3 +88,7 @@ option('storage_scsi', type: 'feature', value: 'auto', description: 'SCSI backen
|
|||||||
option('storage_sheepdog', type: 'feature', value: 'auto', description: 'Sheepdog backend for the storage driver')
|
option('storage_sheepdog', type: 'feature', value: 'auto', description: 'Sheepdog backend for the storage driver')
|
||||||
option('storage_vstorage', type: 'feature', value: 'auto', description: 'Virtuozzo storage backend for the storage driver')
|
option('storage_vstorage', type: 'feature', value: 'auto', description: 'Virtuozzo storage backend for the storage driver')
|
||||||
option('storage_zfs', type: 'feature', value: 'auto', description: 'ZFS backend for the storage driver')
|
option('storage_zfs', type: 'feature', value: 'auto', description: 'ZFS backend for the storage driver')
|
||||||
|
|
||||||
|
|
||||||
|
# build feature options
|
||||||
|
option('chrdev_lock_files', type: 'string', value: '', description: 'location for UUCP style lock files for character devices (leave empty for default paths on some platforms)')
|
||||||
|
Loading…
Reference in New Issue
Block a user