静态库拥有大尺寸 [英] static library has big size

查看:235
本文介绍了静态库拥有大尺寸的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我建立通用的静态库的帮助,这模板

I built universal static library with help of this template

这是我的图书馆libWrapper.a问题有大小1.3 MB? :0
而我的源$ C ​​$ C拥有130 KB。

The problem that is my library libWrapper.a has size 1.3 mb??? :0 while my source code has 130 kb.

我怎样才能减少我的静态库的大小?

其他奇怪的事情 -

Other strange thing -

每个lib中具有相同的大小 - 1.3 MB。我推测,通用(脂肪)库应该有更大的尺寸。

Each lib has the same size - 1.3 mb. I supposed that universal (fat) libs should have bigger size.

推荐答案

另外,还要确保你设置生成调试符号为NO在构建设置。这可以通过30%左右降低静态库的大小。

Also make sure that you set Generate Debug Symbols to NO in your build settings. This can reduce the size of your static library by about 30%.

这篇关于静态库拥有大尺寸的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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