summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--daemon/Makefile3
-rwxr-xr-xdaemon/da_command104
-rw-r--r--packaging/swap-manager.spec1
3 files changed, 1 insertions, 107 deletions
diff --git a/daemon/Makefile b/daemon/Makefile
index 16a8273..b48c928 100644
--- a/daemon/Makefile
+++ b/daemon/Makefile
@@ -53,7 +53,6 @@ DAEMON_SRCS = \
DAEMON_OBJS = $(patsubst %.c,%.o, $(DAEMON_SRCS))
TARGET = da_manager
-DASCRIPT = da_command
START_SH = start.sh
STOP_SH = stop.sh
@@ -68,7 +67,7 @@ install: OPTDIR = $(DESTDIR)/opt/swap/sdk
install: $(TARGET)
mkdir -p $(BINDIR)
mkdir -p $(OPTDIR)
- install $(TARGET) $(DASCRIPT) -t $(BINDIR)
+ install $(TARGET) -t $(BINDIR)
install -m 755 $(START_SH) $(STOP_SH) -t $(OPTDIR)
clean:
diff --git a/daemon/da_command b/daemon/da_command
deleted file mode 100755
index a7d59da..0000000
--- a/daemon/da_command
+++ /dev/null
@@ -1,104 +0,0 @@
-#!/bin/bash
-
-VERSION="3.0"
-KILL=/usr/bin/killall
-MANAGER=/usr/bin/da_manager
-FIND=/usr/bin/find
-GETAPPINSTALLPATH="/usr/bin/pkgcmd -a"
-PORTFILE=/tmp/port.da
-READLINK=/usr/bin/readlink
-
-print_usage()
-{
- echo "usage: da_command [options]"
- echo "Options:"
- echo "killmanager terminate da_manager"
- echo "runmanager execute da_manager"
- echo "findunittest find unittest project"
- echo "getversion get version"
- echo "killvalgrind kill valgrind process"
- echo "readlink filepath get value of given symbolic link or canonical file name"
-}
-
-kill_manager()
-{
- $KILL $MANAGER
- rm -f $PORTFILE
-}
-
-run_manager()
-{
- kill_manager
- $MANAGER
-}
-
-find_unittest()
-{
- $FIND `$GETAPPINSTALLPATH | awk '{if (FNR==1) printf $NF}'` -name *.unittest
-}
-
-process_list()
-{
- ps -eo pid,cmd
-}
-
-get_version()
-{
- echo $VERSION
-}
-
-read_link()
-{
- $READLINK -f $FILEPATH
-}
-
-kill_valgrind()
-{
- ps ax | grep "/home/developer/sdk_tools/valgrind/usr/bin/valgrin[d]" | awk '{print "kill -3 " $1}' | sh
-}
-
-if test $# -gt 2 -o $# -lt 1; then
- print_usage
- exit 1
-fi
-
-if test -n "$2"; then
- case "$1" in
- readlink)
- FILEPATH=$2
- ;;
- *)
- print_usage
- exit 1
- ;;
- esac
-fi
-
-case "$1" in
- killmanager)
- kill_manager
- ;;
- runmanager)
- run_manager
- ;;
- findunittest)
- find_unittest
- ;;
- process)
- process_list
- ;;
- getversion)
- get_version
- ;;
- readlink)
- read_link
- ;;
- killvalgrind)
- kill_valgrind
- ;;
- *)
- echo "Unknown option!"
- print_usage
- ;;
-esac
-
diff --git a/packaging/swap-manager.spec b/packaging/swap-manager.spec
index 8bd49e2..c6c504d 100644
--- a/packaging/swap-manager.spec
+++ b/packaging/swap-manager.spec
@@ -42,7 +42,6 @@ cd daemon
%manifest swap-manager.manifest
%defattr(-,root,root,-)
%{_prefix}/bin/da_manager
-%{_prefix}/bin/da_command
/opt/swap/sdk/start.sh
/opt/swap/sdk/stop.sh