summaryrefslogtreecommitdiff
path: root/strata/lvm
diff options
context:
space:
mode:
authorSam Thursfield <sam.thursfield@codethink.co.uk>2015-01-28 11:20:05 +0000
committerSam Thursfield <sam.thursfield@codethink.co.uk>2015-01-28 11:20:05 +0000
commit12061a73549a396c0b8004ea2dfaabf5e9c78321 (patch)
treed7646cd90df0e0138d34858eec8e6b2d50e46b45 /strata/lvm
parente9b5ef16922d2ed4031576f5df73ff53507c1b57 (diff)
parenta2cb0484b970f2f58c4cc3e0057976b6a4daf64a (diff)
downloaddefinitions-12061a73549a396c0b8004ea2dfaabf5e9c78321.tar.gz
Merge branch 'baserock/sam/lvm-stratum'
Reviewed-By: Pedro Alvarez <pedro.alvarez@codethink.co.uk> Reviewed-By: Francisco Redondo Marchena <francisco.marchena@codethink.co.uk>
Diffstat (limited to 'strata/lvm')
-rw-r--r--strata/lvm/lvm2.morph31
1 files changed, 31 insertions, 0 deletions
diff --git a/strata/lvm/lvm2.morph b/strata/lvm/lvm2.morph
new file mode 100644
index 00000000..791894df
--- /dev/null
+++ b/strata/lvm/lvm2.morph
@@ -0,0 +1,31 @@
+name: lvm2
+kind: chunk
+build-system: autotools
+
+configure-commands:
+# We specify --sbindir explicitly due to a bug in .service file generation:
+# if left to the default, @sbindir@ is expanded to the literal string
+# '${exec_prefix}/sbin' in the generated .service files.
+#
+# udev rules *must* go in /lib, they'll be ignored if they go in /usr/lib.
+- >
+ ./configure --prefix="$PREFIX" \
+ --sbindir="$PREFIX"/sbin \
+ --with-udev-prefix=/lib \
+ --with-systemdsystemunitdir="$PREFIX"/lib/systemd/system \
+ --enable-applib --enable-cmdlib --enable-pkgconfig --enable-lvmetad \
+ --enable-dmeventd --enable-udev_sync
+
+install-commands:
+- make DESTDIR="$DESTDIR" install
+- make DESTDIR="$DESTDIR" install_system_dirs
+- make DESTDIR="$DESTDIR" install_systemd_generators
+- make DESTDIR="$DESTDIR" install_systemd_units
+- make DESTDIR="$DESTDIR" install_tmpfiles_configuration
+
+# Use lvmetad by default. This means we don't have to use the
+# `lvm2-activation-generator` systemd generator, which is a good thing
+# because I have seen it cause systems to completely fail to boot. Fedora
+# does something similar, see:
+# http://pkgs.fedoraproject.org/cgit/lvm2.git/tree/lvm2-enable-lvmetad-by-default.patch
+- sed -e 's/use_lvmetad = 0/use_lvmetad = 1/' -i "$DESTDIR"/etc/lvm/lvm.conf