From: SourceForge.net <no...@so...> - 2007-04-07 17:37:37
|
Bugs item #1693716, was opened at 2007-04-03 08:35 Message generated for change (Comment added) made by nobody You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=109655&aid=1693716&group_id=9655 Please note that this message will contain a full copy of the comment thread, including the initial issue submission, for this request, not just the latest update. Category: None Group: None Status: Open Resolution: None Priority: 5 Private: No Submitted By: ludovic p (pludov) Assigned to: Nobody/Anonymous (nobody) Summary: xine_fast_memcpy not usable outside xinelibs Initial Comment: The function xine_fast_memcpy cannot be used outside of xinelib. The following simple test program illustrates the problem : it is working with 1.1.2 but fails with 1.1.4. (tested on stock ubuntu versions : from 6.0 and feisty). However, part of xine which require xine_fast_memcpy doesn't seem to have problem (plugin, for example) On 1.1.4, xine_fast_memcpy is 0 after xine_init ! However, I traced the xine_init function and noticed that the affectation to xine_fast_memcpy was performed correctly with a non null value ! Maybe it's a linker problem (it seems that the program and the library doesn't share the same variable...) #include <stdio.h> #include <xine.h> #include <xine/xineutils.h> char * a = "0123456789"; char b [20]; extern int plop_memcpy; int main() { xine_t * xine; xine = xine_new(); xine_init(xine); printf("xine memcpy is %p\n", (void*)xine_fast_memcpy); xine_fast_memcpy(b, a, 10); } ---------------------------------------------------------------------- Comment By: Nobody/Anonymous (nobody) Date: 2007-04-07 10:37 Message: Logged In: NO Keeping xine-internals symbol accessible from outside of xine-lib tree is useful : In my case (ost-box), I wrote a specific output plugin (static) outside of xine tree, to correctly handle video output incrustation in my program. This plugin requires some of the xinelib internals, like memcpy, the aligned malloc, the monotonic clocks ... Using these already available functions saves some code duplication, and my output plugin may benefit from futur improvments to theses functions. ---------------------------------------------------------------------- Comment By: Diego Pettenò (dgp85) Date: 2007-04-07 07:13 Message: Logged In: YES user_id=60011 Originator: NO I think I know the problem now: xine_fast_memcpy is declared with protected visibility, which means it's bound to different symbols for xine-lib and plugins (local) and for applications using it (global). In my opinion, this is not a bug, as I can't see any reason to use xine_fast_memcpy outside of xine-lib scope anyway. ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=109655&aid=1693716&group_id=9655 |