📄 939-942.html
字号:
<HTML>
<HEAD>
<TITLE>Linux Unleashed, Third Edition:The Wine Project</TITLE>
<SCRIPT>
<!--
function displayWindow(url, width, height) {
var Win = window.open(url,"displayWindow",'width=' + width +
',height=' + height + ',resizable=1,scrollbars=yes');
}
//-->
</SCRIPT>
</HEAD>
-->
<!--ISBN=0672313723//-->
<!--TITLE=Linux Unleashed, Third Edition//-->
<!--AUTHOR=Tim Parker//-->
<!--PUBLISHER=Macmillan Computer Publishing//-->
<!--IMPRINT=Sams//-->
<!--CHAPTER=59//-->
<!--PAGES=939-942//-->
<!--UNASSIGNED1//-->
<!--UNASSIGNED2//-->
<CENTER>
<TABLE BORDER>
<TR>
<TD><A HREF="../ch58/935-938.html">Previous</A></TD>
<TD><A HREF="../ewtoc.html">Table of Contents</A></TD>
<TD><A HREF="942-945.html">Next</A></TD>
</TR>
</TABLE>
</CENTER>
<P><BR></P>
<H2><A NAME="Heading1"></A><FONT COLOR="#000077">Chapter 59<BR>The Wine Project
</FONT></H2>
<P><I>by Robert Pfister</I></P>
<DL>
<DT><B>In This Chapter</B>
<DT>• Current status of Wine
<DT>• Setting up Wine
<DT>• Using Wine
<DT>• How Wine works
<DT>• Where does Wine end and MS-Windows begin?
<DT>• Limitations of Wine
</DL>
<P><I>Wine</I> stands for Windows Emulator. It enables MS-Windows programs to run under a UNIX X Window environment. Like DOSemu, Wine takes direct advantage of the Intel 386 architecture to actually run the MS-Windows application. Wine simply translates any MS-Windows API calls into appropriate UNIX and X Window calls. Like OS/2, MS-Windows programs running under Wine can take advantage of features of the underlying operating system. Wine is simply another user-mode Linux process that is protected from corruption by other processes. This is dubbed <I>crash-protection</I> under OS/2. Because Linux uses preemptive multitasking, Wine processes can coexist with other processes without some of the problems experienced by applications running under native MS-Windows.</P>
<H3><A NAME="Heading2"></A><FONT COLOR="#000077">Current Status of Wine</FONT></H3>
<P>As with most of the Linux community, developers of Wine are volunteers. Wine is currently Alpha or pre-release code. Only a few of the simplest MS-Windows applications run without incident. My favorite MS-Windows Entertainment Pack game, Pipe Dream by Lucas Arts, runs acceptably under Wine.
</P>
<P>Although Pipe Dream and other simple games are certainly playable under Wine, everything is not perfect. Some speed degradation is noticeable, as is the occasional screen glitch.</P>
<P>Sun Soft has implemented a similar product to Wine, called WABI, for its UNIX-based workstations. WABI has been on the market since 1994 and supports some of the more complex Windows 3.11 applications such as Microsoft Excel and Lotus Smart Suite. However, WABI cannot run Windows 95 applications. Given enough development time, it is reasonable to expect that Wine will be capable of running general MS-Windows applications as well.</P>
<H3><A NAME="Heading3"></A><FONT COLOR="#000077">Setting Up Wine</FONT></H3>
<P>Wine is available only as source code. If you have the prerequisite software and a little patience, setting up Wine is not very difficult—even if you are not a programmer.
</P>
<H4 ALIGN="LEFT"><A NAME="Heading4"></A><FONT COLOR="#000077">System Requirements</FONT></H4>
<P>Any Linux machine suitable for running X Window can run Wine applications at a reasonable speed. In theory, Wine should have some advantages running under Linux as opposed to under MS-Windows, which is confined to the MS-DOS environment. Experiences with current versions of Wine show that an application running under Wine is slower on the same machine running MS-DOS and MS-Windows.
</P>
<P>To make full use of Wine, you need MS-Windows 3.1 installed on a disk partition that is accessible under Linux. It is also convenient to run existing MS-Windows applications from the same directory in which they are installed under native MS-DOS and MS-Windows. The typical Linux user also has MS-DOS and MS-Windows installed on a hard drive; thus it is only a matter of making the directories available under Linux. Linux kernels as of Version 1.1.83 do not support compressed MS-DOS file systems made by MS-DOS utilities such as <TT>stacker</TT> and <TT>drvspace</TT>.</P>
<BLOCKQUOTE>
<P><FONT SIZE="-1"><HR><B>Tip: </B><BR>Some Linux installation programs will prompt you through setting up an MS-DOS partition as a Linux subdirectory. If you do not set up such a partition, add the following line to your <TT>/etc/fstab:</TT>
<!-- CODE SNIP //-->
<PRE>
/dev/hda1 /c MSDOS defaults
</PRE>
<!-- END CODE SNIP //-->
<P><TT>hda1</TT> is the partition that contains MS-DOS and <TT>/c</TT> is the Linux subdirectory to use. In this example it is assumed that the <TT>/c</TT> subdirectory exists. Otherwise, use <TT>mkdir</TT> to create the subdirectory.<HR></FONT>
</BLOCKQUOTE>
</P>
<P>Wine is distributed as source code and must be compiled before use. It requires approximately 10MB of disk space. 3.5MB of that disk space is the source code alone. To build Wine, you need to have the following:</P>
<DL>
<DD><B>•</B> GCC
<DD><B>•</B> LibC
<DD><B>•</B> XFree with development parts loaded
<DD><B>•</B> Linux kernel newer than 99.13
</DL>
<H4 ALIGN="LEFT"><A NAME="Heading5"></A><FONT COLOR="#000077">Where to Get Wine Distribution</FONT></H4>
<P>A new version of Wine is released approximately once a week. Major Linux FTP sites on the Internet contain the most recent release. On <TT>sunsite.unc.edu</TT>, Wine is found in the <TT>/pub/Linux/ALPHA/Wine</TT> directory. Wine releases are named after the date they are released. Wine-950727.tar.gz was released on 7/27/95. The most current release is the one with the latest date. For more information, check out the Web page at <A HREF="http://daedalus.dra.hmg.gb/gale/wine/wine.html.">http://daedalus.dra.hmg.gb/gale/wine/wine.html.</A></P>
<H4 ALIGN="LEFT"><A NAME="Heading6"></A><FONT COLOR="#000077">How to Install Wine</FONT></H4>
<P>Unlike DOSemu, the Wine distribution is not sensitive to where it is installed. For brevity, make a symbolic link from the actual directory (say, <TT>/usr/src/Wine950122</TT>) to <TT>/usr/wine</TT> using the <TT>ln</TT> command as follows:</P>
<!-- CODE SNIP //-->
<PRE>
bash# ln -s /usr/src/Wine950122 /usr/wine
</PRE>
<!-- END CODE SNIP //-->
<P>A Wine distribution consists of a compressed <TT>tar</TT> file. To unpack the distribution, use a shell command such as</P>
<!-- CODE SNIP //-->
<PRE>
bash# tar -zxvf filename.tar.gz
</PRE>
<!-- END CODE SNIP //-->
<P><BR></P>
<CENTER>
<TABLE BORDER>
<TR>
<TD><A HREF="../ch58/935-938.html">Previous</A></TD>
<TD><A HREF="../ewtoc.html">Table of Contents</A></TD>
<TD><A HREF="942-945.html">Next</A></TD>
</TR>
</TABLE>
</CENTER>
</td>
</tr>
</table>
<!-- begin footer information -->
</body></html>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -