chromium thirt_party skia编译shared_liberary
来源:互联网 发布:服装新零售软件 编辑:程序博客网 时间:2024/06/11 19:08
默认情况下,Android4.4 chromium webview使用的skia是系统的skia
'conditions': [ # In component mode (shared_lib), we build all of skia as a single DLL. # However, in the static mode, we need to build skia as multiple targets # in order to support the use case where a platform (e.g. Android) may # already have a copy of skia as a system library. ['component=="static_library" and use_system_skia==0', { 'targets': [ { 'target_name': 'skia_library', 'type': 'static_library', 'includes': [ 'skia_library.gypi', 'skia_common.gypi', ], }, ], }], ['component=="static_library" and use_system_skia==1', { 'targets': [ { 'target_name': 'skia_library', 'type': 'none', 'includes': ['skia_system.gypi'], }, ], }], ['component=="static_library"', { 'targets': [ { 'target_name': 'skia', 'type': 'none', 'dependencies': [ 'skia_library', 'skia_chrome', ], 'export_dependent_settings': [ 'skia_library', 'skia_chrome', ], }, { 'target_name': 'skia_chrome', 'type': 'static_library', 'includes': [ 'skia_chrome.gypi', 'skia_common.gypi', ], }, ], }, { # component != static_library 'targets': [ { 'target_name': 'skia', 'type': 'shared_library', 'includes': [ 'skia_library.gypi', 'skia_chrome.gypi', 'skia_common.gypi', ], 'defines': [ 'SKIA_DLL', 'GR_DLL=1', 'GR_IMPLEMENTATION=1', 'SKIA_IMPLEMENTATION=1', ], 'direct_dependent_settings': { 'defines': [ 'SKIA_DLL', 'GR_DLL=1', ], }, }, { 'target_name': 'skia_library', 'type': 'none', }, { 'target_name': 'skia_chrome', 'type': 'none', }, ], }], ],
变量
use_system_skia
控制是否采用系统所带的skia,但如果因为升级或者移植,skia可能版本不一样,因此不如用chromium中自带的skia.
修改build/common.gypi中代码:
'use_system_skia%': '<(android_webview_build)',
编译webview的话,默认使用系统的skia, 只要注释它 则会用thirt_party的skia.
另一个参数是component,也在build/common.gypi
'component%': 'static_library',
修改为shared_library则可。修改后,gyp之后,编译可能出现问题:
warning: shared library text segment is not shareableerror: treating warnings as errors
参考
1)http://gcc.gnu.org/onlinedocs/gcc-4.8.1/gcc/Code-Gen-Options.html#Code-Gen-Options2)http://eli.thegreenplace.net/2011/11/03/position-independent-code-pic-in-shared-libraries/
--warn-shared-textrel Warn if text segment is not shareable
--no-warn-shared-textrel Do not warn if text segment is not shareable (default)
gyp生成mk文件时,在DEBUG和Rlease中都加入了warn-shared-textrel选项。
去掉则可。
0 0
- chromium thirt_party skia编译shared_liberary
- SKIA 编译
- chromium的图形和skia(Graphics and skia)
- 史上最黑的黑科技--把chromium 的blink、v8、skia用vc6的crt编译并运行!
- unbuntu下编译skia
- skia windows 编译
- skia指定版本编译
- Chromium 编译
- chromium编译
- chromium编译
- chromium编译
- 在ubuntu上编译skia
- windows下编译skia dll
- windows环境下编译skia
- skia编译与简单例子
- skia windows下编译dll
- 在windows上编译skia
- windows环境下编译skia
- 黑马程序员————C语言_练习题解题思路分析(一)
- matlab 生成独立程序(给自己备份用)
- 基于PCA和SVM的人脸识别
- ABAP程序编写过程中怎么提高程序执行效率五
- java 共享锁和ReentrantReadWriteLock
- chromium thirt_party skia编译shared_liberary
- 背包问题第k优解
- cadence实用技巧
- 飞机票(一个神奇的脚本)
- Dll远程注入
- Intent对象(二)简介
- jQuery.noConflict()
- Android Studio 项目结构的工程的Android.mk
- 俞敏洪:三星手机与我身份不符 它必然失败