diff options
author | Eelco Dolstra <eelco.dolstra@logicblox.com> | 2007-02-07 15:23:19 +0000 |
---|---|---|
committer | Eelco Dolstra <eelco.dolstra@logicblox.com> | 2007-02-07 15:23:19 +0000 |
commit | 6c529fac777dc2880aead3a1d325532dcc89c879 (patch) | |
tree | 2ee9158aec559e58a2e84c97a49d0ef37aa8674d /helpers/make-iso9660-image.sh | |
parent | 5d02654a3c09460a845ea7bd205be587b892f20c (diff) | |
download | nixpkgs-6c529fac777dc2880aead3a1d325532dcc89c879.tar nixpkgs-6c529fac777dc2880aead3a1d325532dcc89c879.tar.gz nixpkgs-6c529fac777dc2880aead3a1d325532dcc89c879.tar.bz2 nixpkgs-6c529fac777dc2880aead3a1d325532dcc89c879.tar.lz nixpkgs-6c529fac777dc2880aead3a1d325532dcc89c879.tar.xz nixpkgs-6c529fac777dc2880aead3a1d325532dcc89c879.tar.zst nixpkgs-6c529fac777dc2880aead3a1d325532dcc89c879.zip |
* Very naughty of me not to use -boot-info-table. Now I know better.
svn path=/nixos/trunk/; revision=7875
Diffstat (limited to 'helpers/make-iso9660-image.sh')
-rw-r--r-- | helpers/make-iso9660-image.sh | 15 |
1 files changed, 14 insertions, 1 deletions
diff --git a/helpers/make-iso9660-image.sh b/helpers/make-iso9660-image.sh index 910417cde47..942e782dbad 100644 --- a/helpers/make-iso9660-image.sh +++ b/helpers/make-iso9660-image.sh @@ -8,7 +8,20 @@ symlinks=($symlinks) if test -n "$bootable"; then - bootFlags="-b $bootImage -c boot.cat -no-emul-boot -boot-load-size 4" + + # The -boot-info-table option modifies the $bootImage file, so + # find it in `contents' and make a copy of it (since the original + # is read-only in the Nix store...). + for ((i = 0; i < ${#targets_[@]}; i++)); do + if test "${targets_[$i]}" = "$bootImage"; then + echo "copying the boot image ${sources_[$i]}" + cp "${sources_[$i]}" boot.img + chmod u+w boot.img + sources_[$i]=boot.img + fi + done + + bootFlags="-b $bootImage -c boot.cat -no-emul-boot -boot-load-size 4 -boot-info-table" fi |