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