blob: 9adf5e4f7e967b09045e8444c80dd819d72f3031 [file] [log] [blame]
Chris Mason2e635a22007-03-21 11:12:56 -04001ifneq ($(KERNELRELEASE),)
2# kbuild part of makefile
Chris Masoneb60cea2007-02-02 09:18:22 -05003
Sage Weil61f8c862008-10-09 11:52:35 -04004obj-$(CONFIG_BTRFS_FS) := btrfs.o
Chris Masone20d96d2007-03-22 12:13:20 -04005btrfs-y := super.o ctree.o extent-tree.o print-tree.o root-tree.o dir-item.o \
David Woodhouse615f9962008-08-19 19:21:57 +01006 file-item.o inode-item.o inode-map.o disk-io.o \
Chris Masond352ac62008-09-29 15:18:18 -04007 transaction.o inode.o file.o tree-defrag.o \
Chris Masond1310b22008-01-24 16:13:08 -05008 extent_map.o sysfs.o struct-funcs.o xattr.o ordered-data.o \
Yan Zheng31153d82008-07-28 15:32:19 -04009 extent_io.o volumes.o async-thread.o ioctl.o locking.o orphan.o \
Chris Masonc8b97812008-10-29 14:49:59 -040010 ref-cache.o export.o tree-log.o acl.o free-space-cache.o zlib.o \
Chris Mason56bec292009-03-13 10:10:06 -040011 compression.o delayed-ref.o
Chris Mason2e635a22007-03-21 11:12:56 -040012else
Chris Mason1261ec42007-03-20 20:35:03 -040013
Chris Mason2e635a22007-03-21 11:12:56 -040014# Normal Makefile
Chris Masonfec577f2007-02-26 10:40:21 -050015
Chris Mason2e635a22007-03-21 11:12:56 -040016KERNELDIR := /lib/modules/`uname -r`/build
Chris Masonb4f6c452008-09-24 11:05:53 -040017all:
Sage Weil61f8c862008-10-09 11:52:35 -040018 $(MAKE) -C $(KERNELDIR) M=`pwd` CONFIG_BTRFS_FS=m modules
Chris Masonb3c3da72008-07-23 12:12:13 -040019
Jan Engelhardt432eba02007-09-14 10:22:19 -040020modules_install:
Chris Mason84a5d5e2007-09-14 09:43:53 -040021 $(MAKE) -C $(KERNELDIR) M=`pwd` modules_install
Jan Engelhardt432eba02007-09-14 10:22:19 -040022clean:
Joel Becker8578f0f2007-07-25 14:04:51 -040023 $(MAKE) -C $(KERNELDIR) M=`pwd` clean
Jan Engelhardt432eba02007-09-14 10:22:19 -040024
Chris Mason2e635a22007-03-21 11:12:56 -040025endif