feat: 完成 M2 mosh(LAN + tsnet 端到端验证)
- mosh(blinksh/ios C++)+protobuf-lite 交叉编译为 MoshCore.xcframework (CommonCrypto 后端、含 arm64 模拟器 slice;绕 autotools 用 CMake 直编 + 手写 config.h) - tsnet 桥新增 UDP relay(StartMoshRelay:loopback↔tsnet.Dial 逐包搬运) - MoshSession(pipe↔FILE*/pthread/SIGWINCH)+ MoshConnectScanner(TXCore,+4 单测=39) - SSHTerminalModel 编排:SSH 引导 mosh-server→解析 MOSH CONNECT→relay→mosh 接管 - LAN 直连 + mosh-over-tsnet 均端到端验证通过,R1(tsnet UDP 数据报语义) 证伪 Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
50
vendor/protobuf/protobuf_release.bzl
vendored
Normal file
50
vendor/protobuf/protobuf_release.bzl
vendored
Normal file
@@ -0,0 +1,50 @@
|
||||
"""
|
||||
Generates package naming variables for use with rules_pkg.
|
||||
"""
|
||||
|
||||
load("@rules_pkg//:providers.bzl", "PackageVariablesInfo")
|
||||
load("@bazel_tools//tools/cpp:toolchain_utils.bzl", "find_cpp_toolchain")
|
||||
load(":protobuf_version.bzl", "PROTOC_VERSION")
|
||||
|
||||
def _package_naming_impl(ctx):
|
||||
values = {}
|
||||
values["version"] = PROTOC_VERSION
|
||||
|
||||
# infer from the current cpp toolchain.
|
||||
toolchain = find_cpp_toolchain(ctx)
|
||||
cpu = toolchain.cpu
|
||||
system_name = toolchain.target_gnu_system_name
|
||||
|
||||
# rename cpus to match what we want artifacts to be
|
||||
if cpu == "systemz":
|
||||
cpu = "s390_64"
|
||||
elif cpu == "aarch64":
|
||||
cpu = "aarch_64"
|
||||
elif cpu == "ppc64":
|
||||
cpu = "ppcle_64"
|
||||
|
||||
# use the system name to determine the os and then create platform names
|
||||
if "apple" in system_name:
|
||||
values["platform"] = "osx-" + cpu
|
||||
elif "linux" in system_name:
|
||||
values["platform"] = "linux-" + cpu
|
||||
elif "mingw" in system_name:
|
||||
if cpu == "x86_64":
|
||||
values["platform"] = "win64"
|
||||
else:
|
||||
values["platform"] = "win32"
|
||||
else:
|
||||
values["platform"] = "unknown"
|
||||
|
||||
return PackageVariablesInfo(values = values)
|
||||
|
||||
|
||||
package_naming = rule(
|
||||
implementation = _package_naming_impl,
|
||||
attrs = {
|
||||
# Necessary data dependency for find_cpp_toolchain.
|
||||
"_cc_toolchain": attr.label(default = Label("@bazel_tools//tools/cpp:current_cc_toolchain")),
|
||||
},
|
||||
toolchains = ["@bazel_tools//tools/cpp:toolchain_type"],
|
||||
incompatible_use_toolchain_transition = True,
|
||||
)
|
||||
Reference in New Issue
Block a user