ios - how to compile and use objc runtime from apple's source code? -
as know all, objc's runtime open source , can downloaded from: http://www.opensource.apple.com/tarballs/objc4/
after download tarball extract it. open objc.xcodeproj
using xcode. however, when build it, there many erros, such as, can not find headers. googled missing headers, download them, put them in /tmp/objc.dst/usr/include
. without luck, still errors.
i searched internet, can find few documents or instructions about:
- how compile apple's objc runtime source code?
- after compile , should
libobjc.a.dylib
, how use (as replace of system's libobjc.a.dylib) ?
i appreciate can provide.
compile no error under 10.10.2(14c1514), xcode 6.2 (6c131e).
you need osx 10.8 sdk, can xcode install dmg or repository https://github.com/phracker/macosx-sdks (if download sdk repo, may need fix soft links using script http://blog.jeswang.org/blog/2014/10/26/fix-slash-soft-slash-links-slash-in-slash-an-slash-archived-slash-file/, may need run script 2 times recursion of references)
more 10.8 sdk
/applications/xcode.app/contents/developer/platforms/macosx.platform/developer/sdks
clone repository https://github.com/jeswang/objc4-532.2
compile , run debug-objc scheme
you can set breakpoint in source , debug whole runtime.
Comments
Post a Comment