Skip to content
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

Ruby: Start building the language pack using bazel. #15656

Merged
merged 4 commits into from
Feb 26, 2024
Merged

Conversation

criemen
Copy link
Collaborator

@criemen criemen commented Feb 19, 2024

This PR introduces a bazel and rules_rust-based build system for the ruby extractor and language pack.
This replaces the existing, cargo and cross-based build system.

For local development, nothing changes, and the existing cargo-based build still keeps working as-is.

We no longer need to use cross to compile our Linux binaries, as we now can link against our hermetic C++ toolchain, which ships with an old enough glibc, so that we don't run into symbol version issues when deploying the binaries to older systems. However, this means that we no longer can run the centos-test with the github/codeql/cargo-based buildsystem, as the correct binaries will only be produced by the internal bazel setup.

Besides the one change in dependency (explained in detail in Cargo.toml and in #15595), nothing ought to change in how we build the extractor.

@github-actions github-actions bot added the Ruby label Feb 19, 2024
@criemen criemen force-pushed the criemen/ruby-bazel branch 3 times, most recently from eecdfdb to b3ea60f Compare February 20, 2024 17:09
@criemen criemen marked this pull request as ready for review February 20, 2024 17:19
@criemen criemen requested a review from a team as a code owner February 20, 2024 17:19
@criemen criemen requested a review from redsun82 February 20, 2024 17:19
Copy link
Contributor

@aibaars aibaars left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks alright to me, but let's keep the centos 7 test.

.github/workflows/ruby-build.yml Show resolved Hide resolved
aibaars
aibaars previously approved these changes Feb 22, 2024
.github/workflows/ruby-build.yml Show resolved Hide resolved
ruby/extractor/Cargo.Bazel.lock Outdated Show resolved Hide resolved
ruby/extractor/Cargo.toml Outdated Show resolved Hide resolved
ruby/extractor/Cargo.toml Show resolved Hide resolved
aibaars
aibaars previously approved these changes Feb 26, 2024
Copy link
Contributor

@aibaars aibaars left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good to me. Thanks for looking into this!

This PR introduces a bazel and `rules_rust`-based build system
for the ruby extractor and language pack.
This replacese the existing, `cargo` and `cross`-based build system.

For local development, nothing changes, and the existing `cargo`-based
build still keeps working as-is.

We no longer need to use `cross` to compile our Linux binaries,
as we now can link against our hermetic C++ toolchain, which ships
with an old enough glibc, so that we don't run into symbol version issues
when deploying the binaries to older systems.
Besides the one change in dependency (explained in detail in `Cargo.toml`
and in #15595), nothing ought to
change in how we build the extractor.
As we're now checking out the `codeql` repo in a sub-path,
we need to enable long paths on Windows.
Copy link
Contributor

@redsun82 redsun82 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🚀

@criemen criemen merged commit 4bb725c into main Feb 26, 2024
18 checks passed
@criemen criemen deleted the criemen/ruby-bazel branch February 26, 2024 14:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants