From: Sunwook Bae Date: Wed, 21 Aug 2013 07:30:13 +0000 (+0900) Subject: Update to use the aul api instead of app-manager X-Git-Tag: submit/tizen/20130905.074124~1^2~1 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=43221f752e04eaed04ec926fba07c0340d94c36d;p=platform%2Fcore%2Fappfw%2Fmessage-port.git Update to use the aul api instead of app-manager Change-Id: I976ab3deae12bbcf14d5a79e4a4551e2c9a24d3b Signed-off-by: Sunwook Bae --- diff --git a/CMakeLists.txt b/CMakeLists.txt index 7eedc89..150a797 100755 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -25,7 +25,7 @@ SET (${this_target}_SOURCE_FILES src/MessagePortProxy.cpp ) -SET(requires "dlog bundle glib-2.0 chromium") +SET(requires "dlog bundle glib-2.0 aul chromium") INCLUDE(FindPkgConfig) pkg_check_modules(${this_target} REQUIRED ${requires}) @@ -59,7 +59,7 @@ TARGET_LINK_LIBRARIES(${this_target} "-ldlog" ) TARGET_LINK_LIBRARIES(${this_target} "-lbundle" ) TARGET_LINK_LIBRARIES(${this_target} "-lglib-2.0" ) TARGET_LINK_LIBRARIES(${this_target} "-lchromium" ) -TARGET_LINK_LIBRARIES(${this_target} "-lcapi-appfw-app-manager" ) +TARGET_LINK_LIBRARIES(${this_target} "-laul" ) SET_TARGET_PROPERTIES(${this_target} PROPERTIES diff --git a/message-port.pc.in b/message-port.pc.in index ec7cdb8..bd7816a 100755 --- a/message-port.pc.in +++ b/message-port.pc.in @@ -4,7 +4,7 @@ prefix=@PREFIX@ exec_prefix=/usr libdir=@LIB_INSTALL_DIR@ -includedir=/usr/include/appfw +includedir=@INCLUDE_INSTALL_DIR@/appfw Name: @PC_NAME@ Description: @PACKAGE_DESCRIPTION@ diff --git a/packaging/message-port.spec b/packaging/message-port.spec index 36b375e..899608e 100755 --- a/packaging/message-port.spec +++ b/packaging/message-port.spec @@ -10,7 +10,7 @@ BuildRequires: pkgconfig(dlog) BuildRequires: pkgconfig(bundle) BuildRequires: pkgconfig(glib-2.0) BuildRequires: pkgconfig(chromium) -BuildRequires: pkgconfig(capi-appfw-app-manager) +BuildRequires: pkgconfig(aul) # runtime requires Requires: chromium diff --git a/src/MessagePortProxy.cpp b/src/MessagePortProxy.cpp index 24abd93..0ff878d 100644 --- a/src/MessagePortProxy.cpp +++ b/src/MessagePortProxy.cpp @@ -26,7 +26,7 @@ #include #include -#include +#include #include "message-port.h" #include "message-port-messages.h" @@ -93,18 +93,17 @@ MessagePortProxy::Construct(void) __pIpcClient = pIpcClient; int pid = getpid(); - char* pAppId = NULL; - ret = app_manager_get_app_id(pid, &pAppId); - if (ret < 0) + char buffer[256] = {0, }; + + ret = aul_app_get_appid_bypid(pid, buffer, sizeof(buffer)); + if (ret != AUL_R_OK) { - _LOGE("Failed to get_app_id: %d", ret); + _LOGE("Failed to get the application ID: %d", ret); return MESSAGEPORT_ERROR_IO_ERROR; } - __appId = pAppId; - - free(pAppId); + __appId = buffer; return MESSAGEPORT_ERROR_NONE; }