Hi, I am working on a portable plugin framework that relies on the autoconf, automake, libtool trio to achieve maximum portability. The framework builds the plugins as runtime dynamically linked modules with the following: lib_LTLIBRARIES = module.la module_la_SOURCES = module.cxx module_la_LDFLAGS = -module -avoid-version -no-undefined
My aim is to package my plugin framework in such a way that it can be untarred into an existing project (lets say project X) and integrated into it by just telling automake to descend into its directory structure (i.e. by modifying project X's toplevel Makefile.am with SUBDIRS = plugin_framework ). All works fine and dandy, except for the following minor annoyance... The plugin framework includes a number of internal tests that are run as part of the `make check' target. These tests require certain plugin modules to be built. The problem arises because plugins do not seem to build correctly when they are not built as part of the lib_LTLIBRARIES primary. To clarify, if the plugin called module.la is built as: lib_LTLIBRARIES = module.la all works fine. If, on the other hand, it is built as: check_LTLIBRARIES = module.la it does not work. Same goes when the plugin is built as: noinst_LTLIBRARIES = module.la the module cannot be dynamically opened, since only a static library is built, and no shared library is built. As a result of this, I am forced to build my test plugins as part of the lib_LTLIBRARIES primary, with the consequence that when the project X's developer issues a `make' command, the test plugi\ ns will be built when it is not required and will likely cause errors. Is there a way to build dynamically loadable libraries as part of the check_LTLIBRARIES primary? Failing that, is there a way to conditionally avoid building a lib_LTLIBRARY target depending on whether `make all' or `make check' was invoked? Thanks in advance, Matteo Vescovi __________________________________________________________________ TISCALI ADSL Solo con Tiscali Adsl navighi senza limiti e telefoni senza canone Telecom a partire da 19,95 Euro/mese. Attivala subito, I PRIMI DUE MESI SONO GRATIS! CLICCA QUI: http://abbonati.tiscali.it/adsl/sa/1e25flat_tc/
