From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from ffbox0-bg.mplayerhq.hu (ffbox0-bg.ffmpeg.org [79.124.17.100]) by master.gitmailbox.com (Postfix) with ESMTP id 7F81B47793 for ; Fri, 22 Dec 2023 09:53:41 +0000 (UTC) Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id E060368D283; Fri, 22 Dec 2023 11:53:39 +0200 (EET) Received: from mail8.parnet.fi (mail8.parnet.fi [77.234.108.134]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id 3F02168A9DB for ; Fri, 22 Dec 2023 11:53:33 +0200 (EET) Received: from mail9.parnet.fi (mail9.parnet.fi [77.234.108.21]) by mail8.parnet.fi with ESMTP id 3BM9rWMr020541-3BM9rWMs020541 for ; Fri, 22 Dec 2023 11:53:32 +0200 Received: from foo.martin.st (host-97-144.parnet.fi [77.234.97.144]) by mail9.parnet.fi (Postfix) with ESMTPS id 8790AA146B for ; Fri, 22 Dec 2023 11:53:32 +0200 (EET) Date: Fri, 22 Dec 2023 11:53:32 +0200 (EET) From: =?ISO-8859-15?Q?Martin_Storsj=F6?= To: FFmpeg development discussions and patches In-Reply-To: Message-ID: <9cb47f7-95b6-1e5c-c654-db1bef792de8@martin.st> References: <20231221212747.278886-1-martin@martin.st> MIME-Version: 1.0 X-FE-Policy-ID: 3:14:2:SYSTEM X-Content-Filtered-By: Mailman/MimeDel 2.1.29 Subject: Re: [FFmpeg-devel] [PATCH 1/2] configure: Remove a redundant check for UWP mode 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 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="iso-8859-1"; Format="flowed" Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" Archived-At: List-Archive: List-Post: On Fri, 22 Dec 2023, Wu, Tong1 wrote: >> From: ffmpeg-devel On Behalf Of >> Martin Storsj=F6 >> Sent: Friday, December 22, 2023 4:41 PM >> To: FFmpeg development discussions and patches > devel@ffmpeg.org> >> Subject: Re: [FFmpeg-devel] [PATCH 1/2] configure: Remove a redundant ch= eck >> for UWP mode >> >> On Fri, 22 Dec 2023, Wu, Tong1 wrote: >> >>> >>>> Subject: [FFmpeg-devel] [PATCH 1/2] configure: Remove a redundant check >> for >>>> UWP mode >>>> >>>> The check for UWP mode was duplicated from right above, in >>>> d54127c41a81cf2078a3504f78e0e4232cfe11b7. >>>> >>>> Also, instead of several lines with "enabled uwp && ...", make one >>>> "if enabled uwp; then" block. >>>> --- >>>> configure | 30 +++++++++++------------------- >>>> 1 file changed, 11 insertions(+), 19 deletions(-) >>>> >>>> diff --git a/configure b/configure >>>> index af0bebc1ac..69b755f274 100755 >>>> --- a/configure >>>> +++ b/configure >>>> @@ -7102,9 +7102,8 @@ fi >>>> >>>> check_func_headers "windows.h" CreateDIBSection >>>> "$gdigrab_indev_extralibs" >>>> >>>> -# d3d11va requires linking directly to dxgi and d3d11 if not building= for >>>> -# the desktop api partition >>>> -test_cpp <>>> +# check if building for desktop or uwp >>>> +test_cpp <>>> #ifdef WINAPI_FAMILY >>>> #include >>>> #if WINAPI_FAMILY_PARTITION(WINAPI_PARTITION_DESKTOP) >>>> @@ -7117,23 +7116,16 @@ test_cpp <>>> d3d11va_extralibs=3D"-ldxgi -ld3d11" >>>> #endif >>>> EOF >>>> >>>> -# vaapi_win32 requires linking directly to dxgi if not building for >>>> -# the desktop api partition >>>> -test_cpp <>>> -#ifdef WINAPI_FAMILY >>>> -#include >>>> -#if WINAPI_FAMILY_PARTITION(WINAPI_PARTITION_DESKTOP) >>>> -#error desktop, not uwp >>>> -#else >>>> -// WINAPI_FAMILY_APP, WINAPI_FAMILY_PHONE_APP =3D> UWP >>>> -#endif >>>> -#else >>>> -#error no family set >>>> -#endif >>>> -EOF >>>> +mediafoundation_extralibs=3D"-lmfuuid -lole32 -lstrmiids" >>>> >>>> -# mediafoundation requires linking directly to mfplat if building for= uwp >> target >>>> -enabled uwp && mediafoundation_extralibs=3D"-lmfplat -lmfuuid -lole32= - >>>> lstrmiids" || mediafoundation_extralibs=3D"-lmfuuid -lole32 -lstrmiids" >>>> +if enabled uwp; then >>>> + # In UWP mode, we can't use LoadLibrary+GetProcAddress to >> conditionally >>>> + # try to load these APIs at runtime, like we do in regular deskto= p mode - >>>> + # therefore, we need to link directly against these APIs. >>>> + d3d11va_extralibs=3D"-ldxgi -ld3d11" >>>> + vaapi_win32_extralibs=3D"-ldxgi" >>>> + mediafoundation_extralibs=3D"-lmfplat $mediafoundation_extralibs" >>>> +fi >>>> >>>> enabled libdrm && >>>> check_pkg_config libdrm_getfb2 libdrm "xf86drmMode.h" >>>> drmModeGetFB2 >>>> -- >>>> 2.34.1 >>> >>> LGTM, thx. >> >> Does that cover patch 2/2, which fixes linking errors in the UWP >> configurations, as well? >> >> // Martin > > From the code it looks good to me but I don't have the UWP test = > environment to try out. Well it fixes linking at least, so that's better than failing to link, so = I'll go ahead and push it to unbreak those builds. // Martin _______________________________________________ ffmpeg-devel mailing list ffmpeg-devel@ffmpeg.org https://ffmpeg.org/mailman/listinfo/ffmpeg-devel To unsubscribe, visit link above, or email ffmpeg-devel-request@ffmpeg.org with subject "unsubscribe".