d0a332c50dd5311410911e4652c36811acd68247
[scm/bb/meta-tizen.git] / meta-tizen-ivi / recipes-framework / notification / notification.inc
1 DESCRIPTION = "Notification Library"
2 HOMEPAGE = "http://nohomepage.org"
3 SECTION = "System/API"
4 LICENSE = "Apache-2.0"
5 PV = "0.2.3"
6
7 SRC_URI = ""
8
9 S = "${WORKDIR}/git"
10
11 inherit manifest autotools-brokensep
12
13 BBCLASSEXTEND = ""
14 PROVIDES = ""
15
16 #PROVIDES by notification-service-dev
17 PROVIDES += "notification-service-dev"
18
19
20 #PROVIDES by notification
21
22
23 #PROVIDES by notification-dev
24 PROVIDES += "notification-dev"
25
26
27 RDEPENDS = ""
28 #RDEPENDS of notification-service-dev (${PN}-service-dev)
29 RDEPENDS_${PN}-service-dev += "notification"
30
31 #RDEPENDS of notification (${PN})
32 RDEPENDS_${PN} += "sqlite3"
33 RDEPENDS_${PN} += "glibc"
34 RDEPENDS_${PN} += "libtzplatform-config"
35
36 #RDEPENDS of notification-dev (${PN}-dev)
37 RDEPENDS_${PN}-dev += "notification"
38
39
40 DEPENDS = ""
41 #DEPENDS of notification
42 inherit tizen_cmake
43 DEPENDS += "dbus-glib"
44 DEPENDS += "eina"
45 DEPENDS += "dbus"
46 DEPENDS += "app-svc"
47 DEPENDS += "tizen-platform-config"
48 inherit pkgconfig
49 DEPENDS += "bundle"
50 DEPENDS += "aul"
51 DEPENDS += "ail"
52 DEPENDS += "dlog"
53 DEPENDS += "ecore"
54 DEPENDS += "sqlite3"
55 DEPENDS += "heynoti"
56 DEPENDS += "libcom-core"
57 DEPENDS += "vconf"
58 DEPENDS += "libslp-db-util"
59
60 do_prep() {
61  cd ${S}
62  chmod -Rf a+rX,u+w,g-w,o-w ${S}
63  #setup -q
64  cp ${S}/packaging/notification.manifest .
65  
66  
67 }
68 do_patch_append() {
69     bb.build.exec_func('do_prep', d)
70 }
71
72 do_configure() {
73 }
74
75 do_compile() {
76  cd ${S}
77  LANG=C
78  export LANG
79  unset DISPLAY
80  LD_AS_NEEDED=1; export LD_AS_NEEDED ;
81  
82  
83    cmake \
84          -DCMAKE_VERBOSE_MAKEFILE=ON \
85          -DCMAKE_INSTALL_PREFIX:PATH=${prefix} \
86          -DCMAKE_INSTALL_LIBDIR:PATH=${prefix}/lib \
87          -DINCLUDE_INSTALL_DIR:PATH=${prefix}/include \
88          -DLIB_INSTALL_DIR:PATH=${prefix}/lib \
89          -DSYSCONF_INSTALL_DIR:PATH=${sysconfdir} \
90          -DSHARE_INSTALL_PREFIX:PATH=${prefix}/share \
91          -DCMAKE_SKIP_RPATH:BOOL=ON \
92          -DBUILD_SHARED_LIBS:BOOL=ON \
93          -DCMAKE_TOOLCHAIN_FILE=${WORKDIR}/toolchain.cmake \
94          ${EXTRA_OECMAKE} .
95  make -j16
96  
97  
98  
99 }
100
101 do_install() {
102  export RPM_BUILD_ROOT=${D}
103  cd ${S}
104  LANG=C
105  export LANG
106  unset DISPLAY
107  rm -rf ${D}
108  mkdir -p ${D}
109  
110  rm -rf ${D}
111  
112    oe_runmake \
113          DESTDIR=${D} \
114          INSTALL_ROOT=${D} \
115          BINDIR=${prefix}/bin \
116    install  
117    rm -f ${D}${infodir}/dir 
118    find ${D} -regex ".*\.la$" | xargs rm -f -- 
119    find ${D} -regex ".*\.a$" | xargs rm -f --
120  
121  mkdir -p ${D}/usr/share/license
122  cp -f LICENSE.APLv2.0 ${D}/usr/share/license/notification
123  
124  
125 }
126
127 pkg_postinst_${PN}() {
128     #!/bin/sh -e
129
130     [ "x$D" == "x" ] && ldconfig
131     $D${prefix}/share/notification/notification_DB_init.sh
132
133 }
134
135 pkg_postrm_${PN}() {
136     #!/bin/sh -e
137
138     [ "x$D" == "x" ] && ldconfig
139 }
140
141 PACKAGES = "${PN}-dbg ${PN}-doc ${PN}-locale"
142 PACKAGES += " notification-service-dev "
143 PACKAGES += " notification "
144 PACKAGES += " notification-dev "
145
146 notification-service-dev_files = ""
147 notification-service-dev_files += "${prefix}/include/notification/service/notification_ipc.h"
148 notification-service-dev_files += "${prefix}/include/notification/service/notification_noti.h"
149 notification-service-dev_files += "${prefix}/include/notification/service/notification_setting_service.h"
150 notification-service-dev_files += "${prefix}/lib/pkgconfig/notification-service.pc"
151
152 notification_files = ""
153 notification_files += "${prefix}/lib/libnotification.so*"
154 notification_files += "${prefix}/share/notification/notification_DB_init.sh"
155 notification_files += "/usr/share/license/notification"
156 MANIFESTFILES_${PN} = "notification.manifest"
157
158 notification-dev_files = ""
159 notification-dev_files += "${prefix}/include/notification/notification.h"
160 notification-dev_files += "${prefix}/include/notification/notification_error.h"
161 notification-dev_files += "${prefix}/include/notification/notification_type.h"
162 notification-dev_files += "${prefix}/include/notification/notification_list.h"
163 notification-dev_files += "${prefix}/include/notification/notification_status.h"
164 notification-dev_files += "${prefix}/include/notification/notification_setting.h"
165 notification-dev_files += "${prefix}/lib/pkgconfig/notification.pc"
166
167 FILES_${PN}-service-dev = "${notification-service-dev_files}"
168 FILES_${PN} = "${notification_files}"
169 FILES_${PN}-dev = "${notification-dev_files}"
170
171 PKG_notification-service-dev= "notification-service-dev"
172 PKG_notification= "notification"
173 PKG_notification-dev= "notification-dev"
174
175 require notification-extraconf.inc
176