The accepted answer doesn't seem to work for me, but this did:

cd /Library/Developer/CommandLineTools/Packages/
open .

and double clicking the pkg file.

Answer from Anti Earth on Stack Overflow
Discussions

install errors: fatal error: sys/cdefs.h: No such file or directory
Dear author, I am faced with a kind of installation problem. I have already installed the gcc (version 13) by "brew install gcc". I updated the Makevars in ~/.R/Makevars by: CXX=/usr/loca... More on github.com
🌐 github.com
7
July 20, 2023
Error on mac when compiling certain packages in R - fatal error: sys/cdefs.h: No such file or directory - Stack Overflow
I am working in RStudio and having problems installing from sources an R package that contains C++ code. I have followed instructions from several websites about installing Xcode and gcc, changing ... More on stackoverflow.com
🌐 stackoverflow.com
March 7, 2023
Cdefs.h not found during compile on some packages, but file exists on system
Hi I have EOS on my Pinebook Pro. I’ve been having issues compiling some software from yay. Granted, these are packages which say “architecture not supported, try anyway?”, but this seems like possibly a fixable problem. The compiler pukes and says cdefs.h not found, but the file does ... More on forum.endeavouros.com
🌐 forum.endeavouros.com
0
0
October 22, 2021
fatal error: sys/cdefs.h: No such file or directory
Hi, thanks for the nice framework. I've managed to cross compile and deploy Qt from linux PC to Raspberry Pi 4 (gcc 8.3.0 toolchain). I'm trying to compile a test program for the RPi in QtC... More on github.com
🌐 github.com
6
May 8, 2021
🌐
Arduino Forum
forum.arduino.cc › development tools › cloud editor
Fatal error: sys/cdefs.h: No such file or directory - Cloud Editor - Arduino Forum
June 18, 2023 - Hey, is anyone else getting this error? fatal error: sys/cdefs.h: No such file or directory Mine just showed up the other day...happening on multiple PCs. not even sure where this is included. Running "IRremote.h" and "RTClib.h" More complete error message: In file included from /mnt/creat...
🌐
GitHub
github.com › acorg › Racmacs › issues › 150
install errors: fatal error: sys/cdefs.h: No such file or directory · Issue #150 · acorg/Racmacs
July 20, 2023 - /usr/local/Cellar/gcc/13.1.0/lib/gcc/current/gcc/x86_64-apple-darwin22/13/include-fixed/math.h:45:10: fatal error: sys/cdefs.h: No such file or directory 45 | #include <sys/cdefs.h> | ^~~~~~~~~~~~~_ compilation terminated.
Author   judyssister
🌐
Stack Overflow
stackoverflow.com › questions › 75666847 › error-on-mac-when-compiling-certain-packages-in-r-fatal-error-sys-cdefs-h-no
Error on mac when compiling certain packages in R - fatal error: sys/cdefs.h: No such file or directory - Stack Overflow
March 7, 2023 - In file included from /usr/local/Cellar/gcc/11.1.0_1/include/c++/11.1.0/cmath:45, from /Users/nickjacob/Library/R/x86_64/4.1/library/Rcpp/include/Rcpp/platform/compiler.h:100, from /Users/nickjacob/Library/R/x86_64/4.1/library/Rcpp/include/Rcpp/r/headers.h:62, from /Users/nickjacob/Library/R/x86_64/4.1/library/Rcpp/include/RcppCommon.h:30, from /Users/nickjacob/Library/R/x86_64/4.1/library/RcppArmadillo/include/RcppArmadillo/interface/RcppArmadilloForward.h:25, from /Users/nickjacob/Library/R/x86_64/4.1/library/RcppArmadillo/include/RcppArmadillo.h:29, from helloworld.cpp:1: /usr/local/Cellar/gcc/11.1.0_1/lib/gcc/11/gcc/x86_64-apple-darwin19/11.1.0/include-fixed/math.h:45:10: fatal error: sys/cdefs.h: No such file or directory
🌐
EndeavourOS
forum.endeavouros.com › arm
Cdefs.h not found during compile on some packages, but file exists on system - ARM - EndeavourOS
October 22, 2021 - Hi I have EOS on my Pinebook Pro. I’ve been having issues compiling some software from yay. Granted, these are packages which say “architecture not supported, try anyway?”, but this seems like possibly a fixable problem. The compiler pukes and says cdefs.h not found, but the file does ...
Find elsewhere
🌐
GitHub
github.com › phil-opp › blog_os › issues › 55
Mac OS support · Issue #55 · phil-opp/blog_os
November 23, 2015 - Some Mac OS users seem to have tool problems in the first post. So it might be a good idea to create a separate page that lists all needed extra steps (such as updating nasm). Unfortunately, I have zero Mac experience and can only copy i...
🌐
Gentoo
bugs.gentoo.org › 712846
712846 – sys-auth/pam_ssh-2.3-r1 : pam_ssh.c: fatal error: sys/cdefs.h: No such file or directory
November 12, 2021 - Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo · Gentoo's Bugzilla – Bug 712846 sys-auth/pam_ssh-2.3-r1 : pam_ssh.c: fatal error: sys/cdefs.h: No such file or directory Last modified: 2024-05-08 09:23:36 UTC node [vulture] · New–[Ex] · Browse · Search ...
🌐
GitHub
github.com › GodotNativeTools › godot-cpp › issues › 230
Compile error: fatal error: sys/cdefs.h: No such file or directory [AND] fatal error: bits/c++config.h: No such file or directory · Issue #230 · godotengine/godot-cpp
July 15, 2018 - Compile error: fatal error: sys/cdefs.h: No such file or directory [AND] fatal error: bits/c++config.h: No such file or directory#230
Author   ricardoalcantara
🌐
GitHub
github.com › emscripten-core › emscripten › issues › 10818
compile error : /usr/include/features.h:367:12: fatal error: 'sys/cdefs.h' file not found · Issue #10818 · emscripten-core/emscripten
March 31, 2020 - I want to try compile [camera model] (https://github.com/heguixiang/Remove_ROS_VINS/tree/master/camera_model) using emcripten the command _emconfigure cmake .. _ was passed but the error come from _emmake make _ here is output logs : sam...
Author   pans0ul
🌐
OS2World
os2world.com › forum › index.php
fatal error: sys/cdefs.h: No such file or directory
March 12, 2024 - fatal error: sys/cdefs.h: No such file or directory
🌐
balenaForums
forums.balena.io › openbalena
fatal error: sys/cdefs.h: No such file or directory - openBalena - balenaForums
August 23, 2019 - Hi, I am new to openBalena. Following guide here, I successfully deploy myApp for raspberry pi3(32 bit) on ubuntu 64 bit. Then I tried to deploy a Kivy app using the Dockerfile below. FROM andrewmk/rpi-kivy:stretch RUN apt-get update && apt-get install -y build-essential python3-pip python3-setuptools python3-dev && apt-get clean && rm -rf /var/lib/apt/lists/ RUN pip3 install paho-mqtt && pip3 install wheel && pip3 install pgen && pip3 install -I Cython==0.28.2 && rm -Rf /root/.cache/ RUN...
🌐
HatchJS
hatchjs.com › home › fatal error: sys/cdefs.h: no such file or directory
Fatal Error: sys/cdefs.h: No Such File or Directory
December 17, 2020 - The error `fatal error: sys/cdefs.h: no such file or directory` occurs when a C compiler cannot find the header file `sys/cdefs.h`. This can happen for a variety of reasons, but the most common is that the header file is not installed in the ...