]> git.sesse.net Git - ffmpeg/blobdiff - configure
typos
[ffmpeg] / configure
index 64e304d2246ac4050b27761283c2343a1e1d5296..6af78a7e27b3ff4bd14caf3ca31c464792507c51 100755 (executable)
--- a/configure
+++ b/configure
@@ -70,8 +70,8 @@ show_help(){
   echo "                           and ffmpeg will be under GPL [default=no]"
   echo "  --enable-nonfree         allow use of nonfree code, the resulting libav*"
   echo "                           and ffmpeg will be unredistributable [default=no]"
-  echo "  --enable-pp              enable GPLed postprocessing support [default=no]"
-  echo "  --enable-swscaler        software scaler support [default=no]"
+  echo "  --enable-postproc        enable GPLed postprocessing support [default=no]"
+  echo "  --enable-swscale         software scaler support [default=no]"
   echo "  --enable-avfilter        video filter support (replaces vhook) [default=no]"
   echo "  --enable-avfilter-lavf   video filters dependant on avformat [default=no]"
   echo "  --enable-beosthreads     use BeOS threads [default=no]"
@@ -658,10 +658,10 @@ CONFIG_LIST="
     mpegaudio_hp
     network
     nonfree
+    postproc
     powerpc_perf
-    pp
     small
-    swscaler
+    swscale
     vhook
     x11grab
     zlib
@@ -708,6 +708,7 @@ HAVE_LIST="
     $THREADS_LIST
     altivec_h
     arpa_inet_h
+    bswap
     byteswap_h
     closesocket
     cmov
@@ -732,6 +733,7 @@ HAVE_LIST="
     getrusage
     imlib2
     inet_aton
+    inline_asm
     libdc1394_1
     libdc1394_2
     llrint
@@ -786,22 +788,9 @@ ac3_decoder_deps="gpl"
 dxa_decoder_deps="zlib"
 flashsv_decoder_deps="zlib"
 flashsv_encoder_deps="zlib"
-flv_decoder_deps="h263_decoder"
-h263_decoder_deps="h263_parser mpeg4video_parser"
-h263i_decoder_deps="h263_decoder"
-h264_decoder_deps="h264_parser"
 mpeg_xvmc_decoder_deps="xvmc"
-mpeg4_decoder_deps="h263_decoder"
-msmpeg4v1_decoder_deps="h263_decoder"
-msmpeg4v2_decoder_deps="h263_decoder"
-msmpeg4v3_decoder_deps="h263_decoder"
 png_decoder_deps="zlib"
 png_encoder_deps="zlib"
-svq3_decoder_deps="h264_parser"
-vc1_decoder_deps="h263_decoder"
-wmv1_decoder_deps="h263_decoder"
-wmv2_decoder_deps="h263_decoder"
-wmv3_decoder_deps="h263_decoder"
 zmbv_decoder_deps="zlib"
 zmbv_encoder_deps="zlib"
 
@@ -847,6 +836,8 @@ rtsp_demuxer_deps="sdp_demuxer"
 sdp_demuxer_deps="rtp_protocol mpegts_demuxer"
 v4l2_demuxer_deps="linux_videodev2_h"
 v4l_demuxer_deps="linux_videodev_h"
+vfwcap_demuxer_deps="capCreateCaptureWindow"
+vfwcap_demuxer_extralibs="-lvfw32"
 x11_grab_device_demuxer_deps="x11grab XShmCreateImage"
 x11_grab_device_demuxer_extralibs="-lX11 -lXext"
 
@@ -857,7 +848,7 @@ tcp_protocol_deps="network"
 udp_protocol_deps="network"
 
 # filters
-vsrc_movie_deps="avfilter_lavf"
+movie_filter_deps="avfilter_lavf"
 
 # programs
 ffplay_deps="sdl"
@@ -943,6 +934,10 @@ SLIBNAME_WITH_VERSION='$(SLIBNAME).$(LIBVERSION)'
 SLIBNAME_WITH_MAJOR='$(SLIBNAME).$(LIBMAJOR)'
 LIB_INSTALL_EXTRA_CMD='$(RANLIB) "$(LIBDIR)/$(LIBNAME)"'
 
+# gcc stupidly only outputs the basename of targets with -MM
+DEPEND_CMD='$(CC) -MM $(CFLAGS) $(filter-out %.h,$^) | sed "s,[0-9a-z._-]*: \([a-z0-9]*/\).*,\1&,"'
+VHOOKDEPEND_CMD='$(CC) -MM $(VHOOKCFLAGS) $(filter-out %.h,$^) | sed "s,^\([a-z]\),vhook/\1,"'
+
 # find source path
 source_path="`dirname \"$0\"`"
 enable source_path_used
@@ -961,7 +956,7 @@ find_things(){
     thing=$1
     pattern=$2
     file=$source_path/$3
-    sed -n "s/^[^#]*$pattern.*(.*, *\\(.*\\)).*/\\1_$thing/p" "$file"
+    sed -n "s/^[^#]*$pattern.*([^,]*, *\([^,]*\)\(,.*\)*).*/\1_$thing/p" "$file"
 }
 
 ENCODER_LIST=$(find_things  encoder  ENC      libavcodec/allcodecs.c)
@@ -973,9 +968,7 @@ DEMUXER_LIST=$(find_things  demuxer  DEMUX    libavformat/allformats.c)
 OUTDEV_LIST=$(find_things   muxer    _MUX     libavdevice/alldevices.c)
 INDEV_LIST=$(find_things    demuxer  DEMUX    libavdevice/alldevices.c)
 PROTOCOL_LIST=$(find_things protocol PROTOCOL libavformat/allformats.c)
-VIDEO_FILTER_LIST=$(find_things vf_ VF_ libavfilter/allfilters.c)
-SRC_FILTER_LIST=$(find_things vsrc_ VSRC_ libavfilter/allfilters.c)
-FILTER_LIST="$SRC_FILTER_LIST $VIDEO_FILTER_LIST"
+FILTER_LIST=$(find_things   filter   FILTER   libavfilter/allfilters.c)
 
 enable $ARCH_EXT_LIST \
        $DECODER_LIST \
@@ -1047,36 +1040,26 @@ for opt do
     ;;
     --disable-strip) disable dostrip
     ;;
