From b610722fac7cc54a928e4103567f2679d56b4bc3 Mon Sep 17 00:00:00 2001 From: Kevin Pfeifer Date: Sat, 3 Dec 2022 02:47:27 +0100 Subject: [PATCH] get current toolchain from gcc output --- tools/msys-dist.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tools/msys-dist.sh b/tools/msys-dist.sh index d95a6d3e..31e55fb8 100755 --- a/tools/msys-dist.sh +++ b/tools/msys-dist.sh @@ -6,8 +6,8 @@ if [[ ! -x melonDS.exe ]]; then fi mkdir -p dist - -for lib in $(ldd melonDS.exe | grep mingw | sed "s/.*=> //" | sed "s/(.*)//"); do +tool=$(gcc -v 2>&1 | head -1 | awk '{print $1}') +for lib in $(ldd melonDS.exe | grep $tool | sed "s/.*=> //" | sed "s/(.*)//"); do cp "${lib}" dist done