Apple cctools port for Linux and *BSD
  • C 58.2%
  • C++ 29.4%
  • Makefile 4.3%
  • Shell 3.8%
  • Roff 2.7%
  • Other 1.6%
Find a file
Thomas Pöchtrager 904de2a71d
Merge pull request #191 from locriandev/fix-blobcore-clone-missing-implementation
Add missing BlobCore::clone() implementation
2026-04-03 17:12:24 +02:00
cctools Add missing BlobCore::clone() implementation 2026-04-03 12:26:33 +02:00
tools cctools 1030.6.3 2025-10-29 18:03:46 +01:00
usage_examples/ios_toolchain cctools 1030.6.3 2025-10-29 18:03:46 +01:00
.gitattributes add .gitattributes to ensure EOL handling does not regress 2025-11-05 17:04:54 +11:00
.gitignore gitignore fixes 2025-05-02 06:15:38 +00:00
.travis.yml Merge pull request #67 from fanquake/sudo_deprecated 2019-06-04 15:19:18 +02:00
package.sh * linux ppc/ppc64 & arm/arm64/aarch64 port 2015-03-15 22:21:16 +01:00
README.md cctools 1030.6.3 2025-10-29 18:03:46 +01:00

Apple cctools and ld64 port for Linux, *BSD and macOS

Current Version: cctools: 1030.6.3, ld64: 956.6.
Originally ported by cjacker.

SUPPORTED HOSTS

SUPPORTED HOST OPERATING SYSTEMS:

Linux, FreeBSD, OpenBSD,
macOS, iOS

SUPPORTED HOST ARCHITECTURES:

x86, x86_64, arm, arm64/AArch64, PowerPC/PowerPC64

SUPPORTED TARGET ARCHITECTURES

armv6, armv7, armv7s, arm64, arm64e,
arm64_32 (untested), i386, x86_64, x86_64h,
armv6m, armv7k, armv7m and armv7em

ld64 appears to support riscv32, although its exact use case is unclear.

SUPPORTED TARGET OPERATING SYSTEMS

macOS, iOS, tvOS, watchOS, bridgeOS, Mac Catalyst,
iOS Simluator, watchOS Simulator, DriverKit

Not all of the targets have been tested.

DEPENDENCIES

Clang 10+
libstdc++ or libc++ with C++20 support; depending on what your compiler uses
libdispatch-dev and libblocksruntime (the runtime should be installed by the dispatch library)

SDKs with .tdb stubs (>= Xcode 7) require the TAPI library to be installed.
=> https://github.com/tpoechtrager/apple-libtapi

musl-libc based systems require the musl-fts library to be installed. => https://github.com/pullmoll/musl-fts

Optional, but recommended:

llvm-devel (For Link Time Optimization Support)
uuid-devel (For ld64 -random_uuid Support)
llvm-devel + xar-devel (For ld64 -bitcode_bundle Support)

You can find xar here.
Do not install libxar-dev on Ubuntu, it's a different package.

INSTALLATION

Install Apple's TAPI library:

This step is only required if you intend to use SDKs with .tdb stubs.

git clone https://github.com/tpoechtrager/apple-libtapi.git
cd apple-libtapi
[INSTALLPREFIX=/home/user/cctools] ./build.sh
./install.sh

Install cctools and ld64:

git clone https://github.com/tpoechtrager/cctools-port.git
cd cctools-port/cctools
./configure \
    [--prefix=/home/user/cctools] \
    [--with-libtapi=/home/user/cctools] \
    [--target=<target>] \
    [--with-llvm-config=...]
make
make install

target = i386-apple-darwin11, x86_64-apple-darwin11, arm-apple-darwin11, ...

TRAVIS CI

Build Status