summaryrefslogtreecommitdiff
path: root/Makefile
diff options
context:
space:
mode:
authorEric Sandeen <sandeen@redhat.com>2013-02-14 12:30:03 -0600
committerDavid Sterba <dsterba@suse.cz>2013-02-19 11:15:31 +0100
commit2a2d8e1962e8b6cda7b0a7584f6d2fb95d442cb6 (patch)
treebaf0bcadc48c146e25717f1506ab46edbb8194ad /Makefile
parent3b85739dd6c63c8f94f87d6574494919d2c1119f (diff)
btrfs-progs: require mkfs -f force option to overwrite filesystem or partition table
The core of this is shamelessly stolen from xfsprogs. Use blkid to detect an existing filesystem or partition table on any of the target devices. If something is found, require the '-f' option to overwrite it, hopefully avoiding disaster due to mistyped devicenames, etc. # mkfs.btrfs /dev/sda1 WARNING! - Btrfs v0.20-rc1-59-gd00279c-dirty IS EXPERIMENTAL WARNING! - see http://btrfs.wiki.kernel.org before using /dev/sda1 appears to contain an existing filesystem (xfs). Use the -f option to force overwrite. # This does introduce a requirement on libblkid. Signed-off-by: Eric Sandeen <sandeen@redhat.com>
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile2
1 files changed, 1 insertions, 1 deletions
diff --git a/Makefile b/Makefile
index 456dd4f2..bea8ae96 100644
--- a/Makefile
+++ b/Makefile
@@ -19,7 +19,7 @@ DEPFLAGS = -Wp,-MMD,$(@D)/.$(@F).d,-MT,$@
INSTALL = install
prefix ?= /usr/local
bindir = $(prefix)/bin
-LIBS=-luuid -lm -lz
+LIBS=-luuid -lblkid -lm -lz
ifeq ("$(origin V)", "command line")
BUILD_VERBOSE = $(V)