-
Notifications
You must be signed in to change notification settings - Fork 3
build: Upgrade clp submodule to y-scope/clp@19cd534. #26
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from all commits
43f2f28
8d87f5d
d43ba81
5040225
842e25e
37fb615
1cc4e7e
e931722
d01a65a
4a17d79
7a28a3c
f11380a
ceb5c95
4b38444
b8e2d51
34adc3a
fd2f391
889309c
43688dc
eb19bd2
6acd5ff
fb2f155
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,25 @@ | ||
| # Copyright (c) Facebook, Inc. and its affiliates. | ||
| # | ||
| # Licensed under the Apache License, Version 2.0 (the "License"); | ||
| # you may not use this file except in compliance with the License. | ||
| # You may obtain a copy of the License at | ||
| # | ||
| # http://www.apache.org/licenses/LICENSE-2.0 | ||
| # | ||
| # Unless required by applicable law or agreed to in writing, software | ||
| # distributed under the License is distributed on an "AS IS" BASIS, | ||
| # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
| # See the License for the specific language governing permissions and | ||
| # limitations under the License. | ||
| include_guard(GLOBAL) | ||
|
|
||
| FetchContent_Declare( | ||
| log_surgeon | ||
| GIT_REPOSITORY https://github.com/y-scope/log-surgeon.git | ||
| GIT_TAG 85d4f2c09c0e55f1fb87cdc8b0f4d13fb1a733e1 | ||
| OVERRIDE_FIND_PACKAGE) | ||
|
|
||
|
coderabbitai[bot] marked this conversation as resolved.
Comment on lines
+16
to
+21
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 🧹 Nitpick (assertive) Add progress output; avoid shallow; include FetchContent locally. Safer logging without the shallow-fetch breakage you hit. Also, make this file self-sufficient. Apply: FetchContent_Declare(
log_surgeon
GIT_REPOSITORY https://github.com/y-scope/log-surgeon.git
GIT_TAG 85d4f2c09c0e55f1fb87cdc8b0f4d13fb1a733e1
- OVERRIDE_FIND_PACKAGE)
+ OVERRIDE_FIND_PACKAGE
+ GIT_PROGRESS TRUE)Add near the top (outside this hunk): include(FetchContent)🤖 Prompt for AI Agents |
||
| FetchContent_MakeAvailable(log_surgeon) | ||
|
|
||
|
Comment on lines
+16
to
+23
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 🧹 Nitpick (assertive) Confirm log_surgeon’s public link interface only exposes what consumers need. If log_surgeon PUBLICly links GSL, exporting GSL is reasonable; otherwise make the GSL link PRIVATE in log_surgeon and drop the export plumbing here. I can open a follow-up to upstream a change to log_surgeon so its install/export set is self-consistent (avoiding top-level install hacks). Want me to draft it? 🤖 Prompt for AI Agents |
||
| # To work around y-scope/log-surgeon#155 | ||
| install(TARGETS GSL EXPORT log_surgeon-targets) | ||
| Original file line number | Diff line number | Diff line change | ||||||||||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| @@ -0,0 +1,34 @@ | ||||||||||||||||||||||||||||||||
| # Copyright (c) Facebook, Inc. and its affiliates. | ||||||||||||||||||||||||||||||||
| # | ||||||||||||||||||||||||||||||||
| # Licensed under the Apache License, Version 2.0 (the "License"); | ||||||||||||||||||||||||||||||||
| # you may not use this file except in compliance with the License. | ||||||||||||||||||||||||||||||||
| # You may obtain a copy of the License at | ||||||||||||||||||||||||||||||||
| # | ||||||||||||||||||||||||||||||||
| # http://www.apache.org/licenses/LICENSE-2.0 | ||||||||||||||||||||||||||||||||
| # | ||||||||||||||||||||||||||||||||
| # Unless required by applicable law or agreed to in writing, software | ||||||||||||||||||||||||||||||||
| # distributed under the License is distributed on an "AS IS" BASIS, | ||||||||||||||||||||||||||||||||
| # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||||||||||||||||||||||||||||||||
| # See the License for the specific language governing permissions and | ||||||||||||||||||||||||||||||||
| # limitations under the License. | ||||||||||||||||||||||||||||||||
| include_guard(GLOBAL) | ||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||
| # Version you want to build | ||||||||||||||||||||||||||||||||
| set(VELOX_GSL_BUILD_VERSION 4.0.0) | ||||||||||||||||||||||||||||||||
| set(VELOX_GSL_BUILD_SHA256_CHECKSUM | ||||||||||||||||||||||||||||||||
| f0e32cb10654fea91ad56bde89170d78cfbf4363ee0b01d8f097de2ba49f6ce9) | ||||||||||||||||||||||||||||||||
| set(VELOX_GSL_SOURCE_URL | ||||||||||||||||||||||||||||||||
| "https://github.com/microsoft/GSL/archive/refs/tags/v${VELOX_GSL_BUILD_VERSION}.tar.gz" | ||||||||||||||||||||||||||||||||
| ) | ||||||||||||||||||||||||||||||||
|
Comment on lines
+16
to
+22
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 🧹 Nitpick (assertive) Expose GSL version/checksum as cache variables for override. This makes it easy to test upgrades and ensures reproducibility. -# Version you want to build
-set(VELOX_GSL_BUILD_VERSION 4.0.0)
-set(VELOX_GSL_BUILD_SHA256_CHECKSUM
- f0e32cb10654fea91ad56bde89170d78cfbf4363ee0b01d8f097de2ba49f6ce9)
+# Version you want to build (override via -D on the CMake command line)
+set(VELOX_GSL_BUILD_VERSION 4.0.0 CACHE STRING "Microsoft.GSL version to build")
+set(VELOX_GSL_BUILD_SHA256_CHECKSUM
+ f0e32cb10654fea91ad56bde89170d78cfbf4363ee0b01d8f097de2ba49f6ce9
+ CACHE STRING "SHA256 checksum of the Microsoft.GSL source tarball")📝 Committable suggestion
Suggested change
🤖 Prompt for AI Agents |
||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||
| velox_resolve_dependency_url(GSL) | ||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||
| message(STATUS "Building Microsoft.GSL from source") | ||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||
| FetchContent_Declare( | ||||||||||||||||||||||||||||||||
| Microsoft.GSL | ||||||||||||||||||||||||||||||||
| URL ${VELOX_GSL_SOURCE_URL} | ||||||||||||||||||||||||||||||||
| URL_HASH ${VELOX_GSL_BUILD_SHA256_CHECKSUM} | ||||||||||||||||||||||||||||||||
| OVERRIDE_FIND_PACKAGE EXCLUDE_FROM_ALL SYSTEM) | ||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||
| FetchContent_MakeAvailable(Microsoft.GSL) | ||||||||||||||||||||||||||||||||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -509,20 +509,13 @@ if(${VELOX_BUILD_MINIMAL_WITH_DWIO} OR ${VELOX_ENABLE_HIVE_CONNECTOR}) | |
| find_package(lzo2 REQUIRED) | ||
| find_package(zstd REQUIRED) | ||
| find_package(Snappy REQUIRED) | ||
| if(NOT TARGET zstd::zstd) | ||
| if(TARGET zstd::libzstd_static) | ||
| set(ZSTD_TYPE static) | ||
| else() | ||
| set(ZSTD_TYPE shared) | ||
| endif() | ||
| add_library(zstd::zstd ALIAS zstd::libzstd_${ZSTD_TYPE}) | ||
| endif() | ||
| endif() | ||
|
|
||
| velox_set_source(re2) | ||
| velox_resolve_dependency(re2) | ||
|
|
||
| if(${VELOX_ENABLE_CLP_CONNECTOR}) | ||
| # Independent dependencies | ||
| velox_set_source(absl) | ||
| velox_resolve_dependency(absl) | ||
|
|
||
|
|
@@ -532,6 +525,9 @@ if(${VELOX_ENABLE_CLP_CONNECTOR}) | |
| velox_set_source(date) | ||
| velox_resolve_dependency(date) | ||
|
|
||
| velox_set_source(microsoft_gsl) | ||
| velox_resolve_dependency(microsoft_gsl) | ||
|
|
||
|
Comment on lines
+528
to
+530
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 💡 Verification agent 🧩 Analysis chainOrder is correct (GSL before log_surgeon); verify target naming consistency. Ensure microsoft_gsl defines the target name(s) that log_surgeon expects (GSL vs Microsoft.GSL::GSL) to avoid alias churn and export collisions. Run: If the resolver exposes only Microsoft.GSL::GSL, add a local ALIAS named GSL where needed to match log_surgeon until upstream fixes land. Also applies to: 543-546 🏁 Script executed: #!/bin/bash
# Inspect GSL target names and log_surgeon linkage/exports
rg -n -C2 -g 'CMake/**' -P $'(^|\\b)(add_library|add_library\\s*\\().*GSL|Microsoft\\.GSL::GSL|^\\s*install\\(\\s*TARGETS\\s+GSL\\b|target_link_libraries\\(\\s*log_surgeon\\b.*\\)' Length of output: 420 🏁 Script executed: #!/bin/bash
# List available dependency resolver modules to find microsoft_gsl
ls CMake/resolve_dependency_modules | grep -i gslLength of output: 71 🏁 Script executed: #!/bin/bash
# Inspect microsoft_gsl resolver for target definitions and aliases
rg -n -C3 'add_library\(' CMake/resolve_dependency_modules/microsoft_gsl.cmake
rg -n -C3 'add_library.*ALIAS' CMake/resolve_dependency_modules/microsoft_gsl.cmakeLength of output: 166 🏁 Script executed: #!/bin/bash
# Show contents of the microsoft_gsl resolver to verify what targets it defines or aliases
sed -n '1,200p' CMake/resolve_dependency_modules/microsoft_gsl.cmake
# Search for find_package and alias patterns in the resolver
rg -n -C3 'find_package' CMake/resolve_dependency_modules/microsoft_gsl.cmake
rg -n -C3 'add_library.*ALIAS' CMake/resolve_dependency_modules/microsoft_gsl.cmake
rg -n -C3 'add_library' CMake/resolve_dependency_modules/microsoft_gsl.cmakeLength of output: 1513 Add missing GSL alias in microsoft_gsl resolver FetchContent_MakeAvailable(Microsoft.GSL)insert add_library(GSL ALIAS Microsoft.GSL::GSL)so that the 🤖 Prompt for AI Agents |
||
| velox_set_source(msgpack-cxx) | ||
| velox_resolve_dependency(msgpack-cxx) | ||
|
|
||
|
|
@@ -544,6 +540,10 @@ if(${VELOX_ENABLE_CLP_CONNECTOR}) | |
| velox_set_source(spdlog) | ||
| velox_resolve_dependency(spdlog) | ||
|
|
||
| # Dependencies that depend on other dependencies | ||
| velox_set_source(log_surgeon) | ||
| velox_resolve_dependency(log_surgeon) | ||
|
|
||
| set(ystdlib_cpp_SOURCE BUNDLED) | ||
| velox_resolve_dependency(ystdlib_cpp) | ||
|
|
||
|
|
||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -18,7 +18,6 @@ | |
|
|
||
| using namespace clp_s; | ||
| using namespace clp_s::search; | ||
| using namespace clp_s::search::clp_search; | ||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. can we remove unrelated changes?
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. This is an unsolve symvol and will cause build fail. |
||
|
|
||
| namespace facebook::velox::connector::clp::search_lib { | ||
|
|
||
|
|
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
💡 Verification agent
🧩 Analysis chain
Make CLP repo/tag overridable and enable shallow clone for faster CI
Avoid hardcoding and allow consumers/CI to override; also add
GIT_SHALLOWand progress for speed/observability.Run to confirm the pinned commit exists upstream:
🏁 Script executed:
Length of output: 132
Update CLP_GIT_TAG to a valid existing commit or tag
The SHA “19cd534e629d746395efc64343a60f768b0c9a2d” wasn’t found in the upstream repo—please verify and correct
CLP_GIT_TAGto a valid commit or tag before making it overridable and enablingGIT_SHALLOW/GIT_PROGRESS.🤖 Prompt for AI Agents