The Darwin compatibility feature is active for kernels compiled
with the
COMPAT_DARWIN
,
COMPAT_MACH
,
and
EXEC_MACHO
options enabled.
All Darwin binaries are dynamically linked.
As
COMPAT_DARWIN
only emulates the Darwin system calls, you will need various Darwin
userland files, such as the shared libraries and the dynamic linker.
Theses files are kept in a
``shadow root''
directory, named
/emul/darwin
.
Each time a Darwin binary has to use a file, it will look it up in
/emul/darwin
first.
This feature is used to prevent conflict between native and foreign
libraries and configuration files.
There are two ways of setting up the
/emul/darwin
tree.
pkgsrc/emulators/darwin_lib
.
This package uses files provided by the OpenDarwin project.
Therefore, it does not contain Apple's MacOS X proprietary libraries,
which are required in order to run any Quartz-based application.
If you need some files not installed by the package, read on.
/emul/darwin
by hand.
To do this, you need a Darwin system.
In order to know what libraries a program needs, just use the
otool
-L
program
Please note that you need a valid MacOS X license if you copy Apple proprietary libraries and programs from a MacOS X system.
COMPAT_DARWIN
and
COMPAT_MACH
layers were written by
Emmanuel Dreyfus <manu@NetBSD.org>
EXEC_MACHO
was integrated into
NetBSD
by
Christos Zoulas <christos@NetBSD.org>
.
The
pkgsrc/emulators/darwin_lib
package was created by
James Whitwell <abacau@yahoo.com.au>
.
COMPAT_DARWIN
is still very experimental.