summaryrefslogtreecommitdiff
path: root/Makefile
diff options
context:
space:
mode:
authorNaohiro Aota <naohiro.aota@wdc.com>2017-09-14 19:10:46 +0900
committerDavid Sterba <dsterba@suse.com>2017-09-25 15:17:42 +0200
commitfd8c78a47c2448891db57c867b0f16c4367fa501 (patch)
treeb72506d81e43a1ac2c65867c842dd98958444fc7 /Makefile
parentf7267bc85c6d89d64b534b737c63cf8f88c46d7f (diff)
btrfs-progs: build: generate all dependency files
We're missing several dependency files like: $ diff -u <(find -name '*.o'|cut -d. -f2|sort) <(find -name '*.o.d'|cut -d. -f2|sort) @@ -3,7 +3,6 @@ /btrfs-corrupt-block /btrfs-debug-tree /btrfs-find-root -/btrfs-list /btrfs-map-logical /btrfs-select-super /btrfstune @@ -29,11 +28,6 @@ /cmds-scrub /cmds-send /cmds-subvolume -/convert/common -/convert/main -/convert/source-ext2 -/convert/source-fs -/convert/source-reiserfs /ctree /dir-item /disk-io <snip> This is due to moving things out of objects and cmds_objects variables. Such missing dependency files cause mis-building of some source files (try touch utils.h; make mkfs/main.o). This patch introduce a new variable "all_objects" to keep all the objects and use the variable to generate proper dependency file building rules. Signed-off-by: Naohiro Aota <naohiro.aota@wdc.com> Signed-off-by: David Sterba <dsterba@suse.com>
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile5
1 files changed, 4 insertions, 1 deletions
diff --git a/Makefile b/Makefile
index 6e427bb..9b7ac2f 100644
--- a/Makefile
+++ b/Makefile
@@ -121,6 +121,9 @@ libbtrfs_headers = send-stream.h send-utils.h send.h kernel-lib/rbtree.h btrfs-l
convert_objects = convert/main.o convert/common.o convert/source-fs.o \
convert/source-ext2.o convert/source-reiserfs.o
mkfs_objects = mkfs/main.o mkfs/common.o
+image_objects = image/main.o
+all_objects = $(objects) $(cmds_objects) $(libbtrfs_objects) $(convert_objects) \
+ $(mkfs_objects) $(image_objects)
TESTS = fsck-tests.sh convert-tests.sh
@@ -592,5 +595,5 @@ uninstall:
cd $(DESTDIR)$(bindir); $(RM) -f -- btrfsck fsck.btrfs $(progs_install)
ifneq ($(MAKECMDGOALS),clean)
--include $(objects:.o=.o.d) $(cmds_objects:.o=.o.d) $(subst .btrfs,, $(filter-out btrfsck.o.d, $(progs:=.o.d)))
+-include $(all_objects:.o=.o.d) $(subst .btrfs,, $(filter-out btrfsck.o.d, $(progs:=.o.d)))
endif