Repository navigation
[iceberg-cpp] Add int128 namespace and MSVC 14.42 patches; make static export headers self-contained - #54315
Merged
Billy O'Neal (BillyONeal) merged 4 commits intoOct 6, 2026
Conversation
…c export headers self-contained Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Contributor
There was a problem hiding this comment.
Copilot review overview
🟡 Changes recommended
Static core-only packaging can fail when export headers for disabled optional targets are rewritten unconditionally.
Review effort: Balanced
Findings: 1
Open (2)
What changed in this PR
Updates iceberg-cpp packaging for namespace safety, older MSVC compatibility, and static-library consumers.
Changes:
- Moves 128-bit aliases into
iceberg. - Adds MSVC 14.42 compatibility patches.
- Makes installed static export headers self-contained.
Review used static inspection; builds and consumer examples were not run.
| File | Description |
|---|---|
ports/iceberg-cpp/portfile.cmake |
Applies patches and rewrites static export headers. |
ports/iceberg-cpp/int128-namespace.patch |
Namespaces 128-bit aliases. |
ports/iceberg-cpp/msvc-14.42-compat.patch |
Adds MSVC compatibility changes. |
ports/iceberg-cpp/vcpkg.json |
Increments the port revision. |
versions/i-/iceberg-cpp.json |
Records port version 2. |
versions/baseline.json |
Updates the baseline revision. |
💡 Configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
rohanjain101
deleted the
users/rohanjain/iceberg-cpp-int128-static-headers
branch
October 7, 2026 00:29
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.


Follow-up to #54251.
int128 namespace. Adds
int128-namespace.patch, a backport of apache/iceberg-cpp#972 (open). iceberg-cpp 0.4.0 declaresint128_t/uint128_tin the global namespace in the installediceberg/util/int128.h, which public headers such asiceberg/util/decimal.handiceberg/expression/literal.hinclude. Consumers that declare their ownint128_twith a different type therefore conflict as soon as they include iceberg. The patch moves the aliases intonamespace iceberg. Every use inside iceberg-cpp is already in that namespace.Static export headers. Addresses #54251 (review). The installed
iceberg_*_export.hheaders only select the static (non-dllimport) branch whenICEBERG_STATIC,ICEBERG_BUNDLE_STATIC,ICEBERG_DATA_STATICorICEBERG_REST_STATICis defined. These are only propagated through the CMake targets'INTERFACE_COMPILE_DEFINITIONS. Consumers that don't use the CMake targets (MSBuild integration, hand-written build files) therefore compile__declspec(dllimport)references against the static libraries and fail with LNK2019. On static triplets, the port now rewrites the installed headers so the static branch is always taken. Dynamic triplets are unchanged.MSVC 14.42 compatibility. Adds
msvc-14.42-compat.patch, the library-source part of apache/iceberg-cpp#986. iceberg-cpp 0.4.0 does not compile with MSVC 14.42 (VS 2022 17.12); newer compilers are unaffected. The patch makes no functional change:ParallelCollect(util/executor_util_internal.h) used a lambda in its requires-clause and lambdas expanded over a parameter pack. 14.42 rejects both (C3546/C2326/C3520). They are replaced with a class-template trait and helper function templates.manifest_group.ccused a conditional operator over two move-onlyResult<ManifestEntryStreamPtr>prvalues. 14.42 tries to copy them (C2280). It is replaced with a small if/else helper.snapshot_update.ccused the C++230UZliteral, which 14.42 does not support (C3688). It is replaced withsize_t{0}.Tested locally with
iceberg-cpp[core,bundle,rest]onx64-windowsandx64-windows-static(MSVC 14.51):Both builds succeed. The installed static headers contain
# if 1; the dynamic headers are unchanged.A translation unit compiled with plain
cl /MT(noICEBERG_*_STATICdefines) against the static headers now has 0__imp_references to iceberg symbols (previously 14).static_assert(sizeof(::iceberg::int128_t) == 16)compiles.A CMake consumer of the iceberg, bundle and rest static/shared targets builds and runs in Release and Debug. Static linking also needs [avro-cpp] Link compiled fmt and make config safe to find twice #54314 for the separate fmt duplicate-symbol issue.
Upstream
util_test(376 tests, including the 19ParallelCollect/executor tests) passes on the patched sources.With MSVC 14.42 (VisualCppTools 14.42.34439, VS 2022 17.12), the full library build succeeds and
executor_util_test.cccompiles.Changes comply with the maintainer guide.
SHA512s are updated for each updated download. (No downloads changed.)
The "supports" clause reflects platforms that may be fixed by this new version. (Unchanged.)
Any fixed CI baseline entries are removed from that file. (None.)
Any patches that are no longer applied are deleted from the port's directory. (None.)
The version database is fixed by rerunning
./vcpkg x-add-version --alland committing the result.Only one version is added to each modified port's versions file.
This change was prepared with help from GitHub Copilot.