另許多Linuxer期待的Wine 3.0 RC1 已經釋出了,這是即将釋出的Wine 3的候選版本。它标志着代碼當機期的開始。請大家給這個版本一個很好的測試,以使Wine 3.0盡可能做的更好。
Wine (“Wine Is Not an Emulator” 的遞歸縮寫)是一個能夠在多種 POSIX-compliant 作業系統(諸如 Linux,Mac OSX 及 BSD 等)上運作 Windows 應用的相容層。另外英語單詞wine是葡萄酒的意思。
這個版本有什麼新的變化?:
Direct3D 11在AMD和Intel GPU上預設啟用。
支援macOS的AES加密。
任務排程器的實作。
reg.exe工具中的系統資料庫導出支援。
Progman DDE支援。
OLE資料緩存改進。
MSHTML中的更多事件支援。
中繼調試改進。
各種錯誤修複。
該源現在可用。 二進制軟體包正在建構過程中,應該很快會好。
下面詳細講解在Ubuntu 17.10下編譯安裝 Wine 3.0 RC1 的過程步驟及問題解決。
首先安裝依賴的庫:
sudo apt-get install flex bison qt4-qmake

sudo apt-get install libfreetype6-dev
sudo apt-get install libjpeg-dev libpng-dev libxslt-dev libxml2-dev
sudo apt-get install libxrender-dev
sudo apt-get install libgl1-mesa-dev
sudo apt-get install libglu1-mesa-dev
sudo apt-get install freeglut3-dev
sudo apt-get install prelink
sudo apt-get install libasound2-dev
到官網下載下傳最新的源代碼:
下載下傳之後解壓,我把wine-3.0-rc1.tar.xz源代碼解壓到目前使用者目錄下,進入目錄:
tar jxvf wine-3.0-rc1.tar.xz
cd wine-3.0-rc1
./configure --enable-win64
[email protected]:~/桌面/Linuxidc.com/wine-3.0-rc1$ ./configure --enable-win64
checking build system type... x86_64-pc-linux-gnu
checking host system type... x86_64-pc-linux-gnu
checking whether make sets $(MAKE)... yes
checking for gcc... gcc
checking whether the C compiler works... yes
checking for C compiler default output file name... a.out
checking for suffix of executables...
checking whether we are cross compiling... no
checking for suffix of object files... o
checking whether we are using the GNU C compiler... yes
checking whether gcc accepts -g... yes
checking for gcc option to accept ISO C89... none needed
checking for g++... g++
checking whether we are using the GNU C++ compiler... yes
checking whether g++ accepts -g... yes
checking for cpp... cpp
checking for ld... ld
......
configure: OSS sound system found but too old (OSSv4 needed), OSS won't be supported.
configure: libudev 64-bit development files not found, plug and play won't be supported.
configure: libcapi20 64-bit development files not found, ISDN won't be supported.
configure: libcups 64-bit development files not found, CUPS won't be supported.
configure: fontconfig 64-bit development files not found, fontconfig won't be supported.
configure: libgsm 64-bit development files not found, gsm 06.10 codec won't be supported.
configure: libkrb5 64-bit development files not found, Kerberos won't be supported.
configure: libtiff 64-bit development files not found, TIFF won't be supported.
configure: libmpg123 64-bit development files not found (or too old), mp3 codec won't be supported.
configure: libopenal 64-bit development files not found (or too old), OpenAL won't be supported.
configure: openal-soft 64-bit development files not found (or too old), XAudio2 won't be supported.
configure: libldap (OpenLDAP) 64-bit development files not found, LDAP won't be supported.
configure: WARNING: libgnutls 64-bit development files not found, no schannel support.
configure: Finished. Do 'make' to compile Wine.
[email protected]:~/桌面/Linuxidc.com/wine-3.0-rc1$
--------------------------------------分割線 --------------------------------------
然後開始編譯了,編譯和安裝的過程很簡單。
直接運作make編譯,等等等吧,可以喝杯咖啡。一個多小時編譯完成。
然後運作
sudo make install
會自動編譯Wine 3.0 RC1并安裝程式
運作指令檢查Wine版本:
wine64 --version
wine-3.0-rc1
然後建立一個wine連結,否則很多程式不能用, 比如winecfg。
sudo ln -s /usr/local/bin/wine64 /usr/local/bin/wine
安裝好之後的相關配置
首先要添加wine的執行檔案目錄到PATH環境變量,也可以不添加如果不想修改環境變量,可以使用下面的方式。
在啟動.exe程式的時候先export導入路徑到環境變量。這個可以寫在腳本裡面來啟動。
運作winecfg程式來設定相關的參數,建議標明Windows版本為Windows 7。
其他的相關參數,根據自己的習慣愛好來標明吧。
終端運作winecfg
如下圖:
如上圖,winecfg運作的時候,視窗上的文字都是 ||(||!) 這些,那麼要做下一步中文支援。
首先複制Windows下的simsun.ttc字型到~/.wine/drive-c/windows/fonts/目錄下。
sudo cp simsun.ttc ~/.wine/drive_c/windows/Fonts/
然後建立一個zh.reg檔案,然後打開它,輸入以下内容。然後回答指令行,使用regedit zh.reg來導入到系統資料庫。
REGEDIT4
[HKEY_LOCAL_MACHINE\Software\Microsoft\Windows NT\CurrentVersion\FontSubstitutes]
"Arial"="simsun"
"Arial CE,238"="simsun"
"Arial CYR,204"="simsun"
"Arial Greek,161"="simsun"
"Arial TUR,162"="simsun"
"Courier New"="simsun"
"Courier New CE,238"="simsun"
"Courier New CYR,204"="simsun"
"Courier New Greek,161"="simsun"
"Courier New TUR,162"="simsun"
"FixedSys"="simsun"
"Helv"="simsun"
"Helvetica"="simsun"
"MS Sans Serif"="simsun"
"MS Shell Dlg"="simsun"
"MS Shell Dlg 2"="simsun"
"System"="simsun"
"Tahoma"="simsun"
"Times"="simsun"
"Times New Roman CE,238"="simsun"
"Times New Roman CYR,204"="simsun"
"Times New Roman Greek,161"="simsun"
"Times New Roman TUR,162"="simsun"
"Tms Rmn"="simsun"
現在再運作winecfg看看,如下圖: