xref: /netbsd-src/share/man/man8/compat_netbsd32.8 (revision e5548b402ae4c44fb816de42c7bba9581ce23ef5)
1.\"	$NetBSD: compat_netbsd32.8,v 1.6 2004/12/31 00:57:50 wiz Exp $
2.\"
3.\" Copyright (c) 2001 Matthew R. Green
4.\" All rights reserved.
5.\"
6.\" Redistribution and use in source and binary forms, with or without
7.\" modification, are permitted provided that the following conditions
8.\" are met:
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.
16.\"
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,
22.\" BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
23.\" LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED
24.\" AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
25.\" OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
26.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
27.\" SUCH DAMAGE.
28.\"
29.Dd December 28, 2004
30.Dt COMPAT_NETBSD32 8
31.Os
32.Sh NAME
33.Nm compat_netbsd32
34.Nd setup procedure for 32-bit compatibility on 64-bit platform
35.Sh DESCRIPTION
36The
37.Nm
38module allows
39.Nx Ns Tn /sparc64
40to run
41.Nx Ns Tn /sparc
42executables, and
43.Nx Ns Tn /amd64
44to run
45.Nx Ns Tn /i386
46executables.
47.Pp
48To use
49.Nm ,
50one must either have
51.Dv COMPAT_NETBSD32
52in the kernel, or load the compat_netbsd32 and exec_netbsd32 kernel
53modules.
54.Pp
55Static executables typically need no additional setup.
56Dynamic binaries require the dynamic linker plus shared libraries.
57Most of these files will need to be placed under
58.Pa /emul/netbsd32 .
59.Pp
60The easiest method of installing support for these is via the
61.Pa emulators/netbsd32_compat14 ,
62.Pa emulators/netbsd32_compat15 ,
63and
64.Pa emulators/netbsd32_compat16
65packages, provided in the
66.Nx
67packages collection.
68These install 32-bit a.out and ELF compatibility libraries,
69respectively.
70The details of what is actually necessary for correct operation
71are given below.
72This obviously is handled by the emulator packages.
73.Pp
74For a.out compatibility,
75.Pa /usr/libexec/ld.so
76from a 32-bit distribution is required to exist as
77.Pa /emul/netbsd32/usr/libexec/ld.so .
78For 32-bit ELF compatibility,
79.Pa /usr/libexec/ld.elf_so
80needs to be in
81.Pa /emul/netbsd32/usr/libexec/ld.elf_so .
82.Pp
83The shared libraries for a.out binaries do not live under the
84.Pa /emul/netbsd32
85directory, but under the
86.Pa /emul/aout
87directory, where the a.out dynamic linker will find them.
88.Sh BUGS
89A list of things which fail to work in compatibility mode should
90be here.
91.Pp
92IPC is not well supported.
93.Pp
94.Xr sysctl 3
95is not well supported.
96