From f565b1c7b23aedcf96469f70880f68a0f02aa903 Mon Sep 17 00:00:00 2001 From: yaoguangzhong Date: Fri, 30 Dec 2022 11:47:23 +0800 Subject: [PATCH] backport neon.mak: Silence deprecation/POSIX warnings From: Chun-wei Fan Signed-off-by: Guangzhong Yao --- ...k-Silence-deprecation-POSIX-warnings.patch | 30 +++++++++++++++++++ neon.spec | 6 +++- 2 files changed, 35 insertions(+), 1 deletion(-) create mode 100644 neon-0.30.2-backport-neon.mak-Silence-deprecation-POSIX-warnings.patch diff --git a/neon-0.30.2-backport-neon.mak-Silence-deprecation-POSIX-warnings.patch b/neon-0.30.2-backport-neon.mak-Silence-deprecation-POSIX-warnings.patch new file mode 100644 index 0000000..f52adfc --- /dev/null +++ b/neon-0.30.2-backport-neon.mak-Silence-deprecation-POSIX-warnings.patch @@ -0,0 +1,30 @@ +From 0d797e36ed4478fb8c780a7c327673de01b68439 Mon Sep 17 00:00:00 2001 +From: Chun-wei Fan +Date: Wed, 23 Mar 2022 11:48:04 +0800 +Subject: [PATCH] neon.mak: Silence deprecation/POSIX warnings + +Define the appropriate macros so that we can see less compiler warnings on +using deprecated or POSIX-ish CRT/system APIs, which actually should not really +matter. +--- + neon.mak | 4 ++++ + 1 file changed, 4 insertions(+) + +diff --git a/neon.mak b/neon.mak +index 1d26d3b..5d6e24e 100644 +--- a/neon.mak ++++ b/neon.mak +@@ -20,6 +20,10 @@ CFLAGS = /MDd /W3 /Gm /EHsc /Zi /Od /D "_DEBUG" + TARGET = .\libneonD.lib + !ENDIF + ++# Silence deprecation warnings on later Visual Studio versions, which ++# actually can be ignored ++CFLAGS = $(CFLAGS) /D _CRT_SECURE_NO_WARNINGS /D _CRT_NONSTDC_NO_WARNINGS /D _WINSOCK_DEPRECATED_NO_WARNINGS ++ + ######## + # Whether to build SSPI + !IF "$(SSPI_BUILD)" != "" +-- +2.27.0 + diff --git a/neon.spec b/neon.spec index 3695ca1..bd326e4 100644 --- a/neon.spec +++ b/neon.spec @@ -1,6 +1,6 @@ Name: neon Version: 0.30.2 -Release: 13 +Release: 14 Summary: An HTTP and WebDAV client library License: LGPLv2+ URL: http://www.webdav.org/neon/ @@ -12,6 +12,7 @@ Patch1: neon-0.30.2-sysuioh.patch Patch2: neon-0.30.2-lockprintf.patch Patch3: neon-0.30.2-test-.c-Switch-to-destroy_and_wait-in-various-places.patch Patch4: neon-0.30.2-backport-mak-Replace-GX-with-EHsc.patch +Patch5: neon-0.30.2-backport-neon.mak-Silence-deprecation-POSIX-warnings.patch BuildRequires: gcc git openssl-devel expat-devel gdb-headless Requires: ca-certificates @@ -85,6 +86,9 @@ sed -ri "/^dependency_libs/{s,-l[^ ']*,,g}" \ %{_mandir}/man3/* %changelog +* Fri Dec 30 2022 Guangzhong Yao - 0.30.2-14 +- DESC: backport neon.mak: Silence deprecation/POSIX warnings + * Thu Dec 29 2022 Guangzhong Yao - 0.30.2-13 - DESC: backport neon.mak Replace GX with EHsc -- Gitee