Subject: [ecasound] RE: [linux-audio-dev] LADSPA Update (http://www.ladspa.org)
From: David Benson (firstname.lastname@example.org)
Date: Sun May 21 2000 - 20:30:01 EEST
> These same issues apply to any ladspa plugin which uses an external library
> beyond the standard C and maths library allowed in ladspa.h.
forgot this in the docs i sent out. instead of repeating
myself in response form, please read section 184.108.40.206 below.
the whole new section is repeated, since it changed.
3.4.5. Building LADSPA plugins
The process of building plugins is extremely nonportable, but we give
commands to compile a LADSPA plugin using the GNU tools.
If your plugin is a simple C plugin, try using commands like:
gcc -fPIC -DPIC -Wall -O2 -c -o my_plugin.o my_plugin.c
ld -shared -o my_plugin.so my_plugin.o
If your plugin uses an external library, you must add that to the ld
ld -shared -o my_plugin.so my_plugin.o -lmy_library
The plugin will not load unless the library has been found.
If your plugin uses C++, it is far easier to use g++ to find the
various library that are needed:
g++ -fPIC -DPIC -shared -o my_plugin.so my_plugin.cc
Otherwise non-C++ hosts won't have the standard c++ libraries automat-
ically loaded for them.
If you use external libraries, add them on with -l, as above.
220.127.116.11. More on external libraries
Shared libraries are searched for according to the environment
variable LD_LIBRARY_PATH, then they use the system's shared library
table, which is generated by ldconfig.
In some rare cases, you may wish to support the loading of multiple
versions of the library which define different functions and
You have basically two choices:
o make N-versions of your plugin, using #ifdef to distinguish the
versions at compile time. This is likely easier, and perhaps more
This has the disadvantage that the host must distinguish which
version of the underlying library is present.
o use dlopen and dlsym to make a single plugin that can load any
version of its library. This is more complex, but may be easier to
-- To unsubscribe send message 'unsubscribe' in the body of the message to <email@example.com>.
This archive was generated by hypermail 2b28 : Sun May 21 2000 - 20:31:13 EEST