because of restructuring directories, relative path of sdb changed.
Change-Id: Ib5150ccd9909e02e5c300e5e9a72cb5292820c05
Signed-off-by: Munkyu Im <munkyu.im@samsung.com>
#!/bin/sh
-if [ "$1" == "" ];
+if [ "$#" -ne 2 ];
then
- echo "There is no emulator name for an argument. \nusage: sdbscript emulator-261xx"
- exit -1
-else
- TITLE=$1
- osascript > /dev/null << END
- tell application "Terminal"
- activate
- do script "`pwd`/../../sdb -s $TITLE shell"
- set custom title of first window to "$TITLE"
- end tell
-END
+ echo "usage: sdbscript \${SDB_PATH} emulator-261xx"
+ exit 1
fi
+
+TITLE=$2
+osascript > /dev/null << END
+tell application "Terminal"
+activate
+do script "$1 -s $TITLE shell"
+set custom title of first window to "$TITLE"
+end tell
+END
procSdb.command("cmd.exe", "/c", "start", sdbPath, "sdb",
"-s", "emulator-" + portSdb, "shell");
} else if (SwtUtil.isMacPlatform()) {
- procSdb.command("./sdbscript", "emulator-" + portSdb);
+ procSdb.command("./sdbscript", sdbPath, "emulator-" + portSdb);
/*
* procSdb.command( "/usr/X11/bin/uxterm", "-T", "emulator-"
* + portSdb, "-e", sdbPath, "shell");
}
public static String getSdbPath() {
- String sdbPath = null;
-
+ StringBuilder sdbPath = new StringBuilder(".." + File.separator + ".."
+ + File.separator + ".." + File.separator + ".."
+ + File.separator + ".." + File.separator + "tools"
+ + File.separator);
if (SwtUtil.isWindowsPlatform()) {
- sdbPath = "..\\..\\ansicon.exe";
+ sdbPath.append("ansicon.exe");
} else {
- sdbPath = "../../sdb";
+ sdbPath.append("sdb");
}
- return (binaryPath + sdbPath);
+ return (binaryPath + sdbPath.toString());
}
public static String getEcpPath() {
QString sdbPath = QCoreApplication::applicationDirPath();
#ifdef CONFIG_WIN32
- sdbPath += "\\..\\..\\ansicon.exe";
+ sdbPath += "\\..\\..\\..\\..\\..\\tools\\ansicon.exe";
#else
- sdbPath += "/../../sdb";
+ sdbPath += "/../../../../../tools/sdb";
#endif
QFileInfo sdbFileInfo(sdbPath);
arguments << "/c" << "start" << sdbPath << "sdb" << "-s" << sdbSerialName << "shell";
#elif defined CONFIG_DARWIN
command = QCoreApplication::applicationDirPath() + "/sdbscript";
- arguments << sdbSerialName;
+ arguments << sdbPath << sdbSerialName;
#else
command = "/usr/bin/gnome-terminal";
QString title = "--title=" + vmName;