aboutsummaryrefslogtreecommitdiff
Support the PURPLE_PLUGIN_PATH environment variable.  This patch is based on
one from Nixpkgs, but properly handles the case where that variable is unset.

--- pidgin-2.10.11/libpurple/plugin.c.orig	2014-11-23 11:41:25.000000000 -0500
+++ pidgin-2.10.11/libpurple/plugin.c	2015-08-04 14:31:02.257366144 -0400
@@ -1178,8 +1178,19 @@
 void
 purple_plugins_init(void) {
 	void *handle = purple_plugins_get_handle();
+	const gchar *purple_plugin_path;
 
 	purple_plugins_add_search_path(LIBDIR);
+	purple_plugin_path = g_getenv("PURPLE_PLUGIN_PATH");
+	if (purple_plugin_path && *purple_plugin_path) {
+		gchar **paths = g_strsplit(purple_plugin_path, ":", -1);
+		if (paths) {
+			gchar **p;
+			for (p = paths; *p; ++p)
+				if (**p) purple_plugins_add_search_path(*p);
+		}
+		g_strfreev(paths);
+	}
 
 	purple_signal_register(handle, "plugin-load",
 						 purple_marshal_VOID__POINTER,
erprint. Change-Id: Ic34f364dfc46e403e1d431e5860a63b36143b6f3 Leo Famulari 2023-08-13.guix-authorizations: Authorise Hilton Chain....* .guix-authorizations (hako): Add OpenPGP key fingerprint. Tobias Geerinckx-Rice 2023-06-14.guix-authorizations: Remove Lars-Dominik Braun’s professional key....* .guix-authorizations: Remove from lbraun (professional). Lars-Dominik Braun 2023-05-15.guix-authorizations: Authorize Jorge Gomez....* .guix-authorizations (jgart): Add OpenPGP key fingerprint. Maxim Cournoyer 2023-05-11.guix-authorizations: Authorize Josselin Poiret....* .guix-authorizations (jpoiret): Add OpenPGP key fingerprint. Maxim Cournoyer 2023-05-11.guix-authorizations: Authorize Simon Tournier....* .guix-authorizations (zimoun): Add OpenPGP key fingerprint. Maxim Cournoyer 2023-03-24.guix-authorizations: Remove Paul Garlick due to inactivity....* .guix-authorizations: Remove from pgarlick. Leo Famulari 2023-03-24.guix-authorizations: Remove Jakub Kądziołka due to inactivity....* .guix-authorizations: Remove niedzejkob. Leo Famulari 2023-03-24.guix-authorizations: Remove Chris Marusich due to inactivity....* .guix-authorizations: Remove marusich. Leo Famulari 2023-03-24.guix-authorizations: Remove Brice Waegeneire due to inactivity....* .guix-authorizations: Remove bricewge. Leo Famulari 2023-03-24.guix-authorizations: Remove Alex Kost due to inactivity....* .guix-authorizations: Remove alezost. Leo Famulari 2022-12-11.guix-authorizations: Authorise John Kehayias....* .guix-authorizations (podiki): Add OpenPGP key fingerprint. Tobias Geerinckx-Rice 2022-11-08authorizations: Remove old key for "davexunit"....* .guix-authorizations ("davexunit"): Remove. ("davexunit (2nd)"): Rename to "dthompson". David Thompson 2022-08-11.guix-authorizations: Authorize Andrew Tropin's subkey instead....Addresses <https://issues.guix.gnu.org/57091> for now. * .guix-authorizations (abcdw): Use signing subkey instead of primary. Tobias Geerinckx-Rice 2022-08-05.git-authorizations: Authorize Andrew Tropin....* .git-authorizations (abcdw): Add OpenPGP key fingerprint. Efraim Flashner 2022-01-25.guix-authorizations: Authorize Vinicius Monego....* .guix-authorizations (monego): Add OpenPGP key fingerprint. Maxim Cournoyer