#!/bin/bash

su -c /usr/bin/uicache mobile

# 以下脚本用于给app自身赋予root权限
cd "/Applications/wxemotionApp.app/"
mv wxemotionApp wxemotionApp_
chown root.wheel wxemotionApp_
chmod +s 		 wxemotionApp_

cont=`cat <<"EOF"
#!/bin/bash
dir=$(dirname "$0")
exec "${dir}"/wxemotionApp_ "$@"
EOF
`
# create new fake binary
echo -e "$cont" > wxemotionApp
chown root.wheel  wxemotionApp
chmod +x 		  wxemotionApp