[x264-devel] [PATCH] Solaris: use sysconf(3C) to get processor count
Sean McGovern
gseanmcg at gmail.com
Thu Nov 22 17:15:24 CET 2012
Solaris responds correctly to the same value as Cygwin,
so let's use that.
---
common/cpu.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/common/cpu.c b/common/cpu.c
index 3cae6f8..2ec3084 100644
--- a/common/cpu.c
+++ b/common/cpu.c
@@ -402,7 +402,7 @@ int x264_cpu_num_processors( void )
#elif SYS_WINDOWS
return x264_pthread_num_processors_np();
-#elif SYS_CYGWIN
+#elif SYS_CYGWIN || SYS_SunOS
return sysconf( _SC_NPROCESSORS_ONLN );
#elif SYS_LINUX
--
1.7.12
More information about the x264-devel
mailing list