Add package signature files generation code in spec file
[apps/osp/Gallery.git] / packaging / apps.Gallery.spec
1 Name:       apps.Gallery
2 Summary:    Gallery application
3 Version:    1.0.0
4 Release:    1
5 Group:      TO_BE/FILLED_IN
6 License:    TO BE FILLED IN
7 Source0:    %{name}-%{version}.tar.gz
8 BuildRequires:  cmake
9 BuildRequires:  pkgconfig(osp-appfw)
10 BuildRequires:  pkgconfig(osp-content)
11 BuildRequires:  pkgconfig(osp-image)
12 BuildRequires:  pkgconfig(osp-image-core)
13 BuildRequires:  pkgconfig(osp-locations)
14 BuildRequires:  pkgconfig(osp-media)
15 BuildRequires:  pkgconfig(osp-net)
16 BuildRequires:  pkgconfig(osp-uifw)
17 BuildRequires:  osp-appfw-internal-devel
18 BuildRequires:  osp-image-internal-devel
19 BuildRequires:  osp-media-internal-devel
20 BuildRequires:  osp-net-internal-devel
21 BuildRequires:  osp-uifw-internal-devel
22 BuildRequires:  hash-signer
23
24 Requires: osp-installer
25
26 %description
27 Verification application: Gallery
28
29 %prep
30 %setup -q
31
32 %build
33 MAJORVER=`echo %{version} | awk 'BEGIN {FS="."}{print $1}'`
34 %ifarch %{ix86}
35 CXXFLAGS="$CXXFLAGS -D_OSP_DEBUG_ -D_OSP_X86_ -D_OSP_EMUL_" cmake . -DCMAKE_INSTALL_PREFIX=%{_prefix} -DFULLVER=%{version} -DMAJORVER=${MAJORVER}
36 %else
37 CXXFLAGS="$CXXFLAGS -D_OSP_DEBUG_ -D_OSP_ARMEL_" cmake . -DCMAKE_INSTALL_PREFIX=%{_prefix} -DFULLVER=%{version} -DMAJORVER=${MAJORVER}
38 %endif
39
40 # Call make instruction with smp support
41 make %{?jobs:-j%jobs}
42
43 %install
44 rm -rf %{buildroot}
45 %make_install
46 ###### for package signing step ######
47 PKG_ID=ijudt7w61q
48 %define tizen_sign 1
49 %define tizen_sign_base /usr/apps/${PKG_ID}
50 %define tizen_sign_level platform
51 %define tizen_author_sign 1
52 %define tizen_dist_sign 1
53
54
55 %post
56 /sbin/ldconfig
57 PKG_ID=ijudt7w61q
58 echo "/usr/etc/package-manager/backend/tpk -i /usr/apps/"${PKG_ID}
59 /usr/etc/package-manager/backend/tpk -i /usr/apps/${PKG_ID}
60 cp -f /usr/lib/osp/osp-ui-app-loader /usr/apps/${PKG_ID}/bin/Gallery
61
62 %postun
63 /sbin/ldconfig
64 PKG_ID=ijudt7w61q
65 echo "/usr/etc/package-manager/backend/tpk -u "${PKG_ID}
66 /usr/etc/package-manager/backend/tpk -u ${PKG_ID}
67
68 %files
69 %defattr(-,root,root,-)
70 /usr/apps/*