bazel-contrib / rules_foreign_cc

Build rules for interfacing with "foreign" (non-Bazel) build systems (CMake, configure-make, GNU Make, boost, ninja, Meson)
https://bazel-contrib.github.io/rules_foreign_cc
Apache License 2.0
679 stars 249 forks source link

fix meson tests for macOS CI #1260

Closed jsun-splunk closed 3 months ago

jsun-splunk commented 3 months ago

This is an attempt to fix the macOS CI issues mentioned in https://github.com/bazelbuild/rules_foreign_cc/issues/1244.

Also noting https://github.com/bazelbuild/rules_foreign_cc/pull/1251 disabled the broken tests. Whereas this MR should fix the tests.

The original problem should be a meson issue and not a foreign_cc one. see https://github.com/mesonbuild/meson/pull/12574. Although, I couldn't track down what introduced the problem.

I got the idea that it is a meson problem, given -Wl,--version is not generated as a part of our cxx_linker_executable or cxx_linker_shared.

The quick solution is to update our default meson version to a version that includes the fix.

Had to also update glib, as after the meson fix it was running to this an issue similar to https://gitlab.gnome.org/GNOME/glib/-/issues/2995.

bbatliner-ocient commented 3 months ago

The first URL tried doesn't seem to exist: https://mirror.bazel.build/github.com/mesonbuild/meson/releases/download/1.5.1/meson-1.5.1.tar.gz

I recognize this was copying the pattern from the other Meson versions.

What is the process for getting this file to exist on mirror.bazel.build? The lack of this file's existence produces warnings of the form:

WARNING: Download from https://mirror.bazel.build/github.com/mesonbuild/meson/releases/download/1.5.1/meson-1.5.1.tar.gz failed: class java.io.FileNotFoundException GET returned 404 Not Found