Mercurial
comparison seobeo/BUILD @ 7:114cad94008f
[Seobeo] Updated to support thread and edge server calls.
| author | June Park <parkjune1995@gmail.com> |
|---|---|
| date | Mon, 29 Sep 2025 17:00:38 -0700 |
| parents | 1e61008b9980 |
| children | f33d9ff8b6e8 |
comparison
equal
deleted
inserted
replaced
| 6:1e61008b9980 | 7:114cad94008f |
|---|---|
| 1 load("@rules_cc//cc:cc_binary.bzl", "cc_binary") | 1 load("@rules_cc//cc:cc_binary.bzl", "cc_binary") |
| 2 load("@rules_cc//cc:cc_library.bzl", "cc_library") | 2 load("@rules_cc//cc:cc_library.bzl", "cc_library") |
| 3 | 3 |
| 4 alias( | 4 config_setting( |
| 5 name = "seobeo", | 5 name = "macos", |
| 6 actual = select({ | 6 constraint_values = ["@platforms//os:osx"], |
| 7 "@platforms//os:osx": ":seobeo_example_mac", | 7 ) |
| 8 }), | 8 |
| 9 visibility = ["//visibility:public"], | 9 config_setting( |
| 10 name = "linux", | |
| 11 constraint_values = ["@platforms//os:linux"], | |
| 10 ) | 12 ) |
| 11 | 13 |
| 12 filegroup( | 14 filegroup( |
| 13 name = "pages_files", | 15 name = "pages_files", |
| 14 srcs = glob(["pages/**"]), | 16 srcs = glob(["pages/**"]), |
| 16 | 18 |
| 17 filegroup( | 19 filegroup( |
| 18 name = "seobeo_headers", | 20 name = "seobeo_headers", |
| 19 srcs = [ | 21 srcs = [ |
| 20 "seobeo.h", | 22 "seobeo.h", |
| 21 "seobeo_internal.h" | 23 "seobeo_internal.h", |
| 22 ], | 24 ], |
| 23 visibility = ["//visibility:public"], | 25 visibility = ["//visibility:public"], |
| 24 ) | 26 ) |
| 25 | 27 |
| 26 cc_binary( | 28 cc_binary( |
| 27 name = "seobeo_example_mac", | 29 name = "seobeo_example", |
| 28 srcs = ["main.c"], | 30 srcs = ["main.c"], |
| 29 deps = [":seobeo_non_window"], | 31 deps = [":seobeo"], |
| 30 data = glob(["pages/**"]), | 32 data = [":pages_files"], |
| 33 ) | |
| 34 | |
| 35 alias( | |
| 36 name = "seobeo", | |
| 37 actual = select({ | |
| 38 ":macos": ":seobeo_macos", | |
| 39 ":linux": ":seobeo_linux", | |
| 40 "//conditions:default": ":seobeo_linux", | |
| 41 }), | |
| 42 visibility = ["//visibility:public"], | |
| 43 ) | |
| 44 | |
| 45 cc_library( | |
| 46 name = "seobeo_macos", | |
| 47 srcs = [ | |
| 48 "s_linux_network.c", | |
| 49 "s_web.c", | |
| 50 "os/s_macos_edge.c", | |
| 51 ], | |
| 52 hdrs = [":seobeo_headers"], | |
| 53 deps = ["//dowa:dowa"], | |
| 31 target_compatible_with = [ | 54 target_compatible_with = [ |
| 32 "@platforms//os:osx", | 55 "@platforms//os:osx", |
| 33 ], | 56 ], |
| 34 visibility = ["//visibility:public"], | 57 visibility = ["//visibility:public"], |
| 35 ) | 58 ) |
| 36 | 59 |
| 37 cc_library( | 60 cc_library( |
| 38 name = "seobeo_non_window", | 61 name = "seobeo_linux", |
| 39 srcs = [ | 62 srcs = [ |
| 40 "s_linux_network.c", | 63 "s_linux_network.c", |
| 41 "s_web.c", | 64 "s_web.c", |
| 65 "os/s_linux_edge.c", | |
| 42 ], | 66 ], |
| 67 hdrs = [":seobeo_headers"], | |
| 43 deps = ["//dowa:dowa"], | 68 deps = ["//dowa:dowa"], |
| 44 hdrs = [ | |
| 45 "seobeo.h", | |
| 46 "seobeo_internal.h" | |
| 47 ], | |
| 48 target_compatible_with = [ | 69 target_compatible_with = [ |
| 49 "@platforms//os:osx", | 70 "@platforms//os:linux", |
| 50 ], | 71 ], |
| 51 visibility = ["//visibility:public"], | 72 visibility = ["//visibility:public"], |
| 52 ) | 73 ) |
| 74 |