Also fixes the non-pkg-config check. Patch attached.
>From 6df42fc4ed19e54ee83c7ef3f969a3bc744ca036 Mon Sep 17 00:00:00 2001 From: Lynne <d...@lynne.ee> Date: Wed, 24 Nov 2021 20:17:09 +0100 Subject: [PATCH] configure: do not include -lvulkan in vulkan's pkg-config check Also fixes the non-pkg-config check. --- configure | 15 +++++++++++---- 1 file changed, 11 insertions(+), 4 deletions(-) diff --git a/configure b/configure index d068b11073..e6cee21142 100755 --- a/configure +++ b/configure @@ -1464,13 +1464,13 @@ test_pkg_config_cpp(){ cond="$4" shift 4 disable $name - test_cmd $pkg_config --exists --print-errors $pkg_version || return + test_cmd $pkg_config --exists --print-errors $pkg_version || returnddd pkg_cflags=$($pkg_config --cflags $pkg_config_flags $pkg) - pkg_incdir=$($pkg_config --variable=includedir $pkg_config_flags $pkg) + pkg_incflags=$($pkg_config --cflags-onyl-I $pkg_config_flags $pkg) test_cpp_condition "$pkg_incdir/$headers" "$cond" "$@" && enable $name && set_sanitized "${name}_cflags" $pkg_cflags && - set_sanitized "${name}_incdir" $pkg_incdir + set_sanitized "${name}_incflags" $pkg_incflags } check_pkg_config(){ @@ -1487,6 +1487,13 @@ check_pkg_config_cpp(){ eval add_cflags \$${name}_cflags } +check_pkg_config_header_only(){ + log check_pkg_config_cpp "$@" + name="$1" + test_pkg_config_cpp "$@" && + eval add_cflags \$${name}_incflags +} + test_exec(){ test_ld "cc" "$@" && { enabled cross_compile || $TMPE >> $logfile 2>&1; } } @@ -6842,7 +6849,7 @@ enabled vdpau && enabled crystalhd && check_lib crystalhd "stdint.h libcrystalhd/libcrystalhd_if.h" DtsCrystalHDVersion -lcrystalhd if enabled vulkan; then - require_pkg_config_cpp vulkan "vulkan >= 1.2.189" "vulkan/vulkan.h" "defined VK_VERSION_1_2" || + check_pkg_config_header_only vulkan "vulkan >= 1.2.189" "vulkan/vulkan.h" "defined VK_VERSION_1_2" || require_cpp_condition vulkan "vulkan/vulkan.h" "defined VK_VERSION_1_2" fi -- 2.34.0
_______________________________________________ ffmpeg-devel mailing list ffmpeg-devel@ffmpeg.org https://ffmpeg.org/mailman/listinfo/ffmpeg-devel To unsubscribe, visit link above, or email ffmpeg-devel-requ...@ffmpeg.org with subject "unsubscribe".