xref: /openbmc/linux/fs/btrfs/Makefile (revision 90b90d4a)
1b2441318SGreg Kroah-Hartman# SPDX-License-Identifier: GPL-2.0
2eb60ceacSChris Mason
3e9aa7c28SNikolay Borisov# Subset of W=1 warnings
4e9aa7c28SNikolay Borisovsubdir-ccflags-y += -Wextra -Wunused -Wno-unused-parameter
5e9aa7c28SNikolay Borisovsubdir-ccflags-y += -Wmissing-declarations
6e9aa7c28SNikolay Borisovsubdir-ccflags-y += -Wmissing-format-attribute
7e9aa7c28SNikolay Borisovsubdir-ccflags-y += -Wmissing-prototypes
8e9aa7c28SNikolay Borisovsubdir-ccflags-y += -Wold-style-definition
9e9aa7c28SNikolay Borisovsubdir-ccflags-y += -Wmissing-include-dirs
10ebd99a6bSDavid Sterbacondflags := \
11ebd99a6bSDavid Sterba	$(call cc-option, -Wunused-but-set-variable)		\
12ebd99a6bSDavid Sterba	$(call cc-option, -Wunused-const-variable)		\
13ebd99a6bSDavid Sterba	$(call cc-option, -Wpacked-not-aligned)			\
141ec49744SJosef Bacik	$(call cc-option, -Wstringop-truncation)		\
151ec49744SJosef Bacik	$(call cc-option, -Wmaybe-uninitialized)
16ebd99a6bSDavid Sterbasubdir-ccflags-y += $(condflags)
17e9aa7c28SNikolay Borisov# The following turn off the warnings enabled by -Wextra
18e9aa7c28SNikolay Borisovsubdir-ccflags-y += -Wno-missing-field-initializers
19e9aa7c28SNikolay Borisovsubdir-ccflags-y += -Wno-sign-compare
20e9aa7c28SNikolay Borisovsubdir-ccflags-y += -Wno-type-limits
211344794aSArnd Bergmannsubdir-ccflags-y += -Wno-shift-negative-value
22e9aa7c28SNikolay Borisov
2361f8c86eSSage Weilobj-$(CONFIG_BTRFS_FS) := btrfs.o
242ea2544eSChristoph Hellwig
252ea2544eSChristoph Hellwigbtrfs-y += super.o ctree.o extent-tree.o print-tree.o root-tree.o dir-item.o \
265297199aSNikolay Borisov	   file-item.o inode-item.o disk-io.o \
27778dd695SJosef Bacik	   transaction.o inode.o file.o defrag.o \
28818fe33aSJosef Bacik	   extent_map.o sysfs.o accessors.o xattr.o ordered-data.o \
2931153d81SYan Zheng	   extent_io.o volumes.o async-thread.o ioctl.o locking.o orphan.o \
305c1aab1dSNick Terrell	   export.o tree-log.o free-space-cache.o zlib.o lzo.o zstd.o \
317414a03fSArne Jansen	   compression.o delayed-ref.o relocation.o delayed-inode.o scrub.o \
32f26c9238SQu Wenruo	   backref.o ulist.o qgroup.o send.o dev-replace.o raid56.o \
33550fa228SJosef Bacik	   uuid-tree.o props.o free-space-tree.o tree-checker.o space-info.o \
34cac06d84SQu Wenruo	   block-rsv.o delalloc-space.o block-group.o discard.o reflink.o \
35*90b90d4aSFilipe Manana	   subpage.o tree-mod-log.o extent-io-tree.o fs.o messages.o bio.o \
36*90b90d4aSFilipe Manana	   lru_cache.o
379b89d95aSLi Zefan
389b89d95aSLi Zefanbtrfs-$(CONFIG_BTRFS_FS_POSIX_ACL) += acl.o
39f11e4d7fSStefan Behrensbtrfs-$(CONFIG_BTRFS_FS_CHECK_INTEGRITY) += check-integrity.o
40fd708b81SJosef Bacikbtrfs-$(CONFIG_BTRFS_FS_REF_VERIFY) += ref-verify.o
415b316468SNaohiro Aotabtrfs-$(CONFIG_BLK_DEV_ZONED) += zoned.o
4214605409SBoris Burkovbtrfs-$(CONFIG_FS_VERITY) += verity.o
43dc11dd5dSJosef Bacik
4406ea65a3SJosef Bacikbtrfs-$(CONFIG_BTRFS_FS_RUN_SANITY_TESTS) += tests/free-space-tests.o \
45aaedb55bSJosef Bacik	tests/extent-buffer-tests.o tests/btrfs-tests.o \
467c55ee0cSOmar Sandoval	tests/extent-io-tests.o tests/inode-tests.o tests/qgroup-tests.o \
4772b28077SLiu Bo	tests/free-space-tree-tests.o tests/extent-map-tests.o
48