The Pedigree Project 0.1
DarwinAbi.h
1/*
2 * Copyright (c) 2026, Pedigree Developers
3 *
4 * Permission to use, copy, modify, and distribute this software for any
5 * purpose with or without fee is hereby granted.
6 */
7
8#ifndef PEDIGREE_KERNEL_PROCESSOR_HOSTED_DARWINABI_H
9#define PEDIGREE_KERNEL_PROCESSOR_HOSTED_DARWINABI_H
10#include <config.h>
11
12#ifdef __APPLE__
13// Pedigree's x86-64 ELF ABI uses long for its exact-width 64-bit types. Keep
14// public C++ names identical when the hosted kernel is compiled against the
15// Darwin SDK, which otherwise uses long long for these typedefs.
16#ifndef _INT64_T
17#define _INT64_T
18typedef signed long int64_t;
19#endif
20
21#ifndef _UINT64_T
22#define _UINT64_T
23typedef unsigned long uint64_t;
24#endif
25#endif
26
27#endif