iPhone 的 TAR 编码/解码库(最好是可可) [英] TAR encode/decode library for iPhone (ideally cocoa)

查看:25
本文介绍了iPhone 的 TAR 编码/解码库(最好是可可)的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

有谁知道任何能让我编码和解码 .tar 格式数据的库/代码 - 我可以在我的 iPhone 项目(最好是可可)中使用它

Does anyone know of any library/code that will enable me to encode and decode .tar formatted data - that I can use in my iPhone project (preferably cocoa)

提前致谢

克雷格

更新:我查看了建议的库并得出结论,他们正在解决大部分问题 - 所以我自己正在开发编解码器 - 毕竟它只是一个 512 字节的 ASCII 标头 - 如何难吗:-)

UPDATE: I've taken a look at the suggested libraries and come to the conclusion that they are making waaaay to much of the problem - so I'm developing the codec myself - it's only a 512byte ASCII header after all - how hard can it be :-)

推荐答案

我发现的最好的库是 libarchive.它设计精良、文档齐全且速度快.

The best library I've found is libarchive. It is well-designed, well-documented, and fast.

我刚刚在 GitHub 上创建了一个存储库,其中包含将 libarchivelibbz2 构建为 iOS 4.2+ 静态库的工具.(也应该可以用它来定位 3.x.)

I just created a repository on GitHub that has the tools to build libarchive and libbz2 as static libraries for iOS 4.2+. (It should be possible to use it to target 3.x, too.)

http://github.com/davepeck/iOS-libarchive/

其他人指出 libarchive 包含在 SDK 中.这并不完全正确.包含二进制 libarchive.2.dylib,但不包含头文件.这同样适用于 libbz2(但奇怪的是,不适用于 libz.)这意味着 libarchive 被视为私有 API —— 换句话说,如果您打算在 App Store 上发货,则不能使用它.因此我的存储库.

Others have pointed out that libarchive is included in the SDK. This is not quite true. The binary libarchive.2.dylib is included, but the headers are not. The same applies to libbz2 (but, oddly, not to libz.) This means that libarchive is considered a private API -- in other words, you can't use it if you intend to ship on the App Store. Hence my repository.

这篇关于iPhone 的 TAR 编码/解码库(最好是可可)的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