Portable build framework for OpenNTPD
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

33 lines
534 B

  1. /*
  2. * Public domain
  3. * unistd.h compatibility shim
  4. */
  5. #include_next <unistd.h>
  6. #ifndef LIBCOMPAT_UNISTD_H
  7. #define LIBCOMPAT_UNISTD_H
  8. #ifndef HAVE_GETENTROPY
  9. int getentropy(void *buf, size_t buflen);
  10. #endif
  11. #include <grp.h>
  12. #ifndef HAVE_CLOSEFROM
  13. int closefrom(int fd);
  14. #endif
  15. #ifndef HAVE_SETGROUPS
  16. int setgroups(int ngroups, const gid_t *gidset);
  17. #endif
  18. #ifndef HAVE_SETRESGID
  19. int setresgid(gid_t rgid, gid_t egid, gid_t sgid);
  20. #endif
  21. #ifndef HAVE_SETRESUID
  22. int setresuid(uid_t ruid, uid_t euid, uid_t suid);
  23. #endif
  24. #endif