git: 5c648bf25f56 - main - security/john: attempt to fix the build on armv7

From: Alexey Dokuchaev <danfe_at_FreeBSD.org>
Date: Fri, 30 Sep 2022 18:12:49 UTC
The branch main has been updated by danfe:

URL: https://cgit.FreeBSD.org/ports/commit/?id=5c648bf25f56ca85cf4bbc21cc2ec3fb7ffbdc77

commit 5c648bf25f56ca85cf4bbc21cc2ec3fb7ffbdc77
Author:     Alexey Dokuchaev <danfe@FreeBSD.org>
AuthorDate: 2022-09-30 18:11:46 +0000
Commit:     Alexey Dokuchaev <danfe@FreeBSD.org>
CommitDate: 2022-09-30 18:11:46 +0000

    security/john: attempt to fix the build on armv7
    
    This is from upstream commit c9825e6 which improves
    ARM pseudo-intrinsics portability.
    
    PR:             266729
    Submitted by:   Robert Clausecker
---
 security/john/files/patch-pseudo__intrinsics.h | 17 +++++++++++++++++
 1 file changed, 17 insertions(+)

diff --git a/security/john/files/patch-pseudo__intrinsics.h b/security/john/files/patch-pseudo__intrinsics.h
new file mode 100644
index 000000000000..4be9a9148d12
--- /dev/null
+++ b/security/john/files/patch-pseudo__intrinsics.h
@@ -0,0 +1,17 @@
+--- pseudo_intrinsics.h.orig	2019-04-09 16:13:11 UTC
++++ pseudo_intrinsics.h
+@@ -66,10 +66,10 @@ typedef union {
+ #define VLOADU_EMULATED         1
+ #define vor(x, y)               (vtype)vorrq_u32((x).v32, (y).v32)
+ #define vorn(x, y)              (vtype)vornq_u32((x).v32, (y).v32)
+-#define vroti_epi32(x, i)       (i > 0 ? (vtype)vsliq_n_u32(vshrq_n_u32((x).v32, 32 - (i)), (x).v32, i) : \
+-                                         (vtype)vsriq_n_u32(vshlq_n_u32((x).v32, 32 + (i)), (x).v32, -(i)))
+-#define vroti_epi64(x, i)       (i > 0 ? (vtype)vsliq_n_u64(vshrq_n_u64((x).v64, 64 - (i)), (x).v64, i) : \
+-                                         (vtype)vsriq_n_u64(vshlq_n_u64((x).v64, 64 + (i)), (x).v64, -(i)))
++#define vroti_epi32(x, i)       (i > 0 ? (vtype)vsliq_n_u32(vshrq_n_u32((x).v32, 32 - ((i) & 31)), (x).v32, (i) & 31) : \
++                                 (vtype)vsriq_n_u32(vshlq_n_u32((x).v32, (32 + (i)) & 31), (x).v32, (-(i)) & 31))
++#define vroti_epi64(x, i)       (i > 0 ? (vtype)vsliq_n_u64(vshrq_n_u64((x).v64, 64 - ((i) & 63)), (x).v64, (i) & 63) : \
++                                 (vtype)vsriq_n_u64(vshlq_n_u64((x).v64, (64 + (i)) & 63), (x).v64, (-(i)) & 63))
+ #define vroti16_epi32           vroti_epi32
+ #define vset1_epi32(i)          (vtype)vdupq_n_u32(i)
+ #define vset1_epi64(i)          (vtype)vdupq_n_u64(i)