Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion INSTALL
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ set -e -o pipefail

BASE=$(dirname "$(readlink -f "${BASH_SOURCE[0]}")")

if [ "$(uname -o)" = "Darwin" ]; then
if [ "$(uname -s)" = "Darwin" ]; then
DISTRIB=macOS
else
DISTRIB=$(cat /etc/lsb-release | grep "DISTRIB_ID" | awk -F "=" '{print $2}')
Expand Down
2 changes: 1 addition & 1 deletion aml-flash-tool/INSTALL
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ set -e -o pipefail

BASE=$(dirname "$(readlink -f "${BASH_SOURCE[0]}")")

if [ "$(uname -o)" = "Darwin" ]; then
if [ "$(uname -s)" = "Darwin" ]; then
DISTRIB=macOS
else
DISTRIB=$(cat /etc/lsb-release | grep "DISTRIB_ID" | awk -F "=" '{print $2}')
Expand Down
2 changes: 1 addition & 1 deletion aml-flash-tool/UNINSTALL
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ set -e -o pipefail

BASE=$(dirname "$(readlink -f "${BASH_SOURCE[0]}")")

if [ "$(uname -o)" = "Darwin" ]; then
if [ "$(uname -s)" = "Darwin" ]; then
DISTRIB=macOS
else
DISTRIB=$(cat /etc/lsb-release | grep "DISTRIB_ID" | awk -F "=" '{print $2}')
Expand Down
6 changes: 3 additions & 3 deletions aml-flash-tool/aml-burn-tool
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ BASE=$(dirname "$(readlink -f "${BASH_SOURCE[0]}")")
FLASH_TOOL="$BASE/flash-tool"
KHADAS_TOOL="/usr/local/bin/$(basename $0)"

if [ "$(uname -o)" = "Darwin" ]; then
if [ "$(uname -s)" = "Darwin" ]; then
ADNL_TOOL="$BASE/tools/adnl/macos/adnl_burn_pkg"
else
ADNL_TOOL="$BASE/tools/adnl/adnl_burn_pkg"
Expand Down Expand Up @@ -93,7 +93,7 @@ if [ -z "$BOARD" ]; then
BOARD="VIM1"
fi

if [ "$(uname -o)" = "Darwin" ]; then
if [ "$(uname -s)" = "Darwin" ]; then
if fdisk -t "$IMAGE" && ! fdisk -d "$IMAGE" | grep -q 0xEE; then
IMAGE_INSTALL_TYPE="SD-USB"
else
Expand Down Expand Up @@ -129,7 +129,7 @@ else
exit -1
fi

if [ "$(uname -o)" = "Darwin" ]; then
if [ "$(uname -s)" = "Darwin" ]; then
if ! ioreg -p IOUSB -l | grep -q "Amlogic" > /dev/null; then
error_msg "You should put your board enter upgrade mode!"
exit -1
Expand Down
2 changes: 1 addition & 1 deletion aml-flash-tool/flash-tool
Original file line number Diff line number Diff line change
Expand Up @@ -201,7 +201,7 @@ done

# Testing host machine
# --------------------
host_os=`uname -o`
host_os=`uname -s`
host_machine=`uname -m|grep -i "x86"`
if [ ! -z "$host_os" ]; then
if [ "$host_os" = "Darwin" ]; then
Expand Down
2 changes: 1 addition & 1 deletion rk-flash-tool/INSTALL
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ set -e -o pipefail

BASE=$(dirname "$(readlink -f "${BASH_SOURCE[0]}")")

if [ "$(uname -o)" = "Darwin" ]; then
if [ "$(uname -s)" = "Darwin" ]; then
ANDROID_TOOL_CONFIG="$BASE/tools/macos_upgrade_tool/config.ini"
DISTRIB=macOS
else
Expand Down
2 changes: 1 addition & 1 deletion rk-flash-tool/UNINSTALL
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ set -e -o pipefail

BASE=$(dirname "$(readlink -f "${BASH_SOURCE[0]}")")

