Commit Graph

45 Commits

Author SHA1 Message Date
Chris Brannon 4317c1a4f6 Preserve Linux capabilities when running tar, and misc fixes for mkrootfs. (#92)
* Preserve Linux capabilities in various tar invocations.

Otherwise, ping as non-root will not work when using a Void image.

Don't try to umount pseudofilesystems when $rootfs is undefined.
On mktemp failure, die in the script itself, not the $( ... ) subshell.
And remove the second FATAL: from the error message.
2016-12-10 12:30:13 +01:00
Christopher Brannon 9800862806 mkimage.sh: fix sfdisk usage for multiple arches.
In the case where we have two partitions, boot and root, the
root partition needs to start at sector (2048 + bootfs_size_in_sectors),
not at $BOOT_FSSIZE.
Using $BOOT_FSSIZE as the start tells sfdisk to try to start the
/ partition in the middle of /boot, which it refuses to do.
Leave start blank, and sfdisk uses the first unallocated sector as
the start of /, which happens to be sector 2048 + bootfs_size_in_sectors.

I suspect this fixes #81.
2016-11-30 13:32:00 +01:00
Christian Neukirchen 58f6a3e7c0 mkimage.sh.in: odroid-c2: u-boot doesn't understand new ext4 features, disable. 2016-09-24 17:23:31 +02:00
Juan RP 8a22f2c03d mkimage: typo fix (close #80). 2016-08-11 08:19:31 +02:00
Juan RP fdb41f88e8 mkimage: active first partition (fat32) for bbb and others.
I activated the second partition by accident when the code was changed
to use sfdisk. Found and fixed by @pullmoll.

Close #80
2016-08-10 07:40:35 +02:00
Christian Neukirchen b2415b015d mkimage.sh.in: add odroid-c2. 2016-05-06 14:41:04 +02:00
Juan RP d6f949d640 mkimage: get rid of parted completely (missed this in previous). 2016-04-29 14:17:49 +02:00
Juan RP 3debfb21de mkimage: ci20 uboot does not need /boot/vmlinux.img; looks for uImage. 2016-04-27 12:48:46 +02:00
Juan RP 687cd4e536 mkimage: match any platform (glibc and musl). 2016-04-26 15:47:56 +02:00
Juan RP 6372530837 mkimage: get rid of parted; use sfdisk(8). 2016-04-26 15:00:55 +02:00
Juan RP be2251492f mkimage: ci20 just needs a single partition and expects the kernel in /vmlinux.img. 2016-04-26 11:45:37 +02:00
Juan RP ffe9572e3f mkimage: added ci20 platform support (MIPS CI20 Creator). 2016-04-26 11:20:14 +02:00
Ron Damen 11000d9f3c mkimage.sh.in: fix truncate size argument 2016-02-24 14:35:13 +01:00
Toyam Cox a25ec4a9b0 Switch to truncate to allocate storage for images
Works in low memory situations
2016-01-14 08:48:43 -05:00
Juan RP 391e50f0c2 mkimage: consistently redirect std{err,out} to /dev/null with dd(1). 2015-06-12 10:59:23 +02:00
jbu a7f094439b mkimage.sh: fix partition size + toggle boot flag 2015-05-26 13:44:13 +02:00
Juan RP 41fbde8a5b mk{image,rootfs}: accept musl targets and fix image creation with two partitions. 2015-05-26 11:00:52 +02:00
Juan RP d95e13b4aa mkimage: bananapi-uboot still assumes fat partition. 2015-05-21 12:16:25 +02:00
Juan RP 1bd3d55b05 mkimage: on bpi, cubie{board2,truck} we don't need a FAT partition. 2015-05-21 12:12:17 +02:00
jbu f3b9e9d2e4 mkimage.sh.in: add cubietruck 2015-05-16 20:16:32 +02:00
Enno Boland 8b238fad3f add platform support for USB armory 2015-04-28 17:30:16 +02:00
Juan RP 3d30dbb7a6 mkimage: misc cosmetic tweaks; umount rootfs/boot only if it's mounted. 2015-02-22 09:39:47 +01:00
Juan RP 9b00e0b1fe mkimage: do not touch rootfstype from cmdline, it's unnecessary. 2015-02-10 18:43:38 +01:00
Juan RP e52f493f15 mk{image,rootfs}: add support for the rpi2 platform (armv7). 2015-02-06 11:29:49 +01:00
Juan RP 7dff7059c0 mkimage: added bananapi platform. 2015-01-19 15:49:59 +01:00
Juan RP 1c1251c506 mkimage: disable fsck on rootfs if it's f2fs; it does not work in the rpi. 2015-01-17 11:31:10 +01:00
Juan RP f3dea549e8 mkimage: simplify. 2014-12-06 09:42:17 +01:00
Juan RP 8939262303 mkimage: get rid of partx completely. 2014-12-06 09:41:49 +01:00
Juan RP a7c809c6b0 mkimage: use losetup --partscan rather than partx. 2014-12-05 15:31:27 +01:00
Juan RP a3675d092f mkimage: umount boot only in !beaglebone. 2014-12-05 12:58:19 +01:00
Juan RP 3818e6d425 mk{image,rootfs}: misc tweaks for beaglebone. 2014-12-05 11:06:39 +01:00
Juan RP b7a3926c5b mkimage: remove unnecessary beaglebone workaround. 2014-12-05 07:09:36 +01:00
Juan RP 1c603437d3 mk{image,rootfs}: add beaglebone platform support. 2014-12-05 05:46:31 +01:00
Juan RP c4efb3d95e mkimage: if root fstype is ext[34] disable the journal. 2014-11-29 18:16:50 +01:00
Juan RP 20f2340387 mkimage: guess platform automatically, add new options to set fstype and boot fssize. 2014-01-28 17:04:15 +01:00
Gottox 24f3cd97c2 install bootloader on udroid-u2 2014-01-28 14:31:08 +01:00
Juan RP aedb3ea05c mkimage: use conv=sparse if dd supports it; added -p to set platform. 2014-01-26 20:32:54 +01:00
root 9683dc0045 using xpart instead of losetup -P, as -P is not supported by debian stable
mkfs.vfat thinks it writes to a raw device instead of a partition on debian. force it
2014-01-22 18:15:57 +01:00
Juan RP 1ee561f98d mkimage: create /boot partition at 4096 sectors. 2014-01-21 23:27:52 +01:00
Juan RP ede54ad439 mkimage: check for losetup existence too. 2013-11-12 16:48:55 +01:00
Juan RP adf32efa6b mkimage: check for mkfs.xxx after setting defaults. 2013-11-11 10:09:00 +01:00
Juan RP 2c846d9f4c mkimage: make sure to update rootfstype on /boot/cmdline.txt for Raspberry Pi. 2013-11-11 09:06:03 +01:00
Juan RP 81378ab3c6 mkimage: allow -r f2fs or any other fs and check we have required cmds. 2013-11-10 08:42:04 +01:00
Juan RP ecf9674d14 mkimage: do not force FAT32 for the /boot filesystem.
If the FAT partition does not have enough clusters for FAT32, the Raspberry Pi
will fail to boot.

Fix: let mkfs.vfat choose the FAT type automatically.
2013-09-21 12:30:38 +02:00
Juan RP 065b000f4f New void-mkimage script to generate working images with a provided rootfs tarball. 2013-08-11 12:17:18 +02:00