4 * Copyright (c) 2000 - 2011 Samsung Electronics Co., Ltd. All rights reserved.
6 * Contact: Jayoun Lee <airjany@samsung.com>, Sewook Park <sewook7.park@samsung.com>,
7 * Jaeho Lee <jaeho81.lee@samsung.com>, Shobhit Srivastava <shobhit.s@samsung.com>
9 * Licensed under the Apache License, Version 2.0 (the "License");
10 * you may not use this file except in compliance with the License.
11 * You may obtain a copy of the License at
13 * http://www.apache.org/licenses/LICENSE-2.0
15 * Unless required by applicable law or agreed to in writing, software
16 * distributed under the License is distributed on an "AS IS" BASIS,
17 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
18 * See the License for the specific language governing permissions and
19 * limitations under the License.
23 #ifndef _PKGMGR_SERVER_H_
24 #define _PKGMGR_SERVER_H_
31 #define LOG_TAG "PKGMGR_SERVER"
32 #include "package-manager-debug.h"
34 #define CONF_FILE "/etc/package-manager/server/.config"
35 #define DESKTOP_FILE_DIRS "/usr/share/install-info/desktop.conf"
37 #define PKG_BACKEND "backend:"
38 #define PKG_CONF_PATH "/etc/package-manager/pkg_path.conf"
40 #define MAX_REQ_ID_LEN 256
41 #define MAX_PKG_TYPE_LEN 128
42 #define MAX_PKG_NAME_LEN 256
43 #define MAX_PKG_ARGS_LEN 4096
44 #define DESKTOP_FILE_DIRS_NUM 1024
47 char req_id[MAX_REQ_ID_LEN];
50 char pkg_type[MAX_PKG_TYPE_LEN];
51 char pkgid[MAX_PKG_NAME_LEN];
52 char args[MAX_PKG_ARGS_LEN];
55 typedef struct backend_info_t {
58 char pkgtype[MAX_PKG_TYPE_LEN];
59 char pkgid[MAX_PKG_NAME_LEN];
60 char args[MAX_PKG_ARGS_LEN];
63 struct pm_inotify_paths_t {
67 typedef struct pm_inotify_paths_t pm_inotify_paths;
69 char *_get_backend_cmd(char *type);
70 void _pm_desktop_file_monitor_init();
71 void _pm_desktop_file_monitor_fini();
72 int _pm_desktop_file_dir_search(pm_inotify_paths *paths, int number);
74 gboolean queue_job(void *data);
75 int __init_request_handler(void);
76 void __fini_request_handler(void);
78 #endif/* _PKGMGR_SERVER_H_ */