PyTorch: fix build with Xcode 15 (#40460)

This commit is contained in:
Adam J. Stewart 2023-10-12 08:27:03 -05:00 committed by GitHub
parent 995e82e72b
commit 285a50f862
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -634,6 +634,10 @@ def enable_or_disable(variant, keyword="USE", var=None, newer=False):
# https://github.com/pytorch/pytorch/issues/60332
# env.set("USE_SYSTEM_XNNPACK", "ON")
# https://github.com/pytorch/pytorch/issues/111086
if self.spec.satisfies("%apple-clang@15:"):
env.append_flags("LDFLAGS", "-Wl,-ld_classic")
@run_before("install")
def build_amd(self):
if "+rocm" in self.spec: