2 Summary: notification library
7 Source0: %{name}-%{version}.tar.gz
8 BuildRequires: pkgconfig(sqlite3)
9 BuildRequires: pkgconfig(db-util)
10 BuildRequires: pkgconfig(vconf)
11 BuildRequires: pkgconfig(bundle)
12 BuildRequires: pkgconfig(dbus-1)
13 BuildRequires: pkgconfig(dlog)
14 BuildRequires: pkgconfig(ail)
15 BuildRequires: pkgconfig(aul)
16 BuildRequires: pkgconfig(appsvc)
17 BuildRequires: pkgconfig(dbus-glib-1)
18 BuildRequires: pkgconfig(com-core)
19 BuildRequires: pkgconfig(capi-appfw-application)
20 BuildRequires: pkgconfig(capi-appfw-package-manager)
21 BuildRequires: pkgconfig(edbus)
22 BuildRequires: pkgconfig(elementary)
23 BuildRequires: pkgconfig(ecore)
24 BuildRequires: pkgconfig(eina)
27 Requires(post): /sbin/ldconfig
28 Requires(post): /usr/bin/sqlite3
29 requires(postun): /sbin/ldconfig
32 Client/Server library for sending notifications.
38 Summary: Notification library (devel)
39 Group: Development/Libraries
40 Requires: %{name} = %{version}-%{release}
43 Development files needed to build software that needs to system a system notification.
45 %package service-devel
46 Summary: Notification library (service-devel)
47 Group: Development/Libraries
48 Requires: %{name} = %{version}-%{release}
50 %description service-devel
51 Development files needed to build notification service
54 %if 0%{?tizen_build_binary_release_type_eng}
55 export CFLAGS="$CFLAGS -DTIZEN_ENGINEER_MODE"
56 export CXXFLAGS="$CXXFLAGS -DTIZEN_ENGINEER_MODE"
57 export FFLAGS="$FFLAGS -DTIZEN_ENGINEER_MODE"
59 %if 0%{?sec_build_binary_debug_enable}
60 export CFLAGS="$CFLAGS -DTIZEN_DEBUG_ENABLE"
61 export CXXFLAGS="$CXXFLAGS -DTIZEN_DEBUG_ENABLE"
62 export FFLAGS="$FFLAGS -DTIZEN_DEBUG_ENABLE"
64 export LDFLAGS+="-Wl,--rpath=%{_prefix}/lib -Wl,--as-needed"
65 LDFLAGS="$LDFLAGS" cmake . -DCMAKE_INSTALL_PREFIX=%{_prefix}
72 mkdir -p %{buildroot}/usr/share/license
73 cp -f LICENSE %{buildroot}/usr/share/license/%{name}
81 if [ ! -d /opt/dbspace ]
86 if [ ! -f /opt/dbspace/.notification.db ]
88 sqlite3 /opt/dbspace/.notification.db 'PRAGMA journal_mode = PERSIST;
89 create table if not exists noti_list (
90 type INTEGER NOT NULL,
91 layout INTEGER NOT NULL default 0,
92 caller_pkgname TEXT NOT NULL,
95 group_id INTEGER default 0,
96 internal_group_id INTEGER default 0,
97 priv_id INTERGER NOT NULL,
103 num_format_args INTEGER default 0,
106 time INTEGER default 0,
107 insert_time INTEGER default 0,
110 b_execute_option TEXT,
111 b_service_responding TEXT,
112 b_service_single_launch TEXT,
113 b_service_multi_launch TEXT,
114 b_event_handler_click_on_button_1 TEXT,
115 b_event_handler_click_on_button_2 TEXT,
116 b_event_handler_click_on_button_3 TEXT,
117 b_event_handler_click_on_button_4 TEXT,
118 b_event_handler_click_on_button_5 TEXT,
119 b_event_handler_click_on_button_6 TEXT,
120 b_event_handler_click_on_icon TEXT,
121 b_event_handler_click_on_thumbnail TEXT,
122 sound_type INTEGER default 0,
124 vibration_type INTEGER default 0,
126 led_operation INTEGER default 0,
127 led_argb INTEGER default 0,
128 led_on_ms INTEGER default -1,
129 led_off_ms INTEGER default -1,
130 flags_for_property INTEGER default 0,
131 flag_simmode INTEGER default 0,
132 display_applist INTEGER,
133 progress_size DOUBLE default 0,
134 progress_percentage DOUBLE default 0,
135 rowid INTEGER PRIMARY KEY AUTOINCREMENT,
136 UNIQUE (caller_pkgname, priv_id)
138 create table if not exists noti_group_data (
139 caller_pkgname TEXT NOT NULL,
140 group_id INTEGER default 0,
141 badge INTEGER default 0,
146 count_display_title INTEGER,
147 count_display_content INTEGER,
148 rowid INTEGER PRIMARY KEY AUTOINCREMENT,
149 UNIQUE (caller_pkgname, group_id)
151 create table if not exists ongoing_list (
152 caller_pkgname TEXT NOT NULL,
155 group_id INTEGER default 0,
156 internal_group_id INTEGER default 0,
157 priv_id INTERGER NOT NULL,
160 default_content TEXT,
163 loc_default_content TEXT,
168 flag INTEGER default 0,
169 progress_size DOUBLE default 0,
170 progress_percentage DOUBLE default 0,
171 rowid INTEGER PRIMARY KEY AUTOINCREMENT,
172 UNIQUE (caller_pkgname, priv_id)
174 CREATE TABLE IF NOT EXISTS notification_setting (
175 priv_id INTERGER PRIMARY KEY,
176 package_name TEXT NOT NULL,
177 allow_to_notify INTEGER DEFAULT 1,
178 do_not_disturb_except INTEGER DEFAULT 0,
179 visibility_class INTEGER DEFAULT 0,
180 UNIQUE (priv_id, package_name)
182 CREATE TABLE IF NOT EXISTS notification_system_setting (
183 priv_id INTERGER PRIMARY KEY,
184 do_not_disturb INTEGER DEFAULT 0,
185 visibility_class INTEGER DEFAULT 0,
186 UNIQUE (priv_id, package_name)
189 INSERT INTO notification_setting (priv_id, package_name, allow_to_notify, do_not_disturb_except, visibility_class) VALUES (1, "org.tizen.photos", 1, 0, 0);
190 INSERT INTO notification_setting (priv_id, package_name, allow_to_notify, do_not_disturb_except, visibility_class) VALUES (2, "org.tizen.email", 1, 0, 0);
191 INSERT INTO notification_setting (priv_id, package_name, allow_to_notify, do_not_disturb_except, visibility_class) VALUES (3, "org.tizen.message", 1, 0, 0);
192 INSERT INTO notification_setting (priv_id, package_name, allow_to_notify, do_not_disturb_except, visibility_class) VALUES (4, "org.tizen.internet", 1, 0, 0);
193 INSERT INTO notification_setting (priv_id, package_name, allow_to_notify, do_not_disturb_except, visibility_class) VALUES (5, "org.tizen.games", 1, 0, 0);
194 INSERT INTO notification_system_setting (do_not_disturb, visibility_class) VALUES (0, 0, 0);
196 CREATE UNIQUE INDEX package_name_idx1 ON notification_setting (package_name);
200 chown :5000 /opt/dbspace/.notification.db
201 chown :5000 /opt/dbspace/.notification.db-journal
202 chmod 644 /opt/dbspace/.notification.db
203 chmod 644 /opt/dbspace/.notification.db-journal
204 if [ -f /usr/lib/rpm-plugins/msm.so ]
206 chsmack -a 'notification::db' /opt/dbspace/.notification.db*
208 SMACK_OPTION="-s system::vconf_misc"
209 vconftool set -t string memory/private/libstatus/message "" -i -g 5000 -f $SMACK_OPTION
211 %postun -p /sbin/ldconfig
214 %manifest notification.manifest
215 %defattr(-,root,root,-)
216 %{_libdir}/libnotification.so*
217 /usr/share/license/%{name}
220 %defattr(-,root,root,-)
221 %{_includedir}/notification/notification.h
222 %{_includedir}/notification/notification_internal.h
223 %{_includedir}/notification/notification_error.h
224 %{_includedir}/notification/notification_type.h
225 %{_includedir}/notification/notification_list.h
226 %{_includedir}/notification/notification_ongoing_flag.h
227 %{_includedir}/notification/notification_status.h
228 %{_includedir}/notification/notification_status_internal.h
229 %{_includedir}/notification/notification_setting.h
230 %{_includedir}/notification/notification_setting_internal.h
231 %{_libdir}/pkgconfig/notification.pc
234 %defattr(-,root,root,-)
235 %{_includedir}/notification/service/notification_ipc.h
236 %{_includedir}/notification/service/notification_noti.h
237 %{_includedir}/notification/service/notification_setting_service.h
238 %{_libdir}/pkgconfig/notification-service.pc