From 0e66b3edff000f74f0d3f8670b43082013141ae9 Mon Sep 17 00:00:00 2001 From: Freddie Akeroyd Date: Sun, 9 Jun 2024 15:32:48 +0100 Subject: [PATCH] Improve error message for mingw64 architecture --- src/tools/EpicsHostArch.pl | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/src/tools/EpicsHostArch.pl b/src/tools/EpicsHostArch.pl index abff49007..19a3f417c 100644 --- a/src/tools/EpicsHostArch.pl +++ b/src/tools/EpicsHostArch.pl @@ -52,7 +52,13 @@ sub HostArch { } die "$0: macOS CPU type '$cpu' not recognized\n"; } - + # mingw64 has 32bit and 64bit build shells which give same arch result + if (m/^x86_64-msys/ or m/^i686-msys/) { + die "$0: Architecture '$arch' ambiguous.\n". + "Rerun after typing one of the following:\n". + " export EPICS_HOST_ARCH=windows-x64-mingw # for 64bit build\n". + " export EPICS_HOST_ARCH=win32-x86-mingw # for 32bit build\n"; + } die "$0: Architecture '$arch' not recognized\n"; } }