diff options
| author | Andrea Gottardo <andrea@gottardo.me> | 2024-09-11 15:11:35 -0700 |
|---|---|---|
| committer | Andrea Gottardo <andrea@gottardo.me> | 2024-09-11 15:11:35 -0700 |
| commit | dabe3d8fb2a7193fd47f6172c16171bfdf701a6f (patch) | |
| tree | 849e2345c65fba04242536f1e5d471851efe98bd | |
| parent | f2713b663effefd635192f9d804f3b2f90f9ecea (diff) | |
| download | tailscale-angott/tvos-23087.tar.xz tailscale-angott/tvos-23087.zip | |
tool/gocross: allow building for tvOS Simulatorangott/tvos-23087
Updates tailscale/corp#23087
Allows gocross to set the proper flags to build ipn-go-bridge on tvOS Simulator.
| -rw-r--r-- | tool/gocross/autoflags.go | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/tool/gocross/autoflags.go b/tool/gocross/autoflags.go index c66cab55a..7ad1e3bb5 100644 --- a/tool/gocross/autoflags.go +++ b/tool/gocross/autoflags.go @@ -146,7 +146,11 @@ func autoflagsForTest(argv []string, env *Environment, goroot, nativeGOOS, nativ case env.IsSet("MACOSX_DEPLOYMENT_TARGET"): xcodeFlags = append(xcodeFlags, "-mmacosx-version-min="+env.Get("MACOSX_DEPLOYMENT_TARGET", "")) case env.IsSet("TVOS_DEPLOYMENT_TARGET"): - xcodeFlags = append(xcodeFlags, "-mtvos-version-min="+env.Get("TVOS_DEPLOYMENT_TARGET", "")) + if env.Get("TARGET_DEVICE_PLATFORM_NAME", "") == "appletvsimulator" { + xcodeFlags = append(xcodeFlags, "-mtvos-version-min="+env.Get("TVOS_DEPLOYMENT_TARGET", "")+"-simulator") + } else { + xcodeFlags = append(xcodeFlags, "-mtvos-version-min="+env.Get("TVOS_DEPLOYMENT_TARGET", "")) + } default: return nil, nil, fmt.Errorf("invoked by Xcode but couldn't figure out deployment target. Did Xcode change its envvars again?") } |
