this repo has no description
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

Adding README.md with hacking instructions

+86
+86
README.md
··· 1 + This is a userspace compatibility layer for running Darwin/OS X binaries on Linux. 2 + 3 + # General information 4 + 5 + For more information (such as **build instructions**), visit http://darling.dolezel.info 6 + 7 + # Hacking tutorial 8 + 9 + Want to help and don't know what's currently important? Let me know! 10 + Google Group: https://groups.google.com/d/forum/darling-project 11 + 12 + **Important:** Use git clone -r (as in recursive) to check out this project. 13 + 14 + ## Directory tree 15 + 16 + <dl> 17 + 18 + <dt>benchmarks/</dt> 19 + <dd>No serious stuff in here, used only once for a simple ObjC msg sending benchmark.</dd> 20 + <dt>etc/</dt> 21 + <dd>Contains dylib.conf which is used to map OS X library (framework) paths to Linux/Darling ones. `/dev/null` = load nothing.</dd> 22 + <dt>include/</dt> 23 + <dd>Header files taken from Darwin/OS X (APSL license). The plan is to get rid of these eventually.</dd> 24 + <dt>misc/</dt> 25 + <dd>Random files, nothing that really matters.</dd> 26 + <dt>src/</dt> 27 + <dd>Source code, see below.</dd> 28 + <dt>tests/</dt> 29 + <dd>Test runner. It is specifically designed to work on my testing setup. See below.</dd> 30 + <dt>tests/src/</dt> 31 + <dd>The source code for tests.</dd> 32 + <dt>tools/</dt> 33 + <dd>Various utilities used during the development.</dd> 34 + 35 + </dl> 36 + 37 + ### Source tree 38 + 39 + The structure under `src/`. 40 + 41 + <dl> 42 + <dt>src/libSystem/</dt> 43 + <dd>Wrappers or implementation of libc funcions, BSD system calls and Mach system calls.</dd> 44 + 45 + <dt>src/libobjcdarwin/</dt> 46 + <dd>Loader of ObjC classes/protocols in Mach-O ObjC applications. Contains code for selector fixups and other techniques needed to "make it work" with GNUstep's libobjc2.</dd> 47 + 48 + <dt>src/util/</dt> 49 + <dd>Various utility functions/classes common to all parts of Darling.</dd> 50 + 51 + <dt>src/libmach-o/</dt> 52 + <dd>Mach-O parsing/loading library.</dd> 53 + 54 + <dt>src/dyld/</dt> 55 + <dd>The dynamic loader.</dd> 56 + 57 + <dt>src/motool/</dt> 58 + <dd>A very simple tool for Mach-O file examination. (An allusion to "otool" available on OS X.)</dd> 59 + 60 + <dt>src/crash/</dt> 61 + <dd>A crash ("force quit") dialog app for Cocoa apps. Not really complete yet.</dd> 62 + 63 + <dt>...</dt> 64 + <dd>The rest is code or wrappers in various stages of completion.</dd> 65 + 66 + </dl> 67 + 68 + ### Tests tree 69 + 70 + The testing procedure implemented in `src/tests/runtest.cpp` is as follows: 71 + 72 + 1. It copies the source file to the OS X machine. 73 + 2. It remotely builds the source file. If the current binary name is `runtest32`, then `-m32` is added and `dyld32` is used later on. A similar `runtest64` symlink is needed if your 64-bit dyld is called `dyld64`. If the first line in the source file is `// CFLAGS:`, then the rest is used as CFLAGS. 74 + 3. It remotely runs the program and keeps its stdout. 75 + 4. It copies the binary over to the local machine. 76 + 5. It runs the binary via dyld/dyld32/dyld64. 77 + 6. It compares the stdout contents of dyld with that of the remotely run binary. 78 + 7. Should the stdout contents differ or should the process exit with a non-zero code on either of the systems, the test has failed. 79 + 80 + In `src/tests/libsshcxx`, a copy of my libssh C++ wrapper should check itself out. 81 + 82 + ## Debugging 83 + 84 + Find out how Darling can help you with debugging at http://darling.dolezel.info/en/Debugging 85 + 86 +