summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCarlo Bramini <carlo.bramix@libero.it>2012-06-05 12:18:46 +0300
committerCarlo Bramini <carlo.bramix@libero.it>2012-06-05 12:18:46 +0300
commit43d2cc9a1598132bda53d1e95bf7f90e5cc82fab (patch)
tree87fc334d0474ca7d81f47c0789636d4b42f4fe2b
parente6dddfdfa6cfa00c5e87e99f5c13e24cadf8204d (diff)
downloadxine-lib-43d2cc9a1598132bda53d1e95bf7f90e5cc82fab.tar.gz
xine-lib-43d2cc9a1598132bda53d1e95bf7f90e5cc82fab.tar.bz2
Fixed -no-undefined handling with mingw and cygwin
"-no-undefined" is not a linker flag, it's a libtool flag, so it must be removed from LDFLAGS for CYGWIN and MINGW. There is already another variable for that purpose.
-rw-r--r--configure.ac13
-rw-r--r--m4/attributes.m42
-rw-r--r--src/xine-engine/Makefile.am4
3 files changed, 3 insertions, 16 deletions
diff --git a/configure.ac b/configure.ac
index f4f9b6563..1ff889dbc 100644
--- a/configure.ac
+++ b/configure.ac
@@ -2914,19 +2914,6 @@ mv -f libtool.tmp libtool
chmod +x libtool
dnl ---------------------------------------------
-dnl Libtool flag for Windows:
-dnl
-dnl The "-no-undefined" flag must be added after all other
-dnl configure checks, because it is only for libtool and
-dnl must not be passed to GCC by accident.
-dnl ---------------------------------------------
-case "$host_os" in
- mingw* | cygwin*)
- LDFLAGS="-no-undefined $LDFLAGS"
- ;;
-esac
-
-dnl ---------------------------------------------
dnl Some infos:
dnl ---------------------------------------------
diff --git a/m4/attributes.m4 b/m4/attributes.m4
index 3d9c256a0..4f672bffd 100644
--- a/m4/attributes.m4
+++ b/m4/attributes.m4
@@ -114,7 +114,7 @@ AC_DEFUN([CC_NOUNDEFINED], [
dnl use it only for libraries in mingw32-w64
*-freebsd* | *-openbsd*) ;;
- *-mingw*)
+ *-mingw* | *-cygwin*)
LDFLAGS_NOUNDEFINED="-no-undefined"
;;
*)
diff --git a/src/xine-engine/Makefile.am b/src/xine-engine/Makefile.am
index 67ae63fae..535be3557 100644
--- a/src/xine-engine/Makefile.am
+++ b/src/xine-engine/Makefile.am
@@ -10,7 +10,7 @@ lib_LTLIBRARIES = libxine.la
XINEUTILS_LIB = $(top_builddir)/src/xine-utils/libxineutils.la
DEF_FILE = libxine-$(XINE_MAJOR).def
if WIN32
-def_ldflags=-Wl,--output-def,$(DEF_FILE) $(LDFLAGS_NOUNDEFINED)
+def_ldflags=-Wl,--output-def,$(DEF_FILE)
endif
libxine_la_SOURCES = xine.c metronom.c configfile.c buffer.c \
@@ -30,7 +30,7 @@ libxine_la_LIBADD = $(PTHREAD_LIBS) $(DYNAMIC_LD_LIBS) $(LTLIBINTL) $(ZLIB_LIBS)
-lm $(XINEUTILS_LIB) $(LTLIBICONV) $(FT2_LIBS) $(FONTCONFIG_LIBS) \
$(LIBXINEPOSIX) $(RT_LIBS) $(NET_LIBS)
-libxine_la_LDFLAGS = \
+libxine_la_LDFLAGS = $(LDFLAGS_NOUNDEFINED) \
-version-info $(XINE_LT_CURRENT):$(XINE_LT_REVISION):$(XINE_LT_AGE) \
$(def_ldflags)