syncfiles/lib/BUILD.bazel
Dietrich Epp c4bf86786e Reorganize
- Extracted functions to //lib:test for writing tests

- Extracted functions to lib/util.h if they are useful outside tests
2022-03-30 03:46:19 -04:00

46 lines
703 B
Python

load("@rules_cc//cc:defs.bzl", "cc_library", "cc_test")
load("//bazel:copts.bzl", "COPTS")
cc_library(
name = "lib",
srcs = [
"toolbox.c",
"util.c",
],
hdrs = [
"defs.h",
"endian.h",
"util.h",
],
copts = COPTS,
visibility = ["//visibility:public"],
)
cc_library(
name = "test",
testonly = True,
srcs = [
"test.c",
],
hdrs = [
"test.h",
],
copts = COPTS,
visibility = ["//visibility:public"],
deps = [
":lib",
],
)
cc_test(
name = "endian_test",
srcs = [
"endian_test.c",
],
copts = COPTS,
deps = [
":lib",
":test",
],
)