summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorBrad Smith <brad@comstyle.com>2011-05-17 02:05:22 +0000
committerBrad Smith <brad@comstyle.com>2011-05-17 02:05:22 +0000
commit597429a7d24b55dec3570598f9509e8aa635cf04 (patch)
treef18d59929cf936207b2687ee29162ce13f25488e /src
parentf5e7f8e8d41fd9fa6f8e3fdc7930134eef9855a3 (diff)
downloadxine-lib-597429a7d24b55dec3570598f9509e8aa635cf04.tar.gz
xine-lib-597429a7d24b55dec3570598f9509e8aa635cf04.tar.bz2
Fix build with relatively recent copies of FFmpeg
Relatively recent copies of FFmpeg before the major API clean up have both the old SHA1 API and the new SHA (1/2) API so the recently added autoconf check will reject perfectly valid copies of FFmpeg. Also tweak the input_cdda code to make sure to use the new API and not include the compat macros if both the old and new API are around.
Diffstat (limited to 'src')
-rw-r--r--src/input/input_cdda.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/input/input_cdda.c b/src/input/input_cdda.c
index 53733fddf..2cc2bd49d 100644
--- a/src/input/input_cdda.c
+++ b/src/input/input_cdda.c
@@ -64,10 +64,10 @@
# include <sha1.h>
#else
# include <libavutil/base64.h>
-# ifdef HAVE_LIBAVUTIL_SHA1_H
-# include <libavutil/sha1.h>
-# else
+# ifdef HAVE_LIBAVUTIL_SHA_H
# include <libavutil/sha.h>
+# else
+# include <libavutil/sha1.h>
# endif
#endif
@@ -104,7 +104,7 @@
#define CD_LEADOUT_TRACK 0xAA
#define CD_BLOCK_OFFSET 150
-#ifdef HAVE_LIBAVUTIL_SHA1_H
+#if defined(HAVE_LIBAVUTIL_SHA1_H) && !defined(HAVE_LIBAVUTIL_SHA_H)
/* old libavutil/sha1.h was found... */
#define AVSHA AVSHA1
# define av_sha_init(c,b) av_sha1_init(c)