cairo-1.14.6 static compiler msys mingw32
gtk2.x 静态编译时 需要注意的是 cairo
cairo 1.14.x 使用了 mutex , 用动态方式时 DllMain 中调用了 CAIRO_MUTEX_INITIALIZE ()
在静态编译时不能自动初始化 mutex , 所以 gtk 静态程序出现错误.
需要在 gtk_init() 中加载 CAIRO_MUTEX_INITIALIZE ();
在 gtk_quit_destroy() 中调用 CAIRO_MUTEX_FINALIZE ();
-------------------------------------------------------------------------------------------------------
build static libs
-------------------------------------------------------------------------------------------------------
export LIBFFI_CFLAGS=" -I/usr/local/lib/libffi-3.2.1/include " \
export LIBFFI_LIBS=" -lffi " \
export ZLIB_CFLAGS=-I/usr/local/include \
export ZLIB_LIBS=-lz \
export CFLAGS=" -I/usr/local/include -O2 -Wall -march=i686 -mms-bitfields -mthreads -static " \
export CPPFLAGS=" -I/usr/local/include " \
export LDFLAGS=" -L/usr/local/lib " \
export LIBS=' -lpsapi -lws2_32 -lmswsock -lpthread -lffi -lole32 -lwinmm -lshlwapi -lintl -liconv -lgdiplus -luuid -lharfbuzz -lharfbuzz-icu -lexpat -lgdi32 -lmsimg32 -lz ' # -lsupc++ ./configure --prefix=/usr/local \
--enable-static \
--disable-shared \
--disable-gtk-doc \
--enable-win32 \
--enable-win32-font cairo (version 1.14.6 [release]) will be compiled with: The following surface backends:
Image: yes (always builtin)
Recording: yes (always builtin)
Observer: yes (always builtin)
Mime: yes (always builtin)
Tee: no (disabled, use --enable-tee to enable)
XML: no (disabled, use --enable-xml to enable)
Skia: no (disabled, use --enable-skia to enable)
Xlib: no (requires X development libraries)
Xlib Xrender: no (requires --enable-xlib)
Qt: no (disabled, use --enable-qt to enable)
Quartz: no (requires CoreGraphics framework)
Quartz-image: no (disabled, use --enable-quartz-image to enable)
XCB: no (requires xcb >= 1.6 xcb-render >= 1.6 http://xcb.freedesktop.org)
Win32: yes
OS2: no (disabled, use --enable-os2 to enable)
CairoScript: yes
PostScript: yes
PDF: yes
SVG: yes
OpenGL: no (disabled, use --enable-gl to enable)
OpenGL ES 2.0: no (disabled, use --enable-glesv2 to enable)
BeOS: no (disabled, use --enable-beos to enable)
DirectFB: no (disabled, use --enable-directfb to enable)
OpenVG: no (disabled, use --enable-vg to enable)
DRM: no (disabled, use --enable-drm to enable)
Cogl: no (disabled, use --enable-cogl to enable) The following font backends:
User: yes (always builtin)
FreeType: yes
Fontconfig: yes
Win32: yes
Quartz: no (requires CoreGraphics framework) The following functions:
PNG functions: yes
GLX functions: no (not required by any backend)
WGL functions: no (not required by any backend)
EGL functions: no (not required by any backend)
X11-xcb functions: no (disabled, use --enable-xlib-xcb to enable)
XCB-shm functions: no (requires --enable-xcb) The following features and utilities:
cairo-trace: no (requires dynamic linker and zlib and real pthreads)
cairo-script-interpreter: yes And the following internal features:
pthread: yes
gtk-doc: no
gcov support: no
symbol-lookup: no (requires bfd)
test surfaces: no (disabled, use --enable-test-surfaces to enable)
ps testing: no (requires libspectre)
pdf testing: no (requires poppler-glib >= 0.17.4)
svg testing: no (requires librsvg-2.0 >= 2.35.0)
win32 printing testing: no (requires ghostscript) ----------------------------------------------------------------------------------
src/win32/cairo-win32-system.c
----------------------------------------------------------------------------------
/*
BOOL WINAPI
DllMain (HINSTANCE hinstDLL,
DWORD fdwReason,
LPVOID lpvReserved); BOOL WINAPI
DllMain (HINSTANCE hinstDLL,
DWORD fdwReason,
LPVOID lpvReserved)
{
switch (fdwReason) {
case DLL_PROCESS_ATTACH:
CAIRO_MUTEX_INITIALIZE ();
break; case DLL_PROCESS_DETACH:
CAIRO_MUTEX_FINALIZE ();
break;
} return TRUE;
} */
----------------------------------------------------------------------------------
__declspec(dllexport) fix to --> __attribute__((visibility ("default")))
define xxx __declspec(dllimport) fix to --> define xxx extern
__attribute__((visibility ("hidden"))) fix to --> __attribute__((visibility ("default")))
delete all DllMain function src\cairoint.h(54):#define cairo_public __declspec(dllexport)
#define cairo_public __declspec(dllexport) -> __attribute__((visibility ("default"))) src\cairo.h(55):# define cairo_public __declspec(dllimport)
#define cairo_public __declspec(dllimport) -> extern src\cairo-compiler-private.h(120):#define cairo_private_no_warn __attribute__((__visibility__("hidden")))
#define cairo_private_no_warn __attribute__((__visibility__("hidden"))) -> ("default") util\cairo-script\cairo-script-private.h(165):#define csi_private_no_warn __attribute__((__visibility__("hidden")))
#define csi_private_no_warn __attribute__((__visibility__("hidden"))) -> ("default") ----------------------------------------------------------------------------------
src/cairo.h
----------------------------------------------------------------------------------
cairo_public void cairo_mutex_init();
cairo_public void cairo_mutex_finalize();
---------------------------------------------------------------------------------- ----------------------------------------------------------------------------------
src/cairo.c
----------------------------------------------------------------------------------
void cairo_mutex_init()
{
CAIRO_MUTEX_INITIALIZE ();
} void cairo_mutex_finalize()
{
CAIRO_MUTEX_FINALIZE ();
}
----------------------------------------------------------------------------------
链接:http://pan.baidu.com/s/1hrXKrBY 密码:fxh0
cairo-1.14.6 static compiler msys mingw32的更多相关文章
- GNU Wget 1.19.1 static built on mingw32
http://pan.baidu.com/s/1sluFAVj #wget --version GNU Wget 1.19.1 built on mingw32. -cares +digest -gp ...
- gtk+-3.21.4 static build step in windows XP
In recent days the weather is very hot Unable to sleep properly Under the state of daze research gtk ...
- 开源项目:windows下使用MinGW+msys编译ffmpeg
本文参考了网络上的不少文章,但由于版本环境的问题参考文章并不能直接指导编译,本文吸收多方经验,并在自己多次编译实验的基础上写成,欢迎转载,请注名出处. FFmpeg是在Linux平台下开发的,但 ...
- windows 下使用 MinGW + msys 编译 ffmpeg
本文参考了网络上的不少文章,但由于版本环境的问题参考文章并不能直接指导编译,本文吸收多方经验,并在自己多次编译实验的基础上写成,欢迎转载,请注名出处. FFmpeg是在Linux平台下开发的,但 ...
- Thrift compiler代码生成类解析
代码生成类解析: Thrift--facebook RPC框架,介绍就不说了,百度,google一大把,使用也不介绍,直接上结构和分析吧. Hello.thrift文件内容如下: namespace ...
- [C#6] 1-using static
0. 目录 C#6 新增特性目录 1. 老版本的代码 1 using System; 2 3 namespace csharp6 4 { 5 internal class Program 6 { 7 ...
- static详解
static关键字用来修饰属性.方法,称这些属性.方法为静态属性.静态方法. static关键字声明一个属性或方法是和类相关的,而不是和类的某个特定的实例相关,因此,这类属性或方法也称为“类属性”或“ ...
- PHP面向对象之旅:static变量与方法
static关键字声明一个属性或方法是和类相关的,而不是和类的某个特定的实例相关,因此,这类属性或方法也称为“类属性”或“类方法”. 如果访问控制权限允许,可不必创建该类对象而直接使用类名加两个冒号“ ...
- 解决libc.so.6: version `GLIBC_2.14' not found问题, 升级glibc,glibc-2.15
0.以下在系统CentOS 6.3 x86_64上操作 1.试图运行程序,提示"libc.so.6: version `GLIBC_2.14' not found",原因是系统的g ...
随机推荐
- 新浪微博客户端(35)-使用NSMutableAttributedString实现多行文本的效果
DJComposeViewController.m import "DJComposeViewController.h" #import "DJAccountTool.h ...
- realloc,malloc,calloc函数的区别
from:http://www.cnblogs.com/BlueTzar/articles/1136549.html realloc,malloc,calloc的区别 三个函数的申明分别是: void ...
- jquery mobile常用的data-role类型 data-icon data-iconpos
文章链接: http://blog.csdn.net/cainiaoxiaozhou/article/details/48521241
- nginx同一iP多域名配置方法
文章转自:http://blog.itblood.com/nginx-same-ip-multi-domain-configuration.html 下面的是我本机的配置: server { list ...
- 为什么构造器不能是abstract, static, final, native or synchronized的?
Unlike methods, a constructor cannot be abstract, static, final, native or synchronized. 1. A const ...
- Memcached存储命令 - replace
Memcached replace 命令用于替换已存在的 key(键) 的 value(数据值). 如果 key 不存在,则替换失败,并且您将获得响应 NOT_STORED. replace 命令的基 ...
- HTML5+学习笔记1-------边看代码边研究中
document.addEventListener('touchstart',function(){ return false; },true); touchstart当手指触摸屏幕时候触发,即使已经 ...
- 2015年12月01日 GitHub入门学习(二)手把手教你Git安装
序:Mac与Linux中,Mac都预装了Git,各版本的Linux也都提供了Git的软件包.下面手把手教你Windows下的安装. 一.Git Windows GUI 下载地址 msysgit htt ...
- 一张图告诉你,只会CSS还不够!
会了CSS语法.会了CSS选择器,你就真的会了CSS吗,来看这张图!是超实用的CSS代码段的导览!熊孩子们,赶紧学习去吧! 这是一个Web开发最好的时代,每天都有30000条职位信息,面向互联网,我们 ...
- myeclipse的项目导入到eclipse下,com.sun.org.apache.commons.beanutils.BeanUtils不能导入
com.sun.org.apache.commons.beanutils.BeanUtils这个包不能引入了怎么办自己下了个org.apache.commons的jar包了之后,改成import or ...