-    --disable-encoders) disable $ENCODER_LIST
-    ;;
-    --disable-decoders) disable $DECODER_LIST
-    ;;
-    --disable-muxers) disable $MUXER_LIST
-    ;;
-    --disable-filters) disable $FILTER_LIST
-    ;;
-    --disable-demuxers) disable $DEMUXER_LIST
-    ;;
-    --disable-parsers) disable $PARSER_LIST
-    ;;
-    --disable-bsfs) disable $BSF_LIST
-    ;;
-    --disable-protocols) disable $PROTOCOL_LIST
-    ;;
     --disable-devices) disable $INDEV_LIST $OUTDEV_LIST
     ;;
+    --enable-debug=*) debuglevel="$optval"
+    ;;
     --enable-*=*|--disable-*=*)
     eval `echo "$opt" | sed 's/=/-/;s/--/action=/;s/-/ thing=/;s/-/ name=/'`
     case "$thing" in
-        encoder|decoder|muxer|demuxer|parser|bsf|protocol) $action ${optval}_${thing} ;;
-        filter) $action ${optval} ;;
+        encoder|decoder|muxer|demuxer|parser|bsf|protocol|filter) $action ${optval}_${thing} ;;
         *) die_unknown "$opt" ;;
     esac
     ;;
     --enable-?*|--disable-?*)
     eval `echo "$opt" | sed 's/--/action=/;s/-/ option=/;s/-/_/g'`
-    echo "$CMDLINE_SELECT" | grep -q "^ *$option\$" || die_unknown $opt
-    $action $option
+    if is_in $option $COMPONENT_LIST; then
+        eval $action \$$(toupper ${option%s})_LIST
+    elif is_in $option $CMDLINE_SELECT; then
+        $action $option
+    else
+        die_unknown $opt
+    fi
     ;;
     --list-*)
         NAME="${opt#--list-}"
@@ -1221,7 +1204,7 @@ case $targetos in
         ;;
     darwin)
         disable need_memalign
-        SHFLAGS='-dynamiclib -Wl,-single_module -Wl,-install_name,$(SHLIBDIR)/$(SLIBNAME),-current_version,$(SPPVERSION),-compatibility_version,$(SPPVERSION) -Wl,-read_only_relocs,suppress'
+        SHFLAGS='-dynamiclib -Wl,-single_module -Wl,-install_name,$(SHLIBDIR)/$(SLIBNAME),-current_version,$(LIBVERSION),-compatibility_version,$(LIBMAJOR) -Wl,-read_only_relocs,suppress'
         VHOOKSHFLAGS='-dynamiclib -Wl,-single_module -flat_namespace -undefined suppress -Wl,-install_name,$(SHLIBDIR)/vhook/$@'
         strip="strip -x"
         FFLDFLAGS="-Wl,-dynamic,-search_paths_first"
@@ -1235,7 +1218,7 @@ case $targetos in
         shlibdir="$bindir"
         VHOOKSHFLAGS='-shared -L$(BUILD_ROOT)/libavformat -L$(BUILD_ROOT)/libavcodec -L$(BUILD_ROOT)/libavutil'
         VHOOKLIBS='-lavformat$(BUILDSUF) -lavcodec$(BUILDSUF) -lavutil$(BUILDSUF) $(EXTRALIBS)'
-        if enabled swscaler; then
+        if enabled swscale; then
             VHOOKSHFLAGS="$VHOOKSHFLAGS -L\$(BUILD_ROOT)/libswscale"
             VHOOKLIBS="$VHOOKLIBS -lswscale\$(BUILDSUF)"
         fi
@@ -1255,7 +1238,7 @@ case $targetos in
         shlibdir="$bindir"
         VHOOKSHFLAGS='-shared -L$(BUILD_ROOT)/libavformat -L$(BUILD_ROOT)/libavcodec -L$(BUILD_ROOT)/libavutil'
         VHOOKLIBS='-lavformat$(BUILDSUF) -lavcodec$(BUILDSUF) -lavutil$(BUILDSUF) $(EXTRALIBS)'
-        if enabled swscaler; then
+        if enabled swscale; then
             VHOOKSHFLAGS="$VHOOKSHFLAGS -L\$(BUILD_ROOT)/libswscale"
             VHOOKLIBS="$VHOOKLIBS -lswscale\$(BUILDSUF)"
         fi
@@ -1267,7 +1250,6 @@ case $targetos in
         SHFLAGS='-shared -Wl,--enable-auto-image-base'
         ;;
     *-dos|freedos|opendos)
-        enable memalign_hack
         disable ffplay ffserver vhook
         disable $INDEV_LIST $OUTDEV_LIST
         network_extralibs="-lsocket"
@@ -1306,7 +1288,7 @@ case $targetos in
           emximp -o $(LIBPREF)$(NAME)_dll.lib $(NAME).def;'
         SLIB_INSTALL_EXTRA_CMD='install -m 644 $(LIBPREF)$(NAME)_dll.a $(LIBPREF)$(NAME)_dll.lib "$(LIBDIR)"'
         SLIB_UNINSTALL_EXTRA_CMD='rm -f "$(LIBDIR)"/$(LIBPREF)$(NAME)_dll.a "$(LIBDIR)"/$(LIBPREF)$(NAME)_dll.lib'
-        vhook="no"
+        disable vhook
         ;;
     interix)
         disable vhook
@@ -1371,13 +1353,13 @@ if ! enabled gpl; then
         shift
         enabled_any $@ && die "$name is under GPL and --enable-gpl is not specified."
     }
-    die_gpl_disabled "The Postprocessing code" pp
+    die_gpl_disabled "The Postprocessing code" postproc
     die_gpl_disabled "liba52"                  liba52
     die_gpl_disabled "libx264"                 libx264
     die_gpl_disabled "libxvidcore"             libxvid
     die_gpl_disabled "FAAD2"                   libfaad2
     die_gpl_disabled "The X11 grabber"         x11grab
-    die_gpl_disabled "The software scaler"     swscaler
+    die_gpl_disabled "The software scaler"     swscale
 fi
 
 if ! enabled nonfree && enabled_any libamr_nb libamr_wb; then
@@ -1393,10 +1375,10 @@ if test $targetos = darwin; then
     if test -n "`$cc -v 2>&1 | grep xlc`"; then
         add_cflags "-qpdf2 -qlanglvl=extc99 -qmaxmem=-1 -qarch=auto -qtune=auto"
     else
-        add_cflags "-no-cpp-precomp -pipe"
+        add_cflags "-pipe"
         check_cflags "-force_cpusubtype_ALL"
         check_cflags "-Wno-sign-compare"
-        disabled shared && add_cflags -mdynamic-no-pic
+        enabled shared || add_cflags -mdynamic-no-pic
     fi
 fi
 
@@ -1509,6 +1491,8 @@ if test "$?" != 0; then
     die "C compiler test failed."
 fi
 
+check_asm inline_asm '""'
+
 if enabled x86; then
     # check whether EBP is available on x86
     # As 'i' is stored on the stack, this program will crash
@@ -1527,6 +1511,8 @@ EOF
 
     # check whether binutils is new enough to compile SSSE3
     enabled ssse3 && check_asm ssse3 '"pabsw %xmm0, %xmm0"'
+
+    check_asm bswap '"bswap %%eax" ::: "%eax"'
 fi
 
 # check for assembler specific support
@@ -1579,7 +1565,7 @@ enabled vis && add_cflags "-mcpu=ultrasparc -mtune=ultrasparc"
 check_cc <<EOF || die "endian test failed"
 unsigned int endian = 'B' << 24 | 'I' << 16 | 'G' << 8 | 'E';
 EOF
-grep -q BIGE $TMPO && enable bigendian
+od -A n -t x1 $TMPO | grep -q '42 *49 *47 *45' && enable bigendian
 
 # ---
 # check availability of some header files
@@ -1773,6 +1759,8 @@ EOF
 check_header linux/videodev.h
 check_header linux/videodev2.h
 
+check_func2 "windows.h vfw.h" capCreateCaptureWindow -lvfw32
+
 # check for ioctl_meteor.h, ioctl_bt848.h and alternatives
 { check_header dev/bktr/ioctl_meteor.h &&
   check_header dev/bktr/ioctl_bt848.h; } ||
@@ -1792,7 +1780,7 @@ check_header X11/extensions/XShm.h      &&
 check_func XOpenDisplay -lX11           &&
 check_func XShmCreateImage -lX11 -lXext
 
-enabled debug && add_cflags -g
+enabled debug && add_cflags -g"$debuglevel"
 
 # add some useful compiler flags if supported
 check_cflags -Wdeclaration-after-statement
@@ -1824,6 +1812,7 @@ elif enabled optimizations; then
     fi
 fi
 check_cflags -fno-math-errno
+check_cflags -fno-signed-zeros
 
 # PIC flags for shared library objects where they are needed
 if enabled shared; then
@@ -1912,10 +1901,10 @@ echo "strip symbols             ${dostrip-no}"
 echo "optimizations             ${optimizations-no}"
 echo "static                    ${static-no}"
 echo "shared                    ${shared-no}"
