Buildroot Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: Karoly Kasza <kaszak@gmail.com>
To: buildroot@busybox.net
Subject: [Buildroot] [PATCH v2 3/3] fs/rawimg: new rootfs target
Date: Tue,  9 Dec 2014 17:03:27 +0100	[thread overview]
Message-ID: <1418141008-18739-4-git-send-email-kaszak@gmail.com> (raw)
In-Reply-To: <1418141008-18739-1-git-send-email-kaszak@gmail.com>

Rootfs target to call the new mkrawimg package.

Signed-off-by: Karoly Kasza <kaszak@gmail.com>
---

Changes v1 -> v2:
  - Removed script into new mkrawimg package.

 fs/Config.in        |    1 +
 fs/rawimg/Config.in |   15 +++++++++++++++
 fs/rawimg/rawimg.mk |   13 +++++++++++++
 3 files changed, 29 insertions(+)
 create mode 100644 fs/rawimg/Config.in
 create mode 100644 fs/rawimg/rawimg.mk

diff --git a/fs/Config.in b/fs/Config.in
index 5853113..36961db 100644
--- a/fs/Config.in
+++ b/fs/Config.in
@@ -8,6 +8,7 @@ source "fs/initramfs/Config.in"
 source "fs/iso9660/Config.in"
 source "fs/jffs2/Config.in"
 source "fs/romfs/Config.in"
+source "fs/rawimg/Config.in"
 source "fs/squashfs/Config.in"
 source "fs/tar/Config.in"
 source "fs/ubifs/Config.in"
diff --git a/fs/rawimg/Config.in b/fs/rawimg/Config.in
new file mode 100644
index 0000000..68b518e
--- /dev/null
+++ b/fs/rawimg/Config.in
@@ -0,0 +1,15 @@
+config BR2_TARGET_ROOTFS_RAWIMG
+	bool "raw disk image"
+	depends on BR2_i386 || BR2_x86_64
+	depends on BR2_LINUX_KERNEL
+	select BR2_PACKAGE_HOST_MKRAWIMG
+	select BR2_LINUX_KERNEL_INSTALL_TARGET
+	select BR2_TARGET_ROOTFS_EXT2
+	help
+	  Build a bootable raw disk image, that can be booted in a VM (e.g. QEMU),
+	  or directly written to disk. Creates a valid partition table with MBR,
+	  and one primary ext* partition.
+
+comment "raw disk image needs a Linux kernel to be built"
+	depends on BR2_i386 || BR2_x86_64
+	depends on !BR2_LINUX_KERNEL
diff --git a/fs/rawimg/rawimg.mk b/fs/rawimg/rawimg.mk
new file mode 100644
index 0000000..c0a720d
--- /dev/null
+++ b/fs/rawimg/rawimg.mk
@@ -0,0 +1,13 @@
+################################################################################
+#
+# Build the raw disk image
+#
+################################################################################
+
+ROOTFS_RAWIMG_DEPENDENCIES = rootfs-ext2 host-mkrawimg
+
+define ROOTFS_RAWIMG_CMD
+	PATH=$(BR_PATH) mkrawimg $(BINARIES_DIR) $@
+endef
+
+$(eval $(call ROOTFS_TARGET,rawimg))
-- 
1.7.10.4

  parent reply	other threads:[~2014-12-09 16:03 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-12-09 16:03 [Buildroot] [PATCH v2 0/3] New image target (x86/x64): raw disk image Karoly Kasza
2014-12-09 16:03 ` [Buildroot] [PATCH v2 1/3] util-linux: enable host fdisk Karoly Kasza
2014-12-10 17:47   ` Yann E. MORIN
2014-12-09 16:03 ` [Buildroot] [PATCH v2 2/3] package/mkrawimg: new package Karoly Kasza
2014-12-09 16:03 ` Karoly Kasza [this message]
2014-12-10 18:05   ` [Buildroot] [PATCH v2 3/3] fs/rawimg: new rootfs target Yann E. MORIN
2014-12-11  9:57     ` Károly Kasza

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1418141008-18739-4-git-send-email-kaszak@gmail.com \
    --to=kaszak@gmail.com \
    --cc=buildroot@busybox.net \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox