# Build failed on macOS 15.4, due to "fp.h" not found

**URL:** https://community.aseprite.org/t/build-failed-on-macos-15-4-due-to-fp-h-not-found/25192
**Category:** Development
**Created:** [April 12, 2025, 9:54am UTC](https://community.aseprite.org/t/build-failed-on-macos-15-4-due-to-fp-h-not-found/25192 "2025-04-12T09:54:32Z")
**Posts on this page:** 8
**Page:** 1

<div class="post-metadata">

### Author: ![KCN-judu](https://community.aseprite.org/user_avatar/community.aseprite.org/kcn-judu/32/21065_2.png) [@KCN-judu](https://community.aseprite.org/u/KCN-judu)
#### Post date: [April 12, 2025, 9:54am UTC](https://community.aseprite.org/t/build-failed-on-macos-15-4-due-to-fp-h-not-found/25192/1 "2025-04-12T09:54:33Z")

</div>

**Platform info** :

- Apple Silicon M4
- macOS SDK 15.4
- Skia-m102
- cmake version 4.0.1
- ninja version 1.12.1

**Build Command** :

```auto
cmake \
  -DCMAKE_POLICY_VERSION_MINIMUM=3.5 \
  -DCMAKE_BUILD_TYPE=RelWithDebInfo \
  -DCMAKE_OSX_ARCHITECTURES=arm64 \
  -DCMAKE_OSX_DEPLOYMENT_TARGET=15.4 \
  -DCMAKE_OSX_SYSROOT=/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk \
  -DLAF_BACKEND=skia \
  -DSKIA_DIR=$HOME/deps/skia \
  -DSKIA_LIBRARY_DIR=$HOME/deps/skia/out/Release-arm64 \
  -DSKIA_LIBRARY=$HOME/deps/skia/out/Release-arm64/libskia.a \
  -DPNG_ARM_NEON:STRING=on \
  -G Ninja \
  ..

```

**Error info** :

> FAILED: third\_party/libpng/scripts/intprefix.out /Users/kcn/Downloads/aseprite/build/third\_party/libpng/scripts/intprefix.out  
> cd /Users/kcn/Downloads/aseprite/build/third\_party/libpng && /opt/homebrew/bin/cmake -DINPUT=/Users/kcn/Downloads/aseprite/third\_party/libpng/scripts/intprefix.c -DOUTPUT=/Users/kcn/Downloads/aseprite/build/third\_party/libpng/scripts/intprefix.out -P /Users/kcn/Downloads/aseprite/build/third\_party/libpng/scripts/genout.cmake  
> In file included from /Users/kcn/Downloads/aseprite/third\_party/libpng/scripts/intprefix.c:21:  
> /Users/kcn/Downloads/aseprite/third\_party/libpng/scripts/../pngpriv.h:524:16: fatal error: ‘fp.h’ file not found  
> 524 | # include \<fp.h\>  
> | ^ ~~~~~  
> 1 error generated.  
> CMake Error at scripts/genout.cmake:78 (message):  
> Failed to generate  
> /Users/kcn/Downloads/aseprite/build/third\_party/libpng/scripts/intprefix.out.tf1

---

<div class="post-metadata">

### Author: ![KCN-judu](https://community.aseprite.org/user_avatar/community.aseprite.org/kcn-judu/32/21065_2.png) [@KCN-judu](https://community.aseprite.org/u/KCN-judu)
#### Post date: [April 12, 2025, 10:02am UTC](https://community.aseprite.org/t/build-failed-on-macos-15-4-due-to-fp-h-not-found/25192/2 "2025-04-12T10:02:24Z")

</div>

I’ve recently started migrating my development workflow to macOS and am still familiarizing myself with its build toolchain. While troubleshooting a compilation error related to the missing `fp.h` header, I discovered through external resources that this issue might stem from macOS SDK versions deprecating or excluding `fp.h` in newer releases.

Given that this file appears to be part of the legacy CarbonCore framework, could you advise on:

1. ​ **Workarounds** to resolve the `fp.h` dependency (e.g., explicit framework linking, header path adjustments).
2. ​ **Project-specific optimizations** to modernize the build process and avoid reliance on deprecated components?

Any insights or documentation pointers would be greatly appreciated!

---

<div class="post-metadata">

### Author: ![filtom2](https://community.aseprite.org/user_avatar/community.aseprite.org/filtom2/32/21078_2.png) [@filtom2](https://community.aseprite.org/u/filtom2)
#### Post date: [April 13, 2025, 10:16pm UTC](https://community.aseprite.org/t/build-failed-on-macos-15-4-due-to-fp-h-not-found/25192/3 "2025-04-13T22:16:51Z")

</div>

Hello, did you manage to find any fix ? I am at my wits end, tried 3 different tutorials but i always get stuck here at missing fp.h at line 524 ☹ any help appreciated. Macbook air m3

---

<div class="post-metadata">

### Author: ![filtom2](https://community.aseprite.org/user_avatar/community.aseprite.org/filtom2/32/21078_2.png) [@filtom2](https://community.aseprite.org/u/filtom2)
#### Post date: [April 13, 2025, 10:22pm UTC](https://community.aseprite.org/t/build-failed-on-macos-15-4-due-to-fp-h-not-found/25192/4 "2025-04-13T22:22:06Z")

</div>

I MANAGED TO FIX IT!! I simply changed the line 524 from \<fp.h\> to \<math.h\> and it ninja command compiled and produced exectuables in bin.

---

<div class="post-metadata">

### Author: ![KCN-judu](https://community.aseprite.org/user_avatar/community.aseprite.org/kcn-judu/32/21065_2.png) [@KCN-judu](https://community.aseprite.org/u/KCN-judu)
#### Post date: [April 14, 2025, 10:17am UTC](https://community.aseprite.org/t/build-failed-on-macos-15-4-due-to-fp-h-not-found/25192/5 "2025-04-14T10:17:15Z")

</div>

Thanks for sharing this fix! I’ll try this later.

---

<div class="post-metadata">

### Author: ![Dev\_TJ](https://community.aseprite.org/user_avatar/community.aseprite.org/dev_tj/32/21104_2.png) [@Dev\_TJ](https://community.aseprite.org/u/Dev_TJ)
#### Post date: [April 19, 2025, 7:56am UTC](https://community.aseprite.org/t/build-failed-on-macos-15-4-due-to-fp-h-not-found/25192/6 "2025-04-19T07:56:12Z")

</div>

Fixed using these steps:

> <https://github.com/aseprite/aseprite/issues/5131#issuecomment-2816593408>
>
> OS: MacOS 15.4 (M4 Pro)
> 
> Hi there, i was trying to build aseprite on mac m4 pro …silicon using the following build command:
> 
> \`\`\`
> cmake \\
> -DCMAKE\_POLICY\_VERSION\_MINIMUM=3.5 \\
> -DCMAKE\_BUILD\_TYPE=RelWithDebInfo \\
> -DCMAKE\_OSX\_ARCHITECTURES=arm64 \\
> -DCMAKE\_OSX\_DEPLOYMENT\_TARGET=15.4 \\
> -DCMAKE\_OSX\_SYSROOT=/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk \\
> -DLAF\_BACKEND=skia \\
> -DSKIA\_DIR=$SKIA \\
> -DSKIA\_LIBRARY\_DIR=$SKIA/out/Release-arm64 \\
> -DSKIA\_LIBRARY=$SKIA/out/Release-arm64/libskia.a \\
> -DPNG\_ARM\_NEON:STRING=on \\
> -G Ninja \\
> ..
> \`\`\`
> 
> but im getting the following error:
> 
> \`\`\`
> \[243/1559\] Generating scripts/intprefix.out
> FAILED: third\_party/libpng/scripts/intprefix.out /Users/me/deps/aseprite/build/third\_party/libpng/scripts/intprefix.out
> cd /Users/me/deps/aseprite/build/third\_party/libpng && /opt/homebrew/bin/cmake -DINPUT=/Users/me/deps/aseprite/third\_party/libpng/scripts/intprefix.c -DOUTPUT=/Users/me/deps/aseprite/build/third\_party/libpng/scripts/intprefix.out -P /Users/me/deps/aseprite/build/third\_party/libpng/scripts/genout.cmake
> In file included from /Users/me/deps/aseprite/third\_party/libpng/scripts/intprefix.c:21:
> /Users/me/deps/aseprite/third\_party/libpng/scripts/../pngpriv.h:524:16: fatal error: 'fp.h' file not found
> 524 | # include \<fp.h\>
> | ^ ~~~~~
> 1 error generated.
> CMake Error at scripts/genout.cmake:78 (message):
> Failed to generate
> /Users/me/deps/aseprite/build/third\_party/libpng/scripts/intprefix.out.tf1
> \`\`\`
> 
> i also tried to change the line 524 to #include \<math.h\>, still not working.
> 
> is there any solution ?

---

<div class="post-metadata">

### Author: ![bncaswel](https://community.aseprite.org/user_avatar/community.aseprite.org/bncaswel/32/25977_2.png) [@bncaswel](https://community.aseprite.org/u/bncaswel)
#### Post date: [April 30, 2026, 9:22pm UTC](https://community.aseprite.org/t/build-failed-on-macos-15-4-due-to-fp-h-not-found/25192/7 "2026-04-30T21:22:42Z")

</div>

@filtom2 , excellent fix man! Worked for me too on another project. you saved my arse! 😅

---

<div class="post-metadata">

### Author: ![elizabe](https://community.aseprite.org/letter_avatar/elizabe/32/5_5575768a8748004e209b776fc1b2916d.png) [@elizabe](https://community.aseprite.org/u/elizabe)
#### Post date: [June 9, 2026, 8:20am UTC](https://community.aseprite.org/t/build-failed-on-macos-15-4-due-to-fp-h-not-found/25192/8 "2026-06-09T08:20:34Z")

</div>

Good catch. The fact that replacing `fp.h` with `math.h` resolved the issue suggests that the project was relying on a legacy header that is no longer available in newer macOS SDKs. As Apple continues to modernize its toolchain, older Carbon and legacy framework dependencies can cause build failures when compiling on recent macOS versions. For anyone troubleshooting similar compiler and header issues, Apple’s **[Developer Documentation](https://developer.apple.com/documentation/)** is often the best place to verify API and SDK changes. I also found this overview of **[C Programming Concepts](https://cloudfoundation.com/blog/c-interview-questions-and-answers/)** useful for understanding standard headers and language fundamentals that frequently come up when porting older codebases. In general, replacing deprecated dependencies with standard library equivalents, where possible, tends to be the most future-proof approach.
