From 0f3825b0c40ca379e6b5d2e3e862130c8ccb65f5 Mon Sep 17 00:00:00 2001 From: Daniel Macks Date: Wed, 13 Aug 2008 11:32:41 -0400 Subject: Non-portable linker flag -version-script is an ELF/GNU-ld feature, not available with other linkers & platforms. Libtool already knows when to use it, so attached path just piggy-backs on their main test for this feature. I think they also exclude some other platforms, but this appears to work on linux (passes the flag, tested with libtool-1.5.22) with and OS X (doesn't pass it, tested with libtool-2.2.4). dan -- Daniel Macks dmacks@netspace.org http://www.netspace.org/~dmacks Signed-off-by: Lennart Poettering --- src/Makefile.am | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) (limited to 'src') diff --git a/src/Makefile.am b/src/Makefile.am index 41713ec..198202b 100644 --- a/src/Makefile.am +++ b/src/Makefile.am @@ -60,8 +60,11 @@ libcanberra_la_LIBADD = \ $(VORBIS_LIBS) libcanberra_la_LDFLAGS = \ -export-dynamic \ - -version-info $(LIBCANBERRA_VERSION_INFO) \ - -Wl,-version-script=$(srcdir)/map-file + -version-info $(LIBCANBERRA_VERSION_INFO) + +if USE_VERSION_SCRIPT +libcanberra_la_LDFLAGS += -Wl,-version-script=$(srcdir)/map-file +endif plugin_LTLIBRARIES = -- cgit