summaryrefslogtreecommitdiff
path: root/Makefile
diff options
context:
space:
mode:
authorChris Mason <chris.mason@oracle.com>2009-11-12 14:34:09 -0500
committerChris Mason <chris.mason@oracle.com>2009-11-12 14:49:03 -0500
commitab8fb4c99516c186641bda1dbc0e788f68b4dc77 (patch)
tree1d0d59910d56a51b705ae5428d0910a074145bc9 /Makefile
parent6f3cf25a4e7932bc737ed06bc95f73f80772092d (diff)
Add btrfs-map-logical program to map and read logical block numbers
This allows us to figure out which physical byte offset on which device is the real location for a given logical block number. It can optionally read the block in and save it to a file for debugging analysis. Signed-off-by: Chris Mason <chris.mason@oracle.com>
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile6
1 files changed, 5 insertions, 1 deletions
diff --git a/Makefile b/Makefile
index 8097b5ae..02f881e4 100644
--- a/Makefile
+++ b/Makefile
@@ -16,7 +16,8 @@ prefix ?= /usr/local
bindir = $(prefix)/bin
LIBS=-luuid
-progs = btrfsctl mkfs.btrfs btrfs-debug-tree btrfs-show btrfs-vol btrfsck
+progs = btrfsctl mkfs.btrfs btrfs-debug-tree btrfs-show btrfs-vol btrfsck \
+ btrfs-map-logical
# make C=1 to enable sparse
ifdef C
@@ -56,6 +57,9 @@ btrfs-debug-tree: $(objects) debug-tree.o
btrfstune: $(objects) btrfstune.o
gcc $(CFLAGS) -o btrfstune $(objects) btrfstune.o $(LDFLAGS) $(LIBS)
+btrfs-map-logical: $(objects) btrfs-map-logical.o
+ gcc $(CFLAGS) -o btrfs-map-logical $(objects) btrfs-map-logical.o $(LDFLAGS) $(LIBS)
+
btrfs-image: $(objects) btrfs-image.o
gcc $(CFLAGS) -o btrfs-image $(objects) btrfs-image.o -lpthread -lz $(LDFLAGS) $(LIBS)