Commit 8105162b authored by Guillaume Poirier's avatar Guillaume Poirier

add / fix support for FreeBSD, based on a patch by Igor Mozolevsky % igor A hybrid-lab P co P uk %


git-svn-id: svn://svn.videolan.org/x264/trunk@720 df754926-b1dd-0310-bc7b-ec298dee348c
parent 85a9209e
......@@ -28,7 +28,7 @@
#ifdef SYS_BEOS
#include <kernel/OS.h>
#endif
#ifdef SYS_MACOSX
#if defined(SYS_MACOSX) || defined(SYS_FREEBSD)
#include <sys/types.h>
#include <sys/sysctl.h>
#endif
......@@ -237,7 +237,7 @@ int x264_cpu_num_processors( void )
get_system_info( &info );
return info.cpu_count;
#elif defined(SYS_MACOSX)
#elif defined(SYS_MACOSX) || defined(SYS_FREEBSD)
int numberOfCPUs;
size_t length = sizeof( numberOfCPUs );
if( sysctlbyname("hw.ncpu", &numberOfCPUs, &length, NULL, 0) )
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment