在 Mac 上探索 .app 文件

发布于 2024-12-18 14:04:25 字数 77 浏览 2 评论 0原文

可以在 Mac 上访问应用程序源文件吗?在“应用程序”文件夹中,可以浏览任何 .app 文件,并可以访问头文件,是全部还是也可以访问类文件?

Can one get access to the application source files on mac? In Applications folder any .app file can be explored and there get access to the header files, is it all or can the class files be accessed too?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

幸福还没到 2024-12-25 14:04:25

除非 Mac 应用程序包含私有框架(在应用程序包中),其中包含其标头(很少见),否则不会。

大多数时候,Mac 应用程序仅包含应用程序的二进制文件以及资源(图标、图像、L10N 等)。

如果您知道如何处理汇编语言,则可以反汇编二进制文件。

如果应用程序是使用 Objective-C 构建的,则可以使用特定工具从二进制文件生成包含所有 Objective-C 接口的头文件。

例如,看看 ClassDump

您还可以在应用程序的二进制文件上使用 nm 命令来获取其包含的符号列表。

Unless a Mac application includes private frameworks (in the application bundle), which includes their headers (rare), no.

Most of the time, a Mac application will just contain the application's binary, as well as resources (icons, images, L10N, etc.).

You may disassemble the binary, if you know how to deal with assembly language.

If the application was built with Objective-C, you can use specific tools to produce a header file from the binary, with all the Objective-C interfaces.

Take a look at ClassDump, for instance.

You may also use the nm command, on the application's binary, to get a list of the symbols it contains.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文