Re: building Rootfs

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Linus Walleij wrote:
If you know some way of sneaking a device node into a
.tar file created ENTIRELY running as a regular user,
tell me!

We do this all the time. We have a very minimal root filesystem and aren't currently using any of the frameworks for building root filesystems, so everything is done with make. In general, we create tar files for each piece. The piece that has device nodes has a make file with something like:

	all:
		fakeroot make fakeroot-package

	fakeroot-package:
		mkdir -p image
		mknod image/dev/null c 1 3
		mknod image/dev/random c 1 8
		tar -C image -czf image.tgz .

We ran into some issues when we separated running mknod and tar into separate fakeroot invocations because there is a bug in fakeroot with exporting and importing its state. Fortunately, doing all of this under a single fakeroot command works just fine. When we untar the tar files for all of the pieces to create a root filesystem image and then run mkcramfs to create a CRAMFS image, we do all commands under a single invocation of fakeroot.

No stage of the build requires running as root.
--
David VomLehn, dvomlehn@xxxxxxxxx




- - - - - Cisco - - - - - This e-mail and any attachments may contain information which is confidential, proprietary, privileged or otherwise protected by law. The information is solely intended for the named addressee (or a person responsible for delivering it to the addressee). If you are not the intended recipient of this message, you are not authorized to read, print, retain, copy or disseminate this message or any part of it. If you have received this e-mail in error, please notify the sender immediately by return e-mail and delete it from your computer.

--
To unsubscribe from this list: send the line "unsubscribe linux-embedded" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Gstreamer Embedded]     [Linux MMC Devel]     [U-Boot V2]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux ARM Kernel]     [Linux OMAP]     [Linux SCSI]

  Powered by Linux