1
0
mirror of git://sourceware.org/git/lvm2.git synced 2025-03-26 22:50:36 +03:00

dmeventd: resolve compilation of vdo status parsing

A bit of chicken & egg problem - dmeventd needs to use old libdm library.
VDO is only part of new device_mapper internal library.

So include directly source file for parsing status - this fixes usability
problem of VDO plugin introduced with previous Makefile reshaping
patchset.

NOTE: source file needs to be keep then compilable in both environments.

Also add missing copyright header.
This commit is contained in:
Zdenek Kabelac 2018-12-19 12:54:14 +01:00
parent f05104af76
commit 9785e40b8d
2 changed files with 23 additions and 3 deletions

View File

@ -15,7 +15,9 @@
#include "lib/misc/lib.h"
#include "daemons/dmeventd/plugins/lvm2/dmeventd_lvm.h"
#include "daemons/dmeventd/libdevmapper-event.h"
#include "device_mapper/vdo/target.h"
/* Use parser from new device_mapper library */
#include "device_mapper/vdo/status.c"
#include <sys/wait.h>
#include <stdarg.h>

View File

@ -1,8 +1,26 @@
#include "configure.h"
#include "target.h"
/*
* Copyright (C) 2018 Red Hat, Inc. All rights reserved.
*
* This file is part of the device-mapper userspace tools.
*
* This copyrighted material is made available to anyone wishing to use,
* modify, copy, or redistribute it subject to the terms and conditions
* of the GNU Lesser General Public License v.2.1.
*
* You should have received a copy of the GNU Lesser General Public License
* along with this program; if not, write to the Free Software Foundation,
* Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
*/
/* Note: this object is also used by VDO dmeventd plugin for parsing status */
/* File could be included by VDO plugin and can use original libdm library */
#ifndef LIB_DMEVENT_H
#include "configure.h"
// For DM_ARRAY_SIZE!
#include "device_mapper/all.h"
#endif
#include "device_mapper/vdo/target.h"
#include "base/memory/zalloc.h"
#include <ctype.h>