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 6E2E44250D for ; Sat, 23 Apr 2022 20:57:28 +0000 (UTC) Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id B934A68B40F; Sat, 23 Apr 2022 23:56:54 +0300 (EEST) Received: from msg-4.mailo.com (ip-15.mailobj.net [213.182.54.15]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id C3D6B68B375 for ; Sat, 23 Apr 2022 23:56:43 +0300 (EEST) DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=mailo.com; s=mailo; t=1650747400; bh=hgZlviNGbxJy64Ovqik4Y+rNDcrjoXqjdemKcxkdE6g=; h=X-EA-Auth:From:To:Subject:Date:Message-Id:X-Mailer:In-Reply-To: References:MIME-Version:Content-Transfer-Encoding; b=IWZ4gbjmNbx+WX/t0hQYLLWei91RfEzXXoym+RQndCX0f0XoQIcDYPduDdsqD+K9K hcPdtHI8rJ+wlIC2FaeCeeXcPdsSlAzeTUbVp2JSdkReP2xq6xbRtKIjhUtQcfe01Y 8Dd9GcKmITgzVFaHysnnNx3rASCl07OBNwcvng0I= Received: by b-2.in.mailobj.net [192.168.90.12] with ESMTP via ip-206.mailobj.net [213.182.55.206] Sat, 23 Apr 2022 22:56:40 +0200 (CEST) X-EA-Auth: htmp0dnIRGX7g0wDeXWQLW6AjseLZQxue/BgIKzFCKBbDEMTUU0l1Fu9z8ah9E+1ED034jg3flBWnMUFN2Yn0TmekyswbEPh8eNuBQAv4mc= From: Nil Admirari To: ffmpeg-devel@ffmpeg.org Date: Sat, 23 Apr 2022 23:56:25 +0300 Message-Id: <20220423205626.39039-5-nil-admirari@mailo.com> X-Mailer: git-send-email 2.32.0 In-Reply-To: <20220423205626.39039-1-nil-admirari@mailo.com> References: <20220423205626.39039-1-nil-admirari@mailo.com> MIME-Version: 1.0 Subject: [FFmpeg-devel] [PATCH v11 5/6] fftools: Enable long path support on Windows (fixes #8885) 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-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" Archived-At: List-Archive: List-Post: Newer versions of Windows (Windows 10 1607 and newer) can support path names longer than MAX_PATH (260 characters). To take advantage of that, an application needs to opt in, by including a small manifest as a resource. Application must be prepared to handle filenames greater than MAX_PATH. Additionally, the path length limitation is only lifted for file APIs that pass paths as wchar_t. Therefore, the preceding patches have refactored a few remaining cases where: 1. filename length was restricted to MAX_PATH 2. files were opened using ANSI functions. On older versions of Windows, the newly added manifest has no effect. --- fftools/Makefile | 5 +++++ fftools/fftools.manifest | 10 ++++++++++ fftools/manifest.rc | 3 +++ 3 files changed, 18 insertions(+) create mode 100644 fftools/fftools.manifest create mode 100644 fftools/manifest.rc diff --git a/fftools/Makefile b/fftools/Makefile index 81ad6c4f..105ae5cc 100644 --- a/fftools/Makefile +++ b/fftools/Makefile @@ -15,6 +15,11 @@ OBJS-ffmpeg += \ fftools/ffmpeg_mux.o \ fftools/ffmpeg_opt.o \ +# Windows resource files +OBJS-ffmpeg-$(HAVE_GNU_WINDRES) += fftools/manifest.o +OBJS-ffplay-$(HAVE_GNU_WINDRES) += fftools/manifest.o +OBJS-ffprobe-$(HAVE_GNU_WINDRES) += fftools/manifest.o + define DOFFTOOL OBJS-$(1) += fftools/cmdutils.o fftools/opt_common.o fftools/$(1).o $(OBJS-$(1)-yes) $(1)$(PROGSSUF)_g$(EXESUF): $$(OBJS-$(1)) diff --git a/fftools/fftools.manifest b/fftools/fftools.manifest new file mode 100644 index 00000000..30b7d8fe --- /dev/null +++ b/fftools/fftools.manifest @@ -0,0 +1,10 @@ + + + + + + + true + + + diff --git a/fftools/manifest.rc b/fftools/manifest.rc new file mode 100644 index 00000000..e436fa73 --- /dev/null +++ b/fftools/manifest.rc @@ -0,0 +1,3 @@ +#include + +CREATEPROCESS_MANIFEST_RESOURCE_ID RT_MANIFEST "fftools.manifest" -- 2.32.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-request@ffmpeg.org with subject "unsubscribe".