* Transforming rtp_decoder into a standalone test application
diff --git a/Makefile.in b/Makefile.in
index 6b0a2cb..d9956a0 100644
--- a/Makefile.in
+++ b/Makefile.in
@@ -15,6 +15,7 @@
 # tags          builds etags file from all .c and .h files
 
 USE_OPENSSL = @USE_OPENSSL@
+HAVE_PCAP = @HAVE_PCAP@
 HAVE_PKG_CONFIG = @HAVE_PKG_CONFIG@
 
 .PHONY: all test build_table_apps
@@ -152,9 +153,15 @@
 
 $(testapp): libsrtp.a
 
-test/rtpw$(EXE): test/rtpw.c test/rtp.c test/rtp_decoder.c test/getopt_s.c
+test/rtpw$(EXE): test/rtpw.c test/rtp.c test/getopt_s.c
 	$(COMPILE) $(LDFLAGS) -o $@ $^ $(LIBS) $(SRTPLIB)
 
+ifeq (1, $(HAVE_PCAP))
+testapp += test/rtp_decoder$(EXE)
+test/rtp_decoder$(EXE): test/rtp_decoder.c test/rtp.c test/getopt_s.c
+	$(COMPILE) $(LDFLAGS) -o $@ $^ $(LIBS) $(SRTPLIB)
+endif
+
 test/srtp_driver$(EXE): test/srtp_driver.c test/getopt_s.c
 	$(COMPILE) $(LDFLAGS) -o $@ $^ $(LIBS) $(SRTPLIB)