live-build/scripts/build
Matthijs Kooijman 72ca3bcb20 Handle hardlinks in binary_hdd
To generate an hdd image, binary_hdd first estimates the needed size of
the image using du. By default, when du finds multiple hardlinked copies
of a file, it counts them only once. However, when the target filesystem
is FAT, which does not support hardlinks, these files will take up more
space when finally copying the contents, breaking the build:

	P: Copying binary contents into image...
	cp: error writing 'chroot/binary.tmp/live/initrd.img-4.9.0-3-amd64': No space left on device
	cp: error writing 'chroot/binary.tmp/efi/boot/bootx64.efi': No space left on device
	cp: error writing 'chroot/binary.tmp/efi/boot/bootia32.efi': No space left on device
	cp: cannot create directory 'chroot/binary.tmp/boot/grub': No space left on device
	cp: cannot create directory 'chroot/binary.tmp/isolinux': No space left on device

To fix this, pass --count-links to du when the target is FAT, to make
the space estimation correct.

This problem is exposed by commit 9c974b26b (Instead of renaming kernel
for syslinux, create hardlinks), which might need to be separately fixed
(to not waste space on FAT targets), but binary_hdd should at least
handle hardlinks more gracefully.
2017-09-01 10:29:20 +02:00
..
binary Added EFI support by the means of grub-efi 2016-07-31 15:09:13 +02:00
binary_checksums Updating year in copyright notices to 2015. 2015-01-04 20:05:44 +01:00
binary_chroot Updating year in copyright notices to 2015. 2015-01-04 20:05:44 +01:00
binary_disk Getting rid of hard-coded release numbers and using /etc/os-release instead (Closes: ). 2015-08-10 21:31:21 +02:00
binary_grub-efi Check all dependencies independent of LB_BUILD_WITH_CHROOT 2017-09-01 10:22:09 +02:00
binary_grub-legacy Default for LB_UNION_FILESYSTEM is now "overlay" just like in live-boot. 2016-12-02 15:10:19 +01:00
binary_grub-pc Drop useless code in binary_grub-pc 2016-12-02 15:01:28 +01:00
binary_hdd Handle hardlinks in binary_hdd 2017-09-01 10:29:20 +02:00
binary_hooks Correcting execution of local binary hooks. 2015-06-05 22:28:50 +02:00
binary_includes Updating year in copyright notices to 2015. 2015-01-04 20:05:44 +01:00
binary_iso Add .disk/mkisofs file recording the xorriso command line 2017-08-10 14:53:53 +02:00
binary_linux-image Dropping automagics for casper. 2015-05-03 15:50:03 +02:00
binary_loadlin Check all dependencies independent of LB_BUILD_WITH_CHROOT 2017-09-01 10:22:09 +02:00
binary_loopback_cfg Cleanup binary_loopback_cfg and offer more freedom in overriding the default grub-pc configuration. 2016-12-14 12:33:07 +01:00
binary_manifest Dropping automagics for casper. 2015-05-03 15:50:03 +02:00
binary_memtest Dropping automagics for casper. 2015-05-03 15:50:03 +02:00
binary_netboot Updating year in copyright notices to 2015. 2015-01-04 20:05:44 +01:00
binary_package-lists Check all dependencies independent of LB_BUILD_WITH_CHROOT 2017-09-01 10:22:09 +02:00
binary_rootfs Dropping support for upstart. 2015-05-03 16:12:30 +02:00
binary_syslinux Check all dependencies independent of LB_BUILD_WITH_CHROOT 2017-09-01 10:22:09 +02:00
binary_tar Correcting wrong tar command for tarball images, thanks to Yadickson Soto <yadickson@gmail.com> (Closes: ). 2015-04-28 07:58:16 +02:00
binary_win32-loader Check all dependencies independent of LB_BUILD_WITH_CHROOT 2017-09-01 10:22:09 +02:00
binary_zsync Updating year in copyright notices to 2015. 2015-01-04 20:05:44 +01:00
bootstrap Get rid of useless bootstrap_archive-keys script 2016-11-28 21:36:57 +01:00
bootstrap_archives Installing apt and dpkg updates (if any) first in derivatives mode, then doing dist-upgrade. 2015-05-23 12:42:16 +02:00
bootstrap_cache Updating year in copyright notices to 2015. 2015-01-04 20:05:44 +01:00
bootstrap_debootstrap Support “lb config --debootstrap-script <script>” 2016-11-28 20:58:19 +01:00
build Calling lb config in lb build to support building a all-default-image with a simple lb build (Closes: ). 2015-04-28 07:58:16 +02:00
chroot Dropping support for upstart. 2015-05-03 16:12:30 +02:00
chroot_apt Updating year in copyright notices to 2015. 2015-01-04 20:05:44 +01:00
chroot_archives Drop an optimization in chroot_archives that has undesired side-effects 2016-11-28 21:48:18 +01:00
chroot_cache Updating year in copyright notices to 2015. 2015-01-04 20:05:44 +01:00
chroot_debianchroot Updating year in copyright notices to 2015. 2015-01-04 20:05:44 +01:00
chroot_devpts Updating year in copyright notices to 2015. 2015-01-04 20:05:44 +01:00
chroot_dpkg force link creation when diverting flash-kernel 2015-09-23 10:44:11 +02:00
chroot_firmware Removing temporary hack to exclude prism2-usb-firmware-installer, the download homepage seems to work again (Closes: ). 2015-04-27 07:50:52 +02:00
chroot_hacks Dropping automagics for casper. 2015-05-03 15:50:03 +02:00
chroot_hooks Fix check for presence of chroot hooks 2015-07-26 13:44:16 +02:00
chroot_hostname Updating year in copyright notices to 2015. 2015-01-04 20:05:44 +01:00
chroot_hosts Updating year in copyright notices to 2015. 2015-01-04 20:05:44 +01:00
chroot_includes Correcting typo in stagefile check for includes.chroot. 2015-01-25 10:27:26 +01:00
chroot_install-packages Updating year in copyright notices to 2015. 2015-01-04 20:05:44 +01:00
chroot_interactive Updating year in copyright notices to 2015. 2015-01-04 20:05:44 +01:00
chroot_linux-image Updating year in copyright notices to 2015. 2015-01-04 20:05:44 +01:00
chroot_live-packages Updating year in copyright notices to 2015. 2015-01-04 20:05:44 +01:00
chroot_package-lists Check all dependencies independent of LB_BUILD_WITH_CHROOT 2017-09-01 10:22:09 +02:00
chroot_preseed Updating year in copyright notices to 2015. 2015-01-04 20:05:44 +01:00
chroot_proc Updating year in copyright notices to 2015. 2015-01-04 20:05:44 +01:00
chroot_resolv Updating year in copyright notices to 2015. 2015-01-04 20:05:44 +01:00
chroot_selinuxfs Updating year in copyright notices to 2015. 2015-01-04 20:05:44 +01:00
chroot_sysfs Updating year in copyright notices to 2015. 2015-01-04 20:05:44 +01:00
chroot_sysv-rc Updating year in copyright notices to 2015. 2015-01-04 20:05:44 +01:00
chroot_tmpfs Updating year in copyright notices to 2015. 2015-01-04 20:05:44 +01:00
clean Updating year in copyright notices to 2015. 2015-01-04 20:05:44 +01:00
config Minor updates to lb_config and its manual page 2016-12-16 10:00:36 +01:00
efi-image Try to reuse /isolinux/splash.png in default grub configuration. 2016-11-28 20:58:18 +01:00
grub-cpmodules Stolen efi-image and grub-cpmodules from src:live-installer 2016-07-31 15:09:13 +02:00
installer Dropping support for upstart. 2015-05-03 16:12:30 +02:00
installer_debian-installer Switch d-i.debian.org URIs from http to https. 2016-05-26 21:58:03 +02:00
installer_preseed Updating year in copyright notices to 2015. 2015-01-04 20:05:44 +01:00
source Updating year in copyright notices to 2015. 2015-01-04 20:05:44 +01:00
source_checksums Updating year in copyright notices to 2015. 2015-01-04 20:05:44 +01:00
source_debian Multi bootloader support 2015-08-29 23:56:41 +02:00
source_debian-live Updating year in copyright notices to 2015. 2015-01-04 20:05:44 +01:00
source_disk Getting rid of hard-coded release numbers and using /etc/os-release instead (Closes: ). 2015-08-10 21:31:21 +02:00
source_hdd Disable EXT4 64bit features 2016-06-18 19:36:16 +02:00
source_hooks Correcting execution of local source hooks. 2015-06-05 22:29:47 +02:00
source_iso Set xorriso's "modification time" to SOURCE_DATE_EPOCH 2016-11-28 20:58:19 +01:00
source_live Updating year in copyright notices to 2015. 2015-01-04 20:05:44 +01:00
source_tar Updating year in copyright notices to 2015. 2015-01-04 20:05:44 +01:00