From 7a65aef00d113a38e0d1a54df49eead9df6aa15c Mon Sep 17 00:00:00 2001 From: Andreas Cadhalpun Date: Tue, 11 Oct 2016 20:28:35 +0200 Subject: configure: fix detection of libopenjpeg Use check_lib2 to test the header together with the function. This is necessary, because '-DOPJ_STATIC' changes what the included header does. Also add '-DOPJ_STATIC' to CPPFLAGS, so that it isn't necessary to hardcode this in libavcodec/libopenjpeg{dec,enc}.c. Finally, check for non-static openjpeg 2.1, too. Reviewed-by: Michael Bradshaw Signed-off-by: Andreas Cadhalpun --- libavcodec/libopenjpegenc.c | 2 -- 1 file changed, 2 deletions(-) (limited to 'libavcodec/libopenjpegenc.c') diff --git a/libavcodec/libopenjpegenc.c b/libavcodec/libopenjpegenc.c index 14435515bc..5042507ea4 100644 --- a/libavcodec/libopenjpegenc.c +++ b/libavcodec/libopenjpegenc.c @@ -24,8 +24,6 @@ * JPEG 2000 encoder using libopenjpeg */ -#define OPJ_STATIC - #include "libavutil/avassert.h" #include "libavutil/common.h" #include "libavutil/imgutils.h" -- cgit v1.2.3