From ffbf29ecfc0d1d7c42bcb6949ea77cb7a5871a5d Mon Sep 17 00:00:00 2001 From: Andres Guzman-Ballen Date: Wed, 20 Nov 2024 16:28:00 -0600 Subject: [PATCH] refresh patches --- recipe/meta.yaml | 4 ++-- ...003-VC9-compatibility-test-for-BCryptDeriveKeyPBKDF2.patch | 4 ++-- .../0004-VC9-compatibility-define-BCRYPT_SUCCESS.patch | 4 ++-- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/recipe/meta.yaml b/recipe/meta.yaml index 53aafd5..be474a8 100644 --- a/recipe/meta.yaml +++ b/recipe/meta.yaml @@ -9,8 +9,8 @@ source: sha256: fa62384995e8aa4f5a901c184fb5c91e56a29e24c05b6881a7f8fd5bbea694d2 patches: - patches/0001-Add-lib-to-CMAKE_FIND_LIBRARY_PREFIXES-for-lzma.patch - # - patches/0003-VC9-compatibility-test-for-BCryptDeriveKeyPBKDF2.patch - # - patches/0004-VC9-compatibility-define-BCRYPT_SUCCESS.patch + - patches/0003-VC9-compatibility-test-for-BCryptDeriveKeyPBKDF2.patch + - patches/0004-VC9-compatibility-define-BCRYPT_SUCCESS.patch # This should not be applied in general. It exists so I can build it for # debugging Visual Studio where warnings are errors for some reason. # Hiding warnings is poor practice. diff --git a/recipe/patches/0003-VC9-compatibility-test-for-BCryptDeriveKeyPBKDF2.patch b/recipe/patches/0003-VC9-compatibility-test-for-BCryptDeriveKeyPBKDF2.patch index 158c5d9..ea28ce7 100644 --- a/recipe/patches/0003-VC9-compatibility-test-for-BCryptDeriveKeyPBKDF2.patch +++ b/recipe/patches/0003-VC9-compatibility-test-for-BCryptDeriveKeyPBKDF2.patch @@ -17,8 +17,8 @@ diff -urN work.orig/libarchive/archive_cryptor.c work/libarchive/archive_cryptor return 0; } --#elif defined(_WIN32) && !defined(__CYGWIN__) && defined(HAVE_BCRYPT_H) -+#elif defined(_WIN32) && !defined(__CYGWIN__) && defined(HAVE_BCRYPT_H) && defined(HAVE_BCRYPT_DERIVE_KEY_PBKDF2) +-#elif defined(_WIN32) && !defined(__CYGWIN__) && defined(HAVE_BCRYPT_H) && _WIN32_WINNT >= _WIN32_WINNT_VISTA ++#elif defined(_WIN32) && !defined(__CYGWIN__) && defined(HAVE_BCRYPT_H) && _WIN32_WINNT >= _WIN32_WINNT_VISTA && defined(HAVE_BCRYPT_DERIVE_KEY_PBKDF2) #ifdef _MSC_VER #pragma comment(lib, "Bcrypt.lib") #endif diff --git a/recipe/patches/0004-VC9-compatibility-define-BCRYPT_SUCCESS.patch b/recipe/patches/0004-VC9-compatibility-define-BCRYPT_SUCCESS.patch index 89d9964..0054d0d 100644 --- a/recipe/patches/0004-VC9-compatibility-define-BCRYPT_SUCCESS.patch +++ b/recipe/patches/0004-VC9-compatibility-define-BCRYPT_SUCCESS.patch @@ -3,7 +3,7 @@ @@ -64,12 +64,7 @@ } archive_crypto_ctx; - #elif defined(_WIN32) && !defined(__CYGWIN__) && defined(HAVE_BCRYPT_H) + #elif defined(_WIN32) && !defined(__CYGWIN__) && defined(HAVE_BCRYPT_H) && _WIN32_WINNT >= _WIN32_WINNT_VISTA -#include - -/* Common in other bcrypt implementations, but missing from VS2008. */ @@ -19,7 +19,7 @@ @@ -64,7 +64,7 @@ } archive_crypto_ctx; - #elif defined(_WIN32) && !defined(__CYGWIN__) && defined(HAVE_BCRYPT_H) + #elif defined(_WIN32) && !defined(__CYGWIN__) && defined(HAVE_BCRYPT_H) && _WIN32_WINNT >= _WIN32_WINNT_VISTA -#include +#include "bcrypt_with_vs2008.h"