1
0
mirror of https://git.FreeBSD.org/ports.git synced 2025-01-26 09:46:09 +00:00

security/john: try to fix the port's build on AArch64

In commit 1e6670382f, the observed failure on PowerPC had been
mended in a way that broke AArch64 build.  Robert's investigation
had shown that <altivec.h> should've been included elsewhere, and
it actually is, but guarded by `#ifdef __linux__' for some reason.

Alexander explained that at the time the AltiVec support was just
for two platforms: macOS (first) and Linux (added later).  If the
guard of `#include <altivec.h>' was needed, then we could probably
replace the `#ifdef __linux__' with `#ifndef __APPLE__' for the
same effect on old macOS versions which do not need the #include.

PR:		266732
Submitted by:	Robert Clausecker
Discussed with:	Solar Designer
This commit is contained in:
Alexey Dokuchaev 2022-10-19 07:48:36 +00:00
parent 9effd49f06
commit 809fe307f0
2 changed files with 2 additions and 10 deletions

View File

@ -51,6 +51,8 @@ post-patch:
@${REINPLACE_CMD} -e 's|/usr|${PREFIX}|' ${WRKSRC}/params.h
@${REINPLACE_CMD} -e '/^host_cpu=/s|$$| ; case $$host_cpu in\
amd64) host_cpu=x86_64 ;; esac|' ${WRKSRC}/configure
@${REINPLACE_CMD} -e 's,^#ifdef __linux,#ifndef __APPLE,' \
${WRKSRC}/DES_bs_b.c
do-install:
.for b in ${BINARIES}

View File

@ -1,10 +0,0 @@
--- src/sboxes-s.c.orig 2021-12-13 00:08:30.419393000 +0100
+++ src/sboxes-s.c 2021-12-13 00:08:41.847880000 +0100
@@ -32,6 +32,7 @@
#define regs 8
#else
/* PowerPC with AltiVec, etc. */
+#include <altivec.h>
#define regs 32
#endif