avoid link-time dependency to libavcodec

it has lots of lots of deps, and we want to run on barebone systems
This commit is contained in:
notaz 2013-07-02 03:00:34 +03:00
parent fc11dd059b
commit 986d60fc60
2 changed files with 53 additions and 4 deletions

8
configure vendored
View file

@ -280,7 +280,7 @@ check_libavcodec()
#include <libavcodec/avcodec.h>
void main() { avcodec_decode_audio3(0, 0, 0, 0); }
EOF
compile_binary "$@" -lavcodec
compile_object "$@"
}
#MAIN_LDLIBS="$MAIN_LDLIBS -lz"
@ -291,7 +291,11 @@ check_libpng || fail "please install libpng (libpng-dev)"
if check_libavcodec; then
have_libavcodec="yes"
MAIN_LDLIBS="-lavcodec $MAIN_LDLIBS"
# add -ldl if needed
case "$MAIN_LDLIBS" in
*"-ldl"*) ;;
*) MAIN_LDLIBS="-ldl $MAIN_LDLIBS" ;;
esac
fi
# find what audio support we can compile