-echo "postprocessing support    ${pp-no}"
-echo "software scaler enabled   ${swscaler-no}"
+echo "postprocessing support    ${postproc-no}"
+echo "software scaler enabled   ${swscale-no}"
 echo "new filter support        ${avfilter-no}"
-echo "filters using lavformat   ${avfilter-lavf-no}"
+echo "filters using lavformat   ${avfilter_lavf-no}"
 echo "video hooking             ${vhook-no}"
 if enabled vhook; then
     echo "Imlib2 support            ${imlib2-no}"
@@ -1948,17 +1937,15 @@ echo "libvorbis enabled         ${libvorbis-no}"
 echo "x264 enabled              ${libx264-no}"
 echo "XviD enabled              ${libxvid-no}"
 echo "zlib enabled              ${zlib-no}"
+echo
 
 for type in decoder encoder parser demuxer muxer protocol filter bsf indev outdev; do
     echo "Enabled ${type}s:"
-    ucname="\$`toupper $type`_LIST"
-    list="`eval echo $ucname`"
-    partlist=""
+    eval list=\$$(toupper $type)_LIST
     for part in $list; do
-        enabled $part && partlist="$partlist $part"
-    done
-    partlist=`echo $partlist | sed s/_$type//g | tr ' ' '\n' | sort`
-    echo $partlist
+        enabled $part && echo ${part%_*}
+    done | sort | pr -3 -t
+    echo
 done
 
 enabled nonfree &&
@@ -2008,14 +1995,13 @@ echo "LIBNAME=$LIBNAME" >> config.mak
 echo "SLIBPREF=$SLIBPREF" >> config.mak
 echo "SLIBSUF=$SLIBSUF" >> config.mak
 echo "EXESUF=$EXESUF" >> config.mak
+echo "DEPEND_CMD=$DEPEND_CMD" >> config.mak
+echo "VHOOKDEPEND_CMD=$VHOOKDEPEND_CMD" >> config.mak
 
 if enabled bigendian; then
     echo "WORDS_BIGENDIAN=yes" >> config.mak
     echo "#define WORDS_BIGENDIAN 1" >> $TMPH
 fi
-if enabled mmx; then
-    echo "#define __CPU__ 586" >> $TMPH
-fi
 
 if enabled sdl; then
     echo "SDL_LIBS=`"${SDL_CONFIG}" --libs`" >> config.mak
@@ -2030,6 +2016,9 @@ get_version(){
     file=$source_path/$2
     eval $(grep "#define ${name}_VERSION_M" "$file" | awk '{ print $2"="$3 }')
     eval ${name}_VERSION=\$${name}_VERSION_MAJOR.\$${name}_VERSION_MINOR.\$${name}_VERSION_MICRO
+    lcname=$(tolower $name)
+    eval echo "${lcname}_VERSION=\$${name}_VERSION" >> config.mak
+    eval echo "${lcname}_VERSION_MAJOR=\$${name}_VERSION_MAJOR" >> config.mak
 }
 
 get_version LIBSWSCALE  libswscale/swscale.h
@@ -2038,25 +2027,11 @@ get_version LIBAVCODEC  libavcodec/avcodec.h
 get_version LIBAVDEVICE libavdevice/avdevice.h
 get_version LIBAVFORMAT libavformat/avformat.h
 get_version LIBAVUTIL   libavutil/avutil.h
-lavfi_version=$(get_version LIBAVFILTER   libavfilter/avfilter.h)
+get_version LIBAVFILTER libavfilter/avfilter.h
 
 if enabled shared; then
     echo "BUILD_SHARED=yes" >> config.mak
     echo "PIC=-fPIC -DPIC" >> config.mak
