To generate debuginfo package instead of debug package
[platform/framework/native/content.git] / packaging / osp-content.spec
1 Name:           osp-content
2 Summary:        osp content library
3 Version:        1.2.2.0
4 Release:        0
5 Group:          System/Libraries
6 License:        Apache License, Version 2.0
7 Source0:        %{name}-%{version}.tar.gz
8 BuildRequires:  cmake
9 BuildRequires:  pkgconfig(alarm-service)
10 BuildRequires:  pkgconfig(chromium)
11 BuildRequires:  pkgconfig(aul)
12 BuildRequires:  pkgconfig(glib-2.0)
13 BuildRequires:  pkgconfig(capi-content-media-content)
14 BuildRequires:  pkgconfig(capi-media-metadata-extractor)
15 BuildRequires:  pkgconfig(capi-content-mime-type)
16 BuildRequires:  pkgconfig(capi-web-url-download)
17 BuildRequires:  pkgconfig(osp-appfw)
18 BuildRequires:  osp-appfw-internal-devel
19 BuildRequires:  pkgconfig(osp-net)
20 BuildRequires:  osp-net-internal-devel
21 BuildRequires:  pkgconfig(osp-uifw)
22 BuildRequires:  osp-uifw-internal-devel
23 BuildRequires:  pkgconfig(osp-media)
24 BuildRequires:  osp-media-internal-devel
25 BuildRequires:  pkgconfig(osp-image-core)
26 BuildRequires:  osp-image-core-internal-devel
27 BuildRequires:  pkgconfig(osp-image)
28 BuildRequires:  osp-image-internal-devel
29 BuildRequires:  pkgconfig(osp-locations)
30 BuildRequires:  libexif-devel
31 BuildRequires:  libcurl-devel
32 BuildRequires:  openssl-devel
33
34 # runtime requires
35 Requires: osp-appfw
36 Requires: osp-net
37 Requires: osp-image
38 Requires: osp-media
39 Requires: osp-uifw
40 Requires: osp-locations
41 Requires: capi-web-url-download
42
43 Requires(post): /sbin/ldconfig
44 Requires(post): coreutils
45 Requires(postun): /sbin/ldconfig
46
47 %description
48 osp content library
49
50 %package devel
51 Summary:    osp content library (Development)
52 Group:      TO_BE/FILLED_IN
53 Requires:   %{name} = %{version}-%{release}
54 Requires:   osp-appfw-devel
55 Requires:   osp-uifw-devel
56 Requires:   osp-image-core-devel
57 Requires:   osp-image-devel
58 Requires:   osp-locations-devel
59 Requires:   osp-net-devel
60
61 %description devel
62 osp content library (DEV)
63
64 %package internal-devel
65 Summary:    osp content library (Internal)
66 Group:      TO_BE/FILLED_IN
67 Requires:   %{name} = %{version}-%{release}
68
69 %description internal-devel
70 osp content library (Internal-DEV)
71
72 %prep
73 %setup -q
74
75 %build
76 MAJORVER=`echo %{version} | awk 'BEGIN {FS="."}{print $1}'`
77 %ifarch %{ix86}
78 %if 0%{?simulator}
79 CXXFLAGS="$CXXFLAGS -D_OSP_DEBUG_ -D_SECURE_LOG -D_OSP_X86_ -D_OSP_EMUL_" cmake . -DCMAKE_INSTALL_PREFIX=%{_prefix} -DFULLVER=%{version} -DMAJORVER=${MAJORVER}
80 %else
81 CXXFLAGS="$CXXFLAGS -D_OSP_DEBUG_ -D_SECURE_LOG -D_OSP_X86_ " cmake . -DCMAKE_INSTALL_PREFIX=%{_prefix} -DFULLVER=%{version} -DMAJORVER=${MAJORVER}
82 %endif
83 %else
84 CXXFLAGS="-O2 -g -pipe -Wall -fno-exceptions -Wformat -Wformat-security -Wl,--as-needed -fmessage-length=0 -march=armv7-a -mtune=cortex-a8 -mlittle-endian -mfpu=neon -mfloat-abi=softfp -D__SOFTFP__ -mthumb -Wa,-mimplicit-it=thumb -funwind-tables -D_OSP_DEBUG_ -D_SECURE_LOG -D_OSP_ARMEL_" cmake . -DCMAKE_INSTALL_PREFIX=%{_prefix} -DFULLVER=%{version} -DMAJORVER=${MAJORVER}
85 %endif
86
87 # Call make instruction with smp support
88 make %{?jobs:-j%jobs}
89
90 %install
91 rm -rf %{buildroot}
92 mkdir -p %{buildroot}/usr/share/license
93 cp %{_builddir}/%{name}-%{version}/LICENSE.APLv2  %{buildroot}/usr/share/license/%{name}
94
95 %make_install
96
97 %post -p /sbin/ldconfig
98
99 %postun -p /sbin/ldconfig
100
101 %files
102 %manifest osp-content.manifest
103 /usr/share/license/%{name}
104 %{_libdir}/osp/*.so*
105
106 %files devel
107 %{_includedir}/osp/*.h
108 %{_libdir}/pkgconfig/osp-content.pc
109
110 %files internal-devel
111 %{_includedir}/osp/content/*.h