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

chore(deps): update dependency com_github_bazelbuild_buildtools to v7 #2187

Merged
merged 2 commits into from
May 8, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
4 changes: 2 additions & 2 deletions WORKSPACE
Original file line number Diff line number Diff line change
Expand Up @@ -59,14 +59,15 @@ load("//extensions:rules_haskell_dependencies.bzl", _repositories_3 = "repositor

_repositories_3(bzlmod = False)

load("@rules_haskell_ghc_version//:ghc_version.bzl", "GHC_VERSION")
load(
"@rules_haskell//haskell:ghc_bindist.bzl",
"haskell_register_ghc_bindists",
)
load("@rules_haskell_ghc_version//:ghc_version.bzl", "GHC_VERSION")

haskell_register_ghc_bindists(version = GHC_VERSION)

load("@os_info//:os_info.bzl", "is_nix_shell", "is_windows")
load(
"@rules_haskell//haskell/asterius:repositories.bzl",
"asterius_dependencies_bindist",
Expand All @@ -76,7 +77,6 @@ load(
"@rules_nixpkgs_core//:nixpkgs.bzl",
"nixpkgs_package",
)
load("@os_info//:os_info.bzl", "is_nix_shell", "is_windows")

asterius_dependencies_nix(
nix_repository = "@nixpkgs_default",
Expand Down
4 changes: 2 additions & 2 deletions docs/BUILD.bazel
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
load("@bazel_skylib//:bzl_library.bzl", "bzl_library")
load("@bazel_skylib//rules:common_settings.bzl", "bool_flag")
load("@io_bazel_stardoc//stardoc:stardoc.bzl", "stardoc")
load("@rules_python//python:defs.bzl", "py_binary")
load("@rules_haskell//docs/pandoc:pandoc.bzl", "set_site_end_location")
load("@bazel_skylib//rules:common_settings.bzl", "bool_flag")
load("@rules_python//python:defs.bzl", "py_binary")

bool_flag(
name = "render_dev_website",
Expand Down
4 changes: 2 additions & 2 deletions examples/arm/BUILD.bazel
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
package(default_visibility = ["//visibility:public"])

load(
"@rules_haskell//haskell:defs.bzl",
"haskell_binary",
"haskell_library",
"haskell_toolchain_library",
)

package(default_visibility = ["//visibility:public"])

haskell_toolchain_library(name = "base")

haskell_toolchain_library(name = "template-haskell")
Expand Down
2 changes: 1 addition & 1 deletion examples/arm/WORKSPACE
Original file line number Diff line number Diff line change
Expand Up @@ -20,12 +20,12 @@ load(
"@rules_haskell//haskell:cabal.bzl",
"stack_snapshot",
)
load("@rules_nixpkgs_cc//:cc.bzl", "nixpkgs_cc_configure")
load(
"@rules_nixpkgs_core//:nixpkgs.bzl",
"nixpkgs_git_repository",
"nixpkgs_package",
)
load("@rules_nixpkgs_cc//:cc.bzl", "nixpkgs_cc_configure")
load("@rules_nixpkgs_python//:python.bzl", "nixpkgs_python_configure")

nixpkgs_git_repository(
Expand Down
2 changes: 1 addition & 1 deletion examples/non_module_deps.bzl
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
""" External repositories for the CI that need to be shared between WORKSPACE and MODULE.bazel files """

load("@rules_haskell//tools:os_info.bzl", "os_info")
load("@bazel_tools//tools/build_defs/repo:http.bzl", "http_archive")
load("@rules_haskell//tools:os_info.bzl", "os_info")

def repositories(*, bzlmod):
# Some helpers for platform-dependent configuration
Expand Down
6 changes: 3 additions & 3 deletions extensions/rules_haskell_dependencies.bzl
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
""" This module extension contains rules_haskell dependencies that are not available as modules """

load("@rules_haskell//haskell:repositories.bzl", "rules_haskell_dependencies_bzlmod")
load("@rules_haskell//tools:repositories.bzl", "rules_haskell_worker_dependencies")
load("@bazel_tools//tools/build_defs/repo:http.bzl", "http_archive")
load("@bazel_tools//tools/build_defs/repo:utils.bzl", "maybe")
load("@rules_haskell//haskell:private/versions.bzl", "is_at_least")
load("@rules_haskell//haskell:repositories.bzl", "rules_haskell_dependencies_bzlmod")
load("@rules_haskell//tools:os_info.bzl", "os_info")
load("@rules_haskell//tools:repositories.bzl", "rules_haskell_worker_dependencies")
load("@rules_haskell_ghc_version//:ghc_version.bzl", "GHC_VERSION")
load("@rules_haskell//haskell:private/versions.bzl", "is_at_least")

def _empty_repo_impl(rctx):
fail(rctx.attr.error_msg)
Expand Down
4 changes: 2 additions & 2 deletions extensions/stack_snapshot.bzl
Original file line number Diff line number Diff line change
Expand Up @@ -2,17 +2,17 @@
This module extension gathers packages and configuration from all the modules that use it,
in order to make a unique call to `stack_snapshot` to generate a "stackage" shared repository.

Most of the configuration can only be made by the root module, and
Most of the configuration can only be made by the root module, and
other modules can declare the packages they want installed.

The rules_haskell module itself has more permissions, so that it can
set default configurations for packages as well as set the default
snapshot to use.
"""

load("@rules_haskell//haskell:cabal.bzl", _stack_snapshot = "stack_snapshot")
load("@bazel_skylib//lib:new_sets.bzl", "sets")
load("@os_info//:os_info.bzl", "cpu_value", "is_darwin", "is_linux", "is_windows")
load("@rules_haskell//haskell:cabal.bzl", _stack_snapshot = "stack_snapshot")

_snapshot_tag = tag_class(
doc = "The stack snapshot to use.",
Expand Down
18 changes: 9 additions & 9 deletions haskell/BUILD.bazel
Original file line number Diff line number Diff line change
@@ -1,20 +1,15 @@
load("@bazel_skylib//:bzl_library.bzl", "bzl_library")
load("@rules_python//python:defs.bzl", "py_binary", "py_library")
load(
"@rules_haskell//haskell:private/cc_wrapper.bzl",
"cc_wrapper",
)
load(
"@rules_haskell//haskell:cabal_wrapper.bzl",
"cabal_wrapper",
)
load(
"@rules_haskell//haskell:private/runghc.bzl",
"runghc",
"@rules_haskell//haskell:private/cc_wrapper.bzl",
"cc_wrapper",
)
load(
"@rules_haskell//haskell:toolchain_info.bzl",
"haskell_toolchain_info",
"@rules_haskell//haskell:private/runghc.bzl",
"runghc",
)
load(
"@rules_haskell//haskell:toolchain.bzl",
Expand All @@ -23,6 +18,11 @@ load(
"get_nodejs_toolchain",
"get_posix_toolchain",
)
load(
"@rules_haskell//haskell:toolchain_info.bzl",
"haskell_toolchain_info",
)
load("@rules_python//python:defs.bzl", "py_binary", "py_library")

exports_files(
glob(["*.bzl"]) + [
Expand Down
2 changes: 1 addition & 1 deletion haskell/asterius/defs.bzl
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@
# And for now stardoc always try to explore third party dependencies
# https://github.com/bazelbuild/stardoc/issues/93.

load("@bazel_skylib//lib:paths.bzl", "paths")
load("@aspect_rules_js//js:defs.bzl", "js_binary", "js_test")
load("@bazel_skylib//lib:paths.bzl", "paths")
load("@bazel_skylib//rules:common_settings.bzl", "BuildSettingInfo")
load("@rules_haskell_asterius_webpack//:package_json.bzl", "bin")

Expand Down
20 changes: 10 additions & 10 deletions haskell/asterius/repositories.bzl
Original file line number Diff line number Diff line change
@@ -1,18 +1,14 @@
load("@bazel_skylib//lib:paths.bzl", "paths")
load(
"//haskell:private/workspace_utils.bzl",
"define_rule",
"execute_or_fail_loudly",
"resolve_labels",
)
load("@rules_cc//cc:find_cc_toolchain.bzl", "CC_TOOLCHAIN_TYPE")
load(
"//haskell:private/pkgdb_to_bzl.bzl",
"pkgdb_to_bzl",
)
load(
"//haskell/platforms:list.bzl",
"os_of_constraints",
"platform_of_constraints",
"//haskell:private/workspace_utils.bzl",
"define_rule",
"execute_or_fail_loudly",
"resolve_labels",
)
load("//haskell/asterius:asterius_config.bzl", "asterius_cabalopts")
load(
Expand All @@ -21,7 +17,11 @@ load(
_asterius_dependencies_custom = "asterius_dependencies_custom",
_asterius_dependencies_nix = "asterius_dependencies_nix",
)
load("@rules_cc//cc:find_cc_toolchain.bzl", "CC_TOOLCHAIN_TYPE")
load(
"//haskell/platforms:list.bzl",
"os_of_constraints",
"platform_of_constraints",
)

# For now the asterius bundle is built and uploaded manually for linux.
# When the asterius build works inside the ci we will be able to download the artifacts from there.
Expand Down
10 changes: 5 additions & 5 deletions haskell/c2hs.bzl
Original file line number Diff line number Diff line change
@@ -1,11 +1,8 @@
"""Support for c2hs"""

load("@bazel_skylib//lib:paths.bzl", "paths")
load("@bazel_skylib//lib:sets.bzl", "sets")
load("@rules_cc//cc:find_cc_toolchain.bzl", "use_cc_toolchain")
load(
":providers.bzl",
"C2hsLibraryInfo",
)
load(":cc.bzl", "cc_interop_info")
load(
":private/cc_libraries.bzl",
Expand All @@ -19,8 +16,11 @@ load(
"target_unique_name",
)
load(":private/set.bzl", "set")
load("@bazel_skylib//lib:sets.bzl", "sets")
load(":private/version_macros.bzl", "version_macro_includes")
load(
":providers.bzl",
"C2hsLibraryInfo",
)

def _c2hs_library_impl(ctx):
hs = haskell_context(ctx)
Expand Down
22 changes: 11 additions & 11 deletions haskell/cabal.bzl
Original file line number Diff line number Diff line change
Expand Up @@ -2,13 +2,22 @@

load("@bazel_skylib//lib:dicts.bzl", "dicts")
load("@bazel_skylib//lib:paths.bzl", "paths")
load("@bazel_skylib//lib:sets.bzl", "sets")
load("@bazel_tools//tools/build_defs/repo:utils.bzl", "maybe", "read_netrc", "use_netrc")
load("//vendor/bazel_json/lib:json_parser.bzl", "json_parse")
load("@bazel_tools//tools/cpp:lib_cc_configure.bzl", "get_cpu_value")
load("@rules_cc//cc:find_cc_toolchain.bzl", "find_cc_toolchain", "use_cc_toolchain")
load("//vendor/bazel_json/lib:json_parser.bzl", "json_parse")
load(":cc.bzl", "cc_interop_info", "ghc_cc_program_args")
load(":haddock.bzl", "generate_unified_haddock_info")
load(":private/actions/info.bzl", "library_info_output_groups")
load(":private/actions/link.bzl", "darwin_flags_for_linking_indirect_cc_deps")
load(
":private/cc_libraries.bzl",
"get_cc_libraries",
"get_ghci_library_files",
"get_library_files",
"haskell_cc_libraries_aspect",
)
load(":private/context.bzl", "haskell_context")
load(":private/dependencies.bzl", "gather_dep_info")
load(":private/expansions.bzl", "expand_make_variables")
Expand All @@ -20,9 +29,8 @@ load(
"relative_rpath_prefix",
"truly_relativize",
)
load("@bazel_skylib//lib:sets.bzl", "sets")
load(":private/validate_attrs.bzl", "typecheck_stackage_extradeps")
load(":haddock.bzl", "generate_unified_haddock_info")
load(":private/versions.bzl", "check_bazel_version")
load(
":private/workspace_utils.bzl",
_execute_or_fail_loudly = "execute_or_fail_loudly",
Expand All @@ -34,14 +42,6 @@ load(
"HaskellLibraryInfo",
"all_dependencies_package_ids",
)
load(
":private/cc_libraries.bzl",
"get_cc_libraries",
"get_ghci_library_files",
"get_library_files",
"haskell_cc_libraries_aspect",
)
load(":private/versions.bzl", "check_bazel_version")

def _get_auth(ctx, urls):
"""Find the .netrc file and obtain the auth dict for the required URLs.
Expand Down
2 changes: 1 addition & 1 deletion haskell/cc.bzl
Original file line number Diff line number Diff line change
Expand Up @@ -3,13 +3,13 @@
These rules are deprecated.
"""

load("@bazel_skylib//lib:paths.bzl", "paths")
load(
"@rules_cc//cc:action_names.bzl",
"CPP_LINK_EXECUTABLE_ACTION_NAME",
"C_COMPILE_ACTION_NAME",
)
load("@rules_cc//cc:find_cc_toolchain.bzl", "find_cc_toolchain")
load("@bazel_skylib//lib:paths.bzl", "paths")
load(
"//haskell:providers.bzl",
"GhcPluginInfo",
Expand Down
20 changes: 10 additions & 10 deletions haskell/defs.bzl
Original file line number Diff line number Diff line change
@@ -1,11 +1,21 @@
"""Core Haskell rules"""

load("@bazel_skylib//rules:expand_template.bzl", "expand_template")
load("@rules_cc//cc:find_cc_toolchain.bzl", "use_cc_toolchain")
load(
"//haskell/experimental:providers.bzl",
"HaskellModuleInfo",
)
load(
":haddock.bzl",
_haskell_doc = "haskell_doc",
_haskell_doc_aspect = "haskell_doc_aspect",
)
load(
":plugins.bzl",
_ghc_plugin = "ghc_plugin",
)
load(":private/cc_libraries.bzl", "haskell_cc_libraries_aspect")
load(
":private/haskell_impl.bzl",
_haskell_binary_impl = "haskell_binary_impl",
Expand All @@ -19,23 +29,13 @@ load(
_haskell_repl = "haskell_repl",
_haskell_repl_aspect = "haskell_repl_aspect",
)
load(":private/cc_libraries.bzl", "haskell_cc_libraries_aspect")

# For re-exports:
load(
":toolchain.bzl",
_haskell_register_toolchains = "rules_haskell_toolchains",
_haskell_toolchain = "haskell_toolchain",
)
load(
":plugins.bzl",
_ghc_plugin = "ghc_plugin",
)
load(
"//haskell/experimental:providers.bzl",
"HaskellModuleInfo",
)
load("@bazel_skylib//rules:expand_template.bzl", "expand_template")

# NOTE: Documentation needs to be added to the wrapper macros below.
# Currently it is not possible to automatically inherit rule documentation in
Expand Down
16 changes: 8 additions & 8 deletions haskell/doctest.bzl
Original file line number Diff line number Diff line change
@@ -1,21 +1,21 @@
"""Doctest support"""

load("@bazel_skylib//lib:dicts.bzl", "dicts")
load("@rules_cc//cc:find_cc_toolchain.bzl", "use_cc_toolchain")
load(":cc.bzl", "cc_interop_info", "ghc_cc_program_args")
load(":private/context.bzl", "haskell_context", "render_env")
load("@bazel_skylib//lib:sets.bzl", "sets")
load(
"@rules_haskell//haskell:providers.bzl",
"HaskellCcLibrariesInfo",
"HaskellInfo",
)
load("@rules_cc//cc:find_cc_toolchain.bzl", "use_cc_toolchain")
load(
"@rules_haskell//haskell:private/cc_libraries.bzl",
"get_ghci_library_files",
"haskell_cc_libraries_aspect",
"link_libraries",
)
load(
"@rules_haskell//haskell:providers.bzl",
"HaskellCcLibrariesInfo",
"HaskellInfo",
)
load(":cc.bzl", "cc_interop_info", "ghc_cc_program_args")
load(":private/context.bzl", "haskell_context", "render_env")

def _doctest_toolchain_impl(ctx):
return platform_common.ToolchainInfo(
Expand Down
2 changes: 1 addition & 1 deletion haskell/experimental/defs.bzl
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
"""Experimental Haskell rules"""

load("@rules_cc//cc:find_cc_toolchain.bzl", "use_cc_toolchain")
load("//haskell:private/cc_libraries.bzl", "haskell_cc_libraries_aspect")
load(
"//haskell/experimental/private:module.bzl",
_haskell_module_impl = "haskell_module_impl",
)
load("//haskell:private/cc_libraries.bzl", "haskell_cc_libraries_aspect")

# TODO[GL] should we have repl_ghci_args here?
_haskell_module = rule(
Expand Down