Skip to content

Commit cc7cac0

Browse files
vitautfacebook-github-bot
authored andcommitted
Fix build configs to make Thrift stresstest work
Summary: Fix a few issues in Thrift stresstest and its dependencies, mostly related to build configs: * Make folly liburing dependencies consistent between fbcode and xplat, otherwise uring is disabled. * Build the stresstest `Server` target for the target instead of the host platform. * Enable the FBCODE platform for binaries for dependency remapping to work. * Replace `fbcode_exported_deps` with `exported_deps` for targets that are now consistent between fbcode and xplat. Reviewed By: robertroeser Differential Revision: D78572025 fbshipit-source-id: 97a6b8403c618eca66a8143c44403d12598623cc
1 parent b31c6f1 commit cc7cac0

File tree

1 file changed

+10
-6
lines changed

1 file changed

+10
-6
lines changed

folly/io/async/BUCK

Lines changed: 10 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
load("@fbcode_macros//build_defs:build_file_migration.bzl", "fbcode_target", "non_fbcode_target")
22
load("@fbcode_macros//build_defs:cpp_library.bzl", "cpp_library")
3+
load("@fbsource//tools/build_defs:fbsource_utils.bzl", "is_arvr_mode")
34
load("@fbsource//tools/build_defs/dirsync:fb_dirsync_cpp_library.bzl", "fb_dirsync_cpp_library")
45
load("@fbsource//xplat/pfh/triage_InfrastructureSupermoduleOptou:DEFS.bzl", "triage_InfrastructureSupermoduleOptou")
56
load("../../defs.bzl", "folly_xplat_cxx_library")
@@ -682,23 +683,26 @@ fb_dirsync_cpp_library(
682683
],
683684
)
684685

686+
liburing_deps = select({
687+
"DEFAULT": [],
688+
# @fb-only[end= ]: "ovr_config//distro/constraints:conda": [],
689+
# @fb-only[end= ]: "ovr_config//os:linux-sgx": [],
690+
"ovr_config//runtime:fbcode": [] if is_arvr_mode() else ["fbsource//third-party/liburing:uring"],
691+
})
692+
685693
non_fbcode_target(
686694
_kind = folly_xplat_cxx_library,
687695
name = "liburing",
688696
raw_headers = ["Liburing.h"],
697+
exported_deps = liburing_deps,
689698
)
690699

691700
fbcode_target(
692701
# @autodeps-skip
693702
_kind = cpp_library,
694703
name = "liburing",
695704
headers = ["Liburing.h"],
696-
exported_deps = select({
697-
"DEFAULT": [],
698-
# @fb-only[end= ]: "ovr_config//distro/constraints:conda": [],
699-
# @fb-only[end= ]: "ovr_config//os:linux-sgx": [],
700-
"ovr_config//runtime:fbcode": ["fbsource//third-party/liburing:uring"],
701-
}),
705+
exported_deps = liburing_deps,
702706
)
703707

704708
fb_dirsync_cpp_library(

0 commit comments

Comments
 (0)