use static compilation and
added exclusion of -latomic for Clang/MSYS2 as per ppigazzini's suggestion
fixes #3872
closes https://github.com/official-stockfish/Stockfish/pull/3873
No functional change
ifneq ($(KERNEL),Darwin)
ifneq ($(KERNEL),OpenBSD)
ifneq ($(KERNEL),FreeBSD)
+ ifneq ($(findstring MINGW,$(KERNEL)),MINGW)
ifneq ($(RTLIB),compiler-rt)
LDFLAGS += -latomic
endif
endif
endif
endif
+ endif
ifeq ($(arch),$(filter $(arch),armv7 armv8))
ifeq ($(OS),Android)
CXXFLAGS += -m$(bits)
LDFLAGS += -m$(bits)
endif
+
+ ifeq ($(findstring MINGW,$(KERNEL)),MINGW)
+ LDFLAGS += -static
+ endif
+
endif
ifeq ($(KERNEL),Darwin)