%define gitref ab6ea89b11b1f1a8dcbfd7cfc29d65b3013f2702
%define snap 20240324
-%define rel 1
+%define rel 2
Summary: TV streaming server
Name: tvheadend
Source1: %{name}.service
Source2: %{name}.sysconfig
Source3: %{name}.init
-Patch0: x32.patch
URL: https://tvheadend.org/projects/tvheadend
BuildRequires: avahi-devel
BuildRequires: dbus-devel
%prep
%setup -q -n %{name}-%{gitref}
-%ifarch x32
-%patch0 -p1
-%endif
%{__sed} -i -e '1s,/usr/bin/env python3$,%{__python3},' lib/py/tvh/tv_meta_{tm,tv}db.py support/tvhmeta
+++ /dev/null
---- tvheadend-4.0.2/src/tvheadend.h~ 2015-05-25 15:44:34.000000000 +0000
-+++ tvheadend-4.0.2/src/tvheadend.h 2015-07-16 20:06:46.787257990 +0000
-@@ -789,6 +789,8 @@
-
- #if __WORDSIZE == 32 && defined(PLATFORM_FREEBSD)
- #define PRItime_t "d"
-+#elif defined(__ILP32__)
-+#define PRItime_t "lld"
- #else
- #define PRItime_t "ld"
- #endif
---- tvheadend-4.0.2/src/epggrab/otamux.c~ 2015-05-25 15:44:34.000000000 +0000
-+++ tvheadend-4.0.2/src/epggrab/otamux.c 2015-07-16 20:10:34.961370520 +0000
-@@ -592,7 +592,7 @@
- static void
- epggrab_ota_next_arm( time_t next )
- {
-- tvhtrace(LS_EPGGRAB, "next ota start event in %li seconds", next - time(NULL));
-+ tvhtrace(LS_EPGGRAB, "next ota start event in %"PRItime_t" seconds", next - time(NULL));
- gtimer_arm_absn(&epggrab_ota_start_timer, epggrab_ota_start_cb, NULL, next);
- dbus_emit_signal_s64("/epggrab/ota", "next", next);
- }