diff options
author | github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> | 2022-04-13 18:19:31 +0300 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-04-13 18:19:31 +0300 |
commit | d5fad312d376c11ef1b3b2ccec0bbecf97bf6499 (patch) | |
tree | d93296a5276182ee8cfd3dd5bb19e4cf553e5f1c /src | |
parent | d585c2e84c580c6a94fdde2881482c8a1cd209d4 (diff) |
[release/6.0] [AOT] Don't set the 'CorrectedSynthesize' flag in the objc_imageinfo section. (#67534)
* [AOT] Don't set the 'CorrectedSynthesize' flag in the objc_imageinfo section.
According to Apple's headers, it's not used anymore, and ignored.
However, with Xcode 13.3, it seems Apple has re-used this value for something
else, and it's causing warnings in the linker:
> ld: warning: '[...]/arm64/Xamarin.iOS.dll.o' was built with class_ro_t pointer signing enabled, but previous .o files were not
Fixes https://github.com/mono/mono/issues/21450.
Ref: https://opensource.apple.com/source/objc4/objc4-818.2/runtime/objc-abi.h.auto.html
* Don't set the 'CorrectedSynthesize' flag when using LLVM either.
Co-authored-by: Rolf Bjarne Kvinge <rolf@xamarin.com>
Diffstat (limited to 'src')
-rw-r--r-- | src/mono/mono/mini/aot-compiler.c | 2 | ||||
-rw-r--r-- | src/mono/mono/mini/mini-llvm.c | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/src/mono/mono/mini/aot-compiler.c b/src/mono/mono/mini/aot-compiler.c index 34c1e7606d0..732c2cd961d 100644 --- a/src/mono/mono/mini/aot-compiler.c +++ b/src/mono/mono/mini/aot-compiler.c @@ -11753,7 +11753,7 @@ emit_objc_selectors (MonoAotCompile *acfg) fprintf (acfg->fp, ".align 3\n"); fprintf (acfg->fp, "L_OBJC_IMAGE_INFO:\n"); fprintf (acfg->fp, ".long 0\n"); - fprintf (acfg->fp, ".long 16\n"); + fprintf (acfg->fp, ".long 0\n"); } static void diff --git a/src/mono/mono/mini/mini-llvm.c b/src/mono/mono/mini/mini-llvm.c index f75792659d4..0974486ce17 100644 --- a/src/mono/mono/mini/mini-llvm.c +++ b/src/mono/mono/mini/mini-llvm.c @@ -7366,7 +7366,7 @@ process_bb (EmitContext *ctx, MonoBasicBlock *bb) ctx->module->objc_selector_to_var = g_hash_table_new_full (g_str_hash, g_str_equal, g_free, NULL); LLVMValueRef info_var = LLVMAddGlobal (ctx->lmodule, LLVMArrayType (LLVMInt8Type (), 8), "@OBJC_IMAGE_INFO"); - int32_t objc_imageinfo [] = { 0, 16 }; + int32_t objc_imageinfo [] = { 0, 0 }; LLVMSetInitializer (info_var, mono_llvm_create_constant_data_array ((uint8_t *) &objc_imageinfo, 8)); LLVMSetLinkage (info_var, LLVMPrivateLinkage); LLVMSetExternallyInitialized (info_var, TRUE); |