[vlc-commits] [Git][videolan/vlc][master] 2 commits: contrib: gpg-error: fix --disable-threads usage
Steve Lhomme (@robUx4)
gitlab at videolan.org
Sun Nov 9 16:53:59 UTC 2025
Steve Lhomme pushed to branch master at VideoLAN / VLC
Commits:
de7ff2b6 by Steve Lhomme at 2025-11-09T16:23:09+00:00
contrib: gpg-error: fix --disable-threads usage
The locking API is still called with Win32/POSIX structures even though the locks
are not defined the same way with --disable-threads.
We just turn the locking code off in --disable-threads (locking does nothing).
Fixes a crash on exit on Windows where _gpgrt_fflush (NULL) is always called,
locking estream_list_lock that is not initialized as expected.
- - - - -
f581aa28 by Steve Lhomme at 2025-11-09T16:23:09+00:00
contrib: gpg-error: update to 1.56
- - - - -
15 changed files:
- contrib/src/gpg-error/0004-use-WCHAR-API-for-temporary-windows-folder.patch
- contrib/src/gpg-error/0007-don-t-use-GetThreadLocale-on-UWP.patch
- contrib/src/gpg-error/0008-don-t-use-GetUserNameW-on-Windows-10.patch
- contrib/src/gpg-error/0009-gpg-error-config.in-add-missing-GPG_ERROR_CONFIG_LIB.patch
- − contrib/src/gpg-error/0010-spawn-w32-don-t-compile-non-public-spawn-API.patch
- contrib/src/gpg-error/0011-logging-add-ws2tcpip.h-include-for-proper-inet_pton-.patch
- contrib/src/gpg-error/0012-use-GetCurrentProcessId-in-UWP.patch
- contrib/src/gpg-error/0013-configure-allow-building-Windows-with-disable-thread.patch
- + contrib/src/gpg-error/0014-core-disable-locking-API-with-disable-threads.patch
- + contrib/src/gpg-error/0015-core-disable-process-spawning-with-disable-threads.patch
- contrib/src/gpg-error/SHA512SUMS
- contrib/src/gpg-error/gpg-error-createfile2.patch
- contrib/src/gpg-error/gpg-error-uwp-GetFileSize.patch
- contrib/src/gpg-error/gpg-error-uwp-fix.patch
- contrib/src/gpg-error/rules.mak
Changes:
=====================================
contrib/src/gpg-error/0004-use-WCHAR-API-for-temporary-windows-folder.patch
=====================================
@@ -1,17 +1,17 @@
-From 850fd38ff041406432c8c70b3fb81f6e2ee4b12b Mon Sep 17 00:00:00 2001
+From 1def00f0b864977a7477219c5a8277fcc0e8b9a3 Mon Sep 17 00:00:00 2001
From: Steve Lhomme <robux4 at ycbcr.xyz>
Date: Thu, 23 Oct 2025 12:17:08 +0200
-Subject: [PATCH 04/12] use WCHAR API for temporary windows folder
+Subject: [PATCH 04/14] use WCHAR API for temporary windows folder
---
src/estream.c | 16 ++++++++--------
1 file changed, 8 insertions(+), 8 deletions(-)
diff --git a/src/estream.c b/src/estream.c
-index 66ebc4b..763e811 100644
+index 7e1d55c..6062001 100644
--- a/src/estream.c
+++ b/src/estream.c
-@@ -5074,27 +5074,27 @@ tmpfd (void)
+@@ -5115,27 +5115,27 @@ tmpfd (void)
{
#ifdef HAVE_W32_SYSTEM
int attempts, n;
@@ -45,7 +45,7 @@ index 66ebc4b..763e811 100644
*p++ = '\\';
name = p;
for (attempts=0; attempts < 10; attempts++)
-@@ -5106,8 +5106,8 @@ tmpfd (void)
+@@ -5147,8 +5147,8 @@ tmpfd (void)
*p++ = tohex (((value >> 28) & 0x0f));
value <<= 4;
}
=====================================
contrib/src/gpg-error/0007-don-t-use-GetThreadLocale-on-UWP.patch
=====================================
@@ -1,14 +1,14 @@
-From d4cbfe90ad686d4bed08d38757d2bddfaba4506e Mon Sep 17 00:00:00 2001
+From bed81fbf76b81b6468a8e04cd07155f8358773ab Mon Sep 17 00:00:00 2001
From: Steve Lhomme <robux4 at ycbcr.xyz>
Date: Thu, 23 Oct 2025 12:19:07 +0200
-Subject: [PATCH 07/12] don't use GetThreadLocale on UWP
+Subject: [PATCH 07/14] don't use GetThreadLocale on UWP
---
src/w32-gettext.c | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/src/w32-gettext.c b/src/w32-gettext.c
-index 10a9904..2a64d4e 100644
+index bf085cd..3186458 100644
--- a/src/w32-gettext.c
+++ b/src/w32-gettext.c
@@ -648,8 +648,12 @@ my_nl_locale_name (const char *categoryname)
=====================================
contrib/src/gpg-error/0008-don-t-use-GetUserNameW-on-Windows-10.patch
=====================================
@@ -1,7 +1,7 @@
-From 4d64477f730529cecdf9ee8ec03bf409e039f85e Mon Sep 17 00:00:00 2001
+From e2df6855f455bf3731d407e00da7d6a39827b0ea Mon Sep 17 00:00:00 2001
From: Steve Lhomme <robux4 at ycbcr.xyz>
Date: Thu, 23 Oct 2025 12:19:44 +0200
-Subject: [PATCH 08/12] don't use GetUserNameW on Windows 10+
+Subject: [PATCH 08/14] don't use GetUserNameW on Windows 10+
It's not available in UWP
---
@@ -9,10 +9,10 @@ It's not available in UWP
1 file changed, 17 insertions(+), 1 deletion(-)
diff --git a/src/sysutils.c b/src/sysutils.c
-index 8eee084..a94430b 100644
+index b6d6a55..2830452 100644
--- a/src/sysutils.c
+++ b/src/sysutils.c
-@@ -594,10 +594,11 @@ _gpgrt_getusername (void)
+@@ -685,10 +685,11 @@ _gpgrt_getusername (void)
char *result = NULL;
#ifdef HAVE_W32_SYSTEM
@@ -25,7 +25,7 @@ index 8eee084..a94430b 100644
GetUserNameW (wtmp, &wsize);
wbuf = _gpgrt_malloc (wsize * sizeof *wbuf);
-@@ -614,6 +615,21 @@ _gpgrt_getusername (void)
+@@ -705,6 +706,21 @@ _gpgrt_getusername (void)
}
buf = _gpgrt_wchar_to_utf8 (wbuf, wsize);
xfree (wbuf);
=====================================
contrib/src/gpg-error/0009-gpg-error-config.in-add-missing-GPG_ERROR_CONFIG_LIB.patch
=====================================
@@ -1,7 +1,7 @@
-From 3a566f07a5b89e78eff2459a6b26f7c91d609820 Mon Sep 17 00:00:00 2001
+From 8ceb454e05af8be392dc18309f1800a4945398a5 Mon Sep 17 00:00:00 2001
From: Steve Lhomme <robux4 at ycbcr.xyz>
Date: Thu, 23 Oct 2025 12:20:16 +0200
-Subject: [PATCH 09/12] gpg-error-config.in: add missing
+Subject: [PATCH 09/14] gpg-error-config.in: add missing
GPG_ERROR_CONFIG_LIBS_PRIVATE
Otherwise the confirmity check fails
=====================================
contrib/src/gpg-error/0010-spawn-w32-don-t-compile-non-public-spawn-API.patch deleted
=====================================
@@ -1,144 +0,0 @@
-From ec0bd69513d2c1ea4148a0aef545f89c997fedd6 Mon Sep 17 00:00:00 2001
-From: Steve Lhomme <robux4 at ycbcr.xyz>
-Date: Thu, 23 Oct 2025 12:22:17 +0200
-Subject: [PATCH 10/12] spawn-w32: don't compile non-public spawn API
-
-The calls are already disabled in visibility.c
----
- src/gpgrt-int.h | 2 ++
- src/spawn-posix.c | 6 ++++++
- src/spawn-w32.c | 18 ++++++++++++++++++
- 3 files changed, 26 insertions(+)
-
-diff --git a/src/gpgrt-int.h b/src/gpgrt-int.h
-index adddb26..0e6b268 100644
---- a/src/gpgrt-int.h
-+++ b/src/gpgrt-int.h
-@@ -635,6 +635,7 @@ gpg_err_code_t _gpgrt_make_pipe (int filedes[2], estream_t *r_fp,
- #define _gpgrt_create_outbound_pipe(a,b,c) _gpgrt_make_pipe ((a), (b), 1, (c))
-
-
-+#if 0
- /* Fork and exec the program PGMNAME.
- *
- * If R_INFP is NULL connect stdin of the new process to /dev/null; if
-@@ -723,6 +724,7 @@ gpg_err_code_t _gpgrt_spawn_process_fd (const char *pgmname,
- gpg_err_code_t _gpgrt_spawn_process_detached (const char *pgmname,
- const char *argv[],
- const char *envp[]);
-+#endif
-
- /* If HANG is true, waits for the process identified by PROCESS_ID to
- * exit; if HANG is false, checks whether the process has terminated.
-diff --git a/src/spawn-posix.c b/src/spawn-posix.c
-index 8e36ee1..fe6124d 100644
---- a/src/spawn-posix.c
-+++ b/src/spawn-posix.c
-@@ -254,6 +254,7 @@ get_all_open_fds (void)
- #endif /*0*/
-
-
-+#if 0
- /* The exec core used right after the fork. This will never return. */
- static void
- do_exec (const char *pgmname, const char *argv[],
-@@ -326,6 +327,7 @@ do_exec (const char *pgmname, const char *argv[],
- /* No way to print anything, as we have may have closed all streams. */
- _exit (127);
- }
-+#endif
-
-
- /* Helper for _gpgrt_make_pipe. */
-@@ -428,6 +430,7 @@ convert_from_process (gpgrt_process_t process_id)
- }
-
-
-+#if 0
- /* Fork and exec the PGMNAME, see gpgrt-int.h for details. */
- gpg_err_code_t
- _gpgrt_spawn_process (const char *pgmname, const char *argv[],
-@@ -600,6 +603,7 @@ _gpgrt_spawn_process_fd (const char *pgmname, const char *argv[],
- *r_process_id = convert_from_pid (pid);
- return 0;
- }
-+#endif
-
-
- /* Waiting for child processes.
-@@ -855,6 +859,7 @@ _gpgrt_wait_processes (const char **pgmnames, gpgrt_process_t *process_ids,
- }
-
-
-+#if 0
- /* See gpgrt-int.h for a description. FIXME: We should add a prexec
- * callback. */
- gpg_err_code_t
-@@ -922,6 +927,7 @@ _gpgrt_spawn_process_detached (const char *pgmname, const char *argv[],
-
- return 0;
- }
-+#endif
-
-
- /* Kill a process; that is send an appropriate signal to the process.
-diff --git a/src/spawn-w32.c b/src/spawn-w32.c
-index eca56c0..07f10bf 100644
---- a/src/spawn-w32.c
-+++ b/src/spawn-w32.c
-@@ -65,6 +65,20 @@
- #define fd_to_handle(a) ((HANDLE)(a))
- #define handle_to_fd(a) ((intptr_t)(a))
-
-+#if !WINAPI_FAMILY_PARTITION (WINAPI_PARTITION_DESKTOP) && defined(__MINGW64_VERSION_MAJOR)
-+ typedef struct _STARTUPINFOEXA {
-+ STARTUPINFOA StartupInfo;
-+ LPPROC_THREAD_ATTRIBUTE_LIST lpAttributeList;
-+ } STARTUPINFOEXA,*LPSTARTUPINFOEXA;
-+
-+ typedef struct _STARTUPINFOEXW {
-+ STARTUPINFOW StartupInfo;
-+ LPPROC_THREAD_ATTRIBUTE_LIST lpAttributeList;
-+ } STARTUPINFOEXW,*LPSTARTUPINFOEXW;
-+
-+# define STARTF_USESHOWWINDOW 0x00000001
-+# define STARTF_USESTDHANDLES 0x00000100
-+#endif
-
- /* Return the maximum number of currently allowed open file
- * descriptors. Only useful on POSIX systems but returns a value on
-@@ -407,6 +421,7 @@ convert_from_process (gpgrt_process_t process_id)
- }
-
-
-+#if 0
- /* Fork and exec the PGMNAME, see gpgrt-int.h for details. */
- gpg_err_code_t
- _gpgrt_spawn_process (const char *pgmname, const char *argv[],
-@@ -754,6 +769,7 @@ _gpgrt_spawn_process_fd (const char *pgmname, const char *argv[],
- *r_process_id = convert_from_handle (pi.hProcess);
- return 0;
- }
-+#endif
-
-
- /* See gpgrt-int.h for a description. */
-@@ -848,6 +864,7 @@ _gpgrt_wait_processes (const char **pgmnames, gpgrt_process_t *process_ids,
- }
-
-
-+#if 0
- /* See gpgrt-int.h for a description. */
- gpg_err_code_t
- _gpgrt_spawn_process_detached (const char *pgmname, const char *argv[],
-@@ -928,6 +945,7 @@ _gpgrt_spawn_process_detached (const char *pgmname, const char *argv[],
-
- return 0;
- }
-+#endif
-
-
- /* Kill a process; that is send an appropriate signal to the process.
---
-2.45.1.windows.1
-
=====================================
contrib/src/gpg-error/0011-logging-add-ws2tcpip.h-include-for-proper-inet_pton-.patch
=====================================
@@ -1,7 +1,7 @@
-From db67d9ab41548f9f56a578dbe1c11800dd8b9487 Mon Sep 17 00:00:00 2001
+From 349afde1939f2faaad667024428bd02cb26af86b Mon Sep 17 00:00:00 2001
From: Steve Lhomme <robux4 at ycbcr.xyz>
Date: Thu, 23 Oct 2025 12:23:02 +0200
-Subject: [PATCH 11/12] logging: add ws2tcpip.h include for proper inet_pton
+Subject: [PATCH 11/14] logging: add ws2tcpip.h include for proper inet_pton
definition
---
=====================================
contrib/src/gpg-error/0012-use-GetCurrentProcessId-in-UWP.patch
=====================================
@@ -1,7 +1,7 @@
-From 8709f63dd0384c67929ab2ef9c18733f78533c8b Mon Sep 17 00:00:00 2001
+From 6fbb7b9ec5d4102e1a4c2fcbdc31dd080959963d Mon Sep 17 00:00:00 2001
From: Steve Lhomme <robux4 at ycbcr.xyz>
Date: Thu, 23 Oct 2025 12:24:20 +0200
-Subject: [PATCH 12/12] use GetCurrentProcessId() in UWP
+Subject: [PATCH 12/14] use GetCurrentProcessId() in UWP
getpid() is not declared
---
=====================================
contrib/src/gpg-error/0013-configure-allow-building-Windows-with-disable-thread.patch
=====================================
@@ -1,7 +1,7 @@
-From 596a63bc148d6e644b28987c7210f5d9cbb8feac Mon Sep 17 00:00:00 2001
+From aa9ec7d915bb43cb35e685f384142eb347ccea9b Mon Sep 17 00:00:00 2001
From: Steve Lhomme <robux4 at ycbcr.xyz>
Date: Fri, 24 Oct 2025 08:28:33 +0200
-Subject: [PATCH 13/13] configure: allow building Windows with
+Subject: [PATCH 13/14] configure: allow building Windows with
--disable-threads
---
@@ -9,11 +9,11 @@ Subject: [PATCH 13/13] configure: allow building Windows with
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/configure.ac b/configure.ac
-index a24453e..500714c 100644
+index c327835..4ed37e1 100644
--- a/configure.ac
+++ b/configure.ac
-@@ -141,9 +141,9 @@ case "${host}" in
- esac
+@@ -154,9 +154,9 @@ esac
+ AC_SUBST(EXTRA_LIBS_FOR_BUILD)
-if test "$have_w32_system" != yes; then
@@ -24,7 +24,7 @@ index a24453e..500714c 100644
# We build libgpg-error with large file support so that we have a 64
# bit off_t. Our external interface uses the gpgrt_off_t which is
-@@ -617,7 +617,7 @@ if test "$have_w32_system" = yes; then
+@@ -634,7 +634,7 @@ if test "$have_w32_system" = yes; then
if test "$have_w64_system" = yes; then
AC_DEFINE(HAVE_W64_SYSTEM,1,[Defined if we run on 64 bit W32 API system])
fi
=====================================
contrib/src/gpg-error/0014-core-disable-locking-API-with-disable-threads.patch
=====================================
@@ -0,0 +1,132 @@
+From 749be993cfc7a9994f4e0733182fc6dbb88bd655 Mon Sep 17 00:00:00 2001
+From: Steve Lhomme <robux4 at ycbcr.xyz>
+Date: Thu, 6 Nov 2025 13:31:25 +0100
+Subject: [PATCH 14/14] core: disable locking API with --disable-threads
+
+The _gpgrt_lock_t structure used in the specialized lock API's are not
+matching the structure set by gen-lock-obj.sh with --disable-threads.
+
+In particular LOCK_ABI_VERSION is not set.
+---
+ src/gen-lock-obj.sh | 2 ++
+ src/gpgrt-int.h | 9 +++++++++
+ src/posix-lock.c | 3 +++
+ src/posix-thread.c | 3 +++
+ src/w32-lock.c | 3 +++
+ src/w32-thread.c | 3 +++
+ 6 files changed, 23 insertions(+)
+
+diff --git a/src/gen-lock-obj.sh b/src/gen-lock-obj.sh
+index 6e78c5f..ae867ba 100755
+--- a/src/gen-lock-obj.sh
++++ b/src/gen-lock-obj.sh
+@@ -59,6 +59,8 @@ typedef struct
+ } gpgrt_lock_t;
+
+ #define GPGRT_LOCK_INITIALIZER {-1}
++
++#define GPGRT_LOCK_NOT_SUPPORTED 1
+ EOF
+ else
+ AWK_VERSION_OUTPUT=$($AWK 'BEGIN { print PROCINFO["version"] }')
+diff --git a/src/gpgrt-int.h b/src/gpgrt-int.h
+index 8d2a936..f859a5b 100644
+--- a/src/gpgrt-int.h
++++ b/src/gpgrt-int.h
+@@ -137,12 +137,21 @@ void _gpgrt_post_syscall (void);
+
+ const char *_gpg_error_check_version (const char *req_version);
+
++#ifdef GPGRT_LOCK_NOT_SUPPORTED
++#define _gpgrt_lock_init(l) 0
++#define _gpgrt_lock_lock(l) 0
++#define _gpgrt_lock_trylock(l) 0
++#define _gpgrt_lock_unlock(l) 0
++#define _gpgrt_lock_destroy(l) 0
++#define _gpgrt_yield() 0
++#else
+ gpg_err_code_t _gpgrt_lock_init (gpgrt_lock_t *lockhd);
+ gpg_err_code_t _gpgrt_lock_lock (gpgrt_lock_t *lockhd);
+ gpg_err_code_t _gpgrt_lock_trylock (gpgrt_lock_t *lockhd);
+ gpg_err_code_t _gpgrt_lock_unlock (gpgrt_lock_t *lockhd);
+ gpg_err_code_t _gpgrt_lock_destroy (gpgrt_lock_t *lockhd);
+ gpg_err_code_t _gpgrt_yield (void);
++#endif
+
+
+
+diff --git a/src/posix-lock.c b/src/posix-lock.c
+index 85ec660..79a639a 100644
+--- a/src/posix-lock.c
++++ b/src/posix-lock.c
+@@ -42,6 +42,7 @@
+ #include "lock.h"
+ #include "posix-lock-obj.h"
+
++#ifndef GPGRT_LOCK_NOT_SUPPORTED
+
+ #if USE_POSIX_THREADS
+ # if USE_POSIX_THREADS_FROM_LIBC && HAVE_SYS_SINGLE_THREADED_H
+@@ -298,3 +299,5 @@ _gpgrt_lock_destroy (gpgrt_lock_t *lockhd)
+
+ return rc;
+ }
++
++#endif /* !GPGRT_LOCK_NOT_SUPPORTED */
+diff --git a/src/posix-thread.c b/src/posix-thread.c
+index 36c81ba..f3d3a0f 100644
+--- a/src/posix-thread.c
++++ b/src/posix-thread.c
+@@ -43,6 +43,7 @@
+
+ #include "thread.h"
+
++#ifndef GPGRT_LOCK_NOT_SUPPORTED
+
+
+ gpg_err_code_t
+@@ -66,3 +67,5 @@ _gpgrt_yield (void)
+
+ return 0;
+ }
++
++#endif /* !GPGRT_LOCK_NOT_SUPPORTED */
+diff --git a/src/w32-lock.c b/src/w32-lock.c
+index feed1e6..cd14f5c 100644
+--- a/src/w32-lock.c
++++ b/src/w32-lock.c
+@@ -37,6 +37,7 @@
+ #include "w32-lock-obj.h"
+
+
++#ifndef GPGRT_LOCK_NOT_SUPPORTED
+
+ static _gpgrt_lock_t *
+ get_lock_object (gpgrt_lock_t *lockhd)
+@@ -159,3 +160,5 @@ _gpgrt_lock_destroy (gpgrt_lock_t *lockhd)
+ lock->started = -1;
+ return 0;
+ }
++
++#endif /* !GPGRT_LOCK_NOT_SUPPORTED */
+diff --git a/src/w32-thread.c b/src/w32-thread.c
+index c389635..69599f2 100644
+--- a/src/w32-thread.c
++++ b/src/w32-thread.c
+@@ -35,6 +35,7 @@
+ #include "gpgrt-int.h"
+ #include "thread.h"
+
++#ifndef GPGRT_LOCK_NOT_SUPPORTED
+
+ gpg_err_code_t
+ _gpgrt_yield (void)
+@@ -44,3 +45,5 @@ _gpgrt_yield (void)
+ _gpgrt_post_syscall ();
+ return 0;
+ }
++
++#endif /* !GPGRT_LOCK_NOT_SUPPORTED */
+--
+2.45.1.windows.1
+
=====================================
contrib/src/gpg-error/0015-core-disable-process-spawning-with-disable-threads.patch
=====================================
@@ -0,0 +1,72 @@
+From 10922c66bd0b717114c6b3080e0737b7676afd86 Mon Sep 17 00:00:00 2001
+From: Steve Lhomme <robux4 at ycbcr.xyz>
+Date: Thu, 6 Nov 2025 14:52:04 +0100
+Subject: [PATCH 15/15] core: disable process spawning with --disable-threads
+
+---
+ src/spawn-posix.c | 4 ++++
+ src/spawn-w32.c | 4 ++++
+ src/visibility.c | 2 ++
+ 3 files changed, 10 insertions(+)
+
+diff --git a/src/spawn-posix.c b/src/spawn-posix.c
+index 8cdd032..0791b8a 100644
+--- a/src/spawn-posix.c
++++ b/src/spawn-posix.c
+@@ -58,6 +58,8 @@
+ #define _GPGRT_NEED_AFLOCAL 1
+ #include "gpgrt-int.h"
+
++#ifndef GPGRT_LOCK_NOT_SUPPORTED
++
+ /* Definition for the gpgrt_spawn_actions_t. Note that there is a
+ * different one for Windows. */
+ struct gpgrt_spawn_actions {
+@@ -1066,3 +1068,5 @@ _gpgrt_process_wait_list (gpgrt_process_t *process_list, int count, int hang)
+
+ return ec;
+ }
++
++#endif /* !GPGRT_LOCK_NOT_SUPPORTED */
+diff --git a/src/spawn-w32.c b/src/spawn-w32.c
+index cb15dd0..3a3b648 100644
+--- a/src/spawn-w32.c
++++ b/src/spawn-w32.c
+@@ -49,6 +49,8 @@
+ #define NEED_STRUCT_SPAWN_CB_ARG
+ #include "gpgrt-int.h"
+
++#ifndef GPGRT_LOCK_NOT_SUPPORTED
++
+ /* Define to 1 do enable debugging. */
+ #define DEBUG_W32_SPAWN 0
+
+@@ -1218,3 +1220,5 @@ _gpgrt_process_wait_list (gpgrt_process_t *process_list, int count, int hang)
+
+ return ec;
+ }
++
++#endif /* !GPGRT_LOCK_NOT_SUPPORTED */
+diff --git a/src/visibility.c b/src/visibility.c
+index 54c4e2a..4a97b6d 100644
+--- a/src/visibility.c
++++ b/src/visibility.c
+@@ -1133,6 +1133,7 @@ gpgrt_close_all_fds (int from, int *keep_fds)
+ }
+ #endif /*0*/
+
++#ifndef GPGRT_LOCK_NOT_SUPPORTED
+ gpg_err_code_t
+ gpgrt_spawn_actions_new (gpgrt_spawn_actions_t *r_act)
+ {
+@@ -1257,6 +1258,7 @@ gpgrt_process_release (gpgrt_process_t process)
+ {
+ _gpgrt_process_release (process);
+ }
++#endif GPGRT_LOCK_NOT_SUPPORTED
+
+
+ int
+--
+2.45.1.windows.1
+
=====================================
contrib/src/gpg-error/SHA512SUMS
=====================================
@@ -1 +1 @@
-bb4dd3faa8e2ec945e61fb2006697b48a51da7ee510b6650a6ab09c8734a987bc33c9835bc710ca9a9395c088271939091be418efc6ca5130b426c2fbc4959a3 libgpg-error-1.49.tar.bz2
+ff4160f4133cf1a90eddf5f59d6248214b59db4f021f124302be37bf04fa1f2eb665560914cbe289095e630a31ba141252e7a72a8e6dbbc622cb135a2066259a libgpg-error-1.56.tar.bz2
=====================================
contrib/src/gpg-error/gpg-error-createfile2.patch
=====================================
@@ -1,20 +1,20 @@
-From 52f575635bed478b1c82f8a756fff6ea645cc3e3 Mon Sep 17 00:00:00 2001
+From 2b5fff174b5b9ebaff32e653f3accea0ac782acb Mon Sep 17 00:00:00 2001
From: Steve Lhomme <robux4 at ycbcr.xyz>
Date: Tue, 23 May 2023 14:31:16 +0200
-Subject: [PATCH 05/12] use CreateFile2 in Win8 as CreateFileW is forbidden in
+Subject: [PATCH 05/14] use CreateFile2 in Win8 as CreateFileW is forbidden in
UWP
---
src/estream.c | 24 ++++++++++++++++++++++++
- src/spawn-w32.c | 12 ++++++++++++
+ src/spawn-w32.c | 13 +++++++++++++
src/w32-gettext.c | 10 ++++++++++
- 3 files changed, 46 insertions(+)
+ 3 files changed, 47 insertions(+)
diff --git a/src/estream.c b/src/estream.c
-index 763e811..9fda47e 100644
+index 6062001..f7ab037 100644
--- a/src/estream.c
+++ b/src/estream.c
-@@ -2030,6 +2030,17 @@ func_file_create_w32 (void **cookie, HANDLE *rethd, const char *path,
+@@ -2058,6 +2058,17 @@ func_file_create_w32 (void **cookie, HANDLE *rethd, const char *path,
else
creation_distribution |= OPEN_EXISTING;
@@ -32,7 +32,7 @@ index 763e811..9fda47e 100644
hd = CreateFileW (wpath,
desired_access,
share_mode,
-@@ -2037,6 +2048,7 @@ func_file_create_w32 (void **cookie, HANDLE *rethd, const char *path,
+@@ -2065,6 +2076,7 @@ func_file_create_w32 (void **cookie, HANDLE *rethd, const char *path,
creation_distribution,
flags_and_attrs,
NULL); /* template file */
@@ -40,7 +40,7 @@ index 763e811..9fda47e 100644
if (hd == INVALID_HANDLE_VALUE)
{
_set_errno (map_w32_to_errno (GetLastError ()));
-@@ -5107,6 +5119,17 @@ tmpfd (void)
+@@ -5148,6 +5160,17 @@ tmpfd (void)
value <<= 4;
}
wcscpy (p, L".tmp");
@@ -58,7 +58,7 @@ index 763e811..9fda47e 100644
file = CreateFileW (buffer,
GENERIC_READ | GENERIC_WRITE,
0,
-@@ -5114,6 +5137,7 @@ tmpfd (void)
+@@ -5155,6 +5178,7 @@ tmpfd (void)
CREATE_NEW,
FILE_ATTRIBUTE_TEMPORARY | FILE_FLAG_DELETE_ON_CLOSE,
NULL);
@@ -67,34 +67,35 @@ index 763e811..9fda47e 100644
{
int fd = _open_osfhandle ((intptr_t)file, 0);
diff --git a/src/spawn-w32.c b/src/spawn-w32.c
-index 324b5fe..eca56c0 100644
+index ecc9437..cb15dd0 100644
--- a/src/spawn-w32.c
+++ b/src/spawn-w32.c
-@@ -270,10 +270,22 @@ w32_open_null (int for_write)
- {
- HANDLE hfile;
-
+@@ -224,10 +224,23 @@ w32_open_null (int for_write, int enable_null_device)
+ memset (&sec_attr, 0, sizeof sec_attr );
+ sec_attr.nLength = sizeof sec_attr;
+ sec_attr.bInheritHandle = TRUE;
+#if _WIN32_WINNT >= 0x0602 // _WIN32_WINNT_WIN8
+ {
+ CREATEFILE2_EXTENDED_PARAMETERS createExParams;
+ memset (&createExParams, 0, sizeof(createExParams));
+ createExParams.dwSize = sizeof(CREATEFILE2_EXTENDED_PARAMETERS);
++ createExParams.lpSecurityAttributes = &sec_attr;
+ hfile = CreateFile2 (L"nul",
+ for_write? GENERIC_WRITE : GENERIC_READ,
+ FILE_SHARE_READ | FILE_SHARE_WRITE,
+ OPEN_EXISTING, &createExParams);
+ }
+#else
- hfile = CreateFileW (L"nul",
- for_write? GENERIC_WRITE : GENERIC_READ,
- FILE_SHARE_READ | FILE_SHARE_WRITE,
- NULL, OPEN_EXISTING, 0, NULL);
+ hfile = CreateFileW (L"nul",
+ for_write? GENERIC_WRITE : GENERIC_READ,
+ FILE_SHARE_READ | FILE_SHARE_WRITE,
+ &sec_attr, OPEN_EXISTING, 0, NULL);
+#endif
- if (hfile == INVALID_HANDLE_VALUE)
- _gpgrt_log_debug ("can't open 'nul': ec=%d\n", (int)GetLastError ());
- return hfile;
+ if (hfile == INVALID_HANDLE_VALUE)
+ _gpgrt_log_debug ("can't open 'nul': ec=%d\n", (int)GetLastError ());
+ return hfile;
diff --git a/src/w32-gettext.c b/src/w32-gettext.c
-index 817c1ca..467abba 100644
+index 5b15a77..42aa01c 100644
--- a/src/w32-gettext.c
+++ b/src/w32-gettext.c
@@ -1216,8 +1216,18 @@ load_domain (const char *filename)
=====================================
contrib/src/gpg-error/gpg-error-uwp-GetFileSize.patch
=====================================
@@ -1,14 +1,14 @@
-From ce7b647ee1aa27fc5f4a48c325e07b36398c39ff Mon Sep 17 00:00:00 2001
+From 8e1e760bef6aa94e6e71000ead2bc21716a06d19 Mon Sep 17 00:00:00 2001
From: Steve Lhomme <robux4 at ycbcr.xyz>
Date: Thu, 23 Oct 2025 12:18:54 +0200
-Subject: [PATCH 06/12] don't use GetFileSize on UWP
+Subject: [PATCH 06/14] don't use GetFileSize on UWP
---
src/w32-gettext.c | 8 ++++++++
1 file changed, 8 insertions(+)
diff --git a/src/w32-gettext.c b/src/w32-gettext.c
-index 467abba..10a9904 100644
+index 42aa01c..bf085cd 100644
--- a/src/w32-gettext.c
+++ b/src/w32-gettext.c
@@ -1233,7 +1233,15 @@ load_domain (const char *filename)
=====================================
contrib/src/gpg-error/gpg-error-uwp-fix.patch
=====================================
@@ -1,18 +1,53 @@
-From 9b691eb3b55e4d8ee027e56109081f90cef21dd7 Mon Sep 17 00:00:00 2001
+From 803dc7c5daecc9044483a9b0ad848b52f95e4189 Mon Sep 17 00:00:00 2001
From: Steve Lhomme <robux4 at ycbcr.xyz>
Date: Mon, 15 May 2023 08:20:15 +0200
-Subject: [PATCH 03/12] fix UWP build
+Subject: [PATCH 03/15] fix UWP build
---
- src/mkheader.c | 2 +-
- 2 files changed, 45 insertions(+), 1 deletion(-)
- create mode 100644 src/syscfg/lock-obj-pub.mingw32uwp.h
+ src/init.c | 8 +++++++-
+ src/mkheader.c | 2 +-
+ 2 files changed, 8 insertions(+), 2 deletions(-)
+diff --git a/src/init.c b/src/init.c
+index 7f970d9..4fe6b90 100644
+--- a/src/init.c
++++ b/src/init.c
+@@ -82,8 +82,9 @@ static void
+ windows_specific_init (void)
+ {
+ OSVERSIONINFO osvi;
+- HMODULE hntdll = GetModuleHandle ("ntdll.dll");
++ HMODULE hntdll = GetModuleHandleA ("ntdll.dll");
+
++#if WINAPI_FAMILY_PARTITION (WINAPI_PARTITION_DESKTOP)
+ memset (&osvi,0,sizeof(osvi));
+ osvi.dwOSVersionInfoSize = sizeof(osvi);
+ GetVersionEx (&osvi);
+@@ -91,6 +92,7 @@ windows_specific_init (void)
+ /* The feature of process/thread attribute is available on Vista or
+ later. */
+ windows_features.is_vista_or_later = (osvi.dwMajorVersion >= 6);
++#endif
+
+ if (hntdll && GetProcAddress (hntdll, "wine_get_version"))
+ windows_features.semihosted_by_wine = 1;
+@@ -589,7 +591,11 @@ _gpgrt_windows_feature (int k)
+ switch (k)
+ {
+ case GPGRT_WINDOWS_PROC_ATTRIBUTE:
++#if !WINAPI_FAMILY_PARTITION (WINAPI_PARTITION_DESKTOP)
++ return 0;
++#else
+ return windows_features.is_vista_or_later;
++#endif
+
+ case GPGRT_WINDOWS_UNDER_WINE:
+ return windows_features.semihosted_by_wine;
diff --git a/src/mkheader.c b/src/mkheader.c
-index 000a224..659508f 100644
+index 7c772e6..779e0ab 100644
--- a/src/mkheader.c
+++ b/src/mkheader.c
-@@ -625,7 +625,7 @@ write_special (const char *fname, int lnr, const char *tag)
+@@ -623,7 +623,7 @@ write_special (const char *fname, int lnr, const char *tag)
}
else if (!strcmp (tag, "include:os-add"))
{
=====================================
contrib/src/gpg-error/rules.mak
=====================================
@@ -1,5 +1,5 @@
# GPGERROR
-GPGERROR_VERSION := 1.49
+GPGERROR_VERSION := 1.56
GPGERROR_URL := $(GNUGPG)/libgpg-error/libgpg-error-$(GPGERROR_VERSION).tar.bz2
$(TARBALLS)/libgpg-error-$(GPGERROR_VERSION).tar.bz2:
@@ -28,10 +28,11 @@ libgpg-error: libgpg-error-$(GPGERROR_VERSION).tar.bz2 .sum-gpg-error
$(APPLY) $(SRC)/gpg-error/0007-don-t-use-GetThreadLocale-on-UWP.patch
$(APPLY) $(SRC)/gpg-error/0008-don-t-use-GetUserNameW-on-Windows-10.patch
$(APPLY) $(SRC)/gpg-error/0009-gpg-error-config.in-add-missing-GPG_ERROR_CONFIG_LIB.patch
- $(APPLY) $(SRC)/gpg-error/0010-spawn-w32-don-t-compile-non-public-spawn-API.patch
$(APPLY) $(SRC)/gpg-error/0011-logging-add-ws2tcpip.h-include-for-proper-inet_pton-.patch
$(APPLY) $(SRC)/gpg-error/0012-use-GetCurrentProcessId-in-UWP.patch
$(APPLY) $(SRC)/gpg-error/0013-configure-allow-building-Windows-with-disable-thread.patch
+ $(APPLY) $(SRC)/gpg-error/0014-core-disable-locking-API-with-disable-threads.patch
+ $(APPLY) $(SRC)/gpg-error/0015-core-disable-process-spawning-with-disable-threads.patch
$(MOVE)
View it on GitLab: https://code.videolan.org/videolan/vlc/-/compare/4b12e3fea526212836763ea480ac58d7479b6850...f581aa285168adc7bbc024206cdf87a37a1bfe3e
--
View it on GitLab: https://code.videolan.org/videolan/vlc/-/compare/4b12e3fea526212836763ea480ac58d7479b6850...f581aa285168adc7bbc024206cdf87a37a1bfe3e
You're receiving this email because of your account on code.videolan.org.
VideoLAN code repository instance
More information about the vlc-commits
mailing list