generated from kubernetes/kubernetes-template-project
-
Notifications
You must be signed in to change notification settings - Fork 49
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
5 changed files
with
35 additions
and
198 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,35 +1,20 @@ | ||
load("@rules_cc//cc:defs.bzl", "cc_binary") | ||
load("@rules_foreign_cc//foreign_cc:defs.bzl", "cmake", "make") | ||
|
||
cmake( | ||
name = "kube_c", | ||
build_args = [ | ||
"--verbose", | ||
"--", # <- Pass remaining options to the native tool. | ||
"-j 1", | ||
], | ||
lib_source = "//:kubernetes", | ||
out_shared_libs = ["libkubernetes.so"], | ||
) | ||
# Example of using bazel rules on the existing examples. | ||
|
||
# create lib files (.so or .a) | ||
# Example: bazel build list_pod_lib | ||
cc_library( | ||
name = "list_pod_lib", | ||
srcs = ["bazel/list_pod.c"], | ||
deps = [":kube_c"], | ||
) | ||
load("@rules_cc//cc:defs.bzl", "cc_binary") | ||
|
||
# create and run executable file. | ||
# Example: bazel run list_pod | ||
# Run: bazel run //examples:list_pod | ||
cc_binary( | ||
name = "list_pod", | ||
srcs = ["bazel/list_pod.c"], | ||
deps = [":kube_c"], | ||
srcs = [ | ||
"list_pod/main.c", | ||
], | ||
deps = ["//:kube_c_library"], #imported from BUILD file of root directory | ||
) | ||
|
||
# Run: bazel run //examples:list_event | ||
cc_binary( | ||
name = "create_pod", | ||
srcs = ["bazel/create_pod.c"], | ||
deps = [":kube_c"], | ||
name = "list_event", | ||
srcs = ["list_event/main.c"], | ||
deps = ["//:kube_c_library"], #imported from BUILD file of root directory | ||
) |
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.