Check for --no-undefined linker flag and use it.

This adds extra safety that the built libraries will have all the
correct dependencies linked in.

Signed-off-by: Diego E. 'Flameeyes' Pettenò <flameeyes@gmail.com>
This commit is contained in:
Diego E. 'Flameeyes' Pettenò 2008-11-21 01:16:37 +01:00
parent ca133ff6a2
commit 0b92e53cf9
3 changed files with 7 additions and 5 deletions

View file

@ -44,6 +44,8 @@ AC_DISABLE_STATIC
AC_LIBTOOL_DLOPEN
AM_PROG_LIBTOOL
CC_NOUNDEFINED
dnl Checks for header files.
AC_HEADER_STDC
AM_CONFIG_HEADER(include/config.h)

View file

@ -18,20 +18,20 @@ endif
noinst_HEADERS = sbase.h
smixer_sbase_la_SOURCES = sbase.c
smixer_sbase_la_LDFLAGS = -module -avoid-version
smixer_sbase_la_LDFLAGS = -module -avoid-version $(LDFLAGS_NOUNDEFINED)
smixer_sbase_la_LIBADD = ../../../src/libasound.la
smixer_ac97_la_SOURCES = ac97.c sbasedl.c
smixer_ac97_la_LDFLAGS = -module -avoid-version
smixer_ac97_la_LDFLAGS = -module -avoid-version $(LDFLAGS_NOUNDEFINED)
smixer_ac97_la_LIBADD = ../../../src/libasound.la
smixer_hda_la_SOURCES = hda.c sbasedl.c
smixer_hda_la_LDFLAGS = -module -avoid-version
smixer_hda_la_LDFLAGS = -module -avoid-version $(LDFLAGS_NOUNDEFINED)
smixer_hda_la_LIBADD = ../../../src/libasound.la
if BUILD_PYTHON
smixer_python_la_SOURCES = python.c
smixer_python_la_LDFLAGS = -module -avoid-version $(pythonlibs)
smixer_python_la_LDFLAGS = -module -avoid-version $(pythonlibs) $(LDFLAGS_NOUNDEFINED)
smixer_python_la_CFLAGS = $(pythonincludes)
smixer_python_la_LIBADD = ../../../src/libasound.la
endif

View file

@ -45,7 +45,7 @@ endif
SUBDIRS += compat conf
libasound_la_LIBADD += compat/libcompat.la @ALSA_DEPLIBS@
libasound_la_LDFLAGS = -version-info $(COMPATNUM) $(VSYMS) $(SYMFUNCS)
libasound_la_LDFLAGS = -version-info $(COMPATNUM) $(VSYMS) $(SYMFUNCS) $(LDFLAGS_NOUNDEFINED)
control/libcontrol.la:
$(MAKE) -C control libcontrol.la