if [ "$(uname -o)" = "Darwin" ]; then
if [ "$(uname -s)" = "Darwin" ]; then
DISTRIB=macOS
else
DISTRIB=$(cat /etc/lsb-release | grep "DISTRIB_ID" | awk -F "=" '{print $2}')
Expand Down
8 changes: 4 additions & 4 deletions rk-flash-tool/rk-burn-tool
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ set -e -o pipefail

BASE=$(dirname "$(readlink -f "${BASH_SOURCE[0]}")")

if [ "$(uname -o)" = "Darwin" ]; then
if [ "$(uname -s)" = "Darwin" ]; then
ANDROID_TOOL="$BASE/tools/macos_upgrade_tool/upgrade_tool"
else
ANDROID_TOOL="$BASE/tools/Linux_Upgrade_Tool/upgrade_tool"
Expand Down Expand Up @@ -79,7 +79,7 @@ case $IMAGE in
;;
esac

if [ "$(uname -o)" = "Darwin" ] ; then
if [ "$(uname -s)" = "Darwin" ] ; then
if fdisk -t "$IMAGE" && ! fdisk -d "$IMAGE" | grep -q 0xEE; then
IMAGE_INSTALL_TYPE="SD-USB"
else
Expand Down Expand Up @@ -115,7 +115,7 @@ else
exit -1
fi

if [ "$(uname -o)" = "Darwin" ] ; then
if [ "$(uname -s)" = "Darwin" ] ; then
if ! ioreg -p IOUSB -l -x | grep idVendor | grep -q 2207 || ! ioreg -p IOUSB -l -x | grep idProduct | grep -q "330c\|350b"; then
error_msg "You should put your board enter upgrade mode!"
exit -1
Expand All @@ -129,7 +129,7 @@ else

echo "Burn to eMMC..."

if [ "$(uname -o)" = "Darwin" ] && fdisk -t "$IMAGE" && fdisk -d "$IMAGE" | grep -q 0xEE ; then
if [ "$(uname -s)" = "Darwin" ] && fdisk -t "$IMAGE" && fdisk -d "$IMAGE" | grep -q 0xEE ; then
error_msg "Flashing raw gpt image is currently not supported on mac OS. Please try flashing via oowow instead."
exit -1
elif parted -s "$IMAGE" p 2> /dev/null | grep -q rootfs 2> /dev/null; then
Expand Down
2 changes: 1 addition & 1 deletion tone-dfu-tool/INSTALL
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ set -e -o pipefail

BASE=$(dirname "$(readlink -f "${BASH_SOURCE[0]}")")

if [ "$(uname -o)" = "Darwin" ] ; then
if [ "$(uname -s)" = "Darwin" ] ; then
DISTRIB=macOS
else
DISTRIB=$(cat /etc/lsb-release | grep "DISTRIB_ID" | awk -F "=" '{print $2}')
Expand Down
2 changes: 1 addition & 1 deletion tone-dfu-tool/UNINSTALL
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ set -e -o pipefail

BASE=$(dirname "$(readlink -f "${BASH_SOURCE[0]}")")

if [ "$(uname -o)" = "Darwin" ] ; then
if [ "$(uname -s)" = "Darwin" ] ; then
DISTRIB=macOS
else
DISTRIB=$(cat /etc/lsb-release | grep "DISTRIB_ID" | awk -F "=" '{print $2}')
Expand Down
4 changes: 2 additions & 2 deletions tone-dfu-tool/tone-burn-tool
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ set -e -o pipefail

BASE=$(dirname "$(readlink -f "${BASH_SOURCE[0]}")")

if [ "$(uname -o)" = "Darwin" ] ; then
if [ "$(uname -s)" = "Darwin" ] ; then
BURN_TOOL="$BASE/tools/macos/tone_dfu_tool"
else
BURN_TOOL="$BASE/tools/`uname -i`/tone_dfu_tool"
Expand Down Expand Up @@ -52,7 +52,7 @@ if [ ! -f "$IMAGE" ]; then
exit 1
fi

if [ "$(uname -o)" = "Darwin" ]; then
if [ "$(uname -s)" = "Darwin" ]; then
if ! ioreg -p IOUSB -l -x | grep idVendor | grep -q "${KHADAS_USB_VID}\|${KHADAS_USB_XMOS_VID}"; then
error_msg "You should connect the Tone to your computer!"
exit -1
Expand Down