eval "$(
  declare -f package \
  | sed '
    /\$CARCH/ {
      h
      s/^/[ "$CARCH" = pentium4 ] || /
      p
      g
      s/\$CARCH/i686/g
      s/^/[ "$CARCH" != pentium4 ] || /
    }
  '
)"