[rtmpdump] r373 - trunk/Makefile

hyc subversion at mplayerhq.hu
Sat Mar 20 21:10:29 CET 2010


Author: hyc
Date: Sat Mar 20 21:10:28 2010
New Revision: 373

Log:
GNU vs BSD make syntax issues

Modified:
   trunk/Makefile

Modified: trunk/Makefile
==============================================================================
--- trunk/Makefile	Sat Mar 20 20:43:56 2010	(r372)
+++ trunk/Makefile	Sat Mar 20 21:10:28 2010	(r373)
@@ -35,24 +35,27 @@ cross:
 
 clean:
 	rm -f *.o rtmpdump$(EXT) rtmpgw$(EXT) rtmpsrv$(EXT) rtmpsuck$(EXT)
-	@$(MAKE) -C librtmp clean
+	@cd librtmp; $(MAKE) clean
 
 FORCE:
 
 $(LIBRTMP): FORCE
-	@$(MAKE) -C librtmp all CC="$(CC)" CFLAGS="$(CFLAGS)"
+	@cd librtmp; $(MAKE) all CC="$(CC)" CFLAGS="$(CFLAGS)"
+
+# note: $^ is GNU Make's equivalent to BSD $>
+# we use both since either make will ignore the one it doesn't recognize
 
 rtmpdump: rtmpdump.o $(LIBRTMP)
-	$(CC) $(LDFLAGS) $^ -o $@$(EXT) $(LIBS)
+	$(CC) $(LDFLAGS) $^ $> -o $@$(EXT) $(LIBS)
 
 rtmpsrv: rtmpsrv.o thread.o $(LIBRTMP)
-	$(CC) $(LDFLAGS) $^ -o $@$(EXT) $(SLIBS)
+	$(CC) $(LDFLAGS) $^ $> -o $@$(EXT) $(SLIBS)
 
 rtmpsuck: rtmpsuck.o thread.o $(LIBRTMP)
-	$(CC) $(LDFLAGS) $^ -o $@$(EXT) $(SLIBS)
+	$(CC) $(LDFLAGS) $^ $> -o $@$(EXT) $(SLIBS)
 
 rtmpgw: rtmpgw.o thread.o $(LIBRTMP)
-	$(CC) $(LDFLAGS) $^ -o $@$(EXT) $(SLIBS)
+	$(CC) $(LDFLAGS) $^ $> -o $@$(EXT) $(SLIBS)
 
 rtmpgw.o: rtmpgw.c $(INCRTMP) Makefile
 rtmpdump.o: rtmpdump.c $(INCRTMP) Makefile


More information about the rtmpdump mailing list