diff options
author | David Sterba <dsterba@suse.com> | 2017-03-13 16:52:34 +0100 |
---|---|---|
committer | David Sterba <dsterba@suse.com> | 2017-03-16 17:02:44 +0100 |
commit | b11b36ebdb92b1c8ea039e26208af599e77fb882 (patch) | |
tree | 04c760f8341724ac5db859b0bd85378784ca9f97 /library-test.c | |
parent | 87b971d0cc7c4b72eb45919bc74ca389832e5ea1 (diff) |
btrfs-progs: library-test: update header inclusion
The library-test is supposed to compile and link as an external
program, so we should update the way the headers are included.
Signed-off-by: David Sterba <dsterba@suse.com>
Diffstat (limited to 'library-test.c')
-rw-r--r-- | library-test.c | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/library-test.c b/library-test.c index 9d14bbf9..d25c3da9 100644 --- a/library-test.c +++ b/library-test.c @@ -16,10 +16,21 @@ * Boston, MA 021110-1307, USA. */ +#if BTRFS_FLAT_INCLUDES #include "kerncompat.h" #include "version.h" #include "send-stream.h" #include "btrfs-list.h" +#else +/* + * This needs to include headers the same way as an external program but must + * not use the existing system headers, so we use "...". + */ +#include "btrfs/kerncompat.h" +#include "btrfs/version.h" +#include "btrfs/send-stream.h" +#include "btrfs/btrfs-list.h" +#endif /* * Reduced code snippet from snapper.git/snapper/Btrfs.cc |