File tree Expand file tree Collapse file tree 2 files changed +28
-2
lines changed Expand file tree Collapse file tree 2 files changed +28
-2
lines changed Original file line number Diff line number Diff line change @@ -3,7 +3,7 @@ $(package)_version=2.2.7
3
3
$(package)_download_path =https://miniupnp.tuxfamily.org/files/
4
4
$(package)_file_name =$(package ) -$($(package ) _version) .tar.gz
5
5
$(package)_sha256_hash =b0c3a27056840fd0ec9328a5a9bac3dc5e0ec6d2e8733349cf577b0aa1e70ac1
6
- $(package)_patches =dont_leak_info.patch cmake_get_src_addr.patch
6
+ $(package)_patches =dont_leak_info.patch cmake_get_src_addr.patch fix_windows_snprintf.patch
7
7
$(package)_build_subdir =build
8
8
9
9
define $(package)_set_vars
14
14
15
15
define $(package)_preprocess_cmds
16
16
patch -p1 < $($(package ) _patch_dir) /dont_leak_info.patch && \
17
- patch -p1 < $($(package ) _patch_dir) /cmake_get_src_addr.patch
17
+ patch -p1 < $($(package ) _patch_dir) /cmake_get_src_addr.patch && \
18
+ patch -p1 < $($(package ) _patch_dir) /fix_windows_snprintf.patch
18
19
endef
19
20
20
21
define $(package)_config_cmds
Original file line number Diff line number Diff line change
1
+ commit a1e9de80ab99b4c956a6a4e21d3e0de6f7a1014d
2
+ Author: Hennadii Stepanov <
[email protected] >
3
+ Date: Sat Apr 20 15:14:47 2024 +0100
4
+
5
+ Fix macro expression that guards `snprintf` for Windows
6
+
7
+ Otherwise, the `snprintf` is still wrongly emulated for the following
8
+ cases:
9
+ - mingw-w64 6.0.0 or new with ucrt
10
+ - mingw-w64 8.0.0 or new with iso c ext
11
+
12
+ --- a/src/win32_snprintf.h
13
+ +++ b/src/win32_snprintf.h
14
+ @@ -23,9 +23,9 @@
15
+ (defined(_MSC_VER) && _MSC_VER < 1900) /* Visual Studio older than 2015 */ || \
16
+ (defined(__MINGW32__) && !defined(__MINGW64_VERSION_MAJOR) && defined(__NO_ISOCEXT)) /* mingw32 without iso c ext */ || \
17
+ (defined(__MINGW64_VERSION_MAJOR) && /* mingw-w64 not ... */ !( \
18
+ - (defined (__USE_MINGW_ANSI_STDIO) && __USE_MINGW_ANSI_STDIO != 0)) /* ... with ansi stdio */ || \
19
+ + (defined (__USE_MINGW_ANSI_STDIO) && __USE_MINGW_ANSI_STDIO != 0) /* ... with ansi stdio */ || \
20
+ (__MINGW64_VERSION_MAJOR >= 6 && defined(_UCRT)) /* ... at least 6.0.0 with ucrt */ || \
21
+ - (__MINGW64_VERSION_MAJOR >= 8 && !defined(__NO_ISOCEXT)) /* ... at least 8.0.0 with iso c ext */ || \
22
+ + (__MINGW64_VERSION_MAJOR >= 8 && !defined(__NO_ISOCEXT))) /* ... at least 8.0.0 with iso c ext */ || \
23
+ 0) || \
24
+ 0)
25
+
You can’t perform that action at this time.
0 commit comments