[Gstreamer-bugs] [Bug 106097] New - Build fails on SPARC64 running Linux 2.4.20 SMP

bugzilla-daemon at widget.gnome.org bugzilla-daemon at widget.gnome.org
Fri Feb 14 07:42:25 PST 2003


Please do not reply to this email- if you want to comment on the bug, go to the
URL shown below and enter your comments there.

http://bugzilla.gnome.org/show_bug.cgi?id=106097

Changed by jochen.kmietsch at tu-clausthal.de.

--- shadow/106097	Fri Feb 14 10:42:25 2003
+++ shadow/106097.tmp.20227	Fri Feb 14 10:42:25 2003
@@ -0,0 +1,88 @@
+Bug#: 106097
+Product: GStreamer
+Version: 0.6.0
+OS: Linux
+OS Details: SuSE 7.3 on a SPARC64 with SMP-Kernel
+Status: NEW   
+Resolution: 
+Severity: normal
+Priority: Normal
+Component: gstreamer (core)
+AssignedTo: gstreamer-maint at bugzilla.gnome.org                            
+ReportedBy: jochen.kmietsch at tu-clausthal.de               
+QAContact: gstreamer-maint at bugzilla.gnome.org
+TargetMilestone: 0.6.x
+URL: 
+Summary: Build fails on SPARC64 running Linux 2.4.20 SMP
+
+Hello!
+
+When trying to build GStreamer on a Linux/SPARC host (SuSE 7.3, SPARC64
+architecture), configure detects this:
+
+checking for asm/atomic.h... yes
+configure: WARNING: Atomic reference counting is out of date: doing without.
+checking ucontext.h usability... yes
+
+It then fails with:
+In file included from gstatomic.c:24:
+gstatomic_impl.h: In function `gst_atomic_int_dec_and_test':
+gstatomic_impl.h:274: `val' undeclared (first use in this function)
+gstatomic_impl.h:274: (Each undeclared identifier is reported only once
+gstatomic_impl.h:274: for each function it appears in.)
+make[4]: *** [libgstreamer_0.6_la-gstatomic.lo] Error 1
+
+No big deal, I put a
+int val = 1;
+before line 274 since other CPU-Sections had that too, I hope that was a
+right assumption.
+
+Next problem is
+gcc -g -O2 -o .libs/autoplugtest autoplugtest-autoplugtest.o -pthread
+-Wl,--export-dynamic  -L/ofc/xdt2/sys/lib -L/usr/X11R6/lib
+../../gst/.libs/libgstreamer-0.6.so /ofc/xdt2/sys/lib/libxml2.so -lz -lm
+/ofc/xdt2/sys/lib/libgobject-2.0.so /ofc/xdt2/sys/lib/libgthread-2.0.so
+-lpthread /ofc/xdt2/sys/lib/libgmodule-2.0.so
+-ldl /ofc/xdt2/sys/lib/libglib-2.0.so /usr/lib/libpopt.so -Wl,--rpath
+-Wl,/ofc/xdt2/sys/lib
+../../gst/.libs/libgstreamer-0.6.so: undefined reference to `___atomic_sub'
+../../gst/.libs/libgstreamer-0.6.so: undefined reference to `___atomic_add'
+collect2: ld returned 1 exit status
+make[4]: *** [autoplugtest] Error 1
+
+It seems that the code in gstatomic_impl.h, namely these lines (243-289):
+
+GST_INLINE_FUNC void
+gst_atomic_int_add (GstAtomicInt *aint, gint val)
+{
+  register volatile int *ptr asm ("g1");
+  register int increment asm ("g2");
+ 
+  ptr = &aint->counter;
+  increment = val;
+ 
+  __asm__ __volatile__(
+    "mov    %%o7, %%g4\n\t"
+    "call   ___atomic_add\n\t"
+    " add   %%o7, 8, %%o7\n"
+      : "=&r" (increment)
+      : "0" (increment), "r" (ptr)
+      : "g3", "g4", "g7", "memory", "cc");
+}
+[...]
+
+which only get included on a SPARC with SMP-support in the kernel, somehow
+do not work.  Some more info about my system:
+
+pinky:~ # uname -a
+Linux pinky 2.4.20-PPW #1 SMP Thu Jan 30 09:53:41 MET 2003 sparc64 unknown
+pinky:~ # rpm -q glibc
+glibc-2.2.4-45
+
+I solved the problem by copying the generic implementation in the
+SPARC-section and deleting the above lines.
+Is this a problem with my installation or am I the first one to build
+GStreamer on a (actually one CPU-Slot is empty) SPARC64 box with an
+SMP-Kernel?  And no, it is not my box :)
+
+Jochen





More information about the Gstreamer-bugs mailing list