IN="$(mktemp --suffix .m)" OUT="$(mktemp)" cat > "$IN" gcc -w "$IN" -o "$OUT" -xobjective-c -lobjc if [ $? -eq 0 ]; then exec "$OUT" fi