Sophie

Sophie

distrib > Mageia > 6 > x86_64 > by-pkgid > 39fce8e114a87aff2dbffe8c2f5f2239 > files > 3

hdhomerun-20180817-1.mga6.src.rpm

%define major		4
%define libname		%mklibname %{name} %{major}
%define develname	%mklibname %{name} -d

Name:		hdhomerun
Version:	20180817
Release:	%mkrel 1
Summary:	Silicon Dust HDHomeRun configuration utility
Group:		System/Configuration
License:	LGPLv2+ and GPLv3
URL:		http://www.silicondust.com/
Source0:	http://download.silicondust.com/hdhomerun/lib%{name}_%{version}.tgz
Source1:	http://download.silicondust.com/hdhomerun/hdhomerun_config_gui_%{version}.tgz
Source2:	hdhomerun_config_gui.desktop
Patch0:		hdhomerun-20180817-add-soname.patch
# From debian:
Patch1:		hdhomerun-20180817-upstream-changelog.patch
BuildRequires:	gcc
BuildRequires:	gcc-c++
BuildRequires:	desktop-file-utils
BuildRequires:	libicns-utils
BuildRequires:	pkgconfig(gtk+-2.0)

%description
The configuration and firmware upgrade utility for Silicon Dust's
networked HDTV dual-tuner HDHomeRun device.

#------------------------------------------------

%package -n	%{libname}
Summary:	Silicon Dust HDHomeRun configuration utility
Group:		System/Libraries

%description -n	%{libname}
The configuration and firmware upgrade utility for Silicon Dust's
networked HDTV dual-tuner HDHomeRun device.

#------------------------------------------------

%package -n	%{develname}
Summary:	Development package for %{name}
Group:		Development/C++
Requires:	%{libname} = %{version}-%{release}
Provides:	%{name}-devel = %{version}-%{release}

%description -n	%{develname}
Header files for development with %{name}.

#------------------------------------------------

%prep
%setup -q -c -a 1
%autopatch -p1

# Convert files to utf8
for f in libhdhomerun/*; do
  /usr/bin/iconv -f iso-8859-1 -t utf-8 --output $f.new $f && mv $f.new $f
done

%build
cd hdhomerun_config_gui
%configure2_5x
%make_build

cd ..
cat << __EOF__ > README.firmware
The HDHomeRun Firmwares are not redistributable, but the latest versions of
both the US ATSC and European DVB-T firmwares can always be obtained from
the Silicon Dust web site:

https://www.silicondust.com/support/linux/

__EOF__

pushd hdhomerun_config_gui/OSX
icns2png -x hdhr.icns
popd

%install
%make_install -C hdhomerun_config_gui

mkdir -p %{buildroot}%{_includedir}/%{name}
install -m 0644 libhdhomerun/*.h %{buildroot}%{_includedir}/%{name}/

desktop-file-install --dir=%{buildroot}%{_datadir}/applications %{SOURCE2}

for size in 16x16 32x32 128x128 256x256 512x512
do
    mkdir -p %{buildroot}%{_iconsdir}/hicolor/${size}/apps
    install -m 0644 hdhomerun_config_gui/OSX/hdhr_${size}x32.png %{buildroot}%{_iconsdir}/hicolor/${size}/apps/hdhr.png
done

%files
%doc libhdhomerun/README.md libhdhomerun/ChangeLog README.firmware
%license libhdhomerun/LICENSE hdhomerun_config_gui/COPYING
# lib and cli are LGPLv2+
%{_bindir}/%{name}_config
# gui is GPLv3
%{_bindir}/%{name}_config_gui
%{_datadir}/applications/%{name}_config_gui.desktop
%{_iconsdir}/hicolor/*/apps/hdhr.png

%files -n %{libname}
%doc libhdhomerun/LICENSE
# lib and cli are LGPLv2+
%{_libdir}/lib%{name}.so.%{major}{,.*}

%files -n %{develname}
%doc libhdhomerun/README.md libhdhomerun/ChangeLog
%{_includedir}/%{name}/
%{_libdir}/lib%{name}.so


%changelog
* Mon Jan 21 2019 daviddavid <daviddavid> 20180817-1.mga6
+ Revision: 1358713
- Branching for Mageia 6

* Mon Jan 21 2019 daviddavid <daviddavid> 20180817-1.mga7
+ Revision: 1358696
- initial package hdhomerun (needed for mythtv)