[packages/xmms2] - up to 0.8DrO_o; added -input-sndfile subpackage

qboosh qboosh at pld-linux.org
Sat Jun 24 20:38:15 CEST 2023


commit 26d9461bad8ce73f84b4c5ca9cd69e00a5318e43
Author: Jakub Bogusz <qboosh at pld-linux.org>
Date:   Sat Jun 24 20:23:28 2023 +0200

    - up to 0.8DrO_o; added -input-sndfile subpackage

 xmms2-ffmpeg.patch         |  90 +++---
 xmms2-glib.patch           |  11 +
 xmms2-ruby.patch           |  72 -----
 xmms2-sc68.patch           |  15 +-
 xmms2-tabs.patch           |  42 ---
 xmms2-use-system-waf.patch | 677 +++++++++++++++++++++++++++++++++++++++++++++
 xmms2-version.patch        |  20 +-
 xmms2-waf.patch            |  28 +-
 xmms2.spec                 |  63 +++--
 9 files changed, 805 insertions(+), 213 deletions(-)
---
diff --git a/xmms2.spec b/xmms2.spec
index 1f525d4..d9eb30e 100644
--- a/xmms2.spec
+++ b/xmms2.spec
@@ -5,24 +5,24 @@
 %bcond_without	sdl	# SDL clients
 %bcond_with	java	# Java/JNI module (removed in 0.2DrJekyll)
 %bcond_without	perl	# Perl module
-%bcond_with	python	# Python module (doesn't build with python 2.7)
+%bcond_with	python	# Python module
 %bcond_without	ruby	# Ruby modules
 %bcond_without	flac	# flac plugin
 
 Summary:	Client/server based media player system
 Summary(pl.UTF-8):	System odtwarzania multimediów oparty na architekturze klient/serwer
 Name:		xmms2
-Version:	0.7DrNo
+Version:	0.8DrO_o
 Release:	0.1
 License:	LGPL v2.1
 Group:		Applications/Sound
 Source0:	https://downloads.sourceforge.net/xmms2/%{name}-%{version}.tar.bz2
-# Source0-md5:	60e50b591078acb6a85cd83de0f2b077
-Patch0:		%{name}-tabs.patch
+# Source0-md5:	84d5c05a70bfd31ed392a4e3f701eaa3
+Patch0:		%{name}-use-system-waf.patch
 Patch1:		%{name}-openssl.patch
+Patch2:		%{name}-glib.patch
 Patch3:		%{name}-modplug.patch
 Patch4:		%{name}-ffmpeg.patch
-Patch5:		%{name}-ruby.patch
 Patch7:		%{name}-waf.patch
 Patch8:		%{name}-version.patch
 Patch10:	%{name}-link.patch
@@ -30,7 +30,6 @@ Patch11:	%{name}-sc68.patch
 URL:		http://xmms2.xmms.se/
 BuildRequires:	alsa-lib-devel
 BuildRequires:	avahi-devel
-BuildRequires:	avahi-compat-libdns_sd-devel
 BuildRequires:	avahi-glib-devel
 BuildRequires:	boost-devel
 BuildRequires:	curl-devel >= 7.12.0
@@ -41,7 +40,7 @@ BuildRequires:	fftw3-single-devel >= 3
 %{?with_flac:BuildRequires:	flac-devel >= 1.1.3}
 BuildRequires:	game-music-emu-devel
 BuildRequires:	gamin-devel
-BuildRequires:	glib2-devel >= 1:2.8.0
+BuildRequires:	glib2-devel >= 1:2.18.0
 BuildRequires:	jack-audio-connection-kit-devel
 %{?with_java:BuildRequires:	jdk}
 BuildRequires:	libao-devel
@@ -58,6 +57,7 @@ BuildRequires:	libsamplerate-devel
 BuildRequires:	libshout-devel
 BuildRequires:	libsidplay2-devel
 BuildRequires:	libsmbclient-devel
+BuildRequires:	libsndfile-devel
 BuildRequires:	libstdc++-devel
 BuildRequires:	libvorbis-devel
 BuildRequires:	libxml2-devel >= 2.0
@@ -65,25 +65,25 @@ BuildRequires:	openssl-devel
 BuildRequires:	pkgconfig
 BuildRequires:	pulseaudio-devel
 %if %{with python}
-BuildRequires:	python-Pyrex >= 0.9.4.2
+BuildRequires:	python-Cython >= 0.15.1
 BuildRequires:	python-devel >= 1:2.4
 %endif
 BuildRequires:	python3 >= 1:3.2
 BuildRequires:	rpmbuild(macros) >= 1.277
 %{?with_ruby:BuildRequires:	ruby-modules >= 1:1.8}
 BuildRequires:	sc68-devel
-BuildRequires:	scons >= 4
 BuildRequires:	sed >= 4.0
 BuildRequires:	speex-devel
 BuildRequires:	sqlite3-devel >= 3.5
 BuildRequires:	swig >= 1.3.25
 BuildRequires:	tremor-devel
+BuildRequires:	waf >= 1.6.7
 BuildRequires:	wavpack-devel
 %if %{with sdl}
 BuildRequires:	SDL-devel
 BuildRequires:	libvisual-devel
 %endif
-Requires:	glib2 >= 1:2.8.0
+Requires:	glib2 >= 1:2.18.0
 Requires:	sqlite3 >= 3.5
 BuildRoot:	%{tmpdir}/%{name}-%{version}-root-%(id -u -n)
 
@@ -100,7 +100,7 @@ Summary:	Simple text-ui for xmms2
 Summary(pl.UTF-8):	Prosty tekstowy interfejs dla xmms2
 Group:		Applications/Sound
 Requires:	%{name} = %{version}-%{release}
-Requires:	glib2 >= 1:2.8.0
+Requires:	glib2 >= 1:2.18.0
 
 %description client-cli
 Simple text-ui for xmms2.
@@ -150,7 +150,7 @@ Summary:	GLib client library
 Summary(pl.UTF-8):	Biblioteka kliencka GLib
 Group:		X11/Applications/Sound
 Requires:	%{name} = %{version}-%{release}
-Requires:	glib2 >= 1:2.8.0
+Requires:	glib2 >= 1:2.18.0
 
 %description client-lib-glib
 GLib client library.
@@ -370,6 +370,18 @@ This package enables SID decoding for xmms2.
 %description input-sid -l pl.UTF-8
 Ten pakiet umożliwia dekodowanie SID przez xmms2.
 
+%package input-sndfile
+Summary:	sndfile decoder
+Summary(pl.UTF-8):	Dekoder sndfile
+Group:		X11/Applications/Sound
+Requires:	%{name} = %{version}-%{release}
+
+%description input-sndfile
+This package enables sndfile decoding for xmms2.
+
+%description input-sndfile -l pl.UTF-8
+Ten pakiet umożliwia dekodowanie sndfile przez xmms2.
+
 %package input-speex
 Summary:	speex decoder
 Summary(pl.UTF-8):	Dekoder speex
@@ -570,7 +582,7 @@ Summary:	Development libraries and header files
 Summary(pl.UTF-8):	Biblioteki programistyczne i pliki nagłówkowe
 Group:		Development/Libraries
 Requires:	%{name} = %{version}-%{release}
-Requires:	glib2-devel >= 1:2.8.0
+Requires:	glib2-devel >= 1:2.18.0
 
 %description devel
 This is the package containing the development libaries and header
@@ -584,9 +596,9 @@ xmms2.
 %setup -q
 %patch0 -p1
 %patch1 -p1
+%patch2 -p1
 %patch3 -p1
 %patch4 -p1
-%patch5 -p1
 %patch7 -p1
 %patch8 -p1
 %patch10 -p1
@@ -597,7 +609,6 @@ xmms2.
 
 # recode to UTF-8
 for f in \
-	src/clients/cli/xmms2.1 \
 	src/clients/et/xmms2-et.1 \
 	src/clients/launcher/xmms2-launcher.1 \
 	src/clients/mdns/avahi/xmms2-mdns-avahi.1 \
@@ -607,32 +618,39 @@ do
 	%{__mv} "${f}.utf8" "$f"
 done
 
+%{__rm} waf
+
 %build
 CC="%{__cc}" \
 CXX="%{__cxx}" \
 CFLAGS="%{rpmcflags} %{rpmcppflags} $(pkg-config --cflags smbclient)" \
 CXXFLAGS="%{rpmcxxflags} %{rpmcppflags} $(pkg-config --cflags smbclient)" \
 LDFLAGS="%{rpmldflags}" \
-./waf configure -v \
+waf configure -v \
 	--prefix=%{_prefix} \
 	--libdir=%{_libdir} \
 	--mandir=%{_mandir} \
 	--with-perl-archdir=%{perl_vendorarch} \
 	--with-ruby-archdir=%{ruby_vendorarchdir} \
 	--with-ruby-libdir=%{ruby_vendorlibdir} \
