From patchwork Fri Oct 15 13:39:06 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Xiang, Haihao" X-Patchwork-Id: 31125 Delivered-To: ffmpegpatchwork2@gmail.com Received: by 2002:a05:6602:2084:0:0:0:0 with SMTP id a4csp378578ioa; Fri, 15 Oct 2021 06:39:52 -0700 (PDT) X-Google-Smtp-Source: ABdhPJx0Ucg3CMXuaLvM8ZK/4zboStlCAjV1lzuPMPn4KD/K0YT2lB15TBr2cG2am8y9KRszB14Y X-Received: by 2002:a17:907:3e8e:: with SMTP id hs14mr6949195ejc.35.1634305192111; Fri, 15 Oct 2021 06:39:52 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1634305192; cv=none; d=google.com; s=arc-20160816; b=v23qRuHpHsIpxMefI/FUxsTYPHDrrfVvpeIabuCvLmgaE4b9mgTKF8OvLGal+Ov593 /S8rmQ69F4pkjmZ6eEq0zleNG+rdDpsAltLN2o7VBSZYckeWroSrl3bkT2HpWB/wQMvL XGYZJqLt5rF7sbl91RFSYcm7AUG2MBUZ14/v4sx3XqXwgmM1T7UQWa92iOEoQ6ArbD3X MTm6TMi/BB4jdflOYRxTdC+BzR6LCpkSiaIty/wYvmUfteCHT1PysDdwi/IpeEzPLfeH /E3HvsHZSsqiiWhm9QQHERyHim5/6cesM7nTlnNV9X+z0pkr4HwhEV/s0tNesDzUfZyk sbvw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:content-transfer-encoding:mime-version:cc:reply-to :list-subscribe:list-help:list-post:list-archive:list-unsubscribe :list-id:precedence:subject:references:in-reply-to:message-id:date :to:from:delivered-to; bh=8uxXkniLva69CDSajMCPnvs6W+ckd27nlYJmOCTrwmQ=; b=L8BympqKcVGtC8+zU8vWtev1/CivqbcotzIdvEA8kUsLADahX2x/KAY9Hmv1EqL5i7 pR+fFhqPTpfXROcoqGKKnN/0/fek3X0NdftbA7nXZR0++2CIw7jpe6aOahqVaf0S2/mm Dwre2vqLJBBIuLlos40IH1d/K2a+0K1wtSTscabTdAw7+8jCMGMeqgM1TTECIX9cfDGe Hz8DTgVUIeTLVcjWVyQgmh8u+u7oLUPFMpiV01lDBu8KkOGy/CAKfOP6xwASHlL0v9tL XmOkKTmyuxDl90garJNatou7pi8ehRxw9JFO/M2LBSZlnz/WUv+VSUigamcQiBs/b/LE aF4A== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) smtp.mailfrom=ffmpeg-devel-bounces@ffmpeg.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=intel.com Return-Path: Received: from ffbox0-bg.mplayerhq.hu (ffbox0-bg.ffmpeg.org. [79.124.17.100]) by mx.google.com with ESMTP id p9si8483141ejg.760.2021.10.15.06.39.51; Fri, 15 Oct 2021 06:39:52 -0700 (PDT) Received-SPF: pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) client-ip=79.124.17.100; Authentication-Results: mx.google.com; spf=pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) smtp.mailfrom=ffmpeg-devel-bounces@ffmpeg.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=intel.com Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id 9565168A990; Fri, 15 Oct 2021 16:39:38 +0300 (EEST) X-Original-To: ffmpeg-devel@ffmpeg.org Delivered-To: ffmpeg-devel@ffmpeg.org Received: from mga04.intel.com (mga04.intel.com [192.55.52.120]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id EB95C6808A7 for ; Fri, 15 Oct 2021 16:39:31 +0300 (EEST) X-IronPort-AV: E=McAfee;i="6200,9189,10137"; a="226686969" X-IronPort-AV: E=Sophos;i="5.85,375,1624345200"; d="scan'208";a="226686969" Received: from orsmga006.jf.intel.com ([10.7.209.51]) by fmsmga104.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 15 Oct 2021 06:39:29 -0700 X-IronPort-AV: E=Sophos;i="5.85,375,1624345200"; d="scan'208";a="442524762" Received: from xhh-dg164.sh.intel.com ([10.239.159.167]) by orsmga006-auth.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 15 Oct 2021 06:39:28 -0700 From: Haihao Xiang To: ffmpeg-devel@ffmpeg.org Date: Fri, 15 Oct 2021 21:39:06 +0800 Message-Id: <20211015133915.13624-2-haihao.xiang@intel.com> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20211015133915.13624-1-haihao.xiang@intel.com> References: <20211015133915.13624-1-haihao.xiang@intel.com> Subject: [FFmpeg-devel] [PATCH v6 01/10] configure: ensure --enable-libmfx uses libmfx 1.x X-BeenThere: ffmpeg-devel@ffmpeg.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: FFmpeg development discussions and patches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: FFmpeg development discussions and patches Cc: Haihao Xiang MIME-Version: 1.0 Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" X-TUID: szw/5DGGkNJW Intel's oneVPL is a successor to MediaSDK, but removed some obsolete features of MediaSDK[1]. Some early versions of oneVPL still uses libmfx as library name[2], however some of obsolete features, including OPAQUE memory, multi-frame encode, user plugins and LA_EXT rate control mode etc, have been enabled in QSV, so user can not use --enable-libmfx to enable QSV if using an early version of oneVPL SDK. In order to make sure user builds FFmpeg against a right version of libmfx, this patch added a check for the version of libmfx and warning message about the used obsolete features. [1] https://spec.oneapi.io/versions/latest/elements/oneVPL/source/appendix/VPL_intel_media_sdk.html [2] https://github.com/oneapi-src/oneVPL --- configure | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/configure b/configure index 92610c7edc..f89e769684 100755 --- a/configure +++ b/configure @@ -6438,8 +6438,11 @@ enabled liblensfun && require_pkg_config liblensfun lensfun lensfun.h lf_ # Media SDK or Intel Media Server Studio, these don't come with # pkg-config support. Instead, users should make sure that the build # can find the libraries and headers through other means. -enabled libmfx && { check_pkg_config libmfx libmfx "mfx/mfxvideo.h" MFXInit || - { require libmfx "mfx/mfxvideo.h" MFXInit "-llibmfx $advapi32_extralibs" && warn "using libmfx without pkg-config"; } } +enabled libmfx && { { check_pkg_config libmfx "libmfx < 2.0" "mfx/mfxvideo.h" MFXInit || + { require "libmfx < 2.0" "mfx/mfxvideo.h" MFXInit "-llibmfx $advapi32_extralibs" && warn "using libmfx without pkg-config"; } } && + warn "build FFmpeg against libmfx 1.x, obsolete features of libmfx such as OPAQUE memory,\n"\ + "multi-frame encode, user plugins and LA_EXT rate control mode are enabled"; } + if enabled libmfx; then check_cc MFX_CODEC_VP9 "mfx/mfxvp9.h mfx/mfxstructures.h" "MFX_CODEC_VP9" fi