rpms/audacious-plugins/F-12 audacious-plugins-2.2-ladspa-restore.patch, NONE, 1.1 audacious-plugins.spec, 1.86, 1.87
Michael Schwendt
mschwendt at fedoraproject.org
Thu Feb 4 11:06:23 UTC 2010
Author: mschwendt
Update of /cvs/pkgs/rpms/audacious-plugins/F-12
In directory cvs1.fedora.phx.redhat.com:/tmp/cvs-serv1698
Modified Files:
audacious-plugins.spec
Added Files:
audacious-plugins-2.2-ladspa-restore.patch
Log Message:
* Thu Feb 4 2010 Michael Schwendt <mschwendt at fedoraproject.org> - 2.2-16
- Restore and fix the restore() function in "ladspa" plugin (#561635).
- Substitute hardcoded ladspa search paths in source code.
audacious-plugins-2.2-ladspa-restore.patch:
ladspa.c | 25 ++++++++++++++-----------
1 file changed, 14 insertions(+), 11 deletions(-)
--- NEW FILE audacious-plugins-2.2-ladspa-restore.patch ---
diff -Nur audacious-plugins-2.2-orig/src/ladspa/ladspa.c audacious-plugins-2.2-ladspa/src/ladspa/ladspa.c
--- audacious-plugins-2.2-orig/src/ladspa/ladspa.c 2009-11-22 23:49:53.000000000 +0100
+++ audacious-plugins-2.2-ladspa/src/ladspa/ladspa.c 2010-02-04 12:03:19.000000000 +0100
@@ -145,7 +145,6 @@
static void restore(void)
{
-#if 0
mcs_handle_t *db;
gint k, plugins = 0;
@@ -157,16 +156,20 @@
gint id;
int port, ports = 0;
plugin_instance *instance;
- gchar *bn, *section;
+ gchar *bn, *section, *file;
- bn = g_path_get_basename(instance->filename);
- section = g_strdup_printf("ladspa_plugin:%s:%d", bn, k);
- g_free(bn);
+ section = g_strdup_printf("ladspa_plugin%ld", k);
aud_cfg_db_get_int(db, section, "id", &id);
aud_cfg_db_get_int(db, section, "ports", &ports);
-
- instance = add_plugin(get_plugin_by_id(id));
+ if (!aud_cfg_db_get_string(db, section, "file", &file)) {
+ g_free(section);
+ continue;
+ }
+ bn = g_path_get_basename(file);
+ g_free(string);
+ instance = add_plugin(get_plugin_by_id(bn,id));
+ g_free(bn);
if (!instance)
continue; /* couldn't load this plugin */
@@ -180,7 +183,6 @@
}
aud_cfg_db_close(db);
-#endif
state.initialised = TRUE;
}
@@ -222,8 +224,8 @@
if (ladspa_path == NULL)
{
/* Fallback, look in obvious places */
- find_plugins("/usr/lib/ladspa");
- find_plugins("/usr/local/lib/ladspa");
+ find_plugins("__RPM_LIBDIR__/ladspa");
+ find_plugins("/usr/local/__RPM_LIB__/ladspa");
}
else
{
@@ -306,7 +308,7 @@
int port, ports = 0;
bn = g_path_get_basename(instance->filename);
- section = g_strdup_printf("ladspa_plugin:%s:%ld", bn, instance->descriptor->UniqueID);
+ section = g_strdup_printf("ladspa_plugin%ld", plugins);
g_free(bn);
aud_cfg_db_set_int(db, section, "id", instance->descriptor->UniqueID);
@@ -325,6 +327,7 @@
aud_cfg_db_set_int(db, section, "ports", ports);
g_free(section);
ladspa_shutdown(instance);
+ plugins++;
}
G_UNLOCK(running_plugins);
Index: audacious-plugins.spec
===================================================================
RCS file: /cvs/pkgs/rpms/audacious-plugins/F-12/audacious-plugins.spec,v
retrieving revision 1.86
retrieving revision 1.87
diff -u -p -r1.86 -r1.87
--- audacious-plugins.spec 3 Feb 2010 20:52:11 -0000 1.86
+++ audacious-plugins.spec 4 Feb 2010 11:06:23 -0000 1.87
@@ -5,7 +5,7 @@
Name: audacious-plugins
Version: 2.2
-Release: 15%{?dist}
+Release: 16%{?dist}
Summary: Plugins for the Audacious media player
Group: Applications/Multimedia
URL: http://audacious-media-player.org/
@@ -44,8 +44,12 @@ Patch8: audacious-plugins-2.2-neon-sessi
Patch9: audacious-plugins-2.2-adplug-fclose.patch
#
Patch10: audacious-plugins-2.2-adplug-lds.patch
-#
+# reported upstream (AUDPLUG-180), as a rewrite of the plugin
+# would be better
Patch11: audacious-plugins-2.2-streambrowser-race.patch
+# huh? AUDPLUG-161 / bz561635
+# plus: hardcoded libdir replacement
+Patch12: audacious-plugins-2.2-ladspa-restore.patch
BuildRequires: audacious-devel >= %{aud_ver}
BuildRequires: jack-audio-connection-kit-devel libsamplerate-devel
@@ -187,6 +191,14 @@ in Vortex (.vtx) format.
%patch9 -p1 -b .adplug-fclose
%patch10 -p1 -b .lds-out-of-bounds
%patch11 -p1 -b .streambrowser-race
+%patch12 -p1 -b .ladspa-restore
+
+for i in src/ladspa/ladspa.c
+do
+ sed -i -e 's!__RPM_LIBDIR__!%{_libdir}!g' $i
+ sed -i -e 's!__RPM_LIB__!%{_lib}!g' $i
+done
+grep -q -s __RPM_LIB * -R && exit 1
sed -i '\,^.SILENT:,d' buildsys.mk.in
@@ -280,6 +292,10 @@ update-desktop-database &> /dev/null ||
%changelog
+* Thu Feb 4 2010 Michael Schwendt <mschwendt at fedoraproject.org> - 2.2-16
+- Restore and fix the restore() function in "ladspa" plugin (#561635).
+- Substitute hardcoded ladspa search paths in source code.
+
* Wed Feb 3 2010 Michael Schwendt <mschwendt at fedoraproject.org> - 2.2-15
- Prevent race condition crash in streambrowser GUI (#561469).
More information about the scm-commits
mailing list