remove legacy libtdm backend
[platform/adaptation/nexell/libtdm-nexell.git] / packaging / hal-backend-tdm-nexell.spec
1 Name:           hal-backend-tdm-nexell
2 Version:        3.0.6
3 Release:        0
4 Summary:        hal-backend-tdm module for nexell
5 Group:          System/Libraries
6 License:        MIT
7 ExclusiveArch:  %{arm} aarch64
8 Source0:        %{name}-%{version}.tar.gz
9 Source1001:     %{name}.manifest
10
11 BuildRequires: pkgconfig(libdrm)
12 BuildRequires: pkgconfig(libudev)
13 BuildRequires: pkgconfig(dlog)
14 BuildRequires: pkgconfig(libtbm)
15 BuildRequires: pkgconfig(hal-api-common)
16 BuildRequires: pkgconfig(hal-api-tdm)
17 BuildRequires: pkgconfig(hal-api-tbm)
18 BuildRequires: pkgconfig(pixman-1)
19 %ifarch %{arm}
20 BuildRequires:  artik530-raptor-linux-kernel-headers
21 BuildConflicts: linux-glibc-devel
22 %else
23 BuildRequires:  artik710-raptor-linux-kernel-headers
24 BuildConflicts: linux-glibc-devel
25 %endif
26
27 %description
28 description: hal tdm backend module for nexell
29
30 %global TZ_SYS_RO_SHARE  %{?TZ_SYS_RO_SHARE:%TZ_SYS_RO_SHARE}%{!?TZ_SYS_RO_SHARE:/usr/share}
31
32 %prep
33 %setup -q
34 cp %{SOURCE1001} .
35
36 %build
37 %reconfigure --prefix=%{_prefix} --libdir=%{_libdir}  --disable-static \
38              --with-hal-libdir=%{_hal_libdir} \
39              CFLAGS="${CFLAGS} -Wall -Werror" \
40              LDFLAGS="${LDFLAGS} -Wl,--hash-style=both -Wl,--as-needed"
41 make %{?_smp_mflags}
42
43 %install
44 rm -rf %{buildroot}
45 %make_install
46
47 # make lincense directory and move COPY to it.
48 mkdir -p %{buildroot}%{_hal_licensedir}/libhal-backend-tdm-nexell
49 cp -af COPYING %{buildroot}%{_hal_licensedir}/libhal-backend-tdm-nexell
50
51 %post
52 if [ -f %{_hal_libdir}/libhal-backend-tdm.so ]; then
53     rm -rf %{_hal_libdir}/libhal-backend-tdm.so
54 fi
55 ln -s libhal-backend-tdm-nexell.so %{_hal_libdir}/libhal-backend-tdm.so
56
57 %postun -p /sbin/ldconfig
58
59 %files
60 %manifest %{name}.manifest
61 %{_hal_licensedir}/libhal-backend-tdm-nexell/COPYING
62 %{_hal_libdir}/libhal-backend-*.so*