#include <xvid.h>
#include <unistd.h>
#include "avcodec.h"
+#include "libavutil/cpu.h"
#include "libavutil/intreadwrite.h"
#include "libxvid_internal.h"
#if !HAVE_MKSTEMP
#define BUFFER_REMAINING(x) (BUFFER_SIZE - strlen(x))
#define BUFFER_CAT(x) (&((x)[strlen(x)]))
-/* For PPC Use */
-int has_altivec(void);
-
/**
* Structure for the private Xvid context.
* This stores all the private context for the codec.
#if ARCH_PPC
/* Xvid's PPC support is borked, use libavcodec to detect */
#if HAVE_ALTIVEC
- if( has_altivec() ) {
+ if (av_get_cpu_flags() & AV_CPU_FLAG_ALTIVEC) {
xvid_gbl_init.cpu_flags = XVID_CPU_FORCE | XVID_CPU_ALTIVEC;
} else
#endif