#include // for mknodat, S_IFIFO, mkfifoat #include // for mode_t int mkfifoat(int fd, const char *path, mode_t mode) { return mknodat(fd, path, mode | S_IFIFO, 0); }