From patchwork Thu Jun 2 03:41:09 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Xiang, Haihao" X-Patchwork-Id: 36045 Delivered-To: ffmpegpatchwork2@gmail.com Received: by 2002:a05:6a20:6914:b0:82:6b11:2509 with SMTP id q20csp3803101pzj; Wed, 1 Jun 2022 20:42:16 -0700 (PDT) X-Google-Smtp-Source: ABdhPJx6mG/sUNkNdYzJPjmltMhflQlbFfU2+1GwtsPQvcsjDv1GxHkHyr17yaOyLS3+KkkCN3cd X-Received: by 2002:a17:907:a407:b0:704:34ac:835c with SMTP id sg7-20020a170907a40700b0070434ac835cmr2383733ejc.663.1654141335862; Wed, 01 Jun 2022 20:42:15 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1654141335; cv=none; d=google.com; s=arc-20160816; b=nnPhOIWh9TiEqug5lvSk3NGx1FyAwoOG00vnxHe2PoLoasVC+TOL05BY5rb1QLcbL+ BTHGaydJJ8oe0GwqhJHOpkAgckb9aCcbdKUNz2u5oafiOuG+Vc11dLbOlzA62jeqmZ8Z TLQXmgbhWRAE8x1ydZ73Why6cCsKg0Jt6Vj98hjM01s7RLMXEmPSXTRUpyZsTdjWqXvJ TdVmw8g3mGzVdKoZw55ujl2HxaNOtGh1f7lXUqJRy2hACRRnh64iEnLLAOi3UoMdmdRj zMUyqXDB/zer+PSwnCTZ+W+jpWZnEdmMVb+7Hnr3Ak9gjAqtF+CFAmOEo2NM0nncKGVs hCtw== 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:dkim-signature:delivered-to; bh=mrxITsVPFtL6f+fChxX6lj4b3A6qY8yg5WwB/yC7g9U=; b=eQ6zaBr5gj9FRMoHHRjzA7PjQzJrKfBO/PX92AJpP9UdzLuc9ZUfGR3X+941vG9yqM aJjWAEBEDIrUwX8rv2NSHNI2RSl6j0K4PJ2sOTRZ8fjqwaZUbWiUhn+m+s1rinYpNtys EfHI8TB05/QV0zgrf5ljUyy8ihaalMOCSaubGipOxKnR8ZOVSycvIXlM7TrEXNUA1Vsy WIsvI0h6HtH9OOj9HFHXCSuiIZI87V4OYfz7FyRg1cDQelEG2EwojBZ4t1TepO826Ety rOrBJyqm8zNHFoJAQPm32Tx3mLnJOk+ZJ8fTjGBaEWD31ztJRi3nGAIr5FVuMkaePefI bLpg== ARC-Authentication-Results: i=1; mx.google.com; dkim=neutral (body hash did not verify) header.i=@intel.com header.s=Intel header.b=SpPrLwqn; 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 Return-Path: Received: from ffbox0-bg.mplayerhq.hu (ffbox0-bg.ffmpeg.org. [79.124.17.100]) by mx.google.com with ESMTP id g3-20020a056402424300b0042dcf96f4b1si3737801edb.23.2022.06.01.20.42.15; Wed, 01 Jun 2022 20:42:15 -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; dkim=neutral (body hash did not verify) header.i=@intel.com header.s=Intel header.b=SpPrLwqn; 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 Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id B07FA68B773; Thu, 2 Jun 2022 06:42:00 +0300 (EEST) X-Original-To: ffmpeg-devel@ffmpeg.org Delivered-To: ffmpeg-devel@ffmpeg.org Received: from mga05.intel.com (mga05.intel.com [192.55.52.43]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id 18F1C68B773 for ; Thu, 2 Jun 2022 06:41:53 +0300 (EEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1654141319; x=1685677319; h=from:to:cc:subject:date:message-id:in-reply-to: references; bh=PmtbAigL3Enc3RKPoXOiZTJv+ZqyVC8/cO6DVy+IHXg=; b=SpPrLwqnEs8OcjN0EIj15+4sM4bA61T37fY6/6Fy7/3rJKoLpOuWpUqC Pp7P5O4+KNCuB2M7weVwQTekhZcHcpdQ80hUF+n7gr8eluqP3+aWqI00c /8qcsGsw5TQoZk2xiR5ZOdJgWNh2R3H3mIqyGohs5Bb53hvOYRlQgtgB/ LHgccG3QJagaAZ35pN1OuyVRQKdwFown9Pa6fds/Gebjar2qisWLUJjzC GzsYpWmvsl7fPhhlp2mCZT3kP7Pz4ov0oTOV3nfg2nxqaZLuRaScqOm7X vxcmpxM5gzaHFpzmmRa60w6zuPGm/Y3JU/kpBak8fbwV6eYfKV/exRh7r A==; X-IronPort-AV: E=McAfee;i="6400,9594,10365"; a="362181635" X-IronPort-AV: E=Sophos;i="5.91,270,1647327600"; d="scan'208";a="362181635" Received: from orsmga006.jf.intel.com ([10.7.209.51]) by fmsmga105.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 01 Jun 2022 20:41:49 -0700 X-IronPort-AV: E=Sophos;i="5.91,270,1647327600"; d="scan'208";a="552629524" Received: from xhh-dg164.sh.intel.com ([10.239.159.54]) by orsmga006-auth.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 01 Jun 2022 20:41:48 -0700 From: "Xiang, Haihao" To: ffmpeg-devel@ffmpeg.org Date: Thu, 2 Jun 2022 11:41:09 +0800 Message-Id: <20220602034118.22447-2-haihao.xiang@intel.com> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20220602034118.22447-1-haihao.xiang@intel.com> References: <20220602034118.22447-1-haihao.xiang@intel.com> Subject: [FFmpeg-devel] [PATCH v9 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: pd91196a1PpA From: Haihao Xiang Intel's oneVPL is a successor to MediaSDK, but removed some obsolete features of MediaSDK[1], some early versions of oneVPL still use 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 ensure user builds FFmpeg against a right version of libmfx, this patch added a check for version < 2.0 and warning message about the used obsolete features. [1] https://spec.oneapi.io/versions/latest/elements/oneVPL/source/VPL_intel_media_sdk.html [2] https://github.com/oneapi-src/oneVPL --- configure | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/configure b/configure index 5a167613a4..51a0bb1481 100755 --- a/configure +++ b/configure @@ -6565,10 +6565,12 @@ 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 >= 1.28" "mfx/mfxvideo.h" MFXInit || - { require libmfx "mfx/mfxvideo.h mfx/mfxdefs.h" MFXInit "-llibmfx $advapi32_extralibs" && - { test_cpp_condition mfx/mfxdefs.h "MFX_VERSION >= 1028" || die "ERROR: libmfx version must be >= 1.28"; } && - warn "using libmfx without pkg-config"; } } +enabled libmfx && { { check_pkg_config libmfx "libmfx >= 1.28 libmfx < 2.0" "mfx/mfxvideo.h" MFXInit || + { require libmfx "mfx/mfxvideo.h mfx/mfxdefs.h" MFXInit "-llibmfx $advapi32_extralibs" && + { test_cpp_condition mfx/mfxdefs.h "MFX_VERSION >= 1028 && MFX_VERSION < 2000" || die "ERROR: libmfx version must be >= 1.28 and < 2.0"; } && + 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"