This library maps Apple runtime functions to their mulle-objc counterparts. This makes porting of existing programs that use Apple runtime functions easier. If you can get by with the limited set of functions, these functions are preferable to use over their mulle-objc counterparts for the sake of portability and familiarity.
| Release Version | Release Notes | AI Documentation |
|---|---|---|
| RELEASENOTES | DeepWiki for mulle-objc-compat |
This library
- does not include any other runtime than mulle-objc-runtime.
- does not define any functionality that is not part of the Apple runtime
- does not implement everything that's in the Apple runtime
- This library hasn't been scrutinized for thread-safety.
- Some functionality is missing that mulle-objc does not support. E.g. "weak variables".
- Message sending via
objc_msgSenduses the mulle-objc MetaABI and therefore is only compatible in the case, where there is only one pointer sized parameter and a pointer sized return value. - The library must be compiled with mulle-clang (since the multiverse changes)
| Requirement | Release Version | Description |
|---|---|---|
| MulleObjC | π A collection of Objective-C root classes for mulle-objc |
Use mulle-sde to add mulle-objc-compat to your project.
As long as your sources are using #include "include-private.h" and your headers use #include "include.h", there will nothing more to do:
mulle-sde add github:mulle-objc/mulle-objc-compatTo only add the sources of mulle-objc-compat with all the sources of its dependencies replace "github:" with clib::
One common denominator is that you will likely have to add
#include <mulle-objc-compat/mulle-objc-compat.h> to your source files.
clib install --out src/mulle-objc mulle-objc/mulle-objc-compatAdd -isystem src/mulle-objc to your CFLAGS and compile all the
sources that were downloaded with your project. (In cmake add
include_directories( BEFORE SYSTEM src/mulle-objc) to your CMakeLists.txt
file).
git submodule add --name "mulle-objc-compat" \
"https://github.com/mulle-objc/mulle-objc-compat" \
"stash/mulle-objc-compat"
git submodule update --init --recursiveadd_subdirectory( stash/mulle-objc-compat)
add_subdirectory( stash/)
target_link_libraries( ${PROJECT_NAME} PUBLIC mulle-objc-compat)
target_link_libraries( ${PROJECT_NAME} PUBLIC )Use mulle-sde to build and install mulle-objc-compat and all dependencies:
mulle-sde install --prefix /usr/local \
https://github.com/mulle-objc/mulle-objc-compat/archive/latest.tar.gzInstall all requirements
| Requirements | Description |
|---|---|
| MulleObjC | π A collection of Objective-C root classes for mulle-objc |
Download the latest tar or zip archive and unpack it.
Install mulle-objc-compat into /usr/local with cmake:
PREFIX_DIR="/usr/local"
cmake -B build \
-DMULLE_SDK_PATH="${PREFIX_DIR}" \
-DCMAKE_INSTALL_PREFIX="${PREFIX_DIR}" \
-DCMAKE_PREFIX_PATH="${PREFIX_DIR}" \
-DCMAKE_BUILD_TYPE=Release &&
cmake --build build --config Release &&
cmake --install build --config ReleaseNat! for Mulle kybernetiK