免费注册 查看新帖 |

Chinaunix

  平台 论坛 博客 文库
最近访问板块 发新帖
查看: 901 | 回复: 0
打印 上一主题 下一主题

ubuntu下编译wine [复制链接]

论坛徽章:
1
15-16赛季CBA联赛之北控
日期:2022-03-04 22:35:50
跳转到指定楼层
1 [收藏(0)] [报告]
发表于 2008-04-13 19:56 |只看该作者 |倒序浏览

作者: Goando  出自: http://www.linuxdiyf.com
$sudo apt-get update
$sudo apt-get build-dep wine
$sudo apt-get install fakeroot libglib1.2-dev libglib2.0-dev libltdl3-dev libmad0-dev libmng-dev libodbcinstq1c2 libogg-dev libpng12-dev libqt3-headers libqt3-mt-dev libvorbis-dev libxft-dev libxi-dev libxinerama-dev libxmu-dev libxmu-headers libxmuu-dev libxpm-dev libxtrap-dev libxtst-dev libxv-dev libxxf86dga-dev qt3-dev-tools render-dev unixodbc-dev x-dev x11proto-record-dev x11proto-trap-dev x11proto-video-dev x11proto-xf86dga-dev xlibs-dev
创建一个编译Wine时所需要的目录:
$mkdir wine-src
$cd wine-src
sudo apt-get source wine
或下载Wine的源码包
地址
http://www.winehq.org/?announce=latest

解压
tar jxvf wine-0.9.59.tar.bz2
修改源代码
--- wine-20050111/dlls/gdi/freetype.c 2005-01-06 01:12:07.000000000 +0800
+++ wine-20050111.gbhack/dlls/gdi/freetype.c 2005-01-15 18:30:32.481788272 +0800
@@ -1677,7 +1677,22 @@
if(!strcmpiW(lf.lfFaceName, SymbolW))
lf.lfCharSet = SYMBOL_CHARSET;
- if(!TranslateCharsetInfo((DWORD*)(INT_PTR)lf.lfCharSet, &csi, TCI_SRCCHARSET)) {
+ if( lf.lfCharSet == DEFAULT_CHARSET || lf.lfCharSet == ANSI_CHARSET)
+ {
+ int codepage = 936; /* I'm Chinese. Let me do something selfish. */
+ char *env_wdc = getenv("WINE_DEFAULT_CODEPAGE");
+ if (env_wdc != NULL)
+ {
+ codepage = atoi(env_wdc);
+ }
+ FIXME("Dirty hack. Default and ansi charset is translated to getenv(\"WINE_DEFAULT_CODEPAGE\")\n");
+ if(!TranslateCharsetInfo((DWORD*)(INT_PTR)codepage, &csi, TCI_SRCCODEPAGE)) {
+ FIXME("OMG. Even this dirty hack doesn't work. Let's PRAY.\n");
+ csi.fs.fsCsb[0] = 0;
+ }
+ lf.lfCharSet = csi.ciCharset;
+ }
+ else if(!TranslateCharsetInfo((DWORD*)(INT_PTR)lf.lfCharSet, &csi, TCI_SRCCHARSET)) {
switch(lf.lfCharSet) {
case DEFAULT_CHARSET:
csi.fs.fsCsb[0] = 0;
@@ -1861,6 +1876,10 @@
width = face->size.x_ppem >> 6;
height = face->size.y_ppem >> 6;
}
+
+ if (0  height && height > -12) height = -12;
+
ret->ft_face = OpenFontFile(ret, face->file, face->face_index, width, height);
if (!ret->ft_face)
编译安装
cd wine-0.9.59
sudo ./configure
sudo make depend && make
编译完成以后
sudo make install

本文来自ChinaUnix博客,如果查看原文请点:http://blog.chinaunix.net/u/31/showart_529686.html
您需要登录后才可以回帖 登录 | 注册

本版积分规则 发表回复

  

北京盛拓优讯信息技术有限公司. 版权所有 京ICP备16024965号-6 北京市公安局海淀分局网监中心备案编号:11010802020122 niuxiaotong@pcpop.com 17352615567
未成年举报专区
中国互联网协会会员  联系我们:huangweiwei@itpub.net
感谢所有关心和支持过ChinaUnix的朋友们 转载本站内容请注明原作者名及出处

清除 Cookies - ChinaUnix - Archiver - WAP - TOP