From f06181376921390f181fc5ec0e2c102d78e91449 Mon Sep 17 00:00:00 2001 From: Ramon Novoa Date: Wed, 22 Apr 2020 11:20:38 +0200 Subject: [PATCH] Do not set ARCH if it was already set by other build scripts. Ref pandora_enterprise#5731 --- pandora_agents/win32/build.sh | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/pandora_agents/win32/build.sh b/pandora_agents/win32/build.sh index 2759a6b9cb..ae9f4cf6e8 100755 --- a/pandora_agents/win32/build.sh +++ b/pandora_agents/win32/build.sh @@ -3,13 +3,18 @@ # The installer will be placed in ./installer/output/. # InstallJammer must be installed and in the PATH. -ARCH=`uname -m` +# ARCH may be set by other build scripts. +if [ "$ARCH" == "" ]; then + ARCH=`uname -m` +fi + +# Set the target host. if [ "$ARCH" == "x86_64" ]; then HOST="x86_64-w64-mingw32" else HOST="i686-w64-mingw32" fi -#./autogen.sh && ./configure --host=$HOST && make clean && make && cp PandoraAgent.exe bin/ && installjammer --build installer/pandora.mpi +# Compile and update the Pandora FMS Agent binary. ./autogen.sh && ./configure --host=$HOST && make clean && make && cp PandoraAgent.exe bin/