--- lib/cpluff/libcpluff/cpluff.c.orig	2015-05-11 07:54:22 UTC
+++ lib/cpluff/libcpluff/cpluff.c
@@ -77,6 +77,7 @@ CP_C_API const char *cp_get_host_type(vo
 	return CP_HOST;
 }
 
+#if defined(CP_THREADS) || !defined(NDEBUG)
 CP_HIDDEN void cpi_lock_framework(void) {
 #if defined(CP_THREADS)
 	cpi_lock_mutex(framework_mutex);
@@ -93,6 +94,7 @@ CP_HIDDEN void cpi_unlock_framework(void
 	framework_locked--;
 #endif
 }
+#endif
 
 static void reset(void) {
 #ifdef CP_THREADS
--- lib/cpluff/libcpluff/logging.c.orig	2015-05-11 07:54:22 UTC
+++ lib/cpluff/libcpluff/logging.c
@@ -129,10 +129,12 @@ CP_C_API cp_status_t cp_register_logger(
 	// Report error
 	if (status == CP_ERR_RESOURCE) {
 		cpi_error(context, N_("Logger could not be registered due to insufficient memory."));		
+#if defined(CP_THREADS) || !defined(NDEBUG)
 	} else if (cpi_is_logged(context, CP_LOG_DEBUG)) {
 		char owner[64];
 		/* TRANSLATORS: %s is the context owner */
 		cpi_debugf(context, N_("%s registered a logger."), cpi_context_owner(context, owner, sizeof(owner)));
+#endif
 	}
 	cpi_unlock_context(context);
 
@@ -166,11 +168,13 @@ CP_C_API void cp_unregister_logger(cp_co
 		free(lh);
 		update_logging_limits(context);
 	}
+#if defined(CP_THREADS) || !defined(NDEBUG)
 	if (cpi_is_logged(context, CP_LOG_DEBUG)) {
 		char owner[64];
 		/* TRANSLATORS: %s is the context owner */
 		cpi_debugf(context, N_("%s unregistered a logger."), cpi_context_owner(context, owner, sizeof(owner)));
 	}
+#endif
 	cpi_unlock_context(context);
 }
 
--- lib/cpluff/libcpluff/pinfo.c.orig	2015-05-11 07:54:22 UTC
+++ lib/cpluff/libcpluff/pinfo.c
@@ -569,10 +569,12 @@ CP_C_API cp_status_t cp_register_plisten
 	// Report error or success
 	if (status != CP_OK) {
 		cpi_error(context, _("A plug-in listener could not be registered due to insufficient memory."));
+#if defined(CP_THREADS) || !defined(NDEBUG)
 	} else if (cpi_is_logged(context, CP_LOG_DEBUG)) {
 		char owner[64];
 		/* TRANSLATORS: %s is the context owner */
 		cpi_debugf(context, N_("%s registered a plug-in listener."), cpi_context_owner(context, owner, sizeof(owner)));
+#endif
 	}
 	cpi_unlock_context(context);
 	
@@ -591,11 +593,13 @@ CP_C_API void cp_unregister_plistener(cp
 	if (node != NULL) {
 		process_unregister_plistener(context->env->plugin_listeners, node, NULL);
 	}
+#if defined(CP_THREADS) || !defined(NDEBUG)
 	if (cpi_is_logged(context, CP_LOG_DEBUG)) {
 		char owner[64];
 		/* TRANSLATORS: %s is the context owner */
 		cpi_debugf(context, N_("%s unregistered a plug-in listener."), cpi_context_owner(context, owner, sizeof(owner)));
 	}
+#endif
 	cpi_unlock_context(context);
 }
 
--- lib/cpluff/libcpluff/psymbol.c.orig	2015-05-11 07:54:22 UTC
+++ lib/cpluff/libcpluff/psymbol.c
@@ -248,11 +248,13 @@ CP_C_API void * cp_resolve_symbol(cp_con
 		symbol_info->usage_count++;
 		provider_info->usage_count++;
 
+#if defined(CP_THREADS) || !defined(NDEBUG)
 		if (cpi_is_logged(context, CP_LOG_DEBUG)) {
 			char owner[64];
 			/* TRANSLATORS: First %s is the context owner */
 			cpi_debugf(context, "%s resolved symbol %s defined by plug-in %s.", cpi_context_owner(context, owner, sizeof(owner)), name, id);
 		}
+#endif
 	} while (0);
 
 	// Clean up
@@ -314,11 +316,13 @@ CP_C_API void cp_release_symbol(cp_conte
 		if (symbol_info->usage_count == 0) {
 			hash_delete_free(context->resolved_symbols, node);
 			free(symbol_info);
+#if defined(CP_THREADS) || !defined(NDEBUG)
 			if (cpi_is_logged(context, CP_LOG_DEBUG)) {
 				char owner[64];
 				/* TRANSLATORS: First %s is the context owner */
 				cpi_debugf(context, _("%s released the symbol at address %p defined by plug-in %s."), cpi_context_owner(context, owner, sizeof(owner)), ptr, provider_info->plugin->plugin->identifier);
 			}
+#endif
 		}
 	
 		// Check if the symbol providing plug-in is not being used anymore
--- xbmc/screensavers/rsxs-0.9/lib/argp-fmtstream.h.orig	2015-05-11 07:54:22 UTC
+++ xbmc/screensavers/rsxs-0.9/lib/argp-fmtstream.h
@@ -198,8 +198,12 @@ extern int __argp_fmtstream_ensure (argp
 #endif
 
 #ifndef ARGP_FS_EI
+#ifdef __clang__
+#define ARGP_FS_EI extern inline __attribute__ ((__gnu_inline__))
+#else
 #define ARGP_FS_EI extern inline
 #endif
+#endif
 
 ARGP_FS_EI size_t
 __argp_fmtstream_write (argp_fmtstream_t __fs,
