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

Fix for #1239 #1264

Merged
merged 2 commits into from
Sep 4, 2024
Merged

Fix for #1239 #1264

merged 2 commits into from
Sep 4, 2024

Conversation

dmitry-j-mikhin
Copy link
Contributor

@dmitry-j-mikhin dmitry-j-mikhin commented Aug 19, 2024

Closes #1239

Copy link
Contributor

@meteorcloudy meteorcloudy left a comment

Choose a reason for hiding this comment

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

Thanks! I didn't know rules_cc was a dev_dependency.

@meteorcloudy
Copy link
Contributor

@jsharpe Please take a final look.

MODULE.bazel Outdated
@@ -10,12 +10,12 @@ bazel_dep(name = "bazel_features", version = "1.15.0")
bazel_dep(name = "bazel_skylib", version = "1.3.0")
bazel_dep(name = "platforms", version = "0.0.5")
bazel_dep(name = "rules_python", version = "0.23.1")
bazel_dep(name = "rules_cc", version = "0.0.9")
Copy link
Member

Choose a reason for hiding this comment

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

rules_cc shouldn't be required at all - I'll put in a separate PR to rectify this

Copy link
Member

Choose a reason for hiding this comment

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

Ah rules_cc as a dev_dependency is only present to satisfy the rbe configuration - that package needs some work to fix it up properly..

Copy link
Contributor Author

Choose a reason for hiding this comment

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

@jsharpe without it I have the following error on Windows:

The repository '@@[unknown repo 'rules_cc' requested from @@rules_foreign_cc~~tools~glib_dev]' could not be resolved: No repository visible as '@rules_cc' from repository '@@rules_foreign_cc~~tools~glib_dev'. and referenced by '@@rules_foreign_cc~//toolchains/private:pkgconfig_tool_msvc_build_'

So it was added to fix the error above.

Copy link
Member

Choose a reason for hiding this comment

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

I know but the solution isn't to start depending on rules_cc. I'm addressing this in #1269 instead.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Okay, got it.

Copy link
Member

Choose a reason for hiding this comment

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

I've merged 1269 now so if you remove this files changes from this PR then we can land this fix.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

@jsharpe I removed it.

@dmitry-j-mikhin
Copy link
Contributor Author

dmitry-j-mikhin commented Aug 29, 2024

@jsharpe it looks like CI/CD is broken due to missing APR archive file:
https://github.com/bazelbuild/rules_foreign_cc/blob/24e1bcfdeb0303594e8a96f24da9eea92f00bdc0/examples/third_party/apr/apr_repositories.bzl#L20-L22

This has nothing to do with my PR.

Inspired by foundationrobotics@0bf2b36
But instead of using vulnerable version 1.7.4 with CVE-2023-49582 we use 1.7.5
Check https://downloads.apache.org/apr/CHANGES-APR-1.7
This fix error message like this in case of bzlmod usage:
invalid registered toolchain '@rules_foreign_cc//toolchains:preinstalled_nmake_toolchain': No repository visible as '@rules_foreign_cc' from main repository
@dmitry-j-mikhin
Copy link
Contributor Author

I created a separate PR for the APR issue - #1273 and rebased the current branch onto it to make CI/CD green again.

@jsharpe
Copy link
Member

jsharpe commented Sep 4, 2024

I created a separate PR for the APR issue - #1273 and rebased the current branch onto it to make CI/CD green again.

Thank you!

@jsharpe jsharpe merged commit c939c13 into bazel-contrib:main Sep 4, 2024
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
3 participants