[FFmpeg-cvslog] r22407 - in trunk: libavcodec/fft.c libavcodec/mdct.c libavcodec/rdft.c libavutil/adler32.c libavutil/adler32.h libavutil/arm/bswap.h libavutil/arm/intmath.h libavutil/avr32/bswap.h libavutil/bfin/...

mru subversion
Tue Mar 9 18:39:19 CET 2010


Author: mru
Date: Tue Mar  9 18:39:19 2010
New Revision: 22407

Log:
Replace many includes of libavutil/common.h with what is actually needed

This reduces the number of false dependencies on header files and
speeds up compilation.

Modified:
   trunk/libavcodec/fft.c
   trunk/libavcodec/mdct.c
   trunk/libavcodec/rdft.c
   trunk/libavutil/adler32.c
   trunk/libavutil/adler32.h
   trunk/libavutil/arm/bswap.h
   trunk/libavutil/arm/intmath.h
   trunk/libavutil/avr32/bswap.h
   trunk/libavutil/bfin/bswap.h
   trunk/libavutil/bswap.h
   trunk/libavutil/crc.c
   trunk/libavutil/crc.h
   trunk/libavutil/fifo.h
   trunk/libavutil/internal.h
   trunk/libavutil/intfloat_readwrite.c
   trunk/libavutil/intfloat_readwrite.h
   trunk/libavutil/lfg.c
   trunk/libavutil/mathematics.c
   trunk/libavutil/mathematics.h
   trunk/libavutil/md5.c
   trunk/libavutil/mem.h
   trunk/libavutil/rational.h
   trunk/libavutil/sh4/bswap.h
   trunk/libavutil/sha.c
   trunk/libavutil/tree.c
   trunk/libavutil/x86/bswap.h
   trunk/libavutil/x86/intmath.h
   trunk/libavutil/x86/intreadwrite.h

Modified: trunk/libavcodec/fft.c
==============================================================================
--- trunk/libavcodec/fft.c	Tue Mar  9 17:44:10 2010	(r22406)
+++ trunk/libavcodec/fft.c	Tue Mar  9 18:39:19 2010	(r22407)
@@ -26,6 +26,8 @@
  * FFT/IFFT transforms.
  */
 
+#include <stdlib.h>
+#include <string.h>
 #include "libavutil/mathematics.h"
 #include "fft.h"
 

Modified: trunk/libavcodec/mdct.c
==============================================================================
--- trunk/libavcodec/mdct.c	Tue Mar  9 17:44:10 2010	(r22406)
+++ trunk/libavcodec/mdct.c	Tue Mar  9 18:39:19 2010	(r22407)
@@ -19,6 +19,9 @@
  * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
  */
 
+#include <stdlib.h>
+#include <string.h>
+#include "libavutil/common.h"
 #include "libavutil/mathematics.h"
 #include "fft.h"
 

Modified: trunk/libavcodec/rdft.c
==============================================================================
--- trunk/libavcodec/rdft.c	Tue Mar  9 17:44:10 2010	(r22406)
+++ trunk/libavcodec/rdft.c	Tue Mar  9 18:39:19 2010	(r22407)
@@ -18,6 +18,7 @@
  * License along with FFmpeg; if not, write to the Free Software
  * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
  */
+#include <stdlib.h>
 #include <math.h>
 #include "libavutil/mathematics.h"
 #include "fft.h"

Modified: trunk/libavutil/adler32.c
==============================================================================
--- trunk/libavutil/adler32.c	Tue Mar  9 17:44:10 2010	(r22406)
+++ trunk/libavutil/adler32.c	Tue Mar  9 18:39:19 2010	(r22407)
@@ -21,7 +21,7 @@
  * 3. This notice may not be removed or altered from any source distribution.
  */
 
-#include "common.h"
+#include "config.h"
 #include "adler32.h"
 
 #define BASE 65521L /* largest prime smaller than 65536 */
