From 03423e0583057cbe5a16f8439183e2dbc0e8dd7c Mon Sep 17 00:00:00 2001 From: Cem Keylan Date: Mon, 9 Dec 2019 19:17:24 +0300 Subject: secondary commit --- extra/lvm2/build | 41 +++++++++++++++++++++++++++++++++++++++++ 1 file changed, 41 insertions(+) create mode 100755 extra/lvm2/build (limited to 'extra/lvm2/build') diff --git a/extra/lvm2/build b/extra/lvm2/build new file mode 100755 index 00000000..ffa71785 --- /dev/null +++ b/extra/lvm2/build @@ -0,0 +1,41 @@ +#!/bin/sh -e + +patch -p1 < fix-stdio-usage.patch +patch -p1 < disable-symver.patch + +# LVM2 calls 'fmt -1' throughout the build process. +# Busybox doesn't provide this command, however +# all it does is split words one per line and +# 'tr' can be used in its place. +sed -i 's/fmt -1/tr " " "\\n"/' \ + make.tmpl.in libdm/make.tmpl.in + +# The build fails when using busybox's 'mkdir'(?), +# swap to using 'install -d' instead which works. +export MKDIR_P="install -d" + +./configure \ + --prefix=/usr \ + --sbindir=/usr/bin \ + --sysconfdir=/etc \ + --localstatedir=/var \ + --disable-selinux \ + --enable-pkgconfig \ + --enable-fsadm \ + --enable-dmeventd \ + --enable-cmdlib \ + --enable-udev_sync \ + --enable-udev_rules \ + --enable-symvers=no \ + --disable-symvers \ + --with-default-dm-run-dir=/run \ + --with-default-locking-dir=/run/lock/lvm \ + --with-default-pid-dir=/run \ + --with-default-run-dir=/run/lvm + +make DESTDIR="$1" install + +# Make all libraries and binaries writable. +chmod -v u+w "$1/usr/lib/"* \ + "$1/usr/include/"* \ + "$1/usr/bin/"* -- cgit v1.2.3