tbm_bufmgr_sprd: clean up _sprd_bo_cache_flush()
[platform/adaptation/spreadtrum/libtbm-sprd.git] / packaging / libtbm-sprd.spec
1 Name:           libtbm-sprd
2 Version:        1.0.3
3 Release:        0
4 License:        MIT
5 Summary:        Tizen Buffer Manager - sprd backend
6 Group:          System/Libraries
7 ExcludeArch:    i586 x86_64
8 %if ("%{?tizen_target_name}" != "TM1")
9 ExclusiveArch:
10 %endif
11 Source0:        %{name}-%{version}.tar.gz
12
13 BuildRequires:  pkgconfig(libdrm)
14 BuildRequires:  pkgconfig(libtbm)
15 BuildRequires:  pkgconfig(dlog)
16 BuildRequires:  pkgconfig(libudev)
17 BuildRequires:  kernel-headers-tizen-dev
18 BuildConflicts:  linux-glibc-devel
19
20 %description
21 descriptionion:Tizen Buffer manager backend module for spreadtrum
22
23 %global TZ_SYS_RO_SHARE  %{?TZ_SYS_RO_SHARE:%TZ_SYS_RO_SHARE}%{!?TZ_SYS_RO_SHARE:/usr/share}
24
25 %prep
26 %setup -q
27
28 %build
29
30 %reconfigure --prefix=%{_prefix} --libdir=%{_libdir}/bufmgr \
31             CFLAGS="${CFLAGS} -Wall -Werror `pkg-config --cflags dlog`" LDFLAGS="${LDFLAGS} -Wl,--hash-style=both -Wl,--as-needed"
32
33 make %{?_smp_mflags}
34
35 %install
36 rm -rf %{buildroot}
37 mkdir -p %{buildroot}/%{TZ_SYS_RO_SHARE}/license
38 cp -af COPYING %{buildroot}/%{TZ_SYS_RO_SHARE}/license/%{name}
39 mkdir -p %{buildroot}%{_libdir}/udev/rules.d/
40 cp -af rules/99-libtbm_sprd.rules %{buildroot}%{_libdir}/udev/rules.d/
41 %make_install
42
43
44 %post
45 if [ -f %{_libdir}/bufmgr/libtbm_default.so ]; then
46     rm -rf %{_libdir}/bufmgr/libtbm_default.so
47 fi
48 ln -s libtbm_sprd.so %{_libdir}/bufmgr/libtbm_default.so
49
50 %postun -p /sbin/ldconfig
51
52 %files
53 %defattr(-,root,root,-)
54 %{TZ_SYS_RO_SHARE}/license/%{name}
55 %{_libdir}/bufmgr/libtbm_*.so*
56 %{_libdir}/udev/rules.d/99-libtbm_sprd.rules
57