Mercurial > hg > control-images
changeset 39:31d7462a8649 draft
Copy to chroot if / read-only _or_ if /home has more space.
(Now that we use initramfs, / is writeable but only a few dozen megabytes free.)
author | Rob Landley <rob@landley.net> |
---|---|
date | Wed, 25 Feb 2015 00:44:24 -0600 |
parents | 895de110859a |
children | ef471ef37665 |
files | common/bootstrap/init |
diffstat | 1 files changed, 3 insertions(+), 2 deletions(-) [+] |
line wrap: on
line diff
--- a/common/bootstrap/init Sat Dec 27 15:09:06 2014 -0600 +++ b/common/bootstrap/init Wed Feb 25 00:44:24 2015 -0600 @@ -6,9 +6,10 @@ [ -z "$NATIVE_BUILD" ] && NATIVE_BUILD=chroot -# Is the root filesystem already writeable? +# Is the root filesystem already writeable and same or more storage than / -if touch /.amiwrite 2>/dev/null && rm /.amiwrite 2>/dev/null +if touch /.amiwrite 2>/dev/null && rm /.amiwrite 2>/dev/null && + [ $(($(stat -fc "%a*%S" /))) -ge $(($(stat -fc "%a*%S" /home))) ] then # build and install stuff on the writable filesystem