1 .\" $NetBSD: compat_pecoff.8,v 1.12 2005/06/20 13:25:25 peter Exp $
3 .\" Copyright (c) 2000 The PEACE Project.
4 .\" All rights reserved.
6 .\" Redistribution and use in source and binary forms, with or without
7 .\" modification, are permitted provided that the following conditions
9 .\" 1. Redistributions of source code must retain the above copyright
10 .\" notice, this list of conditions and the following disclaimer.
11 .\" 2. Redistributions in binary form must reproduce the above copyright
12 .\" notice, this list of conditions and the following disclaimer in the
13 .\" documentation and/or other materials provided with the distribution.
14 .\" 3. The name of the author may not be used to endorse or promote products
15 .\" derived from this software without specific prior written permission.
17 .\" THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
18 .\" IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
19 .\" OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
20 .\" IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
21 .\" INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
22 .\" NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
23 .\" DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
24 .\" THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
25 .\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
26 .\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
33 .Nd setup procedure for running Win32 applications (a.k.a. PEACE)
36 has partial support for running
39 This manual page describes how to run
43 in the future) applications on
45 Note that PE (Portable Executable) is a Microsoft extension to the
47 executable file format.
48 .Sh BRIEF INTRODUCTION TO THE WIN32 API
51 API is an application program interface (API) for 32-bit
52 applications for Microsoft Windows 9x/Me/NT/2000. The
55 via a set of core DLLs (Dynamically Linked Libraries), including
61 The structure of these core DLLs and the interface between the
62 operating system kernel and userland is implementation-dependent.
63 Each implementation must provide its own core DLLs.
64 Therefore, these DLLs are different for
72 applications; it provides basic
73 kernel interface such as file access, process control, memory management etc.
78 applications; it provides basic
79 userland functions such as GUI and messaging.
82 provides functions to draw images and characters.
85 is the Windows shell support, including file association.
90 are GUI components which are commonly used in many applications.
92 provides the networking API.
100 Most other DLLs are compatible among all the implementations and
101 therefore can be shared.
102 .Sh NETBSD SUPPORT FOR THE WIN32 API
106 applications is developed by the PEACE Project, and is
107 under active development.
108 Currently it can run some console applications including the
111 as well as a small number of GUI applications.
113 The PEACE system consists of three parts: the kernel part, the dynamic
114 loader and the core DLLs.
116 The kernel part provides loading and executing
118 format executable binaries; i.e. it extends the
120 system call, just like other binary compatibility options.
121 It is activated by enabling the
125 The dynamic loader is the
129 It reads the file header of the executable binary, and
132 The core DLLs implement the actual
134 API functions as described in the
135 previous section. Since the kernel part does not provide
136 any additional system calls and other kernel interface,
139 API functions are implemented on top of the existing
141 APIs (system calls and standard libraries such as
145 .Sh PREPARING THE PEACE DYNAMIC LOADER AND CORE DLLS
146 Development snapshots of the dynamic loader can be retrieved from
147 .Pa http://sourceforge.net/project/showfiles.php?group_id=21711 .
148 The file name of snapshot is
149 .Pa peace-i386-ld.so.dll-*.gz ,
150 where `*' is replaced with the snapshot date.
153 the file and copy the resulting file to
154 .Pa /usr/libexec/ld.so.dll .
156 The core DLLs archives can also be retrieved from
157 .Pa http://sourceforge.net/project/showfiles.php?group_id=21711
159 .Pa peace-i386-sysdll-*.tgz
161 .Pa peace-i386-dll-*.tgz .
162 The dynamic loader searches for required DLLs from the following directories:
165 directories listed in the environment variable
167 (separated by colons)
171 the directory where the executable is located
173 The core DLLs are required to be installed into
179 application) as the login shell.
181 According to the development phase, some other PEACE-specific DLLs
182 might be distributed separately. Please check the announcements
183 on the Web or the mailing list.
185 Other DLLs can be stored in arbitrary directories specified by the
189 .Tn "Windows NT/2000"
190 DLLs installed on a separate partition of the local disk directly
194 .Bd -literal -compact -offset indent
195 mount -t ntfs -o ro /dev/wd0h /nthd
196 setenv DLLPATH /nthd/WINNT/SYSTEM32:/nthd/WINNT
208 .Pa http://chiharu.hauN.org/peace/
217 binary compatibility support for
219 was started by Masaru OKI.
220 The PEACE Project is founded by him to implement the enormous number
227 Currently only the i386 platform is supported.
233 The dynamic loader and core DLLs are not provided in the standard
236 This is because a cross-compiler is required to build them.