-
Notifications
You must be signed in to change notification settings - Fork 55
ci: add newdeps job testing newer versions of cmake and capnproto #212
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
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,6 @@ | ||
| CI_DESC="CI job using newest Cap'n Proto and cmake versions" | ||
| CI_DIR=build-newdeps | ||
| export CXXFLAGS="-Werror -Wall -Wextra -Wpedantic -Wno-unused-parameter -Wno-error=array-bounds" | ||
| CAPNP_CHECKOUT=master | ||
| NIX_ARGS=(--argstr capnprotoVersion "none" --argstr cmakeVersion "4.1.1") | ||
| BUILD_ARGS=(-k) | ||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -21,10 +21,27 @@ cmake --version | |
| cmake_ver=$(cmake --version | awk '/version/{print $3; exit}') | ||
| ver_ge() { [ "$(printf '%s\n' "$2" "$1" | sort -V | head -n1)" = "$2" ]; } | ||
|
|
||
| # If CAPNP_CHECKOUT was requested, clone and install requested Cap'n Proto branch or tag | ||
| capnp_prefix= | ||
| if [ -n "${CAPNP_CHECKOUT-}" ]; then | ||
| capnp_prefix="$PWD/capnp-install" | ||
| [ -e "capnp" ] || git clone -b "${CAPNP_CHECKOUT}" "https://github.com/capnproto/capnproto" capnp | ||
| mkdir -p capnp/build | ||
| ( | ||
| cd capnp/build | ||
| git --no-pager log -1 || true | ||
| CXXFLAGS="-std=c++20" cmake .. "-DCMAKE_INSTALL_PREFIX=${capnp_prefix}" -DBUILD_TESTING=OFF -DWITH_OPENSSL=OFF -DWITH_ZLIB=OFF | ||
| cmake --build . | ||
| cmake --install . | ||
| ) | ||
| export CMAKE_PREFIX_PATH="${capnp_prefix}:${CMAKE_PREFIX_PATH-}" | ||
| fi | ||
|
|
||
| src_dir=$PWD | ||
| mkdir -p "$CI_DIR" | ||
| cd "$CI_DIR" | ||
| export CMAKE_BUILD_PARALLEL_LEVEL="$(nproc)" | ||
| git --no-pager log -1 || true | ||
|
Contributor
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. is there a ci config that does not have
Collaborator
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. re: #212 (comment)
Sounds like the request here is to remove I'd slightly prefer to keep it just because these CI scripts are useful for testing locally even outside context of a real CI system, and there are reasons it can be useful to copy files around and not have valid git checkouts during testing. But it is true that a drawback of |
||
| cmake "$src_dir" "${CMAKE_ARGS[@]+"${CMAKE_ARGS[@]}"}" | ||
| if ver_ge "$cmake_ver" "3.15"; then | ||
| cmake --build . -t "${BUILD_TARGETS[@]}" -- "${BUILD_ARGS[@]+"${BUILD_ARGS[@]}"}" | ||
|
|
||
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.
The default branch is v2, maybe clarify what master means?
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.
re: #212 (comment)
Good suggestion, have added in followup