diff options
| author | tanaka takashi <isazaka@gmail.com> | 2026-06-30 19:03:25 +0900 |
|---|---|---|
| committer | tanaka takashi <isazaka@gmail.com> | 2026-06-30 19:03:25 +0900 |
| commit | 05c8e0a31a0d4192c590e833b24393208e1c751f (patch) | |
| tree | f7c2c82c9327abde67bf3acf1d0258573b3bc6c2 /third_party/mcpc/mk/ccdefs-mingw.mk | |
| parent | 4bc721c3bf7589b519c5730d093f704ce56e3f09 (diff) | |
fix: MCPCをvendored fork化しMCP準拠と接続安定性を改善
- Git submoduleを廃止してMCPCを直接管理
- Windowsで254リクエスト付近に発生する切断を修正
- JSON-RPC 2.0エラー応答を標準化
- tool schemaとruntimeの必須・任意引数を一致
- 1000回連続呼び出しの回帰テストを追加
Diffstat (limited to 'third_party/mcpc/mk/ccdefs-mingw.mk')
| -rw-r--r-- | third_party/mcpc/mk/ccdefs-mingw.mk | 89 |
1 files changed, 89 insertions, 0 deletions
diff --git a/third_party/mcpc/mk/ccdefs-mingw.mk b/third_party/mcpc/mk/ccdefs-mingw.mk new file mode 100644 index 0000000..4b36d0b --- /dev/null +++ b/third_party/mcpc/mk/ccdefs-mingw.mk @@ -0,0 +1,89 @@ +ifneq (,$(and $(isnot_done_ccdefs),$(is_mingw))) + is_unix = xxx + CFLAGS += -Dis_mingw + CFLAGS += -Dis_win # winapi? + + wherecl = $(shell where cl) + ifneq (,$(wherecl)) + found_cl = xxx + endif + + # Use cl whenever possible + ifneq (,$(and $(found_cl),$(is_indirsh))) + CC = cl + is_cllike = xxx + is_winlib = xxx + else + # To find any other cc + + # gh win2019 patch, intentionally to use gcc + ifneq (,$(is_win2019)) + CC = gcc + endif + # GH win2022 patch, intentionally to use gcc + ifneq (,$(is_win2022)) + CC = gcc + endif + + cc_ver = $(shell $(CC) --version) + ifneq (,$(findstring Free Software Foundation,$(cc_ver))) + found_gcc = xxx + endif + ifneq (,$(found_gcc)) + is_gcc = xxx + is_gcclike = xxx + is_unixar = xxx + is_winld = xxx + gcc_ver = $(shell $(CC) --version) + is_gcc8 = $(findstring 8.,$(gcc_ver)) + is_gcc12 = $(findstring 12.,$(gcc_ver)) + is_gcc13 = $(findstring 13.,$(gcc_ver)) + is_gcc14 = $(findstring 14.,$(gcc_ver)) + endif + ifneq (,$(found_clang)) + is_clang = xxx + is_gcclike = xxx + is_unixar = xxx + is_winld = xxx + clang_ver = $(shell $(CC) --version) + is_clang18 = $(findstring 18.,$(clang_ver)) + is_clang19 = $(findstring 19.,$(clang_ver)) + endif + endif + + ifeq (1,2) + else ifneq (,$(is_cllike)) + CFLAGS += /Dis_win + CFLAGS += /Dis_wincl + CFLAGS += /nologo + CFLAGS += /std:c17 + CFLAGS += /DMCPC_C23PTCH_KW1 + CFLAGS += /DMCPC_C23PTCH_CKD1 + CFLAGS += /DMCPC_C23PTCH_UCHAR1 + CFLAGS += /DMCPC_C23GIVUP_FIXENUM + LDFLAGS += /nologo + is_cllike = xxx + is_winlib = xxx + is_cl = xxx + isnot_done_ccdefs = + else ifneq (,$(and $(is_gcc8))) + CFLAGS += -std=c11 + CFLAGS += -DMCPC_C23PTCH_KW1 + CFLAGS += -DMCPC_C23PTCH_CKD1 + CFLAGS += -DMCPC_C23PTCH_UCHAR1 + CFLAGS += -DMCPC_C23GIVUP_FIXENUM + isnot_done_ccdefs = + else ifneq (,$(and $(is_gcc12))) + CFLAGS += -std=c17 + CFLAGS += -DMCPC_C23PTCH_KW1 + CFLAGS += -DMCPC_C23PTCH_CKD1 + CFLAGS += -DMCPC_C23PTCH_UCHAR1 + CFLAGS += -DMCPC_C23GIVUP_FIXENUM + isnot_done_ccdefs = + else ifneq (,$(and $(is_gcc14))) + # fc41 + CFLAGS += -std=c23 + CFLAGS += -DMCPC_C23PTCH_UCHAR2 + isnot_done_ccdefs = + endif +endif |
