diff TOOLS/netstream/Makefile @ 15367:bdcd608b0e97

MinGW compilation fix by Erik Lunchpail <erik_27can at yahoo dot com>
author diego
date Sun, 08 May 2005 14:38:35 +0000
parents cdffac8b6555
children 7bae32bc0ed7
line wrap: on
line diff
--- a/TOOLS/netstream/Makefile	Sun May 08 14:30:53 2005 +0000
+++ b/TOOLS/netstream/Makefile	Sun May 08 14:38:35 2005 +0000
@@ -16,11 +16,9 @@
 	$(CC) -c $(CFLAGS) -o $@ $<
 
 
-netstream: $(MPROOT)/libmpdemux/libmpdemux.a netstream.o
 # FIXME: linking is a mess that should be fixed properly some day
 # it does not work with either GUI, live.com or libavformat enabled
-	$(CC) $(CFLAGS) netstream.o -o netstream \
-		$(MPROOT)/libmpdemux/libmpdemux.a \
+DEPS =		$(MPROOT)/libmpdemux/libmpdemux.a \
 		$(MPROOT)/libmpdvdkit2/libmpdvdkit.a \
 		$(MPROOT)/libmpcodecs/native/minilzo.o \
 		$(MPROOT)/libvo/aclib.o $(MPROOT)/libmpcodecs/img_format.o \
@@ -31,6 +29,14 @@
 		$(VORBIS_LIB) $(CDPARANOIA_LIB) $(Z_LIB) $(GIF_LIB) \
 		$(SMBSUPPORT_LIB) $(LIVE_LIBS) $(ARCH_LIB) $(COMMON_LIBS) -lm
 
+ifeq ($(TARGET_WIN32),yes)
+DEPS += $(MPROOT)/osdep/glob-win.o $(WIN32_LIB) -lwsock32
+endif
+
+netstream: $(MPROOT)/libmpdemux/libmpdemux.a netstream.o
+
+	$(CC) $(CFLAGS) netstream.o -o netstream $(DEPS)
+
 clean:
 	rm -f *.o *.a *~