git: f40fd05965fa - main - security/wazuh-agent: fix build on powerpc64* / riscv64
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Tue, 30 Dec 2025 14:55:06 UTC
The branch main has been updated by pkubaj:
URL: https://cgit.FreeBSD.org/ports/commit/?id=f40fd05965fa5737b91d8078cf1f791f725f9f21
commit f40fd05965fa5737b91d8078cf1f791f725f9f21
Author: Piotr Kubaj <pkubaj@FreeBSD.org>
AuthorDate: 2025-12-30 10:51:20 +0000
Commit: Piotr Kubaj <pkubaj@FreeBSD.org>
CommitDate: 2025-12-30 14:54:56 +0000
security/wazuh-agent: fix build on powerpc64* / riscv64
Correct OpenSSL target needs to be set, because uname -m prints
wrong one.
---
security/wazuh-agent/Makefile | 10 ++++++++++
security/wazuh-agent/files/patch-src-Makefile | 11 ++++++++++-
2 files changed, 20 insertions(+), 1 deletion(-)
diff --git a/security/wazuh-agent/Makefile b/security/wazuh-agent/Makefile
index e4e77b9c01e4..c93ec2b45402 100644
--- a/security/wazuh-agent/Makefile
+++ b/security/wazuh-agent/Makefile
@@ -90,6 +90,16 @@ WAZUHMOD770= /etc/shared/default /logs /queue/alerts /queue/fim \
WAZUHPREFIX= /var/ossec
+.include <bsd.port.options.mk>
+
+.if ${ARCH} == powerpc64
+MAKE_ENV+= OSSL_TARGET=BSD-ppc64
+.elif ${ARCH} == powerpc64le
+MAKE_ENV+= OSSL_TARGET=BSD-ppc64le
+.elif ${ARCH} == riscv64
+MAKE_ENV+= OSSL_TARGET=BSD-riscv64
+.endif
+
.include <bsd.port.pre.mk>
.if ${OSVERSION} >= 1300139 && ${OSVERSION} < 1400000
diff --git a/security/wazuh-agent/files/patch-src-Makefile b/security/wazuh-agent/files/patch-src-Makefile
index a45608e5dff6..27d1da76dd10 100644
--- a/security/wazuh-agent/files/patch-src-Makefile
+++ b/security/wazuh-agent/files/patch-src-Makefile
@@ -75,7 +75,16 @@
else ifeq (${uname_S},Darwin)
EXTERNAL_LIBS += $(LIBCURL_LIB)
endif
-@@ -1193,9 +1199,13 @@
+@@ -1032,7 +1038,7 @@ endif
+
+ #### OpenSSL ##########
+
+-OPENSSL_FLAGS = enable-weak-ssl-ciphers no-shared
++OPENSSL_FLAGS = enable-weak-ssl-ciphers no-shared $(OSSL_TARGET)
+
+ ifeq (${uname_M}, i386)
+ ifeq ($(findstring BSD,${uname_S}), BSD)
+@@ -1196,9 +1202,13 @@ else
cd $(EXTERNAL_CURL) && CPPFLAGS="-fPIC -I${ROUTE_PATH}/${EXTERNAL_OPENSSL}include" LDFLAGS="-L${ROUTE_PATH}/${EXTERNAL_OPENSSL}" LIBS="-ldl -lpthread" ./configure --with-openssl="${ROUTE_PATH}/${EXTERNAL_OPENSSL}" --disable-ldap --without-libidn2 --without-libpsl --without-brotli --without-nghttp2 --without-zstd
endif
else