summaryrefslogtreecommitdiff
path: root/packaging/libtbm-msm.spec
blob: 83cda8d6bda4efc2711e66573c71808426b158b9 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
Name:           libtbm-msm
Version:        1.0.2
Release:        1
License:        MIT
Summary:        Tizen Buffer Manager - drm msm backend
Group:          System/Libraries
Source0:        %{name}-%{version}.tar.gz
Source1001:	%{name}.manifest
Source1002:	libhal-backend-tbm-msm.manifest

BuildRequires:  pkgconfig(libdrm)
BuildRequires:  pkgconfig(libtbm)
BuildRequires:  pkgconfig(dlog)
BuildRequires:  pkgconfig(libudev)
BuildRequires:  pkgconfig(gbm)
BuildRequires:  pkgconfig(hal-api-common)
BuildRequires:  pkgconfig(hal-api-tbm)
ExclusiveArch:  %{arm} aarch64

%description
descriptionion: Tizen Buffer manager backend module uses drm msm

%package -n hal-backend-tbm-msm
Summary:	hal-backend-tbm module for msm
Group:		System/Libraries
Requires:	hal-api-tbm
Requires:	hal-api-common

%description -n hal-backend-tbm-msm
descriptionion: hal tbm backend module for msm

%prep
%setup -q
cp %{SOURCE1001} .
cp %{SOURCE1002} .

%build

%reconfigure --prefix=%{_prefix} --libdir=%{_libdir}/bufmgr \
			--with-hal-libdir=%{_hal_libdir} \
			--with-default-dlog=yes \
			--disable-align-eight \
			--disable-cachectrl \
			CFLAGS="${CFLAGS} -Wall -Werror" LDFLAGS="${LDFLAGS} -Wl,--hash-style=both -Wl,--as-needed"

make %{?_smp_mflags}

%install
rm -rf %{buildroot}

%make_install


%post
if [ -f %{_libdir}/bufmgr/libtbm_default.so ]; then
    rm -rf %{_libdir}/bufmgr/libtbm_default.so
fi
ln -s libtbm-msm.so %{_libdir}/bufmgr/libtbm_default.so

%postun -p /sbin/ldconfig

%post -n hal-backend-tbm-msm
if [ -f %{_hal_libdir}/libhal-backend-tbm.so ]; then
    rm -rf %{_hal_libdir}/libhal-backend-tbm.so
fi
ln -s libhal-backend-tbm-msm.so %{_hal_libdir}/libhal-backend-tbm.so

%postun -n hal-backend-tbm-msm -p /sbin/ldconfig

%files
%manifest %{name}.manifest
%license COPYING
%{_libdir}/bufmgr/libtbm-*.so*

%files -n hal-backend-tbm-msm
%manifest libhal-backend-tbm-msm.manifest
%license COPYING
%{_hal_libdir}/libhal-backend-*.so*