Add a new --enable-blkid switch to use libblkid from util-linux to detect
the device geometry and check for existing partitions or filesystem on a
device. Note that this requires the latest blkid from util-linux-ng git
for the topology calls, odler ones won't work. If I had a little more
autoconf fu we might be able to detect a too early one, but right now it
just fails if it's too old and --enable-blkid is specified. We also
stop building libdisk in the blkid case as it's an internal static library
not otherwise used.
For the actual checks I tried to stay as close as possible to the old
code, so we still don't check topology for external log devices. I hope
to add this at a later stage.
As a small addition we also print a warning if trying to create a filesystem
on a partition that is not properly aligned.
Signed-off-by: Christoph Hellwig <hch@lst.de> Reviewed-by: Eric Sandeen <sandeen@sandeen.net>