Files
android_development/tools/eclipse/scripts/create_adt_symlinks.sh
raphael 991c4bdd4d Fix eclipse setup scripts.
The fix will work for Linux and Mac, however for Windows the DDMS icons will have an invalid path.
I can address the Windows DDMS issue in a next CL if necessary by merging in a different
CL from upstream.
2008-12-03 21:13:12 -08:00

45 lines
1009 B
Bash
Executable File

#!/bin/bash
function die() {
echo "Error: $*"
exit 1
}
set -e # fail early
# CD to the top android directory
D=`dirname "$0"`
cd "$D/../../../../"
DEST="development/tools/eclipse/plugins/com.android.ide.eclipse.adt"
# computes "../.." from DEST to here (in /android)
BACK=`echo $DEST | sed 's@[^/]*@..@g'`
LIBS="jarutils androidprefs"
echo "make java libs ..."
make -j3 showcommands $LIBS || die "Fail to build one of $LIBS."
echo "Copying java libs to $DEST"
HOST=`uname`
if [ "$HOST" == "Linux" ]; then
for LIB in $LIBS; do
ln -svf $BACK/out/host/linux-x86/framework/$LIB.jar "$DEST/"
done
elif [ "$HOST" == "Darwin" ]; then
for LIB in $LIBS; do
ln -svf $BACK/out/host/darwin-x86/framework/$LIB.jar "$DEST/"
done
elif [ "${HOST:0:6}" == "CYGWIN" ]; then
for LIB in $LIBS; do
cp -vf $BACK/out/host/windows-x86/framework/$LIB.jar "$DEST/"
done
chmod -v a+rx "$DEST"/*.jar
else
echo "Unsupported platform ($HOST). Nothing done."
fi