CmdBridge: Add .exe to binaries on Windows

Task-number: QTCREATORBUG-32101
Change-Id: I9ee7b536f04242a2a2e53056dd5f65d4794fad08
Reviewed-by: Cristian Adam <cristian.adam@qt.io>
This commit is contained in:
Marcus Tillmanns
2024-12-04 15:31:56 +01:00
parent 22a694e7d0
commit 08870178bb
2 changed files with 8 additions and 1 deletions

View File

@@ -920,7 +920,10 @@ expected_str<FilePath> Client::getCmdBridgePath(
const QString type = typeToString.value(osType);
const QString arch = archToString.value(osArch);
const QString cmdBridgeName = QStringLiteral("cmdbridge-%1-%2").arg(type, arch);
QString cmdBridgeName = QStringLiteral("cmdbridge-%1-%2").arg(type, arch);
if (osType == OsType::OsTypeWindows)
cmdBridgeName += QStringLiteral(".exe");
const FilePath result = libExecPath.resolvePath(cmdBridgeName);
if (result.exists())

View File

@@ -8,6 +8,10 @@ function(go_build NAME SOURCES PLATFORMS ARCHITECTURES LDFLAGS)
set(TARGET_NAME ${NAME}-${PLATFORM}-${ARCHITECTURE})
set(OUTPUT ${OUTPUT_FOLDER}/${TARGET_NAME})
if (${PLATFORM} STREQUAL "windows")
string(APPEND OUTPUT ".exe")
endif()
if ((${PLATFORM} STREQUAL "linux" OR (${PLATFORM} STREQUAL "windows" AND ${ARCHITECTURE} STREQUAL "amd64")) AND NOT UPX_BIN STREQUAL "UPX_BIN-NOTFOUND")
add_custom_command(
OUTPUT "${OUTPUT}"