-    echo "SPPMAJOR=$LIBPOSTPROC_VERSION_MAJOR" >> config.mak
-    echo "SPPVERSION=$LIBPOSTPROC_VERSION" >> config.mak
-    echo "LAVCMAJOR=$LIBAVCODEC_VERSION_MAJOR" >> config.mak
-    echo "LAVCVERSION=$LIBAVCODEC_VERSION" >> config.mak
-    echo "LAVDMAJOR=$LIBAVDEVICE_VERSION_MAJOR" >> config.mak
-    echo "LAVDVERSION=$LIBAVDEVICE_VERSION" >> config.mak
-    echo "LAVFMAJOR=$LIBAVFORMAT_VERSION_MAJOR" >> config.mak
-    echo "LAVFVERSION=$LIBAVFORMAT_VERSION" >> config.mak
-    echo "LAVUMAJOR=$LIBAVUTIL_VERSION_MAJOR" >> config.mak
-    echo "LAVUVERSION=$LIBAVUTIL_VERSION" >> config.mak
-    echo "LAVFIMAJOR=$LIBAVFILTER_VERSION_MAJOR" >> config.mak
-    echo "LAVFIVERSION=$LIBAVFILTER_VERSION" >> config.mak
-    echo "SWSMAJOR=$LIBSWSCALE_VERSION_MAJOR" >> config.mak
-    echo "SWSVERSION=$LIBSWSCALE_VERSION" >> config.mak
     echo "SLIBNAME=${SLIBNAME}" >> config.mak
     echo "SLIBNAME_WITH_VERSION=${SLIBNAME_WITH_VERSION}" >> config.mak
     echo "SLIBNAME_WITH_MAJOR=${SLIBNAME_WITH_MAJOR}" >> config.mak
@@ -2100,7 +2075,7 @@ enabled asmalign_pot &&
 
 echo "#endif /* FFMPEG_CONFIG_H */" >> $TMPH
 
-# Do not overwrite config.h if unchanged to avoid superfluous rebuilds.
+# Do not overwrite an unchanged config.h to avoid superfluous rebuilds.
 cmp -s $TMPH config.h &&
     echo "config.h is unchanged" ||
     mv -f $TMPH config.h
@@ -2199,33 +2174,33 @@ Cflags: -I\${includedir}
 EOF
 }
 
-pkgconfig_generate libavutil "FFmpeg utility library" "$lavu_version" -lavutil ""
-pkgconfig_generate_uninstalled libavutil "FFmpeg utility library" "$lavu_version"
+pkgconfig_generate libavutil "FFmpeg utility library" "$LIBAVUTIL_VERSION" -lavutil ""
+pkgconfig_generate_uninstalled libavutil "FFmpeg utility library" "$LIBAVUTIL_VERSION"
 
-pkgconfig_generate libavcodec "FFmpeg codec library" "$lavc_version" "-lavcodec $extralibs" "$pkg_requires libavutil = $lavu_version"
-pkgconfig_generate_uninstalled libavcodec "FFmpeg codec library" "$lavc_version" "$extralibs" "$pkg_requires libavutil = $lavu_version"
+pkgconfig_generate libavcodec "FFmpeg codec library" "$LIBAVCODEC_VERSION" "-lavcodec $extralibs" "$pkg_requires libavutil = $LIBAVUTIL_VERSION"
+pkgconfig_generate_uninstalled libavcodec "FFmpeg codec library" "$LIBAVCODEC_VERSION" "$extralibs" "$pkg_requires libavutil = $LIBAVUTIL_VERSION"
 
-pkgconfig_generate libavformat "FFmpeg container format library" "$lavf_version" "-lavformat $extralibs" "$pkg_requires libavcodec = $lavc_version"
-pkgconfig_generate_uninstalled libavformat "FFmpeg container format library" "$lavf_version" "$extralibs" "$pkg_requires libavcodec = $lavc_version"
+pkgconfig_generate libavformat "FFmpeg container format library" "$LIBAVFORMAT_VERSION" "-lavformat $extralibs" "$pkg_requires libavcodec = $LIBAVCODEC_VERSION"
+pkgconfig_generate_uninstalled libavformat "FFmpeg container format library" "$LIBAVFORMAT_VERSION" "$extralibs" "$pkg_requires libavcodec = $LIBAVCODEC_VERSION"
 
