-
-
Notifications
You must be signed in to change notification settings - Fork 698
Closed
Labels
low severityUsed to report low severity bugs (e.g. cosmetic issues, non critical UI glitches)Used to report low severity bugs (e.g. cosmetic issues, non critical UI glitches)
Description
What happened?
The following example fails when compiling with C++.
#include <sys/sysmacros.h>
int main(){return makedev(1,2);}
Workaround is to use extern "C" {}
when including the header <sys/sysmacros.h>
, or compile as C code.
Version
cosmocc (GCC) 14.1.0
What operating system are you seeing the problem on?
Linux x86_64.
Relevant log output
cosmoc++ a.cpp -o a
/home/bart/apps/cosmocc/bin/../libexec/gcc/x86_64-linux-cosmo/14.1.0/ld.bfd: /tmp/fatcosmocc.1g6ec4iyr07v0.o: in function `main':
a.cpp:(.text+0x21): undefined reference to `makedev(unsigned int, unsigned int)'
Metadata
Metadata
Assignees
Labels
low severityUsed to report low severity bugs (e.g. cosmetic issues, non critical UI glitches)Used to report low severity bugs (e.g. cosmetic issues, non critical UI glitches)