Commit Graph

405 Commits

Author SHA1 Message Date
Googler 5a8cab742c Add support for expand_if_available for env_entry
PiperOrigin-RevId: 548694860
Change-Id: I90f46902058fe1ac3a75bb25bddbbf6e181fbabd
2023-07-17 08:12:34 -07:00
Googler 1dbb691712 Get rid of unused objcpp_executable type
PiperOrigin-RevId: 539637641
Change-Id: I80f65a738e77b58054121bfe19a47659fb50fc42
2023-06-12 06:53:11 -07:00
Googler 7f0992b0bd Remove `cc_host_toolchain_alias` target.
Right now there should be no difference between `cc_host_toolchain_alias` and `cc_toolchain_alias` rules.
This is a potentially breaking change for Bazel, if something was depending on `current_cc_host_toolchain` try depending on `current_cc_toolchain` instead.

PiperOrigin-RevId: 528762965
Change-Id: Id2d211c61fa06a578a838c054682c3507aa48261
2023-05-02 06:19:53 -07:00
Googler 2e4313aeba Automated rollback of commit 06e9dcf4b7.
*** Reason for rollback ***

Breaking tap/blaze. Example failure: []

*** Original change description ***

Sort action lists to make diffing easier.

***

PiperOrigin-RevId: 523671424
Change-Id: I475ff02bf8efd3c56e489e2de3ba2c3a5639c32e
2023-04-12 05:19:20 -07:00
Googler 06e9dcf4b7 Sort action lists to make diffing easier.
PiperOrigin-RevId: 523639362
Change-Id: I8a43799f58ad1ed5b19ec074fa9cb9a567591f36
2023-04-12 02:07:04 -07:00
Copybara-Service be9ff3eb41 Merge pull request #183 from renovate-bot:renovate/rules_proto-digest
PiperOrigin-RevId: 513165629
Change-Id: Ib58015b1e049cc54a347b86ca781807196a162cf
2023-03-01 01:22:30 -08:00
Renovate Bot 0baf82487f
Update rules_proto digest to e51f588 2023-02-28 15:13:12 +00:00
Copybara-Service 998319083b Merge pull request #182 from renovate-bot:renovate/rules_proto-digest
PiperOrigin-RevId: 511535003
Change-Id: I4d5847e1339bf8fd882dfcb69140b44efb05072e
2023-02-22 10:36:14 -08:00
Renovate Bot adfbe56c12
Update rules_proto digest to 33aba33 2023-02-21 19:32:32 +00:00
Copybara-Service 42f3259960 Merge pull request #180 from silvergasp:patch-2
PiperOrigin-RevId: 510383031
Change-Id: Id0796b560d646fab81dbda1ee98e6adaf68bfa8e
2023-02-17 02:54:21 -08:00
Yannic 507f49698a Update cc_toolchain_config_lib.bzl for bazelbuild/bazel#10967 2023-02-16 10:19:56 -08:00
Googler ad1830946d Remove redundant "# copybara-use-repo-external-label"
Remove redundant tags for copybara to replace labels with labels including the
repository, where there are no labels to substitute after 2f8c04c044.

PiperOrigin-RevId: 510103824
Change-Id: I9b65a6b7f9b48885aec4df5f4723273633be4860
2023-02-16 04:17:58 -08:00
Googler d8dfa8b829 Introduce flag --@rules_cc//:link_extra_libs
Numerous tools override --custom_malloc to add debugging or monitoring runtimes
(see e.g. sanitizers). While this is fine for cases where the tool must also
override malloc to function, in other cases it's simply misuse of
--custom_malloc where no other mechanism exists to link an extra library.

This becomes especially problematic where a runtime library is supposed to be
added in certain configurations that should run in production or other
performance sensitive builds. In these cases, we should _not_ override malloc,
which may also be specified by a cc_binary target. Doing so would introduce
unwanted changes, potentially affecting performance negatively.

This is the @rules_cc counterpart to the equivalent Bazel tools flag
--@bazel_tools//tools/cpp:link_extra_libs. Users that use @rules_cc to build
their C++ projects may use both flags interchangably, however, the @rules_cc
flag should be preferred.

PiperOrigin-RevId: 510103352
Change-Id: Iafccd00ffdb65cb4f953d5acadc451cffc134533
2023-02-16 04:15:10 -08:00
Googler a43f67b72c Automatic code cleanup.
PiperOrigin-RevId: 509526713
Change-Id: I852b1620897d8c6787ca25b6790f245b5bc274f0
2023-02-14 07:49:46 -08:00
Copybara-Service bfeff307f6 Merge pull request #177 from renovate-bot:renovate/bazel_skylib-1.x
PiperOrigin-RevId: 509457484
Change-Id: I1c72c7e256e831fbcae66900ea4be4ea3dcbd1d1
2023-02-14 01:30:01 -08:00
Copybara-Service 74495aa92a Merge pull request #173 from renovate-bot:renovate/io_abseil_py-1.x
PiperOrigin-RevId: 509457306
Change-Id: I89f3f455e5294765b78c61daaaca4d1c6e69b6fc
2023-02-14 01:29:03 -08:00
Copybara-Service 9e14dd8c39 Merge pull request #176 from renovate-bot:renovate/io_bazel_rules_go-0.x
PiperOrigin-RevId: 509176425
Change-Id: Idc28b71ab3580fe7167737d13dbfd760f360db44
2023-02-13 03:09:00 -08:00
Renovate Bot daaae45616
Update dependency bazel_skylib to v1.4.1 2023-02-09 16:37:03 +00:00
Googler 0d68932a68 Automatic code cleanup.
PiperOrigin-RevId: 506908397
Change-Id: I4571c9e947b5878519d5ec291d2fc58566159c84
2023-02-03 08:23:18 -08:00
Copybara-Service fcd9a03875 Merge pull request #175 from renovate-bot:renovate/bazel_skylib-1.x
PiperOrigin-RevId: 506605277
Change-Id: I3ae667cb3ec4a9391f94261965b765560995fd47
2023-02-02 06:44:32 -08:00
Copybara-Service f1ee8d559e Merge pull request #160 from renovate-bot:renovate/rules_proto-digest
PiperOrigin-RevId: 506604382
Change-Id: Id238acc046b708433a49e1059ce3d20a89e10db9
2023-02-02 06:39:40 -08:00
Renovate Bot ae9ab94e9d
Update dependency io_bazel_rules_go to v0.38.1 2023-02-01 02:18:38 +00:00
Renovate Bot 8a612ecbde
Update dependency bazel_skylib to v1.4.0 2023-02-01 02:18:35 +00:00
Renovate Bot e00c2aa151
Update rules_proto digest to 3f1ab99 2023-02-01 02:18:34 +00:00
Copybara-Service ab49224158 Merge pull request #165 from fmeum:fix-workspace-module
PiperOrigin-RevId: 502815989
Change-Id: I4ab8aeb227f699f8d93d6ff787e4927b26cb21be
2023-01-18 02:29:18 -08:00
Fabian Meumertzheim b0e6fee91f Fix MODULE.bazel formatting
Required due to a new buildifier release.
2023-01-18 10:28:06 +01:00
Copybara-Service c7849af112 Merge pull request #154 from keith:ks/move-apple-toolchain-setup-to-apple_support
PiperOrigin-RevId: 502796914
Change-Id: I2cd0481a244db416ec2abb06e05dee0f783b72b5
2023-01-18 00:42:02 -08:00
Renovate Bot 3627f4fdd3
Update dependency io_abseil_py to v1.4.0 2023-01-11 18:15:37 +00:00
Copybara-Service d7c11265cb Merge pull request #166 from fmeum:patch-1
PiperOrigin-RevId: 501245941
Change-Id: Ic064d20847215c65bf01fda2e1941cb497d949bf
2023-01-11 04:34:10 -08:00
Fabian Meumertzheim 66cf3048e9 Copybara Merge: https://github.com/bazelbuild/rules_cc/pull/165
BEGIN_PUBLIC
Copybara import of the project:

--
56e69b82484f1a9fb55d8173cc112f9f608f3581 by Fabian Meumertzheim <fabian@meumertzhe.im>:

Simplify WORKSPACE setup and update ancient deps

By removing a single unused `bzl_library` target, rules_cc no longer has
any dependencies that would need to be loaded by a dependency macro. The
existing macro is made a no-op.

The few needed Bazel Federation dependencies are inlined and, in the
case of bazel_skylib and abseil-py, updated to modern versions.

Also reorders `WORKSPACE` to list direct dependencies first and keeps
`MODULE.bazel` in sync with the dependency versions used in WORKSPACE.

The `ubuntu1604` CI pipeline is removed as the version of Python used by
it is no longer supported and the distribution is EOL. Instead, a new
pipeline is added to check the Bzlmod build.

END_PUBLIC

COPYBARA_INTEGRATE_REVIEW=https://github.com/bazelbuild/rules_cc/pull/165 from fmeum:fix-workspace-module 56e69b82484f1a9fb55d8173cc112f9f608f3581
PiperOrigin-RevId: 501245864
Change-Id: Ib71ad910705807a00929a76774387a38d2da0f9f
2023-01-11 04:33:23 -08:00
Googler bc665f9271 Automated rollback of commit 48881f1f45.
*** Reason for rollback ***

Broke a test

*** Original change description ***

The auto-configured toolchains provided by Bazel itself have diverged heavily from the version maintained in this repo. There is no need to maintain this duplication until Starlarkification has progressed succiciently for rules_cc to be the source of truth for them.

This is particularly relevant for Bzlmod, which currently uses the toolchains defined in rules_cc. As a result, Bazel C++ builds will use subtly different toolchains depending on whether --enable_bzlmod is used or not. This is fixed...

***

PiperOrigin-RevId: 501228335
Change-Id: I858dc3ea44df7ae70b5603f6dc2e082b4540c42a
2023-01-11 02:48:25 -08:00
Fabian Meumertzheim 48881f1f45 The auto-configured toolchains provided by Bazel itself have diverged heavily from the version maintained in this repo. There is no need to maintain this duplication until Starlarkification has progressed succiciently for rules_cc to be the source of truth for them.
This is particularly relevant for Bzlmod, which currently uses the toolchains defined in rules_cc. As a result, Bazel C++ builds will use subtly different toolchains depending on whether --enable_bzlmod is used or not. This is fixed by loading toolchain detection logic from @bazel_tools in the module extension.

Closes #163

PiperOrigin-RevId: 501199523
Change-Id: I01f263d37495d0c5dd070c8a32945898d1d639c5
2023-01-11 00:12:08 -08:00
Keith Smiley 404bb430e7
Remove entire macOS toolchain
This defaults to C++, and the previous setup will be moved to
apple_support
2023-01-10 08:43:46 -08:00
Keith Smiley 52f5feaf1d
Move Apple toolchain setup to apple_support
Mirrors https://github.com/bazelbuild/bazel/pull/16619
2023-01-10 08:43:45 -08:00
Fabian Meumertzheim cbf01d28ec Delete `cc/version.bzl`
The version has never been updated since the first release and since rules_cc is currently a slim wrapper around Bazel-provided rules, version detection shouldn't be necessary.
2023-01-10 11:02:51 +01:00
Fabian Meumertzheim 06112c7d9e The targets in the old package were either not publicly visible or testonly dependencies and had diverged heavily from @bazel_tools.
Instead, add an alias to the Bazel-provided runfiles library under //cc/runfiles, following https://bazel.build/rules/deploying.

Closes #162

PiperOrigin-RevId: 500929486
Change-Id: I3290c2b836af2313fbf45459c81af24fbde877d0
2023-01-10 02:00:52 -08:00
Googler 15ed46df43 Change copybara file in preparation for unknown commit
PiperOrigin-RevId: 500922407
Change-Id: I109541cd7fa033e2925fdac1e020a72b1ea99736
2023-01-10 01:18:47 -08:00
Googler 7673ce6438 Delete objc_archive action type
PiperOrigin-RevId: 499061707
Change-Id: Ia2a79f33c991a9c517c2fa940ff25c959ca35d65
2023-01-02 12:08:25 -08:00
Copybara-Service 8e2588f2e4 Merge pull request #158 from renovate-bot:renovate/io_bazel_rules_go-0.x
PiperOrigin-RevId: 493609607
Change-Id: I733434458cc6685e2334193ecc08881c5d9a269a
2022-12-07 08:21:33 -08:00
Renovate Bot dd371fd0d0
Update dependency io_bazel_rules_go to v0.37.0 2022-12-06 18:42:20 +00:00
Copybara-Service bb1aaeb77d Merge pull request #156 from renovate-bot:renovate/io_bazel_rules_go-0.x
PiperOrigin-RevId: 491901868
Change-Id: Iff24b64bd995220139c093a315ad69060bc465fe
2022-11-30 06:45:05 -08:00
Renovate Bot a928878133
Update dependency io_bazel_rules_go to v0.36.0 2022-11-23 19:03:57 +00:00
Copybara-Service 99d8c5a387 Merge pull request #155 from renovate-bot:renovate/rules_proto-digest
PiperOrigin-RevId: 490241603
Change-Id: I7b5decf29e05954e5a5423d50d632ccf20d7dd86
2022-11-22 07:52:39 -08:00
Renovate Bot 10aadf7fa2
Update rules_proto digest to b5e5fc8 2022-11-15 20:09:50 +00:00
Copybara-Service 35fb29866e Merge pull request #127 from keith:ks/apply-upstream-libtool_check_unique-fix
PiperOrigin-RevId: 485829598
Change-Id: Ifb0baed68f4a496c50989697f9d1a1cbc851b93e
2022-11-03 03:45:03 -07:00
Keith Smiley 99df95ba02
Apply upstream libtool_check_unique fix
This ports 48dd159808
2022-11-01 10:05:26 -07:00
Copybara-Service dc039dc2d8 Merge pull request #152 from renovate-bot:renovate/rules_proto-digest
PiperOrigin-RevId: 482224948
Change-Id: I372363bf0c513770d83d20fffcdd3bbcc81ad633
2022-10-19 09:28:44 -07:00
Renovate Bot 38aedf1b3e
Update rules_proto digest to 70b4248 2022-10-18 16:19:27 +00:00
Copybara-Service 57cee5e2d7 Merge pull request #151 from renovate-bot:renovate/rules_proto-digest
PiperOrigin-RevId: 481869743
Change-Id: I499904d54c6337abd77a95f8166452ba10ffb40d
2022-10-18 03:02:56 -07:00
Renovate Bot 9ecd4beccd
Update rules_proto digest to ba40143 2022-10-17 16:06:02 +00:00