I have written a gstreamer plugin using the boilerplate template refrenced in the gstreamer plugin writers guide (http://gstreamer.freedesktop.org/data/doc/gstreamer/head/pwg/html/chapter-building-boiler.html). I first built the plugin without full implementation of the chain function (basically an empty plugin that passed data from the source to sink with no changes).
I am now implementing the chain function to perform a basic filtering on the data in the buffer. The filtering uses an external sharpening library (which I have successfully used outside of gstreamer). When building using autotools I get no errors, but when creating a pipeline using the new plugin, I get an undefined symbol error
(gst-plugin-scanner:6512): GStreamer-WARNING **: Failed to load plugin '/usr/local/lib/gstreamer-1.0/libgstsharpening.so': /usr/local/lib/gstreamer-1.0/libgstsharpening.so: undefined symbol: InitializeSharpeningModule
I am admittedly very new to autotools, and I believe my problem lies somewhere in that process, but I can't figure out where. The external sharpening library being used can be found here
/public/gstreamer_pipeline/lib/libsharpening.so
I edited the plugin Makefile.am found in the src directory for my plugin
/public/gstreamer_pipeline/src/gst-sharpening/src
The contents of the edited Makefile.am are
plugin_LTLIBRARIES = libgstsharpening.la
libgstsharpening_la_SOURCES = gstsharpening.c gstsharpening.h
libgstsharpening_la_CFLAGS = $(GST_CFLAGS) -I/public/gstreamer_pipeline/include
libgstsharpening_la_LIBADD = $(GST_LIBS) -lsharpening
libgstsharpening_la_LDFLAGS = $(GST_PLUGIN_LDFLAGS) -L/public/gstreamer_pipeline/lib
libgstsharpening_la_LIBTOOLFLAGS = $(GST_PLUGIN_LIBTOOLFLAGS)
noinst_HEADERS = gstsharpening.h
The undefined symbol error is occuring in the case of creating the pipeline from a main program, or creating the pipeline from the command line using
gst-launch-1.0 fakesrc ! sharpening ! fakesink
The output of running ldd on the new created plugin library (without modifying LD_LIBRARY_PATH) is
ldd /usr/local/lib/gstreamer-1.0/libgstsharpening.so
linux-vdso.so.1 => (0x00007fff17bc0000)
libgstbase-1.0.so.0 => /usr/local/lib/libgstbase-1.0.so.0 (0x00007f3c51778000)
libgstcontroller-1.0.so.0 => /usr/local/lib/libgstcontroller-1.0.so.0 (0x00007f3c51568000)
libgstreamer-1.0.so.0 => /usr/local/lib/libgstreamer-1.0.so.0 (0x00007f3c51250000)
libgmodule-2.0.so.0 => /usr/local/lib/libgmodule-2.0.so.0 (0x00007f3c5104d000)
libm.so.6 => /lib64/libm.so.6 (0x00007f3c50db0000)
libdl.so.2 => /lib64/libdl.so.2 (0x00007f3c50bac000)
libgobject-2.0.so.0 => /usr/local/lib/libgobject-2.0.so.0 (0x00007f3c5095f000)
libffi.so.6 => /usr/local/lib/../lib64/libffi.so.6 (0x00007f3c50755000)
libglib-2.0.so.0 => /usr/local/lib/libglib-2.0.so.0 (0x00007f3c50420000)
libpthread.so.0 => /lib64/libpthread.so.0 (0x00007f3c50203000)
librt.so.1 => /lib64/librt.so.1 (0x00007f3c4fffa000)
libc.so.6 => /lib64/libc.so.6 (0x00007f3c4fc67000)
/lib64/ld-linux-x86-64.so.2 (0x0000003406c00000)
The configure.log output http://pastie.org/10450341
The output of make and make install http://pastie.org/10450352
InitializeSharpeningModule
used? and where it is defined (exporter)? – DyadicLD_LIBRARY_PATH
(or some other means) setup to make the runtime linker look in/public/gstreamer_pipeline/lib/
for libraries? – Dyadic