#!/bin/sh # Script to build images for all archs . ./CONF.sh rm -rf "$TDIR" rm -rf "$OUT" TMP_OUT=$OUT if [ -z "$ARCHES" ]; then export ARCHES='amd64 i386 powerpc' fi for FULLARCH in $ARCHES do export ARCH="${FULLARCH%%+*}" if [ "$ARCH" = "$FULLARCH" ]; then export SUBARCH= else export SUBARCH="${FULLARCH#*+}" fi echo "Now we're going to build CD for $FULLARCH !" CDREV=`git rev-parse HEAD` echo "Using revision $CDREV of debian-cd" echo " ... cleaning" make distclean make init echo " ... selecting packages to include" make list echo " ... building the images" export OUT=$TMP_OUT/$FULLARCH; mkdir -p $OUT make official_images if [ $? -gt 0 ]; then echo "ERROR WHILE BUILDING OFFICIAL IMAGES !!" >&2 # exit 1 continue fi echo Generating list files for images make pi-makelist # XXX: even when we build images for mulitple arches, we only want to # compress those that have IMAGE_FORMAT=img, but that is a per-arch # thing. Right now that's just for riscv64 images. # Let's do this better and allow setting these per-single-arch # somehow nicely. if [ "$CDIMAGE_COMPRESS" = 1 ]; then echo Compressing CD images make compress_images fi echo "--------------- `date` ---------------" done