歡迎您光臨本站 註冊首頁

Linux下安裝WINE支持漢字教程

←手機掃碼閱讀     火星人 @ 2014-03-09 , reply:0

  因為我們學校的校園網是通過在本機運行一個客戶端來上網的,我在linux下上網必須使這個軟體能夠運行,才能上咱linuxsir,於是我就想著怎麼來安裝一個最新版的wine來讓它支持漢字.
  
  下面是我的安裝步驟:
  
  安裝前的準備
  
  把原先的wine卸載掉.rh7.3有wine和wine-devel兩個文件,先卸載掉第二個,然後再卸載第一個,如果你更好的想玩遊戲,把OPENGL也升級一下,freetype不用升級了,rh7.3自帶的就可以滿足漢字的支持了
  
  把你的C盤掛接在linux下
  
  建立目錄來掛接
  
  c盤
  mkdir /winc
  
  掛接C盤
  mount /dev/hda1 /winc
  
  下載wine的最新版到/wind
  http://www.winehq.com上邊有它的最新版
  wine-20020804.tar.gz
  
  以普通用戶登錄linux,把wine-20020804.tar.gz拷貝到/tmp目錄下
  
  進入/tmp目錄
  shell>cd /tmp
  
  解壓wine
  shell>tar vfzx wine-20020804.tar.gz
  
  進入解壓后的目錄
  shell>cd wine-20020804
  
  用wine的安裝工具進行安裝
  shell>./tools/wineinstall
  
  然後就是漫長的等待,
  
  在安裝過程中它要你回答yes/no,你選擇yes就可以了
  
  wine自動搜索windows的目錄的,等你你編譯完了,它要讓你輸入root的密碼進入安裝
  
  這是就快安裝完了,如果安裝成功,就會有good lucky的提示
  
  在shell下運行wine,第一次運行不成攻,這是正常,因為沒有在/root/.wine/config文件里配置好.找到這些把
  [Drive C]
  "Path" = "/usr/share/win_c"
  "Type" = "hd"
  "Label" = "MS-DOS"
  "Filesystem" = "win95"
  改為:[Drive C]
  "Path" = "/winc"
  "Type" = "hd"
  "Label" = "MS-DOS"
  "Filesystem" = "win95"
  
  就可以了,如果你安裝了simsun字體.wine默認就會找到這個字體的下邊就是我的/root/.wine/config
  WINE REGISTRY Version 2
  ;; All keys relative to \Machine\Software\Wine\Wine\Config
  
  ;;
  ;; MS-DOS drives configuration
  ;;
  ;; Each section has the following format:
  ;; [Drive X]
  ;; "Path"="xxx" (Unix path for drive root)
  ;; "Type"="xxx" (supported types are 'floppy', 'hd', 'cdrom' and 'network')
  ;; "Label"="xxx" (drive label, at most 11 characters)
  ;; "Serial"="xxx" (serial number, 8 characters hexadecimal number)
  ;; "Filesystem"="xxx" (supported types are 'msdos'/'dos'/'fat', 'win95'/'vfat', 'unix')
  ;; This is the FS Wine is supposed to emulate on a certain
  ;; directory structure.


  ;; Recommended:
  ;; - "win95" for ext2fs, VFAT and FAT32
  ;; - "msdos" for FAT16 (ugly, upgrading to VFAT driver strongly recommended)
  ;; DON'T use "unix" unless you intend to port programs using Winelib !
  ;; "Device"="/dev/xx" (only if you want to allow raw device access)
  ;;
  [Drive A]
  "Path" = "/mnt/floppy"
  "Type" = "floppy"
  "Label" = "Floppy"
  "Serial" = "87654321"
  "Device" = "/dev/fd0"
  
  [Drive C]
  "Path" = "/winc"
  "Type" = "hd"
  "Label" = "MS-DOS"
  "Filesystem" = "win95"
  
  [Drive D]
  "Path" = "/mnt/cdrom"
  "Type" = "cdrom"
  "Label" = "CD-Rom"
  "Filesystem" = "win95"
  ; make sure that device is correct and has proper permissions !
  "Device" = "/dev/cdrom"
  
  [Drive E]
  "Path" = "/tmp"
  "Type" = "hd"
  "Label" = "Tmp Drive"
  "Filesystem" = "win95"
  
  [Drive F]
  "Path" = "${HOME}"
  "Type" = "network"
  "Label" = "Home"
  "Filesystem" = "win95"
  
  [Drive Z]
  "Path" = "/"
  "Type" = "network"
  "Label" = "Root"
  "Filesystem" = "win95"
  
  [wine]
  "Windows" = "c:\windows"
  "System" = "c:\windows\system"
  "Temp" = "e:\"
  "Path" = "c:\windows;c:\windows\system;e:\;e:\test;f:\"
  "Profile" = "c:\windows\Profiles\Administrator"
  "GraphicsDriver" = "x11drv"
  ; Wine doesn't pass directory symlinks to Windows programs by default.
  ; Enabling this may crash some programs that do recursive lookups of a whole
  ; subdir tree in case of a symlink pointing back to itself.
  ;"ShowDirSymlinks" = "1"
  "ShellLinker" = "wineshelllink"
  
  # <wineconf>
  
  [DllDefaults]
  ; "EXTRA_LD_LIBRARY_PATH" = "${HOME}/wine/cvs/lib"
  "DefaultLoadOrder" = "native, builtin, so"
  
  [DllOverrides]
  "commdlg" = "builtin, native"
  "comdlg32" = "builtin, native"
  "ver" = "builtin, native"
  "version" = "builtin, native"
  "shell" = "builtin, native"
  "shell32" = "builtin, native"
  "lzexpand" = "builtin, native"
  "lz32" = "builtin, native"
  "comctl32" = "builtin, native"
  "commctrl" = "builtin, native"
  "wsock32" = "builtin"
  "winsock" = "builtin"
  "advapi32" = "builtin, native"
  "crtdll" = "builtin, native"
  "mpr" = "builtin, native"
  "winspool.drv" = "builtin, native"
  "ddraw" = "builtin, native"


  "dinput" = "builtin, native"
  "dsound" = "builtin, native"
  "mmsystem" = "builtin"
  "winmm" = "builtin"
  "msvcrt" = "native, builtin"
  "msvideo" = "builtin, native"
  "msvfw32" = "builtin, native"
  "mcicda.drv" = "builtin, native"
  "mciseq.drv" = "builtin, native"
  "mciwave.drv" = "builtin, native"
  "mciavi.drv" = "native, builtin"
  "mcianim.drv" = "native, builtin"
  "msacm.drv" = "builtin, native"
  "msacm" = "builtin, native"
  "msacm32" = "builtin, native"
  "midimap.drv" = "builtin, native"
  "wnaspi32" = "builtin"
  "icmp" = "builtin"
  
  [x11drv]
  ; Number of colors to allocate from the system palette
  "AllocSystemColors" = "100"
  ; Use a private color map
  "PrivateColorMap" = "N"
  ; Favor correctness over speed in some graphics operations
  "PerfectGraphics" = "N"
  ; Color depth to use on multi-depth screens
  ;;"ScreenDepth" = "16"
  ; Name of X11 display to use
  ;;"Display" = ":0.0"
  ; Allow the window manager to manage created windows
  "Managed" = "N"
  ; Use a desktop window of 640x480 for Wine
  ;"Desktop" = "640x480"
  ; Use XFree86 DGA extension if present
  "UseDGA" = "Y"
  ; Use XShm extension if present
  "UseXShm" = "Y"
  ; Enable DirectX mouse grab
  "DXGrab" = "N"
  ; Create the desktop window with a double-buffered visual
  ; (useful to play OpenGL games)
  "DesktopDoubleBuffered" = "N"
  ; Code page used for captions in managed mode
  ; 0 means default ANSI code page (CP_ACP == 0)
  "TextCP" = "0"
  ; Use this if you have more than one port for video on your setup
  ; (Wine uses for now the first 'input image' it finds).
  ;; "XVideoPort" = "43"
  
  [fonts]
  ;Read documentation/fonts before adding aliases
  "Resolution" = "96"
  "Default" = "-misc-simsun-"
  
  [serialports]
  "Com1" = "/dev/ttyS0"
  "Com2" = "/dev/ttyS1"
  "Com3" = "/dev/ttyS2"
  "Com4" = "/dev/modem"
  
  [parallelports]
  "Lpt1" = "/dev/lp0"
  
  [spooler]
  "LPT1:" = "|lpr"
  ;"LPT2:" = "|gs -sDEVICE=bj200 -sOutputFile=/tmp/fred -q -"
  ;"LPT3:" = "/dev/lp3"
  
  [ports]
  ;"read" = "0x779,0x379,0x280-0x2a0"
  ; "write" = "0x779,0x379,0x280-0x2a0"
  
  [spy]
  "Exclude" = "WM_SIZE;WM_TIMER;"
  
  [registry]
  ;These are all booleans. Y/y/T/t/1 are true, N/n/F/f/0 are false.
  ;Defaults are read all, write to Home


  ; Global registries (stored in /etc)
  "LoadGlobalRegistryFiles" = "Y"
  ; Home registries (stored in ~user/.wine/)
  "LoadHomeRegistryFiles" = "Y"
  ; Load Windows registries from the Windows directory
  "LoadWindowsRegistryFiles" = "Y"
  ; TRY to write all changes to home registries
  "WritetoHomeRegistryFiles" = "Y"
  ; Registry periodic save timeout in seconds
  ; "PeriodicSave" = "600"
  ; Save only modified keys
  "SaveOnlyUpdatedKeys" = "Y"
  
  [Tweak.Layout]
  ;; supported styles are 'Win31'(default), 'Win95', 'Win98'
  "WineLook" = "Win98"
  
  [Console]
  ;"Drivers" = "tty"
  ;"XtermProg" = "nxterm"
  ;"InitialRows" = "25"
  ;"InitialColumns" = "80"
  ;"TerminalType" = "nxterm"
  
  [Clipboard]
  "ClearAllSelections" = "0"
  "PersistentSelection" = "1"
  
  # </wineconf>
  附圖:
  http://home.yctc.edu.cn/netclass/wine.png


[火星人 ] Linux下安裝WINE支持漢字教程已經有698次圍觀

http://coctec.com/docs/linux/show-post-56327.html