Skip to content

Commit

Permalink
chore: Use Bazel's built-in constraint values
Browse files Browse the repository at this point in the history
The toktok-stack constraints are thin wrappers around the
bazelbuild/platforms ones, but using the Bazel ones makes depending on
jvm-toxcore-c more convenient.
  • Loading branch information
robinlinden committed Feb 23, 2024
1 parent 84ffab8 commit 2494bba
Showing 1 changed file with 8 additions and 8 deletions.
16 changes: 8 additions & 8 deletions BUILD.bazel
Original file line number Diff line number Diff line change
Expand Up @@ -10,10 +10,10 @@ project()
genrule(
name = "copy_link_jni_md_header",
srcs = select({
"//tools/config:freebsd": ["@bazel_tools//tools/jdk:jni_md_header-freebsd"],
"//tools/config:linux": ["@bazel_tools//tools/jdk:jni_md_header-linux"],
"//tools/config:osx": ["@bazel_tools//tools/jdk:jni_md_header-darwin"],
"//tools/config:windows": ["@bazel_tools//tools/jdk:jni_md_header-windows"],
"@platforms//os:freebsd": ["@bazel_tools//tools/jdk:jni_md_header-freebsd"],
"@platforms//os:linux": ["@bazel_tools//tools/jdk:jni_md_header-linux"],
"@platforms//os:osx": ["@bazel_tools//tools/jdk:jni_md_header-darwin"],
"@platforms//os:windows": ["@bazel_tools//tools/jdk:jni_md_header-windows"],
}),
outs = ["lib/src/jvmMain/cpp/jni_md.h"],
cmd = "cp -f $< $@",
Expand Down Expand Up @@ -58,10 +58,10 @@ cc_binary(
"lib/src/jvmMain/proto",
],
linkopts = select({
"//tools/config:freebsd": ["-Wl,--version-script,$(location lib/src/jvmMain/cpp/libtox4j-c.ld)"],
"//tools/config:linux": ["-Wl,--version-script,$(location lib/src/jvmMain/cpp/libtox4j-c.ld)"],
"//tools/config:osx": [],
"//tools/config:windows": [],
"@platforms//os:freebsd": ["-Wl,--version-script,$(location lib/src/jvmMain/cpp/libtox4j-c.ld)"],
"@platforms//os:linux": ["-Wl,--version-script,$(location lib/src/jvmMain/cpp/libtox4j-c.ld)"],
"@platforms//os:osx": [],
"@platforms//os:windows": [],
}),
linkshared = True,
visibility = ["//visibility:public"],
Expand Down

0 comments on commit 2494bba

Please sign in to comment.