--- core/thread.h.orig 2024-06-14 23:02:44 UTC +++ core/thread.h @@ -9,6 +9,11 @@ #if !defined(_WIN32) #include #include + #if __FreeBSD__ <= 12 + #include + struct _cpuset; + typedef struct _cpuset cpu_set_t; + #endif #if defined(__APPLE__) #include #endif @@ -135,7 +140,7 @@ OIDN_NAMESPACE_BEGIN std::vector oldAffinities; // original thread affinities }; -#elif defined(__linux__) +#elif defined(__linux__) || defined(__FreeBSD__) // ----------------------------------------------------------------------------------------------- // ThreadAffinity: Linux @@ -161,8 +166,8 @@ OIDN_NAMESPACE_BEGIN // Parses a list of numbers from a file in /sys/devices/system static std::vector parseList(const std::string& filename); - std::vector affinities; // thread affinities - std::vector oldAffinities; // original thread affinities + std::vector affinities; // thread affinities + std::vector oldAffinities; // original thread affinities }; #elif defined(__APPLE__)