16 |
exit 1 |
exit 1 |
17 |
fi |
fi |
18 |
|
|
19 |
|
sudo chmod g+w $(pwd)/$distarch/{images,repodata,repoview,LiveOS} |
20 |
for img in product updates EFI |
for img in product updates EFI |
21 |
do |
do |
22 |
if [ "$distrel" == "10" -a "$img" = "updates" ] |
if [ -d "$(pwd)/$distarch/$img" -a "$img" = "product" ] |
23 |
then |
then |
24 |
echo "SME10 do nothing with updates.img, yet" |
echo "building product.img" |
25 |
|
pushd $(pwd)/$distarch/$img |
26 |
|
find . | cpio -c -o | gzip -9cv > ../images/$img.img; |
27 |
|
popd |
28 |
|
sudo chmod 664 $(pwd)/$distarch/images/$img.img |
29 |
|
# echo "SME10 do nothing with updates.img, yet" |
30 |
elif [ -d "$(pwd)/$distarch/$img" -a "$img" = "EFI" ] |
elif [ -d "$(pwd)/$distarch/$img" -a "$img" = "EFI" ] |
31 |
then |
then |
32 |
echo "building efiboot.img" |
echo "building efiboot.img" |
33 |
# the content of the img should be /EFI/BOOT* and not /BOOT/*, so we need to copy the content in a temp dir |
# the content of the img should be /EFI/BOOT* and not /BOOT/*, so we need to copy the content in a temp dir |
34 |
|
mkdir -p /tmp/{loop,remaster} |
35 |
sudo mount -o loop $(pwd)/$distarch/images/efiboot.img /tmp/loop |
sudo mount -o loop $(pwd)/$distarch/images/efiboot.img /tmp/loop |
36 |
sudo cp -a $(pwd)/$distarch/EFI/BOOT/grub.cfg /tmp/loop/EFI/BOOT/ |
sudo cp -a $(pwd)/$distarch/EFI/BOOT/grub.cfg /tmp/loop/EFI/BOOT/ |
37 |
sudo umount /tmp/loop |
sudo umount /tmp/loop |
209 |
mv ../iso/$distrel/$distarch/$disttag-$distvers-$distarch.iso ../iso/$distrel/$distarch/$disttag-$distarch.iso |
mv ../iso/$distrel/$distarch/$disttag-$distvers-$distarch.iso ../iso/$distrel/$distarch/$disttag-$distarch.iso |
210 |
ln -sf $disttag-$distarch.iso ../iso/$distrel/$distarch/$disttag-$distvers-$distarch.iso |
ln -sf $disttag-$distarch.iso ../iso/$distrel/$distarch/$disttag-$distvers-$distarch.iso |
211 |
# for netinstall |
# for netinstall |
212 |
md5sum ../iso/$distrel/$distarch/$disttag-$distvers-$distarch-netinstall.iso | sed 's,\.\..*/,,' > ../iso/$distrel/$distarch/$disttag-$distvers-$distarch.iso.md5sum |
md5sum ../iso/$distrel/$distarch/$disttag-$distvers-$distarch-netinstall.iso | sed 's,\.\..*/,,' > ../iso/$distrel/$distarch/$disttag-$distvers-$distarch-netinstall.iso.md5sum |
213 |
sha1sum ../iso/$distrel/$distarch/$disttag-$distvers-$distarch-netinstall.iso | sed 's,\.\..*/,,' > ../iso/$distrel/$distarch/$disttag-$distvers-$distarch.iso.sha1sum |
sha1sum ../iso/$distrel/$distarch/$disttag-$distvers-$distarch-netinstall.iso | sed 's,\.\..*/,,' > ../iso/$distrel/$distarch/$disttag-$distvers-$distarch-netinstall.iso.sha1sum |
214 |
|
|
215 |
|
|
216 |
rsync -a --delete --delete-excluded \ |
rsync -a --delete --delete-excluded \ |