Permalink
Browse files

Makefile.am: use --version-script only with GNU ld

--version-script is a GNU extension, and fails on non-GNU platforms.
  • Loading branch information...
1 parent 374ade7 commit 54c31b75d2a38d2aaf8a87b7e3a7cd36d1c2dd51 @MaxKellermann MaxKellermann committed Oct 20, 2009
Showing with 10 additions and 2 deletions.
  1. +5 −2 Makefile.am
  2. +1 −0 NEWS
  3. +4 −0 configure.ac
View
@@ -80,8 +80,11 @@ src_libmpdclient_la_SOURCES = \
src/tag.c
src_libmpdclient_la_LDFLAGS = -version-info @LIBMPDCLIENT_LIBTOOL_VERSION@ \
- -no-undefined \
- -Wl,--version-script=$(srcdir)/libmpdclient.ld
+ -no-undefined
+
+if HAVE_GNU_LD
+src_libmpdclient_la_LDFLAGS += -Wl,--version-script=$(srcdir)/libmpdclient.ld
+endif
noinst_PROGRAMS = src/example test/test
View
@@ -1,6 +1,7 @@
libmpdclient 2.1 (2009/??/??)
* status: added mpd_status_get_elapsed_ms()
* song: copy last_modified value in mpd_song_dup()
+* Makefile.am: use --version-script only with GNU ld
libmpdclient 2.0 (2009/10/03)
View
@@ -16,6 +16,10 @@ m4_defun([_LT_AC_LANG_F77_CONFIG], [:])
dnl Check for programs
AC_PROG_CC_C99
AC_PROG_INSTALL
+
+AC_PROG_LD
+AM_CONDITIONAL(HAVE_GNU_LD, test x$with_gnu_ld = xyes)
+
AC_LIBTOOL_WIN32_DLL
AC_PROG_LIBTOOL

0 comments on commit 54c31b7

Please sign in to comment.