Skip to content

Commit

Permalink
fix(halo2): link against intel openmp when intel openmp is installed
Browse files Browse the repository at this point in the history
When linking rust tests with clang, clang strangely detects sytem installed
intel openmp. So compiling even without the option
`--//:has_intel_openmp`, linker tries to link against intel openmp.
  • Loading branch information
chokobole committed May 8, 2024
1 parent b30a8f6 commit bd15530
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions vendors/halo2/BUILD.bazel
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
load("@crate_index//:defs.bzl", "aliases", "all_crate_deps")
load("@cxx.rs//tools/bazel:rust_cxx_bridge.bzl", "rust_cxx_bridge")
load("@local_config_cuda//cuda:build_defs.bzl", "if_cuda")
load("//bazel:tachyon.bzl", "if_gpu_is_configured", "if_has_openmp")
load("//bazel:tachyon_cc.bzl", "tachyon_cc_library")
load("//bazel:tachyon.bzl", "if_gpu_is_configured")
load("//bazel:tachyon_cc.bzl", "tachyon_cc_library", "tachyon_openmp_linkopts")
load("//bazel:tachyon_rust.bzl", "tachyon_rust_library", "tachyon_rust_test")

FEATURES = if_gpu_is_configured(["gpu"])
Expand Down Expand Up @@ -37,7 +37,7 @@ tachyon_rust_library(
# rustc_flags = if_has_openmp(["-lgomp"]),
cc_library(
name = "openmp",
linkopts = if_has_openmp(["-fopenmp"]),
linkopts = tachyon_openmp_linkopts(),
)

tachyon_rust_test(
Expand Down

0 comments on commit bd15530

Please sign in to comment.