rendered paste bodyIndex: libavcodec/allcodecs.c
===================================================================
--- libavcodec/allcodecs.c (revision 7245)
+++ libavcodec/allcodecs.c (working copy)
@@ -26,10 +26,20 @@
#include "avcodec.h"
-#define REGISTER_ENCODER(X,x) \
+#ifdef CONFIG_ENCODERS
+# define REGISTER_ENCODER(X,x) \
if(ENABLE_##X##_ENCODER) register_avcodec(&x##_encoder)
-#define REGISTER_DECODER(X,x) \
+#else
+# define REGISTER_ENCODER(X,x)
+#endif
+
+#ifdef CONFIG_DECODERS
+# define REGISTER_DECODER(X,x) \
if(ENABLE_##X##_DECODER) register_avcodec(&x##_decoder)
+#else
+# define REGISTER_DECODER(X,x)
+#endif
+
#define REGISTER_ENCDEC(X,x) REGISTER_ENCODER(X,x); REGISTER_DECODER(X,x)
#define REGISTER_PARSER(X,x) \
Index: libavformat/allformats.c
===================================================================
--- libavformat/allformats.c (revision 7245)
+++ libavformat/allformats.c (working copy)
@@ -21,10 +21,20 @@
#include "avformat.h"
#include "allformats.h"
-#define REGISTER_MUXER(X,x) \
+#ifdef CONFIG_MUXERS
+# define REGISTER_MUXER(X,x) \
if(ENABLE_##X##_MUXER) av_register_output_format(&x##_muxer)
-#define REGISTER_DEMUXER(X,x) \
+#else
+# define REGISTER_MUXER(X,x)
+#endif
+
+#ifdef CONFIG_DEMUXERS
+# define REGISTER_DEMUXER(X,x) \
if(ENABLE_##X##_DEMUXER) av_register_input_format(&x##_demuxer)
+#else
+# defined REGISTER_DEMUXER(X,x)
+#endif
+
#define REGISTER_MUXDEMUX(X,x) REGISTER_MUXER(X,x); REGISTER_DEMUXER(X,x)
/* If you do not call this function, then you can select exactly which
Index: libavformat/aviobuf.c
===================================================================
--- libavformat/aviobuf.c (revision 7245)
+++ libavformat/aviobuf.c (working copy)
@@ -185,7 +185,7 @@
return s->error;
}
-#if defined(CONFIG_MUXERS) || defined(CONFIG_PROTOCOLS)
+/* #if defined(CONFIG_MUXERS) || defined(CONFIG_PROTOCOLS) */
void put_le32(ByteIOContext *s, unsigned int val)
{
put_byte(s, val);
@@ -252,7 +252,7 @@
put_byte(s, *tag++);
}
}
-#endif //CONFIG_MUXERS || CONFIG_PROTOCOLS
+/* #endif //CONFIG_MUXERS || CONFIG_PROTOCOLS */
/* Input stream */