diff options
author | Youngjae Cho <y0.cho@samsung.com> | 2022-05-03 09:49:14 +0900 |
---|---|---|
committer | Youngjae Cho <y0.cho@samsung.com> | 2022-05-03 09:49:14 +0900 |
commit | e57a3f1f765c3497a97308f83c6cdcc95e9e6946 (patch) | |
tree | 097912234ce1a965da11610f66be21393dec044a | |
parent | e2175c4a9108905bfa5001d092c5bbe9e973d897 (diff) | |
download | mtp-responder-e57a3f1f765c3497a97308f83c6cdcc95e9e6946.tar.gz mtp-responder-e57a3f1f765c3497a97308f83c6cdcc95e9e6946.tar.bz2 mtp-responder-e57a3f1f765c3497a97308f83c6cdcc95e9e6946.zip |
Apply new enums for usb-gadget modesubmit/tizen/20220503.013451accepted/tizen/unified/20220505.134720
Change-Id: If65115acf949bf5631225f8ed9f577841dda0a73
Signed-off-by: Youngjae Cho <y0.cho@samsung.com>
-rw-r--r-- | CMakeLists.txt | 2 | ||||
-rw-r--r-- | packaging/mtp-responder.spec | 1 | ||||
-rw-r--r-- | src/mtp_util.c | 3 |
3 files changed, 4 insertions, 2 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt index 2e80df8..a23036d 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -11,7 +11,7 @@ SET(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} -pie") INCLUDE_DIRECTORIES(${CMAKE_SOURCE_DIR}/include) SET(REQUIRED_PKGS capi-content-media-content capi-media-metadata-extractor - capi-system-info dlog glib-2.0 libsystemd storage tapi vconf + capi-system-device capi-system-info dlog glib-2.0 libsystemd storage tapi vconf ) PKG_CHECK_MODULES(PKGS REQUIRED ${REQUIRED_PKGS}) INCLUDE_DIRECTORIES(${PKGS_INCLUDE_DIRS}) diff --git a/packaging/mtp-responder.spec b/packaging/mtp-responder.spec index fddda5d..d629c46 100644 --- a/packaging/mtp-responder.spec +++ b/packaging/mtp-responder.spec @@ -15,6 +15,7 @@ BuildRequires: cmake BuildRequires: libgcrypt-devel BuildRequires: pkgconfig(capi-content-media-content) BuildRequires: pkgconfig(capi-media-metadata-extractor) +BuildRequires: pkgconfig(capi-system-device) BuildRequires: pkgconfig(capi-system-info) BuildRequires: pkgconfig(dlog) BuildRequires: pkgconfig(glib-2.0) diff --git a/src/mtp_util.c b/src/mtp_util.c index e19f8dc..e45f820 100644 --- a/src/mtp_util.c +++ b/src/mtp_util.c @@ -37,6 +37,7 @@ #include "mtp_util_support.h" #include "mtp_util_fs.h" #include <sys/time.h> +#include <device/usb-gadget.h> /* time to wait for user session creation, in ms */ #define WAIT_FOR_USER_TIMEOUT 10000 @@ -295,7 +296,7 @@ void _util_get_usbmode_status(phone_status_t *val) return; } - if (state == SET_USB_NONE) + if (state == USB_GADGET_FUNC_NONE) *val = MTP_PHONE_USB_DISCONNECTED; else *val = MTP_PHONE_USB_CONNECTED; |