10732499a2edafad23cba2748796d47719906beb
[platform/core/security/libcryptsvc.git] / packaging / libcryptsvc.spec
1 Name:      libcryptsvc
2 Summary:    Crypto Service Library
3 Version:    0.0.1
4 Release:    6
5 Group:      Security/Libraries
6 License:    Apache-2.0
7 Source0:    %{name}-%{version}.tar.gz
8 Source1001:     libcryptsvc.manifest
9 BuildRequires: cmake
10 BuildRequires: pkgconfig(dlog)
11 BuildRequires: pkgconfig(openssl)
12
13 %description
14 Crypto Service Library.
15
16 %package devel
17 Summary:    Crypto Service Library (Development)
18 Group:      Security/Libraries
19 Requires: %{name} = %{version}-%{release}
20
21 %description devel
22 Crypto Service Library (Development).
23
24 %prep
25 %setup -q
26 cp %{SOURCE1001} .
27
28 %build
29 MAJORVER=`echo %{version} | awk 'BEGIN {FS="."}{print $1}'`
30 %ifarch %ix86 x86_64
31 %cmake . -DARCH=x86 -DFULLVER=%{version} -DMAJORVER=${MAJORVER} -DDESCRIPTION="%{summary}"
32 %else
33 %cmake . -DARCH=arm -DFULLVER=%{version} -DMAJORVER=${MAJORVER} -DDESCRIPTION="%{summary}"
34 %endif
35 make %{?jobs:-j%jobs}
36
37 %install
38 %make_install
39
40
41 %post -p /sbin/ldconfig
42
43 %postun -p /sbin/ldconfig
44
45 %files
46 %manifest %{name}.manifest
47 %license  LICENSE.APLv2
48 %{_libdir}/*.so*
49
50 %files devel
51 %manifest %{name}.manifest
52 %{_includedir}/*
53 %{_libdir}/pkgconfig/cryptsvc.pc