@@ -53,6 +53,7 @@ unsigned long av_adler32_update(unsigned
 
 #ifdef TEST
 #include "log.h"
+#include "timer.h"
 #define LEN 7001
 volatile int checksum;
 int main(void){

Modified: trunk/libavutil/adler32.h
==============================================================================
--- trunk/libavutil/adler32.h	Tue Mar  9 17:44:10 2010	(r22406)
+++ trunk/libavutil/adler32.h	Tue Mar  9 18:39:19 2010	(r22407)
@@ -22,7 +22,7 @@
 #define AVUTIL_ADLER32_H
 
 #include <stdint.h>
-#include "common.h"
+#include "attributes.h"
 
 unsigned long av_adler32_update(unsigned long adler, const uint8_t *buf,
                                 unsigned int len) av_pure;

Modified: trunk/libavutil/arm/bswap.h
==============================================================================
--- trunk/libavutil/arm/bswap.h	Tue Mar  9 17:44:10 2010	(r22406)
+++ trunk/libavutil/arm/bswap.h	Tue Mar  9 18:39:19 2010	(r22407)
@@ -21,7 +21,7 @@
 
 #include <stdint.h>
 #include "config.h"
-#include "libavutil/common.h"
+#include "libavutil/attributes.h"
 
 #ifdef __ARMCC_VERSION
 

Modified: trunk/libavutil/arm/intmath.h
==============================================================================
--- trunk/libavutil/arm/intmath.h	Tue Mar  9 17:44:10 2010	(r22406)
+++ trunk/libavutil/arm/intmath.h	Tue Mar  9 18:39:19 2010	(r22407)
@@ -22,7 +22,7 @@
 #define AVUTIL_ARM_INTMATH_H
 
 #include "config.h"
-#include "libavutil/common.h"
+#include "libavutil/attributes.h"
 
 #if HAVE_INLINE_ASM
 

Modified: trunk/libavutil/avr32/bswap.h
==============================================================================
--- trunk/libavutil/avr32/bswap.h	Tue Mar  9 17:44:10 2010	(r22406)
+++ trunk/libavutil/avr32/bswap.h	Tue Mar  9 18:39:19 2010	(r22407)
@@ -21,7 +21,7 @@
 
 #include <stdint.h>
 #include "config.h"
-#include "libavutil/common.h"
+#include "libavutil/attributes.h"
 
 #if HAVE_INLINE_ASM
 

Modified: trunk/libavutil/bfin/bswap.h
==============================================================================
--- trunk/libavutil/bfin/bswap.h	Tue Mar  9 17:44:10 2010	(r22406)
+++ trunk/libavutil/bfin/bswap.h	Tue Mar  9 18:39:19 2010	(r22407)
@@ -28,7 +28,7 @@
 
 #include <stdint.h>
 #include "config.h"
-#include "libavutil/common.h"
+#include "libavutil/attributes.h"
 
 #define bswap_32 bswap_32
 static av_always_inline av_const uint32_t bswap_32(uint32_t x)

Modified: trunk/libavutil/bswap.h
==============================================================================
--- trunk/libavutil/bswap.h	Tue Mar  9 17:44:10 2010	(r22406)
+++ trunk/libavutil/bswap.h	Tue Mar  9 18:39:19 2010	(r22407)
@@ -28,7 +28,7 @@
 
 #include <stdint.h>
 #include "config.h"
-#include "common.h"
+#include "attributes.h"
 
 #if   ARCH_ARM
 #   include "arm/bswap.h"

Modified: trunk/libavutil/crc.c
==============================================================================
--- trunk/libavutil/crc.c	Tue Mar  9 17:44:10 2010	(r22406)
+++ trunk/libavutil/crc.c	Tue Mar  9 18:39:19 2010	(r22407)
@@ -19,6 +19,7 @@
  */
 
 #include "config.h"
+#include "common.h"
 #include "bswap.h"
 #include "crc.h"
 

Modified: trunk/libavutil/crc.h
==============================================================================
--- trunk/libavutil/crc.h	Tue Mar  9 17:44:10 2010	(r22406)
+++ trunk/libavutil/crc.h	Tue Mar  9 18:39:19 2010	(r22407)
@@ -23,7 +23,7 @@
 
 #include <stdint.h>
 #include <stddef.h>
-#include "common.h"
+#include "attributes.h"
 
 typedef uint32_t AVCRC;
 

Modified: trunk/libavutil/fifo.h
==============================================================================
--- trunk/libavutil/fifo.h	Tue Mar  9 17:44:10 2010	(r22406)
+++ trunk/libavutil/fifo.h	Tue Mar  9 18:39:19 2010	(r22407)
@@ -25,8 +25,6 @@
 #define AVUTIL_FIFO_H
 
 #include <stdint.h>
-#include "avutil.h"
-#include "common.h"
 
 typedef struct AVFifoBuffer {
     uint8_t *buffer;

Modified: trunk/libavutil/internal.h
==============================================================================
--- trunk/libavutil/internal.h	Tue Mar  9 17:44:10 2010	(r22406)
+++ trunk/libavutil/internal.h	Tue Mar  9 18:39:19 2010	(r22407)
@@ -35,8 +35,7 @@
 #include <stddef.h>
 #include <assert.h>
 #include "config.h"
-#include "common.h"
-#include "mem.h"
+#include "attributes.h"
 #include "timer.h"
 
 #ifndef attribute_align_arg

Modified: trunk/libavutil/intfloat_readwrite.c
==============================================================================
--- trunk/libavutil/intfloat_readwrite.c	Tue Mar  9 17:44:10 2010	(r22406)
+++ trunk/libavutil/intfloat_readwrite.c	Tue Mar  9 18:39:19 2010	(r22407)
@@ -25,7 +25,8 @@
  * portable IEEE float/double read/write functions
  */
 
-#include "common.h"
+#include <stdint.h>
+#include <math.h>
 #include "intfloat_readwrite.h"
 
 double av_int2dbl(int64_t v){

Modified: trunk/libavutil/intfloat_readwrite.h
==============================================================================
--- trunk/libavutil/intfloat_readwrite.h	Tue Mar  9 17:44:10 2010	(r22406)
+++ trunk/libavutil/intfloat_readwrite.h	Tue Mar  9 18:39:19 2010	(r22407)
@@ -22,7 +22,7 @@
 #define AVUTIL_INTFLOAT_READWRITE_H
 
 #include <stdint.h>
-#include "common.h"
+#include "attributes.h"
 
 /* IEEE 80 bits extended float */
 typedef struct AVExtFloat  {

Modified: trunk/libavutil/lfg.c
==============================================================================
--- trunk/libavutil/lfg.c	Tue Mar  9 17:44:10 2010	(r22406)
+++ trunk/libavutil/lfg.c	Tue Mar  9 18:39:19 2010	(r22407)
@@ -23,6 +23,7 @@
 #include "lfg.h"
 #include "md5.h"
 #include "intreadwrite.h"
+#include "attributes.h"
 
 void av_cold av_lfg_init(AVLFG *c, unsigned int seed){
     uint8_t tmp[16]={0};
@@ -56,7 +57,7 @@ void av_bmg_get(AVLFG *lfg, double out[2
 
 #ifdef TEST
 #include "log.h"
-#include "common.h"
+#include "timer.h"
 
 int main(void)
 {

Modified: trunk/libavutil/mathematics.c
==============================================================================
--- trunk/libavutil/mathematics.c	Tue Mar  9 17:44:10 2010	(r22406)
+++ trunk/libavutil/mathematics.c	Tue Mar  9 18:39:19 2010	(r22407)
@@ -24,8 +24,8 @@
  */
 
 #include <assert.h>
-#include "avutil.h"
-#include "common.h"
+#include <stdint.h>
+#include <limits.h>
 #include "mathematics.h"
 
 const uint8_t ff_sqrt_tab[256]={

Modified: trunk/libavutil/mathematics.h
==============================================================================
--- trunk/libavutil/mathematics.h	Tue Mar  9 17:44:10 2010	(r22406)
+++ trunk/libavutil/mathematics.h	Tue Mar  9 18:39:19 2010	(r22407)
@@ -23,7 +23,7 @@
 
 #include <stdint.h>
 #include <math.h>
-#include "common.h"
+#include "attributes.h"
 #include "rational.h"
 
 #ifndef M_E

Modified: trunk/libavutil/md5.c
==============================================================================
--- trunk/libavutil/md5.c	Tue Mar  9 17:44:10 2010	(r22406)
+++ trunk/libavutil/md5.c	Tue Mar  9 18:39:19 2010	(r22407)
@@ -163,6 +163,7 @@ void av_md5_sum(uint8_t *dst, const uint
 
 #ifdef TEST
 #include <stdio.h>
+#include <inttypes.h>
 #undef printf
 int main(void){
     uint64_t md5val;

Modified: trunk/libavutil/mem.h
==============================================================================
--- trunk/libavutil/mem.h	Tue Mar  9 17:44:10 2010	(r22406)
+++ trunk/libavutil/mem.h	Tue Mar  9 18:39:19 2010	(r22407)
@@ -26,7 +26,7 @@
 #ifndef AVUTIL_MEM_H
 #define AVUTIL_MEM_H
 
-#include "common.h"
+#include "attributes.h"
 
 #if defined(__ICC) || defined(__SUNPRO_C)
     #define DECLARE_ALIGNED(n,t,v)      t __attribute__ ((aligned (n))) v

Modified: trunk/libavutil/rational.h
==============================================================================
--- trunk/libavutil/rational.h	Tue Mar  9 17:44:10 2010	(r22406)
+++ trunk/libavutil/rational.h	Tue Mar  9 18:39:19 2010	(r22407)
@@ -29,7 +29,7 @@
 #define AVUTIL_RATIONAL_H
 
 #include <stdint.h>
-#include "common.h"
+#include "attributes.h"
 
 /**
  * rational number numerator/denominator

Modified: trunk/libavutil/sh4/bswap.h
==============================================================================
--- trunk/libavutil/sh4/bswap.h	Tue Mar  9 17:44:10 2010	(r22406)
+++ trunk/libavutil/sh4/bswap.h	Tue Mar  9 18:39:19 2010	(r22407)
@@ -26,7 +26,7 @@
 
 #include <stdint.h>
 #include "config.h"
-#include "libavutil/common.h"
+#include "libavutil/attributes.h"
 
 #define bswap_16 bswap_16
 static av_always_inline av_const uint16_t bswap_16(uint16_t x)

Modified: trunk/libavutil/sha.c
==============================================================================
--- trunk/libavutil/sha.c	Tue Mar  9 17:44:10 2010	(r22406)
+++ trunk/libavutil/sha.c	Tue Mar  9 18:39:19 2010	(r22407)
@@ -21,8 +21,7 @@
  * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
  */
 
-#include "common.h"
-#include "avutil.h"
+#include <string.h>
 #include "bswap.h"
 #include "sha.h"
 #include "sha1.h"

Modified: trunk/libavutil/tree.c
==============================================================================
--- trunk/libavutil/tree.c	Tue Mar  9 17:44:10 2010	(r22406)
+++ trunk/libavutil/tree.c	Tue Mar  9 18:39:19 2010	(r22407)
@@ -18,7 +18,6 @@
  * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
  */
 
-#include "common.h"
 #include "log.h"
 #include "tree.h"
 

Modified: trunk/libavutil/x86/bswap.h
==============================================================================
--- trunk/libavutil/x86/bswap.h	Tue Mar  9 17:44:10 2010	(r22406)
+++ trunk/libavutil/x86/bswap.h	Tue Mar  9 18:39:19 2010	(r22407)
@@ -26,7 +26,7 @@
 
 #include <stdint.h>
 #include "config.h"
-#include "libavutil/common.h"
+#include "libavutil/attributes.h"
 
 #define bswap_16 bswap_16
 static av_always_inline av_const uint16_t bswap_16(uint16_t x)

Modified: trunk/libavutil/x86/intmath.h
==============================================================================
--- trunk/libavutil/x86/intmath.h	Tue Mar  9 17:44:10 2010	(r22406)
+++ trunk/libavutil/x86/intmath.h	Tue Mar  9 18:39:19 2010	(r22407)
@@ -21,8 +21,6 @@
 #ifndef AVUTIL_X86_INTMATH_H
 #define AVUTIL_X86_INTMATH_H
 
-#include "libavutil/common.h"
-
 #define FASTDIV(a,b) \
     ({\
         int ret, dmy;\

Modified: trunk/libavutil/x86/intreadwrite.h
==============================================================================
--- trunk/libavutil/x86/intreadwrite.h	Tue Mar  9 17:44:10 2010	(r22406)
+++ trunk/libavutil/x86/intreadwrite.h	Tue Mar  9 18:39:19 2010	(r22407)
@@ -23,7 +23,7 @@
 
 #include <stdint.h>
 #include "config.h"
-#include "libavutil/common.h"
+#include "libavutil/attributes.h"
 
 #if HAVE_MMX
 



More information about the ffmpeg-cvslog mailing list