1e5489553f0cc7c630cbfc40f27871b002d55047
[framework/web/wrt-installer.git] / packaging / wrt-installer.spec
1 #git:framework/web/wrt-installer wrt-installer 0.0.89
2 Name:       wrt-installer
3 Summary:    Installer for tizen Webruntime
4 Version:    0.0.89
5 Release:    1
6 Group:      Development/Libraries
7 License:    Apache License, Version 2.0
8 URL:        N/A
9 Source0:    %{name}-%{version}.tar.gz
10 Source100:  wrt-preinstall-widgets.service
11 BuildRequires:  cmake
12 BuildRequires:  edje-tools
13 BuildRequires:  pkgconfig(libxml-2.0)
14 BuildRequires:  pkgconfig(openssl)
15 BuildRequires:  pkgconfig(dpl-efl)
16 BuildRequires:  pkgconfig(cert-svc-vcore)
17 BuildRequires:  pkgconfig(dpl-event-efl)
18 BuildRequires:  pkgconfig(dpl-utils-efl)
19 BuildRequires:  pkgconfig(dpl-wrt-dao-ro)
20 BuildRequires:  pkgconfig(dpl-wrt-dao-rw)
21 BuildRequires:  pkgconfig(security-install)
22 BuildRequires:  pkgconfig(ecore-x)
23 BuildRequires:  pkgconfig(xmlsec1)
24 BuildRequires:  pkgconfig(libidn)
25 BuildRequires:  pkgconfig(libiri)
26 BuildRequires:  pkgconfig(libpcrecpp)
27 BuildRequires:  pkgconfig(pkgmgr-installer)
28 BuildRequires:  pkgconfig(pkgmgr-parser)
29 BuildRequires:  pkgconfig(pkgmgr-types)
30 BuildRequires:  pkgconfig(dlog)
31 BuildRequires:  pkgconfig(cert-svc)
32 BuildRequires:  pkgconfig(utilX)
33 BuildRequires:  pkgconfig(wrt-plugins-types)
34 BuildRequires:  pkgconfig(tapi)
35 BuildRequires:  pkgconfig(shortcut)
36 BuildRequires:  pkgconfig(dpl-encryption)
37 BuildRequires:  pkgconfig(capi-appfw-app-manager)
38 BuildRequires:  pkgconfig(drm-service-core-intel)
39 BuildRequires:  pkgconfig(app2sd)
40 Requires: xmlsec1
41
42 %description
43 Description: Wrt Installer for Tizen apps and Wac apps
44
45 %prep
46 %setup -q
47
48 %build
49
50 export LDFLAGS+="-Wl,--rpath=/usr/lib -Wl,--hash-style=both -Wl,--as-needed"
51 LDFLAGS="$LDFLAGS"
52
53 cmake . -DCMAKE_INSTALL_PREFIX=/usr \
54         -DDPL_LOG=ON \
55         -DCMAKE_PACKAGE_VERSION=%{version} \
56         -DCMAKE_BUILD_TYPE=%{?build_type:%build_type}
57 make %{?jobs:-j%jobs}
58
59 %install
60 rm -rf %{buildroot}
61 mkdir -p %{buildroot}/usr/share/license
62 cp LICENSE %{buildroot}/usr/share/license/%{name}
63 %make_install
64
65 mkdir -p %{buildroot}%{_libdir}/systemd/user
66 install -m 644 %{SOURCE100} %{buildroot}%{_libdir}/systemd/user
67 mkdir -p %{buildroot}%{_libdir}/systemd/user/tizen-mobile-session.target.wants
68 ln -s ../wrt-preinstall-widgets.service %{buildroot}%{_libdir}/systemd/user/tizen-mobile-session.target.wants
69
70 mkdir -p %{buildroot}%{_sysconfdir}/rc.d/rc3.d/
71 mkdir -p %{buildroot}%{_sysconfdir}/rc.d/rc5.d/
72 ln -s ../init.d/wrt_preinstall_widgets.sh %{buildroot}%{_sysconfdir}/rc.d/rc3.d/S46lwrt_preinstall_widgets.sh
73 ln -s ../init.d/wrt_preinstall_widgets.sh %{buildroot}%{_sysconfdir}/rc.d/rc5.d/S46lwrt_preinstall_widgets.sh
74
75 %clean
76 rm -rf %{buildroot}
77
78 %post
79 chmod +s /usr/bin/wrt-installer
80
81 #symlink for package manager
82 ln -sf /usr/bin/wrt-installer /usr/etc/package-manager/backend/wgt
83
84 #for booting recovery
85 mkdir -p /opt/share/widget/temp_info
86
87 # for downloadable Application icons path
88 mkdir -p /opt/share/icons/default/small
89
90 %files
91 %manifest wrt-installer.manifest
92 %attr(755,root,root) %{_bindir}/wrt-installer
93 %attr(775,root,root) %{_initddir}/wrt_preinstall_widgets.sh
94 %{_sysconfdir}/rc.d/rc3.d/S46lwrt_preinstall_widgets.sh
95 %{_sysconfdir}/rc.d/rc5.d/S46lwrt_preinstall_widgets.sh
96 %attr(644,root,root) %{_datadir}/edje/wrt/*
97 /usr/etc/package-manager/backendlib/libwgt.so
98 %{_datadir}/license/%{name}
99 %{_libdir}/systemd/user/tizen-mobile-session.target.wants/wrt-preinstall-widgets.service
100 %{_libdir}/systemd/user/wrt-preinstall-widgets.service