build: third_party を submodule から FetchContent に移行 (#97 + #98)#109
Merged
Conversation
masstree / mimalloc / googletest を tracked submodule + 手動 bootstrap.sh から
FetchContent ベースに切り替える。
- cmake/ThirdParty.cmake を新設し、3 つの依存を SHA / tag で pin して取得:
- masstree: thawk105 fork, commit b3c5d05 (現 submodule と同一)
- mimalloc: v2.3.2 (commit 02a2f5d, 性能を変えないため version 据え置き)
- googletest: commit f8d7d77 (現 submodule と同一)
- masstree は CMake project ではないので FetchContent_Populate 後に旧
bootstrap.sh と同じ手順 (bootstrap → configure → make → ar → ranlib) を
add_custom_command で再現し、ccbench::masstree (INTERFACE library) で
expose する。
- mimalloc は FetchContent_MakeAvailable → upstream の mimalloc-static
ターゲットを ccbench::mimalloc に alias。MI_BUILD_SHARED/OBJECT/TESTS は
OFF にして余計なアーティファクトを抑える。
- googletest は FetchContent_MakeAvailable で GTest::gtest{,_main} を
expose し、cc/ss2pl/test/CMakeLists.txt の生パス直参照を置き換える。
- include/masstree_wrapper.hh の "../third_party/masstree/..." 形式の
include を <...> 形式に変更 (ccbench::masstree の include dir 経由で
解決)。
- build_tools/bootstrap.sh / bootstrap_googletest.sh / bootstrap_mimalloc.sh
と .gitmodules を削除。third_party/{masstree,mimalloc,googletest} の
submodule entry も削除。
Closes #97, closes #98.
CI (build.yml) の submodule/bootstrap ステップ撤去と docs 更新は依存先の
#99 で行う。性能 regression 検証 (#98 の主目的) は user の明示指示により
本 PR ではスキップ — v2.3.2 を据え置いているのでビルド/リンクが通って動く
ことの確認のみ行った。
third_party は FetchContent 経由で cmake build 中に取得・ビルドされるため、 独立した bootstrap step と third_party キャッシュは不要。submodule recursive checkout も .gitmodules 削除済みで不要。
This was referenced May 15, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
third_party/{masstree,mimalloc,googletest}を tracked submodule から FetchContent ベース (cmake/ThirdParty.cmake) に移行。旧 submodule と同じ SHA / tag を pin して挙動を変えないbuild_tools/bootstrap{,_googletest,_mimalloc}.shと.gitmodulesを削除。include/masstree_wrapper.hhの"../third_party/masstree/..."形式の include を angle-bracket に整理FetchContent_Populate+ 旧 bootstrap 相当をadd_custom_commandで再現し、ccbench::masstreeを INTERFACE library として exposeFetchContent_MakeAvailableで取得し、ccbench::mimalloc/GTest::gtest{,_main}を提供Closes #97, closes #98
CI (
build.yml) の submodule / bootstrap ステップ撤去と docs 更新は依存先の #99 で実施。性能 regression 検証 (#98 主目的) はユーザー指示でスキップ — v2.3.2 据え置きのためビルド / リンク確認のみ。Test plan
replay_test.exe成功libkohler_masstree_json.a/libmimalloc.a/libgtest{,_main}.aを生成することを確認