|
1 | | -# c2pool-dgb coin module (V36). Built when -DCOIN_DGB=ON. |
2 | | -# Mirrors src/impl/btc/CMakeLists.txt; emits the c2pool-dgb binary. |
| 1 | +# c2pool-dgb coin module (V36). Mirrors src/impl/btc/CMakeLists.txt. |
3 | 2 | # Per-coin binary scheme: project_v36_per_coin_binary_v37_unified_process. |
4 | 3 | # Impl plan: c2pool-dgb-embedded-impl-plan.md (frstrtr/the docs/v36, 8ef8d2d). |
5 | 4 | # |
|
11 | 10 | # in this module yet: parked behind the Phase 5.8 settle (ltc-doge owns the |
12 | 11 | # shared DOGE-aux surface). Do not add AUX_DOGE plumbing here at M2. |
13 | 12 | # |
14 | | -# TODO(M3): add_library(impl_dgb ...) sources as an OBJECT lib (ci-steward |
15 | | -# PR-CMake-object-library convention; impl_dgb = 1 of 5 per-coin OBJECT libs), |
16 | | -# link bitcoin_family/Scrypt shared base, wire embedded DigiByte Core daemon |
17 | | -# slice under daemon/. Top-level add_subdirectory(src/impl/dgb) registration |
18 | | -# follows the OBJECT-lib convention PR; held ~2-3 heartbeats, not raced here. |
| 13 | +# LIB GATING (mirrors btc/ltc): the dgb_coin (coin-layer) and dgb (pool-layer) |
| 14 | +# OBJECT libs are defined UNCONDITIONALLY — the c2pool-dgb executable links |
| 15 | +# them, and the coin-matrix CI builds that exe WITHOUT -DCOIN_DGB, so the |
| 16 | +# targets MUST exist regardless of the flag (gating them behind COIN_DGB makes |
| 17 | +# the linker fall back to raw -ldgb/-ldgb_coin and fail). Only the test subtree |
| 18 | +# stays behind COIN_DGB; build.yml sets -DCOIN_DGB=ON and builds those targets. |
| 19 | +add_subdirectory(coin) |
| 20 | +# add_subdirectory(daemon) |
| 21 | + |
| 22 | +# dgb -- DGB Scrypt pool-layer OBJECT lib. Mirrors the ltc/btc OBJECT lib: |
| 23 | +# compiles the real NodeImpl translation unit (node.cpp + protocol handlers) |
| 24 | +# so share_tracker.hpp / share_check.hpp are pulled into a compiled TU. Links |
| 25 | +# the shared core / pool / sharechain base plus dgb_coin (embedded P2P+mempool) |
| 26 | +# and c2pool_storage (LevelDB sharechain). |
| 27 | +add_library(dgb OBJECT |
| 28 | + config_coin.hpp config_coin.cpp config_pool.hpp config_pool.cpp |
| 29 | + node.hpp node.cpp |
| 30 | + peer.hpp |
| 31 | + protocol_actual.cpp protocol_legacy.cpp |
| 32 | + messages.hpp |
| 33 | + share_types.hpp share.hpp |
| 34 | +) |
| 35 | +target_link_libraries(dgb core pool sharechain dgb_coin btclibs c2pool_storage ${SECP256K1_LIBRARIES}) |
| 36 | + |
19 | 37 | if(COIN_DGB) |
20 | 38 | message(STATUS "c2pool: DGB Scrypt-only coin module enabled") |
21 | | - add_subdirectory(coin) |
22 | 39 | add_subdirectory(stratum) # dgb_stratum: IWorkSource (#82 miner-facing path) |
23 | | - # add_subdirectory(daemon) |
24 | 40 | add_subdirectory(test) |
25 | | - |
26 | | - # dgb -- DGB Scrypt pool-layer OBJECT lib. Mirrors the ltc OBJECT lib |
27 | | - # (src/impl/ltc/CMakeLists.txt): compiles the real NodeImpl translation unit |
28 | | - # (node.cpp + protocol handlers) so share_tracker.hpp / share_check.hpp are |
29 | | - # pulled into a compiled TU. Links the shared core / pool / sharechain base |
30 | | - # plus dgb_coin (embedded P2P+mempool) and c2pool_storage (LevelDB sharechain). |
31 | | - add_library(dgb OBJECT |
32 | | - config_coin.hpp config_coin.cpp config_pool.hpp config_pool.cpp |
33 | | - node.hpp node.cpp |
34 | | - peer.hpp |
35 | | - protocol_actual.cpp protocol_legacy.cpp |
36 | | - messages.hpp |
37 | | - share_types.hpp share.hpp |
38 | | - ) |
39 | | - target_link_libraries(dgb core pool sharechain dgb_coin btclibs c2pool_storage ${SECP256K1_LIBRARIES}) |
40 | 41 | endif() |
0 commit comments