btrfs-progs: libbtrfs: drop ifdef BTRFS_FLAT_INCLUDES where not necessary

Headers that are only exported and not used for build do not need the
BTRFS_FLAT_INCLUDES switch (between local and installed headers). Now
that there are local copies of the shared headers drop the respective
part from local headers.

Signed-off-by: David Sterba <dsterba@suse.com>
This commit is contained in:
David Sterba 2022-06-03 16:28:58 +02:00
parent bb7db09e46
commit 0f65bf66be
4 changed files with 0 additions and 31 deletions

View File

@ -19,13 +19,8 @@
#ifndef __BTRFS_EXTENT_CACHE_H__
#define __BTRFS_EXTENT_CACHE_H__
#if BTRFS_FLAT_INCLUDES
#include "kerncompat.h"
#include "kernel-lib/rbtree.h"
#else
#include <btrfs/kerncompat.h>
#include <btrfs/rbtree.h>
#endif /* BTRFS_FLAT_INCLUDES */
struct cache_tree {
struct rb_root root;

View File

@ -21,19 +21,11 @@
#include <stdbool.h>
#if BTRFS_FLAT_INCLUDES
#include "kernel-lib/list.h"
#include "kerncompat.h"
#include "common/extent-cache.h"
#include "kernel-shared/extent_io.h"
#include "ioctl.h"
#else
#include <btrfs/list.h>
#include <btrfs/kerncompat.h>
#include <btrfs/extent-cache.h>
#include <btrfs/extent_io.h>
#include <btrfs/ioctl.h>
#endif /* BTRFS_FLAT_INCLUDES */
struct btrfs_root;
struct btrfs_trans_handle;

View File

@ -19,15 +19,9 @@
#ifndef __BTRFS_EXTENT_IO_H__
#define __BTRFS_EXTENT_IO_H__
#if BTRFS_FLAT_INCLUDES
#include "kerncompat.h"
#include "common/extent-cache.h"
#include "kernel-lib/list.h"
#else
#include <btrfs/kerncompat.h>
#include <btrfs/extent-cache.h>
#include <btrfs/list.h>
#endif /* BTRFS_FLAT_INCLUDES */
#define EXTENT_DIRTY (1U << 0)
#define EXTENT_WRITEBACK (1U << 1)

View File

@ -20,15 +20,7 @@
#ifndef __BTRFS_SEND_H__
#define __BTRFS_SEND_H__
#if BTRFS_FLAT_INCLUDES
#include "kernel-shared/ctree.h"
#else
#include <btrfs/ctree.h>
#endif /* BTRFS_FLAT_INCLUDES */
#ifdef __cplusplus
extern "C" {
#endif
#define BTRFS_SEND_STREAM_MAGIC "btrfs-stream"
#define BTRFS_SEND_STREAM_VERSION 1
@ -140,8 +132,4 @@ enum {
};
#define BTRFS_SEND_A_MAX (__BTRFS_SEND_A_MAX - 1)
#ifdef __cplusplus
}
#endif
#endif