From dc51c5fc5be3852abf4887dffa86324c4d93d0e4 Mon Sep 17 00:00:00 2001 From: Paolo Tranquilli Date: Tue, 20 Aug 2024 17:38:04 +0200 Subject: [PATCH] KE2: add bazel BUILD file --- java/kotlin-extractor2/BUILD.bazel | 40 ++++++++++++++++++++++++++++++ 1 file changed, 40 insertions(+) create mode 100644 java/kotlin-extractor2/BUILD.bazel diff --git a/java/kotlin-extractor2/BUILD.bazel b/java/kotlin-extractor2/BUILD.bazel new file mode 100644 index 00000000000..0414db5d62f --- /dev/null +++ b/java/kotlin-extractor2/BUILD.bazel @@ -0,0 +1,40 @@ +load("@rules_kotlin//kotlin:core.bzl", "kt_javac_options", "kt_kotlinc_options") +load("@rules_kotlin//kotlin:jvm.bzl", "kt_jvm_library") + +kt_javac_options( + name = "javac-options", + # if needed, see https://bazelbuild.github.io/rules_kotlin/kotlin.html#kt_javac_options for available options +) + +kt_kotlinc_options( + name = "kotlinc-options", + # if needed, see https://bazelbuild.github.io/rules_kotlin/kotlin.html#kt_kotlinc_options for available options +) + +# uncomment if you need the DB scheme generated bindings +#py_binary( +# name = "generate_dbscheme", +# srcs = ["generate_dbscheme.py"], +#) +#genrule( +# name = "generated-dbscheme", +# srcs = ["@codeql//java:dbscheme"], +# outs = ["KotlinExtractorDbScheme.kt"], +# cmd = "$(execpath :generate_dbscheme) $< $@", +# tools = [":generate_dbscheme"], +#) + +kt_jvm_library( + name = "kotlin-extractor2", + srcs = [ + # ":generated-dbscheme", + "src/main/kotlin/KotlinExtractor.kt", + ], + javac_opts = ":javac-options", + kotlinc_opts = ":kotlinc-options", + module_name = "codeql-kotlin-extractor2", + resources = glob(["src/main/resources/**"]), + visibility = ["//visibility:public"], + deps = [ + ], +)