-	--without-optionals=python
+	--with-vis-reference-clients \
+	%{!?with_python:--without-optionals=python}
 
-./waf build -v
+waf build -v
 
 %install
 rm -rf $RPM_BUILD_ROOT
 
-./waf install \
+waf install \
 	--destdir=$RPM_BUILD_ROOT
 
 chmod 755 $RPM_BUILD_ROOT%{_libdir}/lib*.so.*.*
 chmod 755 $RPM_BUILD_ROOT%{_libdir}/xmms2/lib*.so
 
+install -d $RPM_BUILD_ROOT%{_mandir}/man3
+pod2man --section=3 $RPM_BUILD_ROOT%{perl_vendorarch}/Audio/XMMSClient.pod $RPM_BUILD_ROOT%{_mandir}/man3/XMMSClient.3pm
+%{__rm} $RPM_BUILD_ROOT%{perl_vendorarch}/Audio/XMMSClient.pod
+
 %clean
 rm -rf $RPM_BUILD_ROOT
 
@@ -699,9 +717,7 @@ rm -rf $RPM_BUILD_ROOT
 %attr(755,root,root) %{_bindir}/xmms2-et
 %attr(755,root,root) %{_bindir}/xmms2-find-avahi
 %attr(755,root,root) %{_bindir}/xmms2-mdns-avahi
-%attr(755,root,root) %{_bindir}/xmms2-mdns-dnssd
 %attr(755,root,root) %{_bindir}/xmms2-mlib-updater
-%{_mandir}/man1/nyxmms2.1*
 %{_mandir}/man1/xmms2.1*
 %{_mandir}/man1/xmms2-et.1*
 %{_mandir}/man1/xmms2-mdns-avahi.1*
@@ -755,6 +771,7 @@ rm -rf $RPM_BUILD_ROOT
 %{perl_vendorarch}/Audio/XMMSClient
 %dir %{perl_vendorarch}/auto/Audio/XMMSClient
 %attr(755,root,root) %{perl_vendorarch}/auto/Audio/XMMSClient/XMMSClient.so
+%{_mandir}/man3/XMMSClient.3pm*
 %endif
 
 %if %{with python}
@@ -823,6 +840,10 @@ rm -rf $RPM_BUILD_ROOT
 %defattr(644,root,root,755)
 %attr(755,root,root) %{_libdir}/%{name}/libxmms_sid.so
 
+%files input-sndfile
+%defattr(644,root,root,755)
+%attr(755,root,root) %{_libdir}/%{name}/libxmms_sndfile.so
+
 %files input-speex
 %defattr(644,root,root,755)
 %attr(755,root,root) %{_libdir}/%{name}/libxmms_speex.so
diff --git a/xmms2-ffmpeg.patch b/xmms2-ffmpeg.patch
index 50e9ccc..8ad7f21 100644
--- a/xmms2-ffmpeg.patch
+++ b/xmms2-ffmpeg.patch
@@ -1,24 +1,32 @@
---- xmms2-0.6DrMattDestruction/src/plugins/avcodec/avcodec.c.orig	2009-04-21 19:51:11.000000000 +0200
-+++ xmms2-0.6DrMattDestruction/src/plugins/avcodec/avcodec.c	2023-05-22 09:34:51.481410306 +0200
-@@ -160,7 +160,7 @@ xmms_avcodec_init (xmms_xform_t *xform)
- 		goto err;
- 	}
+--- xmms2-0.8DrO_o/src/plugins/avcodec/avcodec.c.orig	2011-10-20 21:26:08.000000000 +0200
++++ xmms2-0.8DrO_o/src/plugins/avcodec/avcodec.c	2023-06-24 12:35:16.781344459 +0200
+@@ -134,7 +134,6 @@ xmms_avcodec_init (xmms_xform_t *xform)
  
--	if (codec->type != CODEC_TYPE_AUDIO) {
-+	if (codec->type != AVMEDIA_TYPE_AUDIO) {
- 		XMMS_DBG ("Codec '%s' found but its type is not audio", data->codec_id);
- 		goto err;
+ 	xmms_xform_private_data_set (xform, data);
+ 
+-	avcodec_init ();
+ 	avcodec_register_all ();
+ 
+ 	mimetype = xmms_xform_indata_get_str (xform,
+@@ -200,7 +199,7 @@ xmms_avcodec_init (xmms_xform_t *xform)
+ 		}
  	}
-@@ -219,7 +219,7 @@ xmms_avcodec_init (xmms_xform_t *xform)
- 	data->codecctx->extradata = data->extradata;
- 	data->codecctx->extradata_size = data->extradata_size;
+ 
+-	data->codecctx = avcodec_alloc_context ();
++	data->codecctx = avcodec_alloc_context3 (codec);
+ 	data->codecctx->sample_rate = data->samplerate;
+ 	data->codecctx->channels = data->channels;
+ 	data->codecctx->bit_rate = data->bitrate;
+@@ -211,7 +210,7 @@ xmms_avcodec_init (xmms_xform_t *xform)
+ 	data->codecctx->codec_id = codec->id;
+ 	data->codecctx->codec_type = codec->type;
  
 -	if (avcodec_open (data->codecctx, codec) < 0) {
 +	if (avcodec_open2 (data->codecctx, codec, NULL) < 0) {
  		XMMS_DBG ("Opening decoder '%s' failed", codec->name);
  		goto err;
  	} else {
-@@ -270,7 +270,6 @@ xmms_avcodec_read (xmms_xform_t *xform,
+@@ -263,7 +262,6 @@ xmms_avcodec_read (xmms_xform_t *xform,
                     xmms_error_t *error)
  {
  	xmms_avcodec_data_t *data;
@@ -26,29 +34,22 @@
  	gint outbufsize, bytes_read = 0;
  	guint size;
  
-@@ -279,6 +278,11 @@ xmms_avcodec_read (xmms_xform_t *xform,
+@@ -272,6 +270,8 @@ xmms_avcodec_read (xmms_xform_t *xform,
  
  	size = MIN (data->outbuf->len, len);
  	while (size == 0) {
 +		int got_frame = 0;
 +		AVFrame *frame;
-+		AVPacket packet;
-+		av_init_packet (&packet);
-+
- 		if (data->buffer_length == 0) {
- 			gint read_total;
+ 		AVPacket packet;
+ 		av_init_packet (&packet);
  
-@@ -332,12 +336,19 @@ xmms_avcodec_read (xmms_xform_t *xform,
- 			data->buffer_length = read_total;
- 		}
+@@ -330,9 +330,13 @@ xmms_avcodec_read (xmms_xform_t *xform,
+ 		packet.data = data->buffer;
+ 		packet.size = data->buffer_length;
  
 -		outbufsize = sizeof (outbuf);
--		bytes_read = avcodec_decode_audio2 (data->codecctx, (short *) outbuf,
--		                                    &outbufsize, data->buffer_pos,
--		                                    data->buffer_length);
-+		packet.data = data->buffer;
-+		packet.size = data->buffer_length;
-+
+-		bytes_read = avcodec_decode_audio3 (data->codecctx, (short *) outbuf,
+-		                                    &outbufsize, &packet);
 +		frame = av_frame_alloc();
 +		if (frame == NULL) {
 +			XMMS_DBG ("AVFrame allocation failed");
@@ -57,13 +58,18 @@
 +
 +		bytes_read = avcodec_decode_audio4 (data->codecctx, frame, &got_frame, &packet);
  
+ 		/* The DTS decoder of ffmpeg is buggy and always returns
+ 		 * the input buffer length, get frame length from header */
+@@ -344,6 +348,7 @@ xmms_avcodec_read (xmms_xform_t *xform,
+ 		}
+ 
  		if (bytes_read < 0 || bytes_read > data->buffer_length) {
 +			av_frame_free(&frame);
  			XMMS_DBG ("Error decoding data!");
  			return -1;
- 		}
-@@ -345,9 +356,11 @@ xmms_avcodec_read (xmms_xform_t *xform,
- 		data->buffer_pos += bytes_read;
+ 		} else if (bytes_read != data->buffer_length) {
+@@ -354,9 +359,11 @@ xmms_avcodec_read (xmms_xform_t *xform,
+ 
  		data->buffer_length -= bytes_read;
  
 -		if (outbufsize > 0) {
@@ -76,7 +82,7 @@
  
  		size = MIN (data->outbuf->len, len);
  	}
-@@ -375,7 +375,6 @@ static gint64
+@@ -371,7 +378,6 @@ static gint64
  xmms_avcodec_seek (xmms_xform_t *xform, gint64 samples, xmms_xform_seek_mode_t whence, xmms_error_t *err)
  {
  	xmms_avcodec_data_t *data;
@@ -84,22 +90,20 @@
  	gint outbufsize, bytes_read = 0;
  	gint64 ret = -1;
  
-@@ -395,10 +394,22 @@ xmms_avcodec_seek (xmms_xform_t *xform,
+@@ -391,14 +397,21 @@ xmms_avcodec_seek (xmms_xform_t *xform,
  	/* The buggy ape decoder doesn't flush buffers, so we need to finish decoding
  	 * the frame before seeking to avoid segfaults... this hack sucks */
  	while (data->buffer_length > 0) {
--		outbufsize = sizeof (outbuf);
--		bytes_read = avcodec_decode_audio2 (data->codecctx, (short *) outbuf,
--		                                    &outbufsize, data->buffer,
--		                                    data->buffer_length);
 +		int got_frame = 0;
 +		AVFrame *frame;
-+		AVPacket packet;
-+		av_init_packet (&packet);
-+
-+		packet.data = data->buffer;
-+		packet.size = data->buffer_length;
-+
+ 		AVPacket packet;
+ 		av_init_packet (&packet);
+ 		packet.data = data->buffer;
+ 		packet.size = data->buffer_length;
+ 
+-		outbufsize = sizeof (outbuf);
+-		bytes_read = avcodec_decode_audio3 (data->codecctx, (short *) outbuf,
+-		                                    &outbufsize, &packet);
 +		frame = av_frame_alloc();
 +		if (frame == NULL) {
 +			XMMS_DBG ("AVFrame allocation failed");
diff --git a/xmms2-glib.patch b/xmms2-glib.patch
new file mode 100644
index 0000000..7b6ba7e
--- /dev/null
+++ b/xmms2-glib.patch
@@ -0,0 +1,11 @@
+--- xmms2-0.8DrO_o/src/clients/medialib-updater/main.c.orig	2011-10-20 21:26:08.000000000 +0200
++++ xmms2-0.8DrO_o/src/clients/medialib-updater/main.c	2023-06-24 12:43:46.711915262 +0200
+@@ -40,7 +40,7 @@ static void on_directory_event (GFileMon
+                                 gpointer udata);
+ 
+ /* TODO: Remove once we depend on GLib >= 2.18 */
+-#ifndef HAVE_G_FILE_QUERY_FILE_TYPE
++#if 0
+ static GFileType
+ g_file_query_file_type (GFile *file, GFileQueryInfoFlags flags,
+                         GCancellable *cancellable);
diff --git a/xmms2-ruby.patch b/xmms2-ruby.patch
deleted file mode 100644
index 145d316..0000000
--- a/xmms2-ruby.patch
+++ /dev/null
@@ -1,72 +0,0 @@
---- xmms2-0.7DrNo/waftools/ruby.py.orig	2023-06-23 06:13:20.083662855 +0200
-+++ xmms2-0.7DrNo/waftools/ruby.py	2023-06-23 06:23:46.506545435 +0200
-@@ -63,12 +63,12 @@ def check_ruby_ext_devel(conf):
-     version = conf.env['RUBY_VERSION']
- 
-     def ruby_get_config(key):
--        return Utils.cmd_output(ruby + " -rrbconfig -e 'print Config::CONFIG[\"" + key + "\"]'").strip()
-+        return Utils.cmd_output(ruby + " -rrbconfig -e 'print RbConfig::CONFIG[\"" + key + "\"]'").strip()
- 
-     if version >= (1, 9, 0):
--        ruby_h = Utils.cmd_output(ruby + " -rrbconfig -e 'puts File.exist?(Config::CONFIG[\"rubyhdrdir\"] + \"/ruby.h\")'").strip()
-+        ruby_h = Utils.cmd_output(ruby + " -rrbconfig -e 'puts File.exist?(RbConfig::CONFIG[\"rubyhdrdir\"] + \"/ruby.h\")'").strip()
-     elif version >= (1, 8, 0):
--        ruby_h = Utils.cmd_output(ruby + " -rrbconfig -e 'puts File.exist?(Config::CONFIG[\"archdir\"] + \"/ruby.h\")'").strip()
-+        ruby_h = Utils.cmd_output(ruby + " -rrbconfig -e 'puts File.exist?(RbConfig::CONFIG[\"archdir\"] + \"/ruby.h\")'").strip()
- 
-     if ruby_h != 'true':
-         conf.check_message('ruby', 'header file', False)
-@@ -76,18 +76,18 @@ def check_ruby_ext_devel(conf):
- 
-     conf.check_message('ruby', 'header file', True)
- 
--    archdir = Utils.cmd_output(ruby + " -rrbconfig -e 'puts \"%s\" % [].fill(Config::CONFIG[\"archdir\"], 0..1)'").strip()
-+    archdir = Utils.cmd_output(ruby + " -rrbconfig -e 'puts \"%s\" % [].fill(RbConfig::CONFIG[\"archdir\"], 0..1)'").strip()
-     conf.env["CPPPATH_RUBY"] = [archdir]
-     conf.env["LINKFLAGS_RUBY"] = '-L%s' % archdir
- 
-     if version >= (1, 9, 0):
--        incpaths = Utils.cmd_output(ruby + " -rrbconfig -e 'puts Config::CONFIG[\"rubyhdrdir\"]'").strip()
-+        incpaths = Utils.cmd_output(ruby + " -rrbconfig -e 'puts RbConfig::CONFIG[\"rubyhdrdir\"]'").strip()
-         conf.env["CPPPATH_RUBY"] += [incpaths]
- 
--        incpaths = Utils.cmd_output(ruby + " -rrbconfig -e 'puts File.join(Config::CONFIG[\"rubyhdrdir\"], Config::CONFIG[\"arch\"])'").strip()
-+        incpaths = Utils.cmd_output(ruby + " -rrbconfig -e 'puts File.join(RbConfig::CONFIG[\"rubyhdrdir\"], RbConfig::CONFIG[\"arch\"])'").strip()
-         conf.env["CPPPATH_RUBY"] += [incpaths]
- 
--    ldflags = Utils.cmd_output(ruby + " -rrbconfig -e 'print Config::CONFIG[\"LDSHARED\"]'").strip()
-+    ldflags = Utils.cmd_output(ruby + " -rrbconfig -e 'print RbConfig::CONFIG[\"LDSHARED\"]'").strip()
- 
-     # ok this is really stupid, but the command and flags are combined.
-     # so we try to find the first argument...
-@@ -113,14 +113,14 @@ def check_ruby_ext_devel(conf):
-     if Options.options.rubyarchdir:
-         conf.env["ARCHDIR_RUBY"] = Options.options.rubyarchdir
-     else:
--        conf.env["ARCHDIR_RUBY"] = Utils.cmd_output(ruby + " -rrbconfig -e 'print Config::CONFIG[\"sitearchdir\"]'").strip()
-+        conf.env["ARCHDIR_RUBY"] = Utils.cmd_output(ruby + " -rrbconfig -e 'print RbConfig::CONFIG[\"sitearchdir\"]'").strip()
- 
-     if Options.options.rubylibdir:
-         conf.env["LIBDIR_RUBY"] = Options.options.rubylibdir
-     else:
--        conf.env["LIBDIR_RUBY"] = Utils.cmd_output(ruby + " -rrbconfig -e 'print Config::CONFIG[\"sitelibdir\"]'").strip()
-+        conf.env["LIBDIR_RUBY"] = Utils.cmd_output(ruby + " -rrbconfig -e 'print RbConfig::CONFIG[\"sitelibdir\"]'").strip()
- 
--    conf.env['rubyext_PATTERN'] = '%s.' + Utils.cmd_output(ruby + " -rrbconfig -e 'print Config::CONFIG[\"DLEXT\"]'").strip()
-+    conf.env['rubyext_PATTERN'] = '%s.' + Utils.cmd_output(ruby + " -rrbconfig -e 'print RbConfig::CONFIG[\"DLEXT\"]'").strip()
- 
-     # Change some strings to a list
-     conf.env["LINKFLAGS_RUBY"] = Utils.to_list(conf.env["LINKFLAGS_RUBY"])
---- xmms2-0.5DrLecter/src/clients/lib/ruby/rb_collection.c.orig	2008-06-15 19:31:38.000000000 +0200
-+++ xmms2-0.5DrLecter/src/clients/lib/ruby/rb_collection.c	2023-05-21 15:05:06.452132360 +0200
-@@ -285,8 +285,8 @@ attrs_inspect_cb (VALUE args, VALUE s)
- {
- 	VALUE key, value;
- 
--	key = RARRAY (args)->ptr[0];
--	value = RARRAY (args)->ptr[1];
-+	key = RARRAY_PTR (args)[0];
-+	value = RARRAY_PTR (args)[1];
- 
- 	if (RSTRING_LEN (s) > 1)
- 		rb_str_buf_cat2 (s, ", ");
diff --git a/xmms2-sc68.patch b/xmms2-sc68.patch
index 3b7a3e4..c975199 100644
--- a/xmms2-sc68.patch
+++ b/xmms2-sc68.patch
@@ -1,14 +1,13 @@
---- xmms2-0.7DrNo/src/plugins/sc68/wscript.orig	2010-02-19 18:43:54.000000000 +0100
-+++ xmms2-0.7DrNo/src/plugins/sc68/wscript	2023-06-24 10:14:52.663648483 +0200
-@@ -1,7 +1,7 @@
- from waftools.plugin import plugin
+--- xmms2-0.8DrO_o/src/plugins/sc68/wscript.orig	2023-06-24 11:36:55.240313931 +0200
++++ xmms2-0.8DrO_o/src/plugins/sc68/wscript	2023-06-24 11:44:47.417755926 +0200
+@@ -2,6 +2,6 @@ from waftools.plugin import plugin
  
  def plugin_configure(conf):
--	if not conf.check_cfg(path="sc68-config", package="sc68", uselib_store="sc68", atleast_version="2.3.0", args="--cflags --libs"):
-+	if not conf.check_cfg(path="sc68-config", package="sc68", uselib_store="sc68", atleast_version="2.2.1", args="--cflags --libs"):
- 		return False
+     conf.check_cfg(path="sc68-config", package="sc68", uselib_store="sc68",
+-            atleast_version="2.3.0", args="--cflags --libs")
++            atleast_version="2.2.1", args="--cflags --libs")
  
- 	return True
+ configure, build = plugin('sc68', configure=plugin_configure, libs=["sc68"])
 --- xmms2-0.7DrNo/src/plugins/sc68/sc68.c.orig	2010-02-19 18:43:54.000000000 +0100
 +++ xmms2-0.7DrNo/src/plugins/sc68/sc68.c	2023-06-24 10:24:06.463981622 +0200
 @@ -237,7 +237,7 @@ sc68_load_track (api68_disk_t disk, int
diff --git a/xmms2-tabs.patch b/xmms2-tabs.patch
deleted file mode 100644
index 449e4b2..0000000
--- a/xmms2-tabs.patch
+++ /dev/null
@@ -1,42 +0,0 @@
---- xmms2-0.2DrJekyll/src/xmms/sample.genpy.orig	2007-05-20 17:55:40.000000000 +0200
-+++ xmms2-0.2DrJekyll/src/xmms/sample.genpy	2023-05-14 18:51:40.261637819 +0200
-@@ -152,10 +152,10 @@ def get_channelconv(numin, numout, t):
- 		for a in range(numout):
- 			out += "\t\tout[%d] = WRITE%s(temp[%d]);\n" % (a,t,a)
- 	elif numin == 1 and numout == 2:
--       		out += "\t\tout[0] = WRITE%s(temp[0]);\n" % t
--       		out += "\t\tout[1] = WRITE%s(temp[0]);\n" % t
-+		out += "\t\tout[0] = WRITE%s(temp[0]);\n" % t
-+		out += "\t\tout[1] = WRITE%s(temp[0]);\n" % t
- 	elif numin == 2 and numout == 1:
--       		out += "\t\tout[0] = WRITE%s((temp[0] + temp[1])/2);\n" % t
-+		out += "\t\tout[0] = WRITE%s((temp[0] + temp[1])/2);\n" % t
- 	else:
- 		raise RuntimeError("go implement channelconversion from %d to %d channels" % (numin, numout))
- 	return out
-@@ -196,11 +196,11 @@ def make_conv(fields, curr):
- 			out = re.sub(key,str(val),out)
- 
- 		out = re.sub("CONVERTER",
--			     get_channelconv(curr['INCHANNELS'],
--					     curr['OUTCHANNELS'],
--					     curr['OUTTYPE']),
--			     out)
--		
-+			get_channelconv(curr['INCHANNELS'],
-+				curr['OUTCHANNELS'],
-+				curr['OUTTYPE']),
-+			out)
-+
- 		return out
- 
- 
-@@ -234,7 +234,7 @@ def make_switch(fields, curr):
- 			val += indent + "case XMMS_SAMPLE_FORMAT_%s:\n" % a.upper()
- 		else:
- 			val += indent + "case %s:\n" % a
--       		val += make_switch(fields[1:], t)
-+		val += make_switch(fields[1:], t)
- 	val += indent + "}\n"
- 	return val
- 
diff --git a/xmms2-use-system-waf.patch b/xmms2-use-system-waf.patch
new file mode 100644
index 0000000..002ab4b
--- /dev/null
+++ b/xmms2-use-system-waf.patch
@@ -0,0 +1,677 @@
+diff -up xmms2-0.8DrO_o/src/clients/et/wscript.fixme xmms2-0.8DrO_o/src/clients/et/wscript
+--- xmms2-0.8DrO_o/src/clients/et/wscript.fixme	2011-10-20 15:26:08.000000000 -0400
++++ xmms2-0.8DrO_o/src/clients/et/wscript	2020-02-28 09:49:55.142637980 -0500
+@@ -23,9 +23,9 @@ def build(bld):
+ 
+ 
+ def configure(conf):
+-    if Options.platform == "win32":
++    if Utils.unversioned_sys_platform == "win32":
+         conf.fatal("Not supported on Windows")
+-    elif Options.platform == "sunos":
++    elif Utils.unversioned_sys_platform == "sunos":
+         conf.check_cc(lib="resolv", uselib_store="resolv", mandatory=True)
+     return True
+ 
+diff -up xmms2-0.8DrO_o/src/clients/launcher/wscript.fixme xmms2-0.8DrO_o/src/clients/launcher/wscript
+--- xmms2-0.8DrO_o/src/clients/launcher/wscript.fixme	2011-10-20 15:26:08.000000000 -0400
++++ xmms2-0.8DrO_o/src/clients/launcher/wscript	2020-02-28 09:49:55.142637980 -0500
+@@ -1,4 +1,4 @@
+-import Options
++from waflib import Utils
+ 
+ def build(bld):
+     bld(features = 'c cprogram',
+@@ -14,7 +14,7 @@ def build(bld):
+         )
+ 
+ def configure(conf):
+-    if Options.platform == 'win32':
++    if Utils.unversioned_sys_platform == 'win32':
+         conf.fatal("Not supported on Windows")
+ 
+ def options(opt):
+diff -up xmms2-0.8DrO_o/src/clients/lib/perl/wscript.fixme xmms2-0.8DrO_o/src/clients/lib/perl/wscript
+--- xmms2-0.8DrO_o/src/clients/lib/perl/wscript.fixme	2011-10-20 15:26:08.000000000 -0400
++++ xmms2-0.8DrO_o/src/clients/lib/perl/wscript	2020-02-28 09:49:55.143637956 -0500
+@@ -37,11 +37,11 @@ def build(bld):
+ 
+ 
+ def configure(conf):
+-    conf.check_tool('perl')
++    conf.load('perl')
+     conf.check_perl_version((5,7,3))
+     conf.check_perl_ext_devel()
+     conf.load('podselect', tooldir='waftools')
+-    conf.check_tool('podselect')
++    conf.load('podselect')
+ 
+     if not os.path.commonprefix([conf.env.ARCHDIR_PERL, conf.env.PREFIX]).startswith(conf.env.PREFIX):
+         Logs.warn("Default perl libdir is not under PREFIX. specify the path "
+@@ -54,4 +54,4 @@ def configure(conf):
+ 
+ 
+ def options(opt):
+-    opt.tool_options('perl')
++    opt.load('perl')
+diff -up xmms2-0.8DrO_o/src/clients/lib/python/wscript.fixme xmms2-0.8DrO_o/src/clients/lib/python/wscript
+--- xmms2-0.8DrO_o/src/clients/lib/python/wscript.fixme	2011-10-20 15:26:08.000000000 -0400
++++ xmms2-0.8DrO_o/src/clients/lib/python/wscript	2020-02-28 09:49:55.143637956 -0500
+@@ -79,7 +79,7 @@ def build(bld):
+     # TODO: Distribute .pxd files
+ 
+ def configure(conf):
+-    conf.check_tool('python')
++    conf.load('python')
+     if not conf.env.PYTHON:
+         conf.fatal("python not found")
+ 
+@@ -112,7 +112,7 @@ def configure(conf):
+                   "files, you should consider reconfiguring with --no-cython")
+ 
+ def options(opt):
+-    opt.tool_options('cython', tooldir = os.path.abspath('waftools'))
++    opt.load('cython', tooldir = os.path.abspath('waftools'))
+     opt.add_option('--no-cython', action="store_true",
+             dest="no_cython", default=False,
+             help="Use precompiled cython files even if cython is installed on "
+diff -up xmms2-0.8DrO_o/src/clients/lib/ruby/wscript.fixme xmms2-0.8DrO_o/src/clients/lib/ruby/wscript
+--- xmms2-0.8DrO_o/src/clients/lib/ruby/wscript.fixme	2011-10-20 15:26:08.000000000 -0400
++++ xmms2-0.8DrO_o/src/clients/lib/ruby/wscript	2020-02-28 09:49:55.143637956 -0500
+@@ -48,11 +48,11 @@ def build(bld):
+             )
+ 
+ def configure(conf):
+-    conf.check_tool("ruby")
++    conf.load("ruby")
+     conf.check_ruby_version((1,8,0))
+     conf.check_ruby_ext_devel()
+ 
+-    conf.check_cc(function_name="rb_protect_inspect", header_name="ruby.h",
++    conf.check_cc(header_name="ruby.h",
+             uselib="RUBYEXT", mandatory=False)
+ 
+     prefix = os.path.commonprefix([conf.env.ARCHDIR_RUBY, conf.env.PREFIX])
+@@ -70,4 +70,4 @@ def configure(conf):
+     return True
+ 
+ def options(opt):
+-    opt.tool_options('ruby', tdir=os.path.abspath('waftools'))
++    opt.load('ruby', tdir=os.path.abspath('waftools'))
+diff -up xmms2-0.8DrO_o/src/clients/lib/xmmsclient++/wscript.fixme xmms2-0.8DrO_o/src/clients/lib/xmmsclient++/wscript
+--- xmms2-0.8DrO_o/src/clients/lib/xmmsclient++/wscript.fixme	2011-10-20 15:26:08.000000000 -0400
++++ xmms2-0.8DrO_o/src/clients/lib/xmmsclient++/wscript	2020-02-28 09:49:55.143637956 -0500
+@@ -40,4 +40,4 @@ def configure(conf):
+     return True
+ 
+ def options(opt):
+-    opt.tool_options('boost')
++    opt.load('boost')
+diff -up xmms2-0.8DrO_o/src/clients/lib/xmmsclient/wscript.fixme xmms2-0.8DrO_o/src/clients/lib/xmmsclient/wscript
+--- xmms2-0.8DrO_o/src/clients/lib/xmmsclient/wscript.fixme	2011-10-20 15:26:08.000000000 -0400
++++ xmms2-0.8DrO_o/src/clients/lib/xmmsclient/wscript	2020-02-28 09:49:55.143637956 -0500
+@@ -39,8 +39,7 @@ def build(bld):
+ def configure(conf):
+     conf.env.XMMS_PKGCONF_FILES.append(("xmms2-client", "-lxmmsclient"))
+ 
+-    conf.check_cc(function_name="semtimedop",
+-            header_name=["sys/types.h", "sys/ipc.h", "sys/sem.h"],
++    conf.check_cc(header_name=["sys/types.h", "sys/ipc.h", "sys/sem.h"],
+             defines=["_GNU_SOURCE=1"], mandatory=False)
+     if not conf.env.HAVE_SEMTIMEDOP:
+         Logs.warn("Compiling visualization without shm support!")
+diff -up xmms2-0.8DrO_o/src/clients/medialib-updater/wscript.fixme xmms2-0.8DrO_o/src/clients/medialib-updater/wscript
+--- xmms2-0.8DrO_o/src/clients/medialib-updater/wscript.fixme	2011-10-20 15:26:08.000000000 -0400
++++ xmms2-0.8DrO_o/src/clients/medialib-updater/wscript	2020-02-28 09:49:55.143637956 -0500
+@@ -24,8 +24,7 @@ def configure(conf):
+     conf.check_cfg(package="gthread-2.0", uselib_store='gthread2',
+             args="--cflags --libs")
+ 
+-    conf.check_cc(function_name="g_file_query_file_type",
+-            header_name="gio/gio.h", uselib="gio2", mandatory=False)
++    conf.check_cc(header_name="gio/gio.h", uselib="gio2", mandatory=False)
+ 
+ 
+ def options(opt):
+diff -up xmms2-0.8DrO_o/src/clients/nycli/wscript.fixme xmms2-0.8DrO_o/src/clients/nycli/wscript
+--- xmms2-0.8DrO_o/src/clients/nycli/wscript.fixme	2011-10-20 15:26:08.000000000 -0400
++++ xmms2-0.8DrO_o/src/clients/nycli/wscript	2020-02-28 09:49:55.143637956 -0500
+@@ -1,4 +1,4 @@
+-from waflib import Options, Errors
++from waflib import Utils, Errors
+ 
+ source = """
+ main.c
+@@ -37,7 +37,7 @@ def build(bld):
+ 
+ 
+ def configure(conf):
+-    if Options.platform == 'win32':
++    if Utils.unversioned_sys_platform == 'win32':
+         conf.env.CLI_COMPAT_IMPL = 'win32'
+     else:
+         conf.env.CLI_COMPAT_IMPL = 'unix'
+@@ -49,8 +49,7 @@ def configure(conf):
+     # first try just linking against libreadline
+     try:
+         conf.check_cc(lib="readline", header_name=rl_headers,
+-                function_name='rl_filename_dequoting_function',
+-                uselib_store="readline", uselib="glib2")
++                      uselib_store="readline", uselib="glib2")
+     except Errors.ConfigurationError:
+         pass
+     else:
+diff -up xmms2-0.8DrO_o/src/clients/vistest/wscript.fixme xmms2-0.8DrO_o/src/clients/vistest/wscript
+--- xmms2-0.8DrO_o/src/clients/vistest/wscript.fixme	2020-02-28 09:49:55.137638098 -0500
++++ xmms2-0.8DrO_o/src/clients/vistest/wscript	2020-02-28 09:49:55.144637932 -0500
+@@ -1,4 +1,4 @@
+-import Options
++from waflib import Utils
+ 
+ def build(bld):
+     t = bld(features = 'c cprogram',
+@@ -46,7 +46,7 @@ def build(bld):
+             t.install_path = None
+ 
+ def configure(conf):
+-    if Options.platform == "win32":
++    if Utils.unversioned_sys_platform == "win32":
+         conf.fatal("visualisation clients not supported on windows")
+ 
+     conf.env.INSTALL_VIS_REFERENCE_CLIENTS = conf.options.with_vis_clients
+diff -up xmms2-0.8DrO_o/src/includepriv/wscript.fixme xmms2-0.8DrO_o/src/includepriv/wscript
+--- xmms2-0.8DrO_o/src/includepriv/wscript.fixme	2020-02-28 09:50:50.912314901 -0500
++++ xmms2-0.8DrO_o/src/includepriv/wscript	2020-02-28 09:51:04.246998545 -0500
+@@ -3,5 +3,5 @@ def configure(conf):
+ def options(conf):
+     pass
+ def build(bld):
+-    bld.add_subdirs("xmmspriv")
+-    bld.add_subdirs("xmmsclientpriv")
++    bld.recurse("xmmspriv")
++    bld.recurse("xmmsclientpriv")
+diff -up xmms2-0.8DrO_o/src/include/wscript.fixme xmms2-0.8DrO_o/src/include/wscript
+--- xmms2-0.8DrO_o/src/include/wscript.fixme	2011-10-20 15:26:08.000000000 -0400
++++ xmms2-0.8DrO_o/src/include/wscript	2020-02-28 09:49:55.144637932 -0500
+@@ -17,7 +17,7 @@ def build(bld):
+         #bld.install_files(os.path.join(bld.env.INCLUDEDIR, 'xmms2', p), " ".join(f))
+ 
+ def configure(conf):
+-    conf.sub_config("xmms")
++    conf.recurse("xmms")
+ 
+     return True
+ 
+diff -up xmms2-0.8DrO_o/src/include/xmms/wscript.fixme xmms2-0.8DrO_o/src/include/xmms/wscript
+--- xmms2-0.8DrO_o/src/include/xmms/wscript.fixme	2011-10-20 15:26:08.000000000 -0400
++++ xmms2-0.8DrO_o/src/include/xmms/wscript	2020-02-28 09:49:55.144637932 -0500
+@@ -1,5 +1,5 @@
+ import os, sys
+-from waflib import Options, Logs
++from waflib import Options, Logs, Utils
+ 
+ def build(bld):
+     pass
+@@ -20,7 +20,7 @@ def configure(conf):
+         else:
+             conf.fatal('The "%s" output plugin could not be found.' % (preferred))
+ 
+-    if Options.platform == 'darwin':
++    if Utils.unversioned_sys_platform == 'darwin':
+         uconf = 'Library/xmms2'
+         ucache = 'Library/xmms2/logs'
+     else:
+@@ -28,7 +28,7 @@ def configure(conf):
+         ucache = '.cache/xmms2'
+ 
+     sharedir = os.path.join(conf.env.DATADIR, 'xmms2')
+-    if Options.platform == 'win32':
++    if Utils.unversioned_sys_platform == 'win32':
+         # The plugin path in Windows should be relative, not absolute
+         conf.env.PLUGINDIR = 'Plugins/'
+     else:
+diff -up xmms2-0.8DrO_o/src/lib/xmmsutils/wscript.fixme xmms2-0.8DrO_o/src/lib/xmmsutils/wscript
+--- xmms2-0.8DrO_o/src/lib/xmmsutils/wscript.fixme	2011-10-20 15:26:08.000000000 -0400
++++ xmms2-0.8DrO_o/src/lib/xmmsutils/wscript	2020-02-28 09:49:55.144637932 -0500
+@@ -4,7 +4,7 @@
+ # Copyright (C) 2006-2011 XMMS2 Team
+ #
+ 
+-from waflib import Options, Logs, Errors
++from waflib import Options, Logs, Errors, Utils
+ 
+ def build(bld):
+     source = """
+@@ -26,14 +26,14 @@ def build(bld):
+ 
+ 
+ def configure(conf):
+-    if Options.platform == 'win32':
++    if Utils.unversioned_sys_platform == 'win32':
+         conf.env.util_impl = 'win32'
+     else:
+         conf.env.util_impl = 'unix'
+         try:
+-            conf.check_cc(function_name="nanosleep", header_name="time.h")
++            conf.check_cc(header_name="time.h")
+         except Errors.ConfigurationError:
+-            conf.check_cc(function_name="nanosleep", header_name="time.h",
++            conf.check_cc(header_name="time.h",
+                     lib="rt", uselib_store="rt")
+     return True
+ 
+diff -up xmms2-0.8DrO_o/src/lib/xmmsvisualization/wscript.fixme xmms2-0.8DrO_o/src/lib/xmmsvisualization/wscript
+--- xmms2-0.8DrO_o/src/lib/xmmsvisualization/wscript.fixme	2011-10-20 15:26:08.000000000 -0400
++++ xmms2-0.8DrO_o/src/lib/xmmsvisualization/wscript	2020-02-28 09:49:55.144637932 -0500
+@@ -21,7 +21,7 @@ def build(bld):
+ 
+ def configure(conf):
+     # Check for the modf function in the math lib
+-    conf.check_cc(function_name="modf", header_name="math.h",
++    conf.check_cc(header_name="math.h",
+             lib="m", uselib_store="math")
+     return True
+ 
+diff -up xmms2-0.8DrO_o/src/plugins/cdda/wscript.fixme xmms2-0.8DrO_o/src/plugins/cdda/wscript
+--- xmms2-0.8DrO_o/src/plugins/cdda/wscript.fixme	2011-10-20 15:26:08.000000000 -0400
++++ xmms2-0.8DrO_o/src/plugins/cdda/wscript	2020-02-28 09:49:55.145637908 -0500
+@@ -1,11 +1,11 @@
+ from waftools.plugin import plugin
+ 
+-import Options
++from waflib import Utils
+ 
+ def plugin_configure(conf):
+     conf.check_cfg(package="libcdio_cdda", args="--cflags --libs", uselib_store="cdda")
+     conf.check_cfg(package="libdiscid", args="--cflags --libs", uselib_store="discid")
+-    if Options.platform == "win32":
++    if Utils.unversioned_sys_platform == "win32":
+         conf.check_cc(lib="winmm", uselib_store="winmm", args="--cflags --libs")
+ 
+ configure, build = plugin("cdda", configure=plugin_configure,
+diff -up xmms2-0.8DrO_o/src/plugins/curl/wscript.fixme xmms2-0.8DrO_o/src/plugins/curl/wscript
+--- xmms2-0.8DrO_o/src/plugins/curl/wscript.fixme	2011-10-20 15:26:08.000000000 -0400
++++ xmms2-0.8DrO_o/src/plugins/curl/wscript	2020-02-28 09:49:55.145637908 -0500
+@@ -16,8 +16,7 @@ def plugin_configure(conf):
+     # This is a function this plugin uses and that was added to curl in
+     # version 7.12.0. We cannot check for the curl version as curl-config
+     # did not support version tests before version 7.15.0
+-    conf.check_cc(function_name="curl_multi_strerror",
+-            header_name="curl/curl.h", uselib="curl")
++    conf.check_cc(header_name="curl/curl.h", uselib="curl")
+ 
+ configure, build = plugin('curl', configure=plugin_configure,
+                           source=source, libs=["socket", "curl"])
+diff -up xmms2-0.8DrO_o/src/plugins/daap/wscript.fixme xmms2-0.8DrO_o/src/plugins/daap/wscript
+--- xmms2-0.8DrO_o/src/plugins/daap/wscript.fixme	2011-10-20 15:26:08.000000000 -0400
++++ xmms2-0.8DrO_o/src/plugins/daap/wscript	2020-02-28 09:49:55.146637885 -0500
+@@ -1,4 +1,4 @@
+-import Options
++from waflib 	import Options
+ from waftools.plugin import plugin
+ 
+ source = """
+diff -up xmms2-0.8DrO_o/src/plugins/file/wscript.fixme xmms2-0.8DrO_o/src/plugins/file/wscript
+--- xmms2-0.8DrO_o/src/plugins/file/wscript.fixme	2011-10-20 15:26:08.000000000 -0400
++++ xmms2-0.8DrO_o/src/plugins/file/wscript	2020-02-28 09:49:55.146637885 -0500
+@@ -7,9 +7,9 @@ def plugin_build(bld, obj):
+         obj.source.append('browse/gdir.c')
+ 
+ def plugin_configure(conf):
+-    conf.check_cc(function_name='fstatat', header_name=['fcntl.h','sys/stat.h'],
++    conf.check_cc(header_name=['fcntl.h','sys/stat.h'],
+             defines=['_ATFILE_SOURCE=1'])
+-    conf.check_cc(function_name='dirfd', header_name=['dirent.h','sys/types.h'])
++    conf.check_cc(header_name=['dirent.h','sys/types.h'])
+ 
+ configure, build = plugin("file",
+         configure=plugin_configure, build=plugin_build,
+diff -up xmms2-0.8DrO_o/src/xmms/wscript.fixme xmms2-0.8DrO_o/src/xmms/wscript
+--- xmms2-0.8DrO_o/src/xmms/wscript.fixme	2011-10-20 15:26:08.000000000 -0400
++++ xmms2-0.8DrO_o/src/xmms/wscript	2020-02-28 09:49:55.147637861 -0500
+@@ -5,7 +5,7 @@
+ #
+ 
+ import os
+-from waflib import Options, Logs, Errors
++from waflib import Options, Logs, Errors, Utils
+ 
+ source = """
+     config.c
+@@ -127,7 +127,7 @@ int main() {
+ 
+ def get_statfs_impl(conf):
+     # Detect the type of stat call used
+-    if Options.platform == 'win32':
++    if Utils.unversioned_sys_platform == 'win32':
+         return 'dummy'
+     else:
+         try:
+@@ -147,7 +147,7 @@ def get_statfs_impl(conf):
+                 else:
+                     return 'bsd'
+         else:
+-            if Options.platform == 'sunos':
++            if Utils.unversioned_sys_platform == 'sunos':
+                 return 'solaris'
+             else:
+                 return 'linux'
+@@ -155,7 +155,7 @@ def get_statfs_impl(conf):
+ # Get the implementation variant for the localtime_r function.
+ def get_localtime_impl(conf):
+     try:
+-        conf.check_cc(function_name='localtime_r', header_name='time.h')
++        conf.check_cc(header_name='time.h')
+     except Errors.ConfigurationError:
+         return 'dummy'
+     else:
+@@ -174,7 +174,7 @@ def get_thread_name_impl(conf):
+ 
+ # Get the implementation variant for signals, symlinks and uid check.
+ def get_compat_impl(conf):
+-    if Options.platform == 'win32':
++    if Utils.unversioned_sys_platform == 'win32':
+         return 'dummy'
+     else:
+         return 'unix'
+@@ -183,8 +183,7 @@ def get_visualization_impl(conf):
+     if conf.options.without_unixshmserver:
+         return 'dummy'
+ 
+-    conf.check_cc(function_name='semctl',
+-                  header_name=['sys/types.h','sys/ipc.h','sys/sem.h'],
++    conf.check_cc(header_name=['sys/types.h','sys/ipc.h','sys/sem.h'],
+                   mandatory=False)
+     try:
+         conf.check_cc(fragment=semun_fragment, uselib_store="semun",
+@@ -198,7 +197,7 @@ def get_visualization_impl(conf):
+     return 'dummy'
+ 
+ def configure(conf):
+-    conf.check_tool('python-generator', tooldir=os.path.abspath('waftools'))
++    conf.load('python-generator', tooldir=os.path.abspath('waftools'))
+ 
+     conf.check_cfg(package='gmodule-2.0', atleast_version='2.6.0',
+             uselib_store='gmodule2', args='--cflags --libs')
+@@ -208,7 +207,7 @@ def configure(conf):
+             uselib_store='sqlite3', args='--cflags --libs')
+ 
+     # Check for the sin function in the math lib
+-    conf.check_cc(lib='m', function_name='sin', header_name='math.h',
++    conf.check_cc(lib='m', header_name='math.h',
+                   uselib_store="math")
+ 
+     conf.env.compat_impl = get_compat_impl(conf)
+@@ -221,11 +220,11 @@ def configure(conf):
+         Logs.warn("Compiling visualization without shm support")
+ 
+     # Add Darwin stuff
+-    if Options.platform == 'darwin':
++    if Utils.unversioned_sys_platform == 'darwin':
+         conf.env.append_value('LINKFLAGS', ['-framework', 'CoreFoundation'])
+         conf.env.append_value('DEFINES', 'USE_BUNDLES')
+ 
+-    conf.env.xmms_shared_library = (Options.platform == 'win32')
++    conf.env.xmms_shared_library = (Utils.unversioned_sys_platform == 'win32')
+ 
+     conf.env.XMMS_PKGCONF_FILES.append(('xmms2-plugin', ''))
+ 
+diff -up xmms2-0.8DrO_o/waftools/cython_extra.py.fixme xmms2-0.8DrO_o/waftools/cython_extra.py
+--- xmms2-0.8DrO_o/waftools/cython_extra.py.fixme	2011-10-20 15:26:08.000000000 -0400
++++ xmms2-0.8DrO_o/waftools/cython_extra.py	2020-02-28 09:49:55.147637861 -0500
+@@ -3,37 +3,9 @@
+ 
+ import re
+ from waflib import Configure
+-from subprocess import Popen, STDOUT, PIPE
++import subprocess
+ 
+-# Borrowed from Python 2.7, subprocess.py
+-class CalledProcessError(Exception):
+-    """This exception is raised when a process run by check_call() or
+-    check_output() returns a non-zero exit status.
+-    The exit status will be stored in the returncode attribute;
+-    check_output() will also store the output in the output attribute.
+-    """
+-    def __init__(self, returncode, cmd, output=None):
+-        self.returncode = returncode
+-        self.cmd = cmd
+-        self.output = output
+-    def __str__(self):
+-        return "Command '%s' returned non-zero exit status %d" % (self.cmd, self.returncode)
+-
+-# Borrowed from Python 2.7, subprocess.py
+-def check_output(*popenargs, **kwargs):
+-    if 'stdout' in kwargs:
+-        raise ValueError('stdout argument not allowed, it will be overridden.')
+-    process = Popen(stdout=PIPE, *popenargs, **kwargs)
+-    output, unused_err = process.communicate()
+-    retcode = process.poll()
+-    if retcode:
+-        cmd = kwargs.get("args")
+-        if cmd is None:
+-            cmd = popenargs[0]
+-        raise CalledProcessError(retcode, cmd, output=output)
+-    return output
+-
+-cython_ver_re = re.compile('Cython version ([0-9.]+)')
++cython_ver_re = re.compile(b'Cython version ([0-9.]+)')
+ def check_cython_version(self, version=None, minver=None, maxver=None):
+ 	log_s = []
+ 	if version:
+@@ -53,15 +25,15 @@ def check_cython_version(self, version=N
+ 		minver = tuple(map(int, minver))
+ 	if maxver:
+ 		maxver = tuple(map(int, maxver))
+-	
+-	# Trick to be compatible python 2.x and 3.x
+-	try:
+-		u = unicode
+-	except NameError:
+-		u = str
+ 
+-	cmd = [self.env.CYTHON, '-V']
+-	o = u(check_output(cmd, stderr=STDOUT), 'UTF-8').strip()
++	if isinstance(self.env.CYTHON, list):
++		cmdbin = " "
++		cmdbin = cmdbin.join(self.env.CYTHON)
++	else:
++		cmdbin = self.env.CYTHON
++
++	cmd = [cmdbin, '-V']
++	o = subprocess.check_output(cmd, stderr=subprocess.STDOUT).strip()
+ 	m = cython_ver_re.match(o)
+ 	self.start_msg('Checking for cython version')
+ 	if not m:
+@@ -69,11 +41,11 @@ def check_cython_version(self, version=N
+ 		self.fatal("No version found")
+ 	else:
+ 		v = m.group(1)
+-		ver = tuple(map(int, v.split('.')))
++		ver = tuple(map(int, v.split(b'.')))
+ 		check = (not minver or minver <= ver) and (not maxver or maxver >= ver)
+ 		self.to_log('  cython %s\n  -> %r\n' % (" ".join(log_s), v))
+ 		if check:
+-			self.end_msg(v)
++			self.end_msg(v.decode("utf-8"))
+ 			self.env.CYTHON_VERSION = ver
+ 		else:
+ 			self.end_msg('wrong version %s' % v, 'YELLOW')
+diff -up xmms2-0.8DrO_o/waftools/man.py.fixme xmms2-0.8DrO_o/waftools/man.py
+--- xmms2-0.8DrO_o/waftools/man.py.fixme	2011-10-20 15:26:08.000000000 -0400
++++ xmms2-0.8DrO_o/waftools/man.py	2020-02-28 09:49:55.147637861 -0500
+@@ -2,7 +2,7 @@ from waflib import Task, Errors, Utils
+ import os
+ import gzip
+ 
+-from TaskGen import feature,before_method
++from waflib.TaskGen import feature,before_method
+ 
+ def gzip_func(task):
+     infile = task.inputs[0].abspath()
+diff -up xmms2-0.8DrO_o/waftools/python-generator.py.fixme xmms2-0.8DrO_o/waftools/python-generator.py
+--- xmms2-0.8DrO_o/waftools/python-generator.py.fixme	2011-10-20 15:26:08.000000000 -0400
++++ xmms2-0.8DrO_o/waftools/python-generator.py	2020-02-28 09:49:55.147637861 -0500
+@@ -1,6 +1,5 @@
+-import Task
+-import TaskGen
+-from TaskGen import extension
++from waflib import TaskGen
++from waflib.TaskGen import extension
+ import sys
+ 
+ TaskGen.declare_chain(
+diff -up xmms2-0.8DrO_o/waftools/tool.py.fixme xmms2-0.8DrO_o/waftools/tool.py
+--- xmms2-0.8DrO_o/waftools/tool.py.fixme	2020-02-28 09:49:55.130638264 -0500
++++ xmms2-0.8DrO_o/waftools/tool.py	2020-02-28 09:49:55.147637861 -0500
+@@ -1,4 +1,4 @@
+-import Utils
++from waflib import Utils
+ import os
+ 
+ def add_install_flag(bld, obj):
+diff -up xmms2-0.8DrO_o/wscript.fixme xmms2-0.8DrO_o/wscript
+--- xmms2-0.8DrO_o/wscript.fixme	2020-02-28 09:49:55.141638004 -0500
++++ xmms2-0.8DrO_o/wscript	2020-02-28 09:50:32.736746099 -0500
+@@ -113,9 +113,9 @@ def build(bld):
+         bld.fatal("You need to run waf configure")
+         raise SystemExit()
+ 
+-    bld.add_subdirs(subdirs)
+-    bld.add_subdirs(plugindirs)
+-    bld.add_subdirs(optionaldirs)
++    bld.recurse(subdirs)
++    bld.recurse(plugindirs)
++    bld.recurse(optionaldirs)
+ 
+     for name, lib in bld.env.XMMS_PKGCONF_FILES:
+         bld(features = 'subst',
+@@ -170,7 +170,7 @@ def _configure_optionals(conf):
+     for o in selected_optionals:
+         x = [x for x in optional_subdirs if os.path.basename(x) == o][0]
+         try:
+-            conf.sub_config(x)
++            conf.recurse(x)
+             conf.env.append_value('XMMS_OPTIONAL_BUILD', x)
+             succeeded_optionals.add(o)
+         except Errors.ConfigurationError:
+@@ -220,7 +220,7 @@ def _configure_plugins(conf):
+ 
+     for plugin in selected_plugins:
+         try:
+-            conf.sub_config("src/plugins/%s" % plugin)
++            conf.recurse("src/plugins/%s" % plugin)
+             if (not conf.env.XMMS_PLUGINS_ENABLED or
+                     (len(conf.env.XMMS_PLUGINS_ENABLED) > 0 and
+                         conf.env.XMMS_PLUGINS_ENABLED[-1] != plugin)):
+@@ -277,14 +277,14 @@ def configure(conf):
+         conf.env.BUILD_XMMS2D = True
+         subdirs.insert(0, "src/xmms")
+ 
+-    conf.check_tool('gnu_dirs')
+-    conf.check_tool('man', tooldir=os.path.abspath('waftools'))
+-    conf.check_tool('misc')
+-    conf.check_tool('gcc')
+-    conf.check_tool('g++')
++    conf.load('gnu_dirs')
++    conf.load('man', tooldir=os.path.abspath('waftools'))
++    ## conf.load('misc')
++    conf.load('gcc')
++    conf.load('g++')
+ 
+-    if conf.options.target_platform:
+-        Options.platform = conf.options.target_platform
++    ## if conf.options.target_platform:
++        ## Options.platform = conf.options.target_platform
+ 
+     nam,changed = gittools.get_info()
+     conf.msg("git commit id", nam)
+@@ -340,7 +340,7 @@ def configure(conf):
+             conf.env.prepend_value('LIBPATH', os.path.join(d, 'lib'))
+             conf.env.prepend_value('CPPPATH', os.path.join(d, 'include'))
+ 
+-    if Options.platform != 'win32':
++    if Utils.unversioned_sys_platform != 'win32':
+         conf.env.append_unique('CFLAGS_cstlib', ['-fPIC', '-DPIC'])
+         conf.env.append_unique('CPPFLAGS_cxxshlib', ['-fPIC', '-DPIC'])
+     else:
+@@ -356,14 +356,14 @@ def configure(conf):
+         conf.env.cshlib_PATTERN = 'lib%s.dll'
+         conf.env.cprogram_PATTERN = '%s.exe'
+ 
+-    if Options.platform == 'darwin':
++    if Utils.unversioned_sys_platform == 'darwin':
+         conf.env.append_value('LINKFLAGS', '-multiply_defined_suppress')
+         conf.env.explicit_install_name = True
+     else:
+         conf.env.explicit_install_name = False
+ 
+-    if Options.platform == 'sunos':
+-        conf.check_cc(function_name='socket', lib='socket', header_name='sys/socket.h', uselib_store='socket')
++    if Utils.unversioned_sys_platform == 'sunos':
++        conf.check_cc(lib='socket', header_name='sys/socket.h', uselib_store='socket')
+         if not conf.env.HAVE_SOCKET:
+             conf.fatal("xmms2 requires libsocket on Solaris.")
+             raise SystemExit(1)
+@@ -371,7 +371,7 @@ def configure(conf):
+         conf.env.append_unique('CFLAGS', '-D_REENTRANT')
+         conf.env.append_unique('CFLAGS', '-std=gnu99')
+         conf.env.socket_impl = 'socket'
+-    elif Options.platform == 'win32':
++    elif Utils.unversioned_sys_platform == 'win32':
+         if conf.options.winver:
+             major, minor = [int(x) for x in Options.options.winver.split('.')]
+         else:
+@@ -413,9 +413,9 @@ int main() { return 0; }
+         conf.env.socket_impl = 'posix'
+ 
+     conf.env.xmms_icon = False
+-    if Options.platform == 'win32':
++    if Utils.unversioned_sys_platform == 'win32':
+         try:
+-            conf.check_tool('winres')
++            conf.load('winres')
+         except Errors.ConfigurationError:
+             pass
+         else:
+@@ -425,7 +425,7 @@ int main() { return 0; }
+     # TaskGen.mac_bundle option seems to be no longer silently ignored
+     # if gcc -bundle option is not available.
+     # TODO: Add --no-mac-bundle in options ?
+-    conf.env.mac_bundle_enabled = Options.platform == 'darwin'
++    conf.env.mac_bundle_enabled = Utils.unversioned_sys_platform == 'darwin'
+ 
+     conf.check_cfg(package='glib-2.0', atleat_version='2.8.0',
+             uselib_store='glib2', args='--cflags --libs')
+@@ -439,7 +439,7 @@ int main() { return 0; }
+     newest = get_newest(subdirs, plugindirs, optionaldirs)
+     conf.env.NEWEST_WSCRIPT_SUBDIR = newest
+ 
+-    [conf.sub_config(s) for s in subdirs]
++    [conf.recurse(s) for s in subdirs]
+     conf.write_config_header('xmms_configuration.h')
+ 
+     output_plugins = [name for x, name in conf.env.XMMS_OUTPUT_PLUGINS if x > 0]
+@@ -464,8 +464,8 @@ def _list_cb(option, opt, value, parser)
+     setattr(parser.values, option.dest, vals)
+ 
+ def options(opt):
+-    opt.tool_options('gnu_dirs')
+-    opt.tool_options('gcc')
++    opt.load('gnu_dirs')
++    opt.load('gcc')
+ 
+     opt.add_option('--with-custom-version', type='string',
+                    dest='customversion', help="Override git commit hash version")
+@@ -503,9 +503,9 @@ def options(opt):
+     opt.add_option('--without-ldconfig', action='store_false',
+                    dest='ldconfig', help="Don't run ldconfig after install")
+ 
+-    opt.sub_options("src/xmms")
++    opt.recurse("src/xmms")
+     for o in optional_subdirs + subdirs:
+-        opt.sub_options(o)
++        opt.recurse(o)
+ 
+ def shutdown(ctx):
+     if ctx.cmd != 'install':
diff --git a/xmms2-version.patch b/xmms2-version.patch
index 2869112..1bb9c01 100644
--- a/xmms2-version.patch
+++ b/xmms2-version.patch
@@ -1,11 +1,11 @@
---- xmms2-0.7DrNo/wscript.orig	2023-06-23 06:29:12.321345610 +0200
-+++ xmms2-0.7DrNo/wscript	2023-06-23 06:29:55.905086544 +0200
-@@ -273,7 +273,7 @@ def configure(conf):
-         if changed:
-             dirty="-dirty"
-         conf.check_message("uncommitted changes", "", bool(changed))
--        conf.env["VERSION"] = BASEVERSION + " (git commit: %s%s)" % (nam, dirty)
-+        conf.env["VERSION"] = BASEVERSION
+--- xmms2-0.8DrO_o/wscript.orig	2023-06-24 11:34:31.911090412 +0200
++++ xmms2-0.8DrO_o/wscript	2023-06-24 11:35:23.207479182 +0200
+@@ -293,7 +293,7 @@ def configure(conf):
+     else:
+         dirty = changed and "-dirty" or ""
+         conf.msg("uncommited changed", changed and "yes" or "no")
+-        conf.env.VERSION = "%s (git commit: %s%s)" % (BASEVERSION, nam, dirty)
++        conf.env.VERSION = BASEVERSION
  
-     for warning in ('all',
-                     'no-format-extra-args',
+     if conf.options.with_profiling:
+         conf.env.with_profiling = True
diff --git a/xmms2-waf.patch b/xmms2-waf.patch
index 1a58002..e1b73f8 100644
--- a/xmms2-waf.patch
+++ b/xmms2-waf.patch
@@ -1,18 +1,12 @@
---- xmms2-0.7DrNo/wscript.orig	2023-06-23 06:27:29.055856784 +0200
-+++ xmms2-0.7DrNo/wscript	2023-06-23 06:28:26.602468011 +0200
-@@ -275,7 +275,6 @@ def configure(conf):
-         conf.check_message("uncommitted changes", "", bool(changed))
-         conf.env["VERSION"] = BASEVERSION + " (git commit: %s%s)" % (nam, dirty)
- 
--    conf.env["CCFLAGS"] = Utils.to_list(conf.env["CCFLAGS"]) + ['-g', '-O0']
-     for warning in ('all',
-                     'no-format-extra-args',
-                     'no-format-zero-length',
-@@ -295,7 +294,6 @@ def configure(conf):
-             # autogenerate uselib definitions to disable warnings
-             conf.env["CCFLAGS_NO%s" % warning.replace("-","").upper()] = ["-Wno-%s" % warning]
- 
--    conf.env["CXXFLAGS"] = Utils.to_list(conf.env["CXXFLAGS"]) + ['-g', '-O0']
-     conf.env['XMMS_PKGCONF_FILES'] = []
-     conf.env['XMMS_OUTPUT_PLUGINS'] = [(-1, "NONE")]
+--- xmms2-0.8DrO_o/wscript.orig	2023-06-24 11:28:29.276388306 +0200
++++ xmms2-0.8DrO_o/wscript	2023-06-24 11:34:20.147820806 +0200
+@@ -295,9 +295,6 @@ def configure(conf):
+         conf.msg("uncommited changed", changed and "yes" or "no")
+         conf.env.VERSION = "%s (git commit: %s%s)" % (BASEVERSION, nam, dirty)
  
+-    conf.env.append_unique('CFLAGS', ['-g', '-O0'])
+-    conf.env.append_unique('CXXFLAGS', ['-g', '-O0'])
+-
+     if conf.options.with_profiling:
+         conf.env.with_profiling = True
+         conf.env.append_unique('CFLAGS', ['--coverage'])
================================================================

---- gitweb:

http://git.pld-linux.org/gitweb.cgi/packages/xmms2.git/commitdiff/26d9461bad8ce73f84b4c5ca9cd69e00a5318e43



More information about the pld-cvs-commit mailing list