add gerrit release file
[profile/ivi/audiomanager.git] / packaging / audiomanager.spec
1 Name:             audiomanager
2 License:          Mozilla Public License 2.0
3 Group:            System/Daemons
4 Summary:          AudioManager
5 Version:          0.0.0.5
6 Release:          0
7 Source:           %{name}-0.5.tar.gz
8 Patch0: 0001-build-sys-fixes-to-get-built-fixes-for-64-bit-distro.patch
9 Patch1: 0002-DBus-sending-routing-interface-bug-fixes.patch
10 Patch2: 0003-Uninitialized-member-fixes.patch
11 Patch3: 0004-dbus-system-bus-fix.patch
12 Patch4: 0005-remove-async-plugin-from-build.patch
13 Patch5: 0006-packaging-added-spec-file-template.patch
14 Patch6: 0007-scripts-added-obs-export.sh.patch
15 Patch7: 0008-build-sys-make-sure-libdbus-pulls-in-lrt-for-the-lin.patch
16 #BuildRequires:    pkgconfig(automotive-dlt)
17 BuildRequires:    pkgconfig(sqlite3)
18 BuildRequires:    pkgconfig(dbus-1)
19 BuildRequires:    cmake
20 Requires(post):   /sbin/ldconfig
21 Requires(postun): /sbin/ldconfig
22
23 %description
24 Automotive AudioManager
25
26 %package devel
27 License:         Mozilla Public License 2.0
28 Summary:         Automotive AudioManager Development Package
29 Group:           System/Development
30 Requires:        %{name} = %{version}-%{release}
31
32 %description devel
33 Files needed for developing against the Automotive AudioManager
34
35 %prep
36 %setup -q -n %{name}-0.5
37 %patch0 -p1
38 %patch1 -p1
39 %patch2 -p1
40 %patch3 -p1
41 %patch4 -p1
42 %patch5 -p1
43 %patch6 -p1
44 %patch7 -p1
45
46 %build
47 mkdir build
48 cd build
49
50 case %{_arch} in
51 *64) libdir=lib64;;
52 *)   libdir=lib;;
53 esac
54
55 cmake -DWITH_TESTS=OFF -DUSE_BUILD_LIBS=OFF -DWITH_DLT=OFF -DCMAKE_INSTALL_PREFIX=/usr -DLIBDIR=$libdir ..
56 make %{?jobs:-j %jobs}
57
58 %install
59 rm -rf "$RPM_BUILD_ROOT"
60 cd build
61 make install DESTDIR=$RPM_BUILD_ROOT
62
63 %post -p /sbin/ldconfig
64
65 %postun -p /sbin/ldconfig
66
67 %clean
68 rm -rf "$RPM_BUILD_ROOT"
69
70 %files
71 %defattr(-,root,root,-)
72 %{_bindir}/AudioManager
73 %{_libdir}/audioManager/command/*.so.*
74 %{_libdir}/audioManager/control/*.so.*
75 %{_libdir}/audioManager/routing/*.so.*
76 %{_libdir}/audioManager/command/*.so
77 %{_libdir}/audioManager/control/*.so
78 %{_libdir}/audioManager/routing/*.so
79
80 %files devel
81 %defattr(-,root,root,-)
82 %{_includedir}/*.h
83 %{_includedir}/command/*.h
84 %{_includedir}/control/*.h
85 %{_includedir}/routing/*.h
86 %{_includedir}/shared/*.h
87 %{_libdir}/pkgconfig/*.pc