diff --git a/haskell/cc.bzl b/haskell/cc.bzl index e6851444e..485c86a37 100644 --- a/haskell/cc.bzl +++ b/haskell/cc.bzl @@ -87,7 +87,10 @@ def cc_interop_info(ctx, override_cc_toolchain = None): ctx = real_ctx, cc_toolchain = cc_toolchain, requested_features = ctx.features, - unsupported_features = ctx.disabled_features, + # we explicitly declare macos_default_link_flags as unsupported since it will by default add + # the linker flag "-fobjc-link-runtime", since it leads to the Foundation framewok being linked on macOS + # which leads to: "ld: framework not found Foundation" + unsupported_features = ctx.disabled_features + ["macos_default_link_flags"], ) compile_variables = cc_common.create_compile_variables( feature_configuration = feature_configuration,