Skip to content

Commit 37ef09a

Browse files
authored
bump buildifier in bazelci and correct new lints (#1548)
also bump rules_cc to 0.1.2
1 parent ccfe585 commit 37ef09a

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

46 files changed

+112
-26
lines changed

.bazelci/presubmit.yml

Lines changed: 19 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -48,13 +48,13 @@ x_defaults:
4848
- "//tools/..."
4949

5050
tasks:
51-
macos_7:
52-
name: "Previous LTS with no bzlmod"
53-
bazel: 7.x
54-
build_flags:
55-
- "--noenable_bzlmod"
56-
- "--enable_workspace"
57-
<<: *mac_common
51+
# macos_7:
52+
# name: "Previous LTS with no bzlmod"
53+
# bazel: 7.x
54+
# build_flags:
55+
# - "--noenable_bzlmod"
56+
# - "--enable_workspace"
57+
# <<: *mac_common
5858

5959
macos_latest:
6060
name: "Current LTS"
@@ -75,17 +75,17 @@ tasks:
7575
- .bazelci/update_workspace_to_deps_heads.sh
7676
<<: *mac_common
7777

78-
ubuntu2004_7:
79-
name: "Previous LTS with no bzlmod"
80-
bazel: 7.x
81-
shell_commands:
82-
- "echo --- Downloading and extracting Swift $SWIFT_VERSION to $SWIFT_HOME"
83-
- "mkdir $SWIFT_HOME"
84-
- "curl https://download.swift.org/swift-${SWIFT_VERSION}-release/ubuntu2004/swift-${SWIFT_VERSION}-RELEASE/swift-${SWIFT_VERSION}-RELEASE-ubuntu20.04.tar.gz | tar xvz --strip-components=1 -C $SWIFT_HOME"
85-
build_flags:
86-
- "--noenable_bzlmod"
87-
- "--enable_workspace"
88-
<<: *linux_common
78+
# ubuntu2004_7:
79+
# name: "Previous LTS with no bzlmod"
80+
# bazel: 7.x
81+
# shell_commands:
82+
# - "echo --- Downloading and extracting Swift $SWIFT_VERSION to $SWIFT_HOME"
83+
# - "mkdir $SWIFT_HOME"
84+
# - "curl https://download.swift.org/swift-${SWIFT_VERSION}-release/ubuntu2004/swift-${SWIFT_VERSION}-RELEASE/swift-${SWIFT_VERSION}-RELEASE-ubuntu20.04.tar.gz | tar xvz --strip-components=1 -C $SWIFT_HOME"
85+
# build_flags:
86+
# - "--noenable_bzlmod"
87+
# - "--enable_workspace"
88+
# <<: *linux_common
8989

9090
ubuntu2004_latest:
9191
name: "Current LTS"
@@ -134,5 +134,4 @@ tasks:
134134
test_targets:
135135
- "doc/..."
136136

137-
# TODO: Update to version 8+ and fix errors
138-
buildifier: 6.3.2
137+
buildifier: 8.2.1

MODULE.bazel

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
"""rules_swift MODULE.bazel file"""
2+
13
module(
24
name = "rules_swift",
35
version = "0",
@@ -9,7 +11,7 @@ module(
911
bazel_dep(name = "bazel_features", version = "1.10.0")
1012
bazel_dep(name = "bazel_skylib", version = "1.3.0")
1113
bazel_dep(name = "apple_support", version = "1.21.0", repo_name = "build_bazel_apple_support")
12-
bazel_dep(name = "rules_cc", version = "0.0.2")
14+
bazel_dep(name = "rules_cc", version = "0.1.2")
1315
bazel_dep(name = "rules_shell", version = "0.3.0")
1416
bazel_dep(name = "platforms", version = "0.0.9")
1517
bazel_dep(name = "protobuf", version = "23.1", repo_name = "com_google_protobuf")

examples/apple/objc_interop/BUILD

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22
# vice versa when it is linked into the existing native linking rules for Apple
33
# platforms.
44

5+
load("@rules_cc//cc:objc_library.bzl", "objc_library")
56
load("//swift:swift_binary.bzl", "swift_binary")
67
load("//swift:swift_library.bzl", "swift_library")
78

examples/apple/objc_interop_modulemap/BUILD

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22
# vice versa when it is linked into the existing native linking rules for Apple
33
# platforms.
44

5+
load("@rules_cc//cc:objc_library.bzl", "objc_library")
56
load("//swift:swift_binary.bzl", "swift_binary")
67
load("//swift:swift_library.bzl", "swift_library")
78

examples/xplatform/c_from_swift/BUILD

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
load("@rules_cc//cc:cc_library.bzl", "cc_library")
12
load("//swift:swift_binary.bzl", "swift_binary")
23
load("//swift:swift_interop_hint.bzl", "swift_interop_hint")
34
load("//swift:swift_library.bzl", "swift_library")

examples/xplatform/cxx_from_swift/BUILD

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
load("@rules_cc//cc:cc_library.bzl", "cc_library")
12
load("//swift:swift_binary.bzl", "swift_binary")
23
load("//swift:swift_interop_hint.bzl", "swift_interop_hint")
34

examples/xplatform/overlay/BUILD

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
load("@rules_cc//cc:cc_library.bzl", "cc_library")
12
load(
23
"//swift:swift_interop_hint.bzl",
34
"swift_interop_hint",

mixed_language/BUILD

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,5 +23,6 @@ bzl_library(
2323
"//swift:swift_library",
2424
"//swift/internal:compiling",
2525
"@bazel_skylib//lib:paths",
26+
"@rules_cc//cc:core_rules",
2627
],
2728
)

mixed_language/internal/library.bzl

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,8 @@
1616

1717
load("@bazel_skylib//lib:dicts.bzl", "dicts")
1818
load("@bazel_skylib//lib:paths.bzl", "paths")
19+
load("@rules_cc//cc/common:cc_common.bzl", "cc_common")
20+
load("@rules_cc//cc/common:cc_info.bzl", "CcInfo")
1921
load(
2022
"//swift:providers.bzl",
2123
"SwiftInfo",

mixed_language/internal/umbrella_header.bzl

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,8 @@
1515
"""Implementation of the `mixed_language_umbrella_header` rule."""
1616

1717
load("@bazel_skylib//lib:paths.bzl", "paths")
18+
load("@rules_cc//cc/common:cc_common.bzl", "cc_common")
19+
load("@rules_cc//cc/common:cc_info.bzl", "CcInfo")
1820

1921
def _mixed_language_umbrella_header_impl(ctx):
2022
actions = ctx.actions

0 commit comments

Comments
 (0)