[1/6] lib/system: Add losetup to pb_system_apps
diff mbox

Message ID 20161025034448.28723-1-sam@mendozajonas.com
State Superseded
Headers show

Commit Message

Samuel Mendoza-Jonas Oct. 25, 2016, 3:44 a.m. UTC
Add losetup which will enable us to setup loopback devices from within
Petitboot.

Signed-off-by: Samuel Mendoza-Jonas <sam@mendozajonas.com>
---
 configure.ac        | 1 +
 lib/system/system.c | 1 +
 lib/system/system.h | 1 +
 3 files changed, 3 insertions(+)

Patch
diff mbox

diff --git a/configure.ac b/configure.ac
index 41560d1..fdff93d 100644
--- a/configure.ac
+++ b/configure.ac
@@ -328,6 +328,7 @@  DEFINE_HOST_PROG(UMOUNT, umount, [/bin/umount])
 DEFINE_HOST_PROG(WGET, wget, [/usr/bin/wget])
 DEFINE_HOST_PROG(IP, ip, [/sbin/ip])
 DEFINE_HOST_PROG(UDHCPC, udhcpc, [/sbin/udhcpc])
+DEFINE_HOST_PROG(LOSETUP, losetup, [/sbin/losetup])
 
 AC_ARG_WITH(
     [tftp],
diff --git a/lib/system/system.c b/lib/system/system.c
index 917d444..cdf637d 100644
--- a/lib/system/system.c
+++ b/lib/system/system.c
@@ -28,6 +28,7 @@  const struct pb_system_apps pb_system_apps = {
 	.wget		= HOST_PROG_WGET,
 	.ip		= HOST_PROG_IP,
 	.udhcpc		= HOST_PROG_UDHCPC,
+	.losetup	= HOST_PROG_LOSETUP,
 };
 
 #ifndef TFTP_TYPE
diff --git a/lib/system/system.h b/lib/system/system.h
index ab25101..8497b22 100644
--- a/lib/system/system.h
+++ b/lib/system/system.h
@@ -13,6 +13,7 @@  struct pb_system_apps {
 	const char *wget;
 	const char *ip;
 	const char *udhcpc;
+	const char *losetup;
 };
 
 extern const struct pb_system_apps pb_system_apps;