gpt4 book ai didi

macos - Mac App 因使用非公共(public) API 而被拒绝

转载 作者:行者123 更新时间:2023-12-02 04:09:09 26 4
gpt4 key购买 nike

Mac 应用程序最近被 Mac App Store 拒绝使用非公共(public) API(见下文),我不确定如何解决这个问题——主要是因为我不完全理解问题本身。

我尝试使用 otool -L 和 nm -u 来更好地了解该问题,但我在终端中收到“无法映射文件”警告。

同样重要的是要注意我在应用程序中使用 PyObjC,我觉得这是这个问题的根源。

有人知道如何解决这个问题吗?

2.5

The use of non-public APIs can lead to a poor user experience should these APIs change in the future, and is therefore not permitted. The following non-public APIs are included in your application:

'pthread_key_init_np', framework: '/usr/lib/libSystem.B.dylib' 'auto_assign_weak_reference', framework: '/usr/lib/libauto.dylib' 'auto_collect', framework: '/usr/lib/libauto.dylib' 'auto_collect_multithreaded', framework: '/usr/lib/libauto.dylib' 'auto_collection_parameters', framework: '/usr/lib/libauto.dylib' 'auto_read_weak_reference', framework: '/usr/lib/libauto.dylib' 'auto_zone_add_root', framework: '/usr/lib/libauto.dylib' 'auto_zone_allocate_object', framework: '/usr/lib/libauto.dylib' 'auto_zone_assert_thread_registered', framework: '/usr/lib/libauto.dylib' 'auto_zone_atomicCompareAndSwap', framework: '/usr/lib/libauto.dylib' 'auto_zone_atomicCompareAndSwapPtr', framework: '/usr/lib/libauto.dylib' 'auto_zone_clear_stack', framework: '/usr/lib/libauto.dylib' 'auto_zone_create', framework: '/usr/lib/libauto.dylib' 'auto_zone_dump', framework: '/usr/lib/libauto.dylib' 'auto_zone_erase_associative_refs', framework: '/usr/lib/libauto.dylib' 'auto_zone_get_associative_ref', framework: '/usr/lib/libauto.dylib' 'auto_zone_get_layout_type', framework: '/usr/lib/libauto.dylib' 'auto_zone_is_collecting', framework: '/usr/lib/libauto.dylib' 'auto_zone_is_finalized', framework: '/usr/lib/libauto.dylib' 'auto_zone_is_valid_pointer', framework: '/usr/lib/libauto.dylib' 'auto_zone_register_datasegment', framework: '/usr/lib/libauto.dylib' 'auto_zone_register_thread', framework: '/usr/lib/libauto.dylib' 'auto_zone_release', framework: '/usr/lib/libauto.dylib' 'auto_zone_retain', framework: '/usr/lib/libauto.dylib' 'auto_zone_retain_count', framework: '/usr/lib/libauto.dylib' 'auto_zone_root_write_barrier', framework: '/usr/lib/libauto.dylib' 'auto_zone_set_associative_ref', framework: '/usr/lib/libauto.dylib' 'auto_zone_set_class_list', framework: '/usr/lib/libauto.dylib' 'auto_zone_set_write_barrier', framework: '/usr/lib/libauto.dylib' 'auto_zone_size', framework: '/usr/lib/libauto.dylib' 'auto_zone_start_monitor', framework: '/usr/lib/libauto.dylib' 'auto_zone_unregister_datasegment', framework: '/usr/lib/libauto.dylib' 'auto_zone_unregister_thread', framework: '/usr/lib/libauto.dylib' 'auto_zone_write_barrier_memmove', framework: '/usr/lib/libauto.dylib'

If you have defined methods in your source code with the same names as the above-mentioned APIs, we suggest altering your method names so that they no longer collide with Apple's private APIs to avoid your application being flagged in future submissions.

Additionally, one or more of the above-mentioned APIs may reside in a library included with your application. If you do not have access to the library's source, you may be able to search the compiled binary using “strings" or “otool" command line tools. The “strings" tool can output a list of the methods that the library calls and “otool -ov" will output the Objective-C class structures and their defined methods. These techniques can help you narrow down where the problematic code resides.

最佳答案

如消息中所述,PyObjC 框架正在(直接或通过正在使用的另一个库)导入这些库“/usr/lib/libSystem.B.dylib”和“/usr/lib/libauto.dylib”。这两个库包含某些方法(也在消息中提到)

collide with Apple's private APIs



我猜这些方法会与 QTKit 框架发生冲突(参见 API notes for QTKit)。现在有两种可能:
  • 如果可以在构建时删除那个有问题的库
  • 与 PyObjC 的人交谈,看看他们是否需要更改他们的 API
  • 关于macos - Mac App 因使用非公共(public) API 而被拒绝,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/6114983/

    26 4 0
    Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
    广告合作:1813099741@qq.com 6ren.com