mirror of
https://gitlab.com/libvirt/libvirt.git
synced 2024-12-22 21:55:25 +00:00
storage: move storage file sources to separate directory
Introduce a new storage_file directory where we will keep storage file related code. Add a backend prefix to the file name to separate it from other future files with 'storage_file' prefix. Signed-off-by: Pavel Hrdina <phrdina@redhat.com> Reviewed-by: Peter Krempa <pkrempa@redhat.com>
This commit is contained in:
parent
3e210d204c
commit
90caf9d763
@ -222,9 +222,9 @@
|
|||||||
@SRCDIR@src/storage/storage_backend_vstorage.c
|
@SRCDIR@src/storage/storage_backend_vstorage.c
|
||||||
@SRCDIR@src/storage/storage_backend_zfs.c
|
@SRCDIR@src/storage/storage_backend_zfs.c
|
||||||
@SRCDIR@src/storage/storage_driver.c
|
@SRCDIR@src/storage/storage_driver.c
|
||||||
@SRCDIR@src/storage/storage_file_fs.c
|
|
||||||
@SRCDIR@src/storage/storage_file_gluster.c
|
|
||||||
@SRCDIR@src/storage/storage_util.c
|
@SRCDIR@src/storage/storage_util.c
|
||||||
|
@SRCDIR@src/storage_file/storage_file_backend_fs.c
|
||||||
|
@SRCDIR@src/storage_file/storage_file_backend_gluster.c
|
||||||
@SRCDIR@src/test/test_driver.c
|
@SRCDIR@src/test/test_driver.c
|
||||||
@SRCDIR@src/util/iohelper.c
|
@SRCDIR@src/util/iohelper.c
|
||||||
@SRCDIR@src/util/viralloc.c
|
@SRCDIR@src/util/viralloc.c
|
||||||
|
@ -266,6 +266,7 @@ subdir('nwfilter')
|
|||||||
subdir('secret')
|
subdir('secret')
|
||||||
subdir('security')
|
subdir('security')
|
||||||
subdir('storage')
|
subdir('storage')
|
||||||
|
subdir('storage_file')
|
||||||
|
|
||||||
subdir('bhyve')
|
subdir('bhyve')
|
||||||
subdir('esx')
|
subdir('esx')
|
||||||
|
@ -15,10 +15,6 @@ storage_backend_fs_sources = [
|
|||||||
'storage_backend_fs.c',
|
'storage_backend_fs.c',
|
||||||
]
|
]
|
||||||
|
|
||||||
stoarge_file_fs_sources = [
|
|
||||||
'storage_file_fs.c',
|
|
||||||
]
|
|
||||||
|
|
||||||
storage_backend_disk_sources = [
|
storage_backend_disk_sources = [
|
||||||
'storage_backend_disk.c',
|
'storage_backend_disk.c',
|
||||||
]
|
]
|
||||||
@ -31,10 +27,6 @@ storage_backend_gluster_sources = [
|
|||||||
'storage_backend_gluster.c',
|
'storage_backend_gluster.c',
|
||||||
]
|
]
|
||||||
|
|
||||||
storage_file_gluster_sources = [
|
|
||||||
'storage_file_gluster.c',
|
|
||||||
]
|
|
||||||
|
|
||||||
storage_backend_iscsi_sources = [
|
storage_backend_iscsi_sources = [
|
||||||
'storage_backend_iscsi.c',
|
'storage_backend_iscsi.c',
|
||||||
]
|
]
|
||||||
@ -72,7 +64,6 @@ storage_backend_zfs_sources = [
|
|||||||
]
|
]
|
||||||
|
|
||||||
storage_backend_install_dir = libdir / 'libvirt' / 'storage-backend'
|
storage_backend_install_dir = libdir / 'libvirt' / 'storage-backend'
|
||||||
storage_file_install_dir = libdir / 'libvirt' / 'storage-file'
|
|
||||||
|
|
||||||
if conf.has('WITH_STORAGE')
|
if conf.has('WITH_STORAGE')
|
||||||
storage_driver_impl_lib = static_library(
|
storage_driver_impl_lib = static_library(
|
||||||
@ -109,14 +100,6 @@ if conf.has('WITH_STORAGE')
|
|||||||
'install_dir': storage_backend_install_dir,
|
'install_dir': storage_backend_install_dir,
|
||||||
}
|
}
|
||||||
|
|
||||||
virt_modules += {
|
|
||||||
'name': 'virt_storage_file_fs',
|
|
||||||
'sources': [
|
|
||||||
files(stoarge_file_fs_sources),
|
|
||||||
],
|
|
||||||
'install_dir': storage_file_install_dir,
|
|
||||||
}
|
|
||||||
|
|
||||||
virt_daemons += {
|
virt_daemons += {
|
||||||
'name': 'virtstoraged',
|
'name': 'virtstoraged',
|
||||||
'c_args': [
|
'c_args': [
|
||||||
@ -181,17 +164,6 @@ if conf.has('WITH_STORAGE_GLUSTER')
|
|||||||
],
|
],
|
||||||
'install_dir': storage_backend_install_dir,
|
'install_dir': storage_backend_install_dir,
|
||||||
}
|
}
|
||||||
|
|
||||||
virt_modules += {
|
|
||||||
'name': 'virt_storage_file_gluster',
|
|
||||||
'sources': [
|
|
||||||
files(storage_file_gluster_sources),
|
|
||||||
],
|
|
||||||
'deps': [
|
|
||||||
glusterfs_dep,
|
|
||||||
],
|
|
||||||
'install_dir': storage_file_install_dir,
|
|
||||||
}
|
|
||||||
endif
|
endif
|
||||||
|
|
||||||
if conf.has('WITH_STORAGE_ISCSI')
|
if conf.has('WITH_STORAGE_ISCSI')
|
||||||
@ -303,3 +275,5 @@ if conf.has('WITH_STORAGE_ZFS')
|
|||||||
'install_dir': storage_backend_install_dir,
|
'install_dir': storage_backend_install_dir,
|
||||||
}
|
}
|
||||||
endif
|
endif
|
||||||
|
|
||||||
|
storage_inc_dir = include_directories('.')
|
||||||
|
38
src/storage_file/meson.build
Normal file
38
src/storage_file/meson.build
Normal file
@ -0,0 +1,38 @@
|
|||||||
|
stoarge_file_fs_sources = [
|
||||||
|
'storage_file_backend_fs.c',
|
||||||
|
]
|
||||||
|
|
||||||
|
storage_file_gluster_sources = [
|
||||||
|
'storage_file_backend_gluster.c',
|
||||||
|
]
|
||||||
|
|
||||||
|
storage_file_install_dir = libdir / 'libvirt' / 'storage-file'
|
||||||
|
|
||||||
|
if conf.has('WITH_STORAGE')
|
||||||
|
virt_modules += {
|
||||||
|
'name': 'virt_storage_file_fs',
|
||||||
|
'sources': [
|
||||||
|
files(stoarge_file_fs_sources),
|
||||||
|
],
|
||||||
|
'include': [
|
||||||
|
storage_inc_dir,
|
||||||
|
],
|
||||||
|
'install_dir': storage_file_install_dir,
|
||||||
|
}
|
||||||
|
endif
|
||||||
|
|
||||||
|
if conf.has('WITH_STORAGE_GLUSTER')
|
||||||
|
virt_modules += {
|
||||||
|
'name': 'virt_storage_file_gluster',
|
||||||
|
'sources': [
|
||||||
|
files(storage_file_gluster_sources),
|
||||||
|
],
|
||||||
|
'include': [
|
||||||
|
storage_inc_dir,
|
||||||
|
],
|
||||||
|
'deps': [
|
||||||
|
glusterfs_dep,
|
||||||
|
],
|
||||||
|
'install_dir': storage_file_install_dir,
|
||||||
|
}
|
||||||
|
endif
|
@ -1,5 +1,5 @@
|
|||||||
/*
|
/*
|
||||||
* storage_file_fs.c: storage file code for FS and directory handling
|
* storage_file_backend_fs.c: storage file code for FS and directory handling
|
||||||
*
|
*
|
||||||
* Copyright (C) 2007-2018 Red Hat, Inc.
|
* Copyright (C) 2007-2018 Red Hat, Inc.
|
||||||
*
|
*
|
||||||
@ -25,7 +25,7 @@
|
|||||||
#include <fcntl.h>
|
#include <fcntl.h>
|
||||||
|
|
||||||
#include "virerror.h"
|
#include "virerror.h"
|
||||||
#include "storage_file_fs.h"
|
#include "storage_file_backend_fs.h"
|
||||||
#include "storage_util.h"
|
#include "storage_util.h"
|
||||||
#include "virstoragefilebackend.h"
|
#include "virstoragefilebackend.h"
|
||||||
#include "vircommand.h"
|
#include "vircommand.h"
|
@ -1,5 +1,5 @@
|
|||||||
/*
|
/*
|
||||||
* storage_file_fs.h: storage file code for FS and directory handling
|
* storage_file_backend_fs.h: storage file code for FS and directory handling
|
||||||
*
|
*
|
||||||
* Copyright (C) 2018 Red Hat, Inc.
|
* Copyright (C) 2018 Red Hat, Inc.
|
||||||
*
|
*
|
@ -1,5 +1,5 @@
|
|||||||
/*
|
/*
|
||||||
* storage_file_gluster.c: storage file backend for Gluster handling
|
* storage_file_backend_gluster.c: storage file backend for Gluster handling
|
||||||
*
|
*
|
||||||
* Copyright (C) 2013-2018 Red Hat, Inc.
|
* Copyright (C) 2013-2018 Red Hat, Inc.
|
||||||
*
|
*
|
||||||
@ -23,7 +23,7 @@
|
|||||||
|
|
||||||
#include <glusterfs/api/glfs.h>
|
#include <glusterfs/api/glfs.h>
|
||||||
|
|
||||||
#include "storage_file_gluster.h"
|
#include "storage_file_backend_gluster.h"
|
||||||
#include "viralloc.h"
|
#include "viralloc.h"
|
||||||
#include "virerror.h"
|
#include "virerror.h"
|
||||||
#include "virlog.h"
|
#include "virlog.h"
|
@ -1,5 +1,5 @@
|
|||||||
/*
|
/*
|
||||||
* storage_file_gluster.h: storage file backend for Gluster handling
|
* storage_file_backend_gluster.h: storage file backend for Gluster handling
|
||||||
*
|
*
|
||||||
* Copyright (C) 2018 Red Hat, Inc.
|
* Copyright (C) 2018 Red Hat, Inc.
|
||||||
*
|
*
|
Loading…
Reference in New Issue
Block a user