summaryrefslogtreecommitdiff
path: root/Makefile
diff options
context:
space:
mode:
authorDavid Sterba <dsterba@suse.com>2017-10-20 00:31:44 +0200
committerDavid Sterba <dsterba@suse.com>2017-11-14 15:59:00 +0100
commitaf524c95392b409be3b7643c9ac117b5e060a26e (patch)
treeda6ac936cee4ac17b7b900d76768665d4caeea30 /Makefile
parentc76b05fba284c68c6cb7b710dbb95a42089e8538 (diff)
btrfs-progs: build: use variables for btrfs-image images
More separate sources will be created for btrfs-image. Signed-off-by: David Sterba <dsterba@suse.com>
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile5
1 files changed, 3 insertions, 2 deletions
diff --git a/Makefile b/Makefile
index d0657aa..6ee754b 100644
--- a/Makefile
+++ b/Makefile
@@ -246,6 +246,7 @@ static_cmds_objects = $(patsubst %.o, %.static.o, $(cmds_objects))
static_libbtrfs_objects = $(patsubst %.o, %.static.o, $(libbtrfs_objects))
static_convert_objects = $(patsubst %.o, %.static.o, $(convert_objects))
static_mkfs_objects = $(patsubst %.o, %.static.o, $(mkfs_objects))
+static_image_objects = $(patsubst %.o, %.static.o, $(image_objects))
libs_shared = libbtrfs.so.0.1
libs_static = libbtrfs.a
@@ -424,11 +425,11 @@ btrfstune.static: btrfstune.static.o $(static_objects) $(static_libbtrfs_objects
@echo " [LD] $@"
$(Q)$(CC) -o $@ $^ $(STATIC_LDFLAGS) $(STATIC_LIBS)
-btrfs-image: image/main.o $(objects) $(libs_static)
+btrfs-image: $(image_objects) $(objects) $(libs_static)
@echo " [LD] $@"
$(Q)$(CC) -o $@ $^ $(LDFLAGS) $(LIBS) $(LIBS_COMP)
-btrfs-image.static: image/main.static.o $(static_objects) $(static_libbtrfs_objects)
+btrfs-image.static: $(static_image_objects) $(static_objects) $(static_libbtrfs_objects)
@echo " [LD] $@"
$(Q)$(CC) -o $@ $^ $(STATIC_LDFLAGS) $(STATIC_LIBS) $(STATIC_LIBS_COMP)