]>
Commit | Line | Data |
---|---|---|
afa143c0 JB |
1 | # TODO (for arm): |
2 | # - --enable-tda995x (needs nxp_hdmi SDK) | |
3 | # - --enable-rpi (needs Raspberry Pi SDK) | |
d4157d51 | 4 | # - package python module |
9bf76b75 JB |
5 | # |
6 | # Conditional build: | |
d4157d51 | 7 | %bcond_with static_libs # static library build |
9bf76b75 | 8 | # |
26910e22 | 9 | Summary: Pulse-Eight CEC adapter control library |
9bf76b75 | 10 | Summary(pl.UTF-8): Biblioteka sterowania adapterem CEC Pulse-Eight |
26910e22 | 11 | Name: libcec |
d4157d51 | 12 | Version: 6.0.2 |
3e40ea94 | 13 | Release: 2 |
26910e22 LG |
14 | License: GPL v2+ |
15 | Group: Libraries | |
43ca1a8c | 16 | Source0: http://github.com/Pulse-Eight/libcec/archive/%{name}-%{version}.tar.gz |
d4157d51 | 17 | # Source0-md5: 977e7f56279a85b52d4a2d08addb233e |
9bf76b75 | 18 | URL: http://libcec.pulse-eight.com/ |
d4157d51 | 19 | BuildRequires: cmake |
9bf76b75 | 20 | BuildRequires: libstdc++-devel >= 6:4.2 |
9bf76b75 | 21 | BuildRequires: lockdev-devel >= 1.0 |
d4157d51 | 22 | BuildRequires: ncurses-devel |
3e40ea94 | 23 | BuildRequires: p8-platform-devel |
d4157d51 AM |
24 | BuildRequires: python3-devel |
25 | BuildRequires: swig | |
26 | BuildRequires: systemd-devel | |
9bf76b75 | 27 | BuildRequires: udev-devel >= 1:151 |
d4157d51 | 28 | BuildRequires: xorg-lib-libXrandr-devel |
9bf76b75 | 29 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) |
26910e22 LG |
30 | |
31 | %description | |
32 | Pulse-Eight CEC adapter control library. | |
33 | ||
34 | %description -l pl.UTF-8 | |
9bf76b75 | 35 | Biblioteka sterowania adapterem CEC firmy Pulse-Eight. |
26910e22 LG |
36 | |
37 | %package utils | |
38 | Summary: Utilities for Pulse-Eight CEC adapter control | |
9bf76b75 JB |
39 | Summary(pl.UTF-8): Narzędla dla adaptera CEC Pulse-Eight |
40 | Group: Applications/System | |
26910e22 LG |
41 | Requires: %{name} = %{version}-%{release} |
42 | ||
43 | %description utils | |
44 | With libcec you can access your Pulse-Eight CEC adapter. | |
45 | ||
46 | This package contains the command-line tools to configure and test | |
47 | your Pulse-Eight CEC adapter. | |
48 | ||
9bf76b75 JB |
49 | %description utils -l pl.UTF-8 |
50 | libcec pozwala na dostęp do adaptera CEC firmy Pulse-Eight. | |
51 | ||
52 | Ten pakiet zawiera narzędzie linii poleceń do konfiguracji i | |
53 | testowania adaptera CEC Pulse-Eight. | |
54 | ||
26910e22 LG |
55 | %package devel |
56 | Summary: Header files for libcec library | |
57 | Summary(pl.UTF-8): Pliki nagłówkowe biblioteki libcec | |
58 | Group: Development/Libraries | |
59 | Requires: %{name} = %{version}-%{release} | |
9bf76b75 JB |
60 | Requires: libstdc++-devel >= 6:4.2 |
61 | Requires: udev-devel >= 1:151 | |
26910e22 LG |
62 | |
63 | %description devel | |
64 | Header files for libcec library. | |
65 | ||
66 | %description devel -l pl.UTF-8 | |
67 | Pliki nagłówkowe biblioteki libcec. | |
68 | ||
9bf76b75 JB |
69 | %package static |
70 | Summary: Static libcec library | |
71 | Summary(pl.UTF-8): Statyczna biblioteka libcec | |
72 | Group: Development/Libraries | |
73 | Requires: %{name}-devel = %{version}-%{release} | |
74 | ||
75 | %description static | |
76 | Static libcec library. | |
77 | ||
78 | %description static -l pl.UTF-8 | |
79 | Statyczna biblioteka libcec. | |
80 | ||
26910e22 LG |
81 | %prep |
82 | %setup -q -n %{name}-%{name}-%{version} | |
83 | ||
84 | %build | |
d4157d51 AM |
85 | install -d build |
86 | cd build | |
87 | %cmake \ | |
88 | -DHAVE_LINUX_API=on \ | |
89 | .. | |
26910e22 LG |
90 | |
91 | %{__make} | |
92 | ||
93 | %install | |
94 | rm -rf $RPM_BUILD_ROOT | |
26910e22 | 95 | |
d4157d51 AM |
96 | %{__make} -C build install \ |
97 | DESTDIR=$RPM_BUILD_ROOT | |
26910e22 | 98 | |
f6d721c7 | 99 | # Remove versioned binaries |
3e40ea94 AM |
100 | rm $RPM_BUILD_ROOT%{_bindir}/cec-client $RPM_BUILD_ROOT/%{_bindir}/cecc-client |
101 | mv $RPM_BUILD_ROOT%{_bindir}/cec-client-%{version} $RPM_BUILD_ROOT/%{_bindir}/cec-client | |
102 | mv $RPM_BUILD_ROOT%{_bindir}/cecc-client-%{version} $RPM_BUILD_ROOT/%{_bindir}/cecc-client | |
f6d721c7 | 103 | |
26910e22 LG |
104 | %clean |
105 | rm -rf $RPM_BUILD_ROOT | |
106 | ||
107 | %post -p /sbin/ldconfig | |
108 | %postun -p /sbin/ldconfig | |
109 | ||
110 | %files | |
111 | %defattr(644,root,root,755) | |
9bf76b75 | 112 | # COPYING contains also general notes |
d4157d51 | 113 | %doc AUTHORS COPYING ChangeLog README.md |
9bf76b75 | 114 | %attr(755,root,root) %{_libdir}/libcec.so.*.*.* |
d4157d51 | 115 | %attr(755,root,root) %ghost %{_libdir}/libcec.so.6 |
26910e22 LG |
116 | |
117 | %files utils | |
118 | %defattr(644,root,root,755) | |
f6d721c7 AM |
119 | %attr(755,root,root) %{_bindir}/cec-client |
120 | %attr(755,root,root) %{_bindir}/cecc-client | |
26910e22 LG |
121 | |
122 | %files devel | |
123 | %defattr(644,root,root,755) | |
9bf76b75 JB |
124 | %attr(755,root,root) %{_libdir}/libcec.so |
125 | %{_pkgconfigdir}/libcec.pc | |
126 | %{_includedir}/libcec | |
127 | ||
128 | %if %{with static_libs} | |
129 | %files static | |
130 | %defattr(644,root,root,755) | |
131 | %{_libdir}/libcec.a | |
132 | %endif |