On Wed, 11 Jan 2006 14:51:46 -0800 "Robin H. Johnson" <[EMAIL PROTECTED]> wrote:
> I've been cleaning up media-fonts/ to work with modular-X, and I see a
> lot of ebuilds with stuff like this:
> for font in *.bdf; do
> /usr/X11R6/bin/bdftopcf ${font} > `basename $font .bdf`.pcf
> done
> gzip *.pcf
>
> ['make' suggestion and example makefile snipped]
You could just do it directly in bash:
for font in *.bdf; do
pcf=`basename $font`.pcf && \
/usr/X11R6/bin/bdftopcf ${font} > ${pcf} &&
gzip ${pcf} &
done
wait
You may want to limit the number of parallel processes somewhat (as
with 'make -jN'), which is also easy enough to do:
n=${MAX_PARALLEL}
for font in *.bdf; do
pcf=`basename $font .bdf`.pcf && \
/usr/X11R6/bin/bdftopcf ${font} > ${pcf} && \
gzip ${pcf} &
[[ ${n} -eq 0 ]] && wait && n=${MAX_PARALLEL}
((n=${n}-1))
done
wait
--
Kevin F. Quinn
--
Kevin F. Quinn
signature.asc
Description: PGP signature