-pkgconfig_generate libavdevice "FFmpeg device handling library" "$lavd_version" "-lavdevice $extralibs" "$pkg_requires libavformat = $lavf_version"
-pkgconfig_generate_uninstalled libavdevice "FFmpeg device handling library" "$lavd_version" "$extralibs" "$pkg_requires libavformat = $lavf_version"
-if enabled pp; then
-    pkgconfig_generate libpostproc "FFmpeg post processing library" "$pp_version" -lpostproc ""
-    pkgconfig_generate_uninstalled libpostproc "FFmpeg post processing library" "$pp_version"
+pkgconfig_generate libavdevice "FFmpeg device handling library" "$LIBAVDEVICE_VERSION" "-lavdevice $extralibs" "$pkg_requires libavformat = $LIBAVFORMAT_VERSION"
+pkgconfig_generate_uninstalled libavdevice "FFmpeg device handling library" "$LIBAVDEVICE_VERSION" "$extralibs" "$pkg_requires libavformat = $LIBAVFORMAT_VERSION"
+if enabled postproc; then
+    pkgconfig_generate libpostproc "FFmpeg post processing library" "$LIBPOSTPROC_VERSION" -lpostproc ""
+    pkgconfig_generate_uninstalled libpostproc "FFmpeg post processing library" "$LIBPOSTPROC_VERSION"
 fi
 
-if enabled swscaler; then
-    pkgconfig_generate libswscale "FFmpeg image rescaling library" "$sws_version" -lswscale "libavutil = $lavu_version"
-    pkgconfig_generate_uninstalled libswscale "FFmpeg image rescaling library" "$sws_version" "" "libavutil = $lavu_version"
+if enabled swscale; then
+    pkgconfig_generate libswscale "FFmpeg image rescaling library" "$LIBSWSCALE_VERSION" -lswscale "libavutil = $LIBAVUTIL_VERSION"
+    pkgconfig_generate_uninstalled libswscale "FFmpeg image rescaling library" "$LIBSWSCALE_VERSION" "" "libavutil = $LIBAVUTIL_VERSION"
 else
-    pkgconfig_generate libswscale "FFmpeg image rescaling library" "$sws_version" "" "$pkg_requires libavcodec = $lavc_version"
-    pkgconfig_generate_uninstalled libswscale "FFmpeg image rescaling library" "$sws_version" "" "$pkg_requires libavcodec = $lavc_version"
+    pkgconfig_generate libswscale "FFmpeg image rescaling library" "$LIBSWSCALE_VERSION" "" "$pkg_requires libavcodec = $LIBAVCODEC_VERSION"
+    pkgconfig_generate_uninstalled libswscale "FFmpeg image rescaling library" "$LIBSWSCALE_VERSION" "" "$pkg_requires libavcodec = $LIBAVCODEC_VERSION"
     apply libswscale.pc sed s/^Libs:.*$/Libs:/
     apply libswscale-uninstalled.pc sed s/^Libs:.*$/Libs:/
 fi
 
 if enabled avfilter; then
-  pkgconfig_generate libavfilter "FFmpeg video filtering library" "$avfilter_version" "-lavfilter $extralibs" "$pkg_requires libavutil = $lavu=version" ffmpeg
-  pkgconfig_generate_uninstalled libavfilter "FFmpeg video filtering library" "$avfilter_version" "$extralibs" "$pkg_requires libavutil = $libavu_version"
+  pkgconfig_generate libavfilter "FFmpeg video filtering library" "$LIBAVFILTER_VERSION" "-lavfilter $extralibs" "$pkg_requires libavutil = $LIBAVUTIL_VERSION" ffmpeg
+  pkgconfig_generate_uninstalled libavfilter "FFmpeg video filtering library" "$LIBAVFILTER_VERSION" "$extralibs" "$pkg_requires libavutil = $LIBAVUTIL_VERSION"
 fi