9f2c79ad1db68b4b0a4e1d19572058c335a06beb
[AGL/meta-agl-demo.git] / recipes-wam / wam / wam_git.bb
1 SUMMARY = "WAM"
2 AUTHOR = "Jani Hautakangas <jani.hautakangas@lge.com>"
3 LICENSE = "Apache-2.0"
4 LIC_FILES_CHKSUM = "file://${COMMON_LICENSE_DIR}/Apache-2.0;md5=89aea4e17d99a7cacdbeed46a0096b10"
5
6 DEPENDS = "glib-2.0 jsoncpp boost protobuf protobuf-native grpc grpc-native"
7
8 SRC_URI = "\
9     git://github.com/igalia/${BPN}.git;branch=@58.agl;protocol=https \
10     file://WebAppMgrCli \
11     file://WebAppMgr.service \
12     file://WebAppMgr.env \
13     file://WebAppMgr-cef.env \
14 "
15
16 SRCREV = "4fbd6e648913bcf0fba63e4460eb44242c11f71b"
17
18 PV = "ose58.agl"
19
20 S = "${WORKDIR}/git"
21
22 inherit cmake pkgconfig systemd
23
24 # Disable some of security flags
25 # Disable D_FORTIFY_SOURCE=2 and -fstack-protector-strong
26 # Refer conf/distro/include/security_flags.inc in meta-webos/conf/distro/include/webos.inc
27 lcl_maybe_fortify = ""
28 SECURITY_STACK_PROTECTOR = ""
29
30 SYSTEMD_SERVICE:${PN} = "WebAppMgr.service"
31
32 do_install:append() {
33     install -v -d ${D}${sysconfdir}/wam
34     install -v -m 644 ${S}/files/launch/security_policy.conf ${D}${sysconfdir}/wam/security_policy.conf
35     install -v -D -m 644 ${WORKDIR}/WebAppMgr.service ${D}${systemd_system_unitdir}/WebAppMgr.service
36     install -v -D -m 755 ${WORKDIR}/WebAppMgrCli ${D}${bindir}/WebAppMgrCli
37 }
38
39 CXXFLAGS:append:agl-devel = " -DAGL_DEVEL"
40
41 do_install:append:agl-devel() {
42     # Enable remote inspector and dev mode
43     install -d ${D}${localstatedir}/agl-devel/preferences
44     touch ${D}${localstatedir}/agl-devel/preferences/debug_system_apps
45     touch ${D}${localstatedir}/agl-devel/preferences/devmode_enabled
46 }
47
48 require wam-cef.inc
49
50 FILES:${PN} += "${sysconfdir}/init \
51                 ${sysconfdir}/wam \
52                 ${bindir} \
53                 ${libdir}/webappmanager/plugins/*.so"
54
55 RDEPENDS:${PN} += " bash"
56
57 PROVIDES += "virtual/webruntime"
58 RPROVIDES:${PN} += "virtual/webruntime"