commit 8f73ce313320714a1553f257daf87c198a6d59b5
Author: Xavier Bachelot <xavier(a)bachelot.org>
Date: Thu Mar 10 14:39:05 2022 +0100
Fix build on EL7 and EL8
xine-lib-1.2.12-fix_older_libcaca.patch | 22 ++++++++++++++++++++++
xine-lib.spec | 17 ++++++++++++++---
2 files changed, 36 insertions(+), 3 deletions(-)
---
diff --git a/xine-lib-1.2.12-fix_older_libcaca.patch
b/xine-lib-1.2.12-fix_older_libcaca.patch
new file mode 100644
index 0000000..85bb014
--- /dev/null
+++ b/xine-lib-1.2.12-fix_older_libcaca.patch
@@ -0,0 +1,22 @@
+# HG changeset patch
+# User Xavier Bachelot <xavier(a)bachelot.org>
+# Date 1646916446 -3600
+# Thu Mar 10 13:47:26 2022 +0100
+# Node ID 6488085f778dd8115562ca308e2a60b502954dfc
+# Parent 41217d6440d1f52478180d7e477aa7e7df953507
+Fix build with older libcaca
+
+This was introduced in 3f383e
+
+diff -r 41217d6440d1 -r 6488085f778d src/video_out/video_out_caca.c
+--- a/src/video_out/video_out_caca.c Wed Mar 09 15:12:14 2022 +0200
++++ b/src/video_out/video_out_caca.c Thu Mar 10 13:47:26 2022 +0100
+@@ -44,7 +44,7 @@
+ # define caca_get_canvas_height cucul_get_canvas_height
+ # define caca_free_canvas cucul_free_canvas
+ # define caca_dither_t cucul_dither_t
+-# define caca_create_dither define cucul_create_dither
++# define caca_create_dither cucul_create_dither
+ # define caca_dither_bitmap cucul_dither_bitmap
+ # define caca_free_dither cucul_free_dither
+ #endif
diff --git a/xine-lib.spec b/xine-lib.spec
index e7d3536..483e4c8 100644
--- a/xine-lib.spec
+++ b/xine-lib.spec
@@ -4,9 +4,14 @@
%if 0%{?el7}
%global _without_dav1d 1
+ %global _without_gcrypt 1
%global _without_png 1
%endif
+%if 0%{?el8}
+ %global _without_gcrypt 1
+%endif
+
%if 0%{?el9}
# RHBZ 2031269
%global _without_caca 1
@@ -39,7 +44,7 @@
Summary: A multimedia engine
Name: xine-lib
Version: 1.2.12
-Release: 1%{?snapshot:.%{date}hg%{revision}}%{?dist}
+Release: 2%{?snapshot:.%{date}hg%{revision}}%{?dist}
License: GPLv2+
URL:
https://www.xine-project.org/
%if ! 0%{?snapshot}
@@ -50,6 +55,8 @@ Source0: xine-lib-%{version}-%{date}hg%{revision}.tar.xz
# Script to make a snapshot
Source1: make_xinelib_snapshot.sh
+Patch1: xine-lib-1.2.12-fix_older_libcaca.patch
+
Provides: xine-lib(plugin-abi) = %{plugin_abi}
%{?_isa:Provides: xine-lib(plugin-abi)%{?_isa} = %{plugin_abi}}
@@ -78,7 +85,7 @@ BuildRequires: libdca-devel
%{!?_without_dvdnav:BuildRequires: libdvdnav-devel}
BuildRequires: libdvdread-devel
%{!?_without_fame:BuildRequires: libfame-devel}
-BuildRequires: libgcrypt-devel
+%{!?_without_gcrypt:BuildRequires: libgcrypt-devel}
BuildRequires: libGLU-devel
BuildRequires: libmad-devel
BuildRequires: libmng-devel
@@ -143,6 +150,7 @@ This package contains extra plugins for %{name}:
%prep
%if ! 0%{?snapshot}
%setup -q
+%patch1 -p1
%else
%setup -q -n %{name}-%{version}-%{date}hg%{revision}
%endif
@@ -280,7 +288,7 @@ mkdir -p %{buildroot}%{codecdir}
%{!?_without_va:%{_libdir}/xine/plugins/%{plugin_abi}/xineplug_hw_frame_vaapi.so}
%{!?_without_bluray:%{_libdir}/xine/plugins/%{plugin_abi}/xineplug_inp_bluray.so}
%{_libdir}/xine/plugins/%{plugin_abi}/xineplug_inp_cdda.so
-%{_libdir}/xine/plugins/%{plugin_abi}/xineplug_inp_crypto.so
+%{!?_without_gcrypt:%{_libdir}/xine/plugins/%{plugin_abi}/xineplug_inp_crypto.so}
%{_libdir}/xine/plugins/%{plugin_abi}/xineplug_inp_dvb.so
%{_libdir}/xine/plugins/%{plugin_abi}/xineplug_inp_dvd.so
%{_libdir}/xine/plugins/%{plugin_abi}/xineplug_inp_mms.so
@@ -348,6 +356,9 @@ mkdir -p %{buildroot}%{codecdir}
%changelog
+* Thu Mar 10 2022 Xavier Bachelot <xavier(a)bachelot.org> - 1.2.12-2
+- Fix build on EL7 and EL8
+
* Thu Mar 10 2022 Xavier Bachelot <xavier(a)bachelot.org> - 1.2.12-1
- Update to 1.2.12