view more/for-each-target.sh @ 1398:b74d36876c0a

Replace read_arch_dir with load_target, which understands that sources/targets/$TARGET can be a file or a directory.
author Rob Landley <rob@landley.net>
date Sun, 26 Jun 2011 17:44:02 -0500
parents dadbb8873a36
children 096ac2dfb9bd
line wrap: on
line source

#!/bin/bash

# Iterate through every target architecture, running rest of command line
# on each $TARGET.

# If $FORK is set, run them in parallel with filtered output.

. sources/utility_functions.sh || exit 1

[ -z "${ARCHES}" ] &&
  ARCHES="$(ls sources/targets)"

for TARGET in $ARCHES
do
  [ ! -f "$TARGET" ] && continue
  maybe_fork "$* | maybe_quiet"
done

wait