|
| 1 | +%global pname mcli |
| 2 | +%global __provides_exclude_from ^%{vdr_plugindir}/.*\\.so.*$ |
| 3 | + |
| 4 | +#global fork_account pbiering |
| 5 | +#global fork_branch vdr-2.4.1 |
| 6 | + |
| 7 | +#global gitcommit e050aa1e1bb9563bd7120b2715ec1d7e3da98256 |
| 8 | +#global gitshortcommit #(c=#{gitcommit}; echo ${c:0:7}) |
| 9 | +#global gitdate 20210123 |
| 10 | + |
| 11 | +%define rel 1 |
| 12 | + |
| 13 | + |
| 14 | +Name: vdr-%{pname} |
| 15 | +Version: 0.9.5 |
| 16 | +%if 0%{?gitcommit:1} |
| 17 | +Release: %{rel}.git.%{gitshortcommit}.%{gitdate}%{?dist} |
| 18 | +%else |
| 19 | +%if 0%{?fork_account:1} |
| 20 | +Release: %{rel}.%{?fork_account:.fork.%fork_branch}%{?dist} |
| 21 | +%else |
| 22 | +Release: %{rel}%{?dist} |
| 23 | +%endif |
| 24 | +%endif |
| 25 | +Summary: DVB multicast stream client for the NetCeiver hardware for VDR |
| 26 | + |
| 27 | +License: GPLv2+ and LGPLv2+ |
| 28 | +URL: https://github.com/vdr-projects/vdr-plugin-mcli |
| 29 | +%if 0%{?fork_branch:1} |
| 30 | +Source0: https://github.com/%{fork_account}/vdr-plugin-mcli/archive/%{fork_branch}/%{name}.tar.gz |
| 31 | +%else |
| 32 | +%if 0%{?gitcommit:1} |
| 33 | +Source0: https://github.com/vdr-projects/vdr-plugin-mcli/archive/%{gitcommit}/%{name}-%{gitshortcommit}.tar.gz |
| 34 | +%else |
| 35 | +Source0: https://github.com/vdr-projects/vdr-plugin-mcli/archive/v%{version}/%{name}-%{version}.tar.gz |
| 36 | +%endif |
| 37 | +%endif |
| 38 | +Source1: %{name}.conf |
| 39 | + |
| 40 | +BuildRequires: gcc-c++ |
| 41 | +BuildRequires: vdr-devel >= 2.3.9 |
| 42 | +BuildRequires: zlib-devel |
| 43 | +BuildRequires: libxml2-devel |
| 44 | +Requires: vdr(abi)%{?_isa} = %{vdr_apiversion} |
| 45 | + |
| 46 | +%description |
| 47 | +Multicast client plugin to access DVB-streams produced by the |
| 48 | +NetCeiver hardware for VDR |
| 49 | +%if 0%{?fork_account:1} |
| 50 | +Fork: %{fork_account} / Branch: %{fork_branch} |
| 51 | +%else |
| 52 | +%if 0%{?gitcommit:1} |
| 53 | +git-commit: %{gitshortcommit} from %{gitdate} |
| 54 | +%endif |
| 55 | +%endif |
| 56 | + |
| 57 | + |
| 58 | +%package devel |
| 59 | +Summary: C header files for DVB multicast stream client |
| 60 | +Requires: vdr-devel |
| 61 | + |
| 62 | +%description devel |
| 63 | +C header files for multicast client plugin to access DVB-streams |
| 64 | +produced by the NetCeiver hardware for VDR |
| 65 | +%if 0%{?fork_account:1} |
| 66 | +Fork: %{fork_account} / Branch: %{fork_branch} |
| 67 | +%endif |
| 68 | + |
| 69 | + |
| 70 | +%prep |
| 71 | +%if 0%{?fork_account:1} |
| 72 | +%setup -q -n vdr-plugin-%{pname}-%{fork_branch} |
| 73 | +%else |
| 74 | +%if 0%{?gitcommit:1} |
| 75 | +%setup -q -n vdr-plugin-%{pname}-%{gitcommit} |
| 76 | +%else |
| 77 | +%setup -q -n vdr-plugin-%{pname}-%{version} |
| 78 | +%endif |
| 79 | +%endif |
| 80 | + |
| 81 | + |
| 82 | +%build |
| 83 | +# enforce non-parallel build |
| 84 | +%define _smp_mflags -j1 |
| 85 | + |
| 86 | +%make_build AUTOCONFIG=0 |
| 87 | + |
| 88 | +cd mcast/tool |
| 89 | +%make_build AUTOCONFIG=0 |
| 90 | + |
| 91 | + |
| 92 | +%install |
| 93 | +%make_install |
| 94 | + |
| 95 | +pushd mcast/tool |
| 96 | +mkdir -p $RPM_BUILD_ROOT/usr/sbin/ |
| 97 | +%make_install |
| 98 | +popd |
| 99 | + |
| 100 | +install -Dpm 644 %{SOURCE1} \ |
| 101 | + $RPM_BUILD_ROOT%{_sysconfdir}/sysconfig/vdr-plugins.d/%{pname}.conf |
| 102 | + |
| 103 | +%find_lang %{name} --all-name --with-man |
| 104 | + |
| 105 | +mkdir -p $RPM_BUILD_ROOT/usr/include/vdr/ |
| 106 | +install -Dpm 644 mcliheaders.h $RPM_BUILD_ROOT%{_includedir}/vdr |
| 107 | + |
| 108 | + |
| 109 | +%files -f %{name}.lang |
| 110 | +%license COPYING |
| 111 | +%doc HISTORY README |
| 112 | +%config(noreplace) %{_sysconfdir}/sysconfig/vdr-plugins.d/*.conf |
| 113 | +%{vdr_plugindir}/libvdr-*.so.%{vdr_apiversion} |
| 114 | +%{_sbindir}/* |
| 115 | + |
| 116 | +%files devel |
| 117 | +%{_includedir}/vdr/*.h |
| 118 | + |
| 119 | + |
| 120 | +%changelog |
| 121 | +* Tue Jan 26 2021 Peter Bieringer <[email protected]> - 0.9.5-1 |
| 122 | +- Create subpackage devel |
| 123 | + |
| 124 | +* Sun Dec 20 2020 Peter Bieringer <[email protected]> - 0.9.4-2 |
| 125 | +- Create subpackage devel |
| 126 | + |
| 127 | +* Sun Dec 20 2020 Peter Bieringer <[email protected]> - 0.9.4-1 |
| 128 | +- First build |
0 commit comments