From 2a4c17984c93a8326583ea81b4c3e352868fd543 Mon Sep 17 00:00:00 2001 From: Dan Rosser Date: Wed, 14 Oct 2026 23:22:56 +1300 Subject: [PATCH 1/2] msys2: clang toolchain for CLANG64/CLANGARM64; fix vscode template Win32 include path --- .../project/msys2/config.msys2.default.mk | 16 ++++++++++++---- .../vscode/.vscode/c_cpp_properties.json | 2 +- 2 files changed, 13 insertions(+), 5 deletions(-) diff --git a/libs/openFrameworksCompiled/project/msys2/config.msys2.default.mk b/libs/openFrameworksCompiled/project/msys2/config.msys2.default.mk index 7b5709fcddc..e02283cb59c 100644 --- a/libs/openFrameworksCompiled/project/msys2/config.msys2.default.mk +++ b/libs/openFrameworksCompiled/project/msys2/config.msys2.default.mk @@ -31,14 +31,22 @@ PLATFORM_CXXFLAGS += -std=gnu++17 PLATFORM_CFLAGS += -DUNICODE -D_UNICODE #PLATFORM_CFLAGS += -IC:/msys64/mingw32/include/gstreamer-1.0 -DOF_VIDEO_PLAYER_GSTREAMER -CC = $(MINGW_PREFIX)/bin/gcc -CXX = $(MINGW_PREFIX)/bin/g++ +# CLANG64 / CLANGARM64 ship clang + LLVM tools and no gcc/binutils +ifneq ($(filter CLANG64 CLANGARM64,$(MSYSTEM)),) + CC = $(MINGW_PREFIX)/bin/clang + CXX = $(MINGW_PREFIX)/bin/clang++ + PLATFORM_AR = $(firstword $(wildcard $(MINGW_PREFIX)/bin/llvm-ar.exe) $(MINGW_PREFIX)/bin/ar) + PLATFORM_RESOURCE_COMPILER = $(firstword $(wildcard $(MINGW_PREFIX)/bin/llvm-windres.exe) $(MINGW_PREFIX)/bin/windres) +else + CC = $(MINGW_PREFIX)/bin/gcc + CXX = $(MINGW_PREFIX)/bin/g++ + PLATFORM_AR = $(MINGW_PREFIX)/bin/ar + PLATFORM_RESOURCE_COMPILER = $(MINGW_PREFIX)/bin/windres +endif FIND ?= /usr/bin/find -PLATFORM_AR = $(MINGW_PREFIX)/bin/ar #PLATFORM_LD = $(MINGW_PREFIX)/bin/ld PLATFORM_LD = /usr/bin/lld -PLATFORM_RESOURCE_COMPILER = $(MINGW_PREFIX)/bin/windres PLATFORM_PKG_CONFIG = $(MINGW_PREFIX)/bin/pkgconf diff --git a/scripts/templates/vscode/.vscode/c_cpp_properties.json b/scripts/templates/vscode/.vscode/c_cpp_properties.json index 7b1fa035ae1..cc254a1d83f 100644 --- a/scripts/templates/vscode/.vscode/c_cpp_properties.json +++ b/scripts/templates/vscode/.vscode/c_cpp_properties.json @@ -111,7 +111,7 @@ "name": "Win32", "includePath": [ "C:/msys64/mingw64/include/c++/**", - "C:/msys64/mingw64/i686-w64-mingw64/include", + "C:/msys64/mingw64/include", "${OF_INCLUDE}", "${OF_LIBS_INCLUDE}", "${workspaceFolder}/src/**", From b3f34f756db22f9f51fd6233eba039361f88b0a8 Mon Sep 17 00:00:00 2001 From: Dan Rosser Date: Fri, 16 Oct 2026 15:02:33 +1300 Subject: [PATCH 2/2] vscode template: MSYS2 UCRT64 paths and shell instead of MINGW64 MINGW64 is no longer supported (#8589); the MSYS2 build task, include paths and compiler now use UCRT64. --- scripts/templates/vscode/.vscode/c_cpp_properties.json | 6 +++--- scripts/templates/vscode/.vscode/tasks.json | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/scripts/templates/vscode/.vscode/c_cpp_properties.json b/scripts/templates/vscode/.vscode/c_cpp_properties.json index cc254a1d83f..3a950a98004 100644 --- a/scripts/templates/vscode/.vscode/c_cpp_properties.json +++ b/scripts/templates/vscode/.vscode/c_cpp_properties.json @@ -110,8 +110,8 @@ { "name": "Win32", "includePath": [ - "C:/msys64/mingw64/include/c++/**", - "C:/msys64/mingw64/include", + "C:/msys64/ucrt64/include/c++/**", + "C:/msys64/ucrt64/include", "${OF_INCLUDE}", "${OF_LIBS_INCLUDE}", "${workspaceFolder}/src/**", @@ -130,7 +130,7 @@ ] }, "intelliSenseMode": "clang-x64", - "compilerPath": "C:/msys64/mingw64/bin/g++.exe", + "compilerPath": "C:/msys64/ucrt64/bin/g++.exe", "configurationProvider": "ms-vscode.makefile-tools", "mergeConfigurations": true, "cStandard": "c17", diff --git a/scripts/templates/vscode/.vscode/tasks.json b/scripts/templates/vscode/.vscode/tasks.json index a2221281e45..525749e95d5 100644 --- a/scripts/templates/vscode/.vscode/tasks.json +++ b/scripts/templates/vscode/.vscode/tasks.json @@ -10,7 +10,7 @@ "executable": "C:\\msys64\\msys2_shell.cmd", "args": [ "-defterm", - "-mingw64", + "-ucrt64", "-no-start", "-here", "-shell bash -c"