xz/src/common
Lasse Collin df8f446e3a tuklib_cpucores: Add support for sched_getaffinity().
It's available in glibc (GNU/Linux, GNU/kFreeBSD). It's better
than sysconf(_SC_NPROCESSORS_ONLN) because sched_getaffinity()
gives the number of cores available to the process instead of
the total number of cores online.

As a side effect, this commit fixes a bug on GNU/kFreeBSD where
configure would detect the FreeBSD-specific cpuset_getaffinity()
but it wouldn't actually work because on GNU/kFreeBSD it requires
using -lfreebsd-glue when linking. Now the glibc-specific function
will be used instead.

Thanks to Sebastian Andrzej Siewior for the original patch
and testing.
2016-10-24 18:51:36 +03:00
..
common_w32res.rc Windows: Update common_w32res.rc. 2010-10-09 12:52:12 +03:00
mythread.h Fix build when --disable-threads is used. 2014-12-21 18:00:38 +02:00
sysdefs.h Windows: Add MSVC defines for inline and restrict keywords. 2014-01-12 17:04:33 +02:00
tuklib_common.h Avoid non-standard preprocessor construct. 2009-09-22 13:40:19 +03:00
tuklib_config.h Use a tuklib module for integer handling. 2009-10-04 22:57:12 +03:00
tuklib_cpucores.c tuklib_cpucores: Add support for sched_getaffinity(). 2016-10-24 18:51:36 +03:00
tuklib_cpucores.h Various changes. 2009-09-19 09:47:30 +03:00
tuklib_exit.c Various changes. 2009-09-19 09:47:30 +03:00
tuklib_exit.h Various changes. 2009-09-19 09:47:30 +03:00
tuklib_gettext.h Fix use of N_() and ngettext(). 2010-09-07 10:42:13 +03:00
tuklib_integer.h Add a few casts to tuklib_integer.h to silence possible warnings. 2015-02-03 21:45:53 +02:00
tuklib_mbstr.h xz: Multiple fixes. 2010-09-10 10:30:33 +03:00
tuklib_mbstr_fw.c xz: Multiple fixes. 2010-09-10 10:30:33 +03:00
tuklib_mbstr_width.c xz: Multiple fixes. 2010-09-10 10:30:33 +03:00
tuklib_open_stdxxx.c Don't call close(-1) in tuklib_open_stdxxx() on error. 2011-05-28 16:43:26 +03:00
tuklib_open_stdxxx.h Various changes. 2009-09-19 09:47:30 +03:00
tuklib_physmem.c tuklib_physmem: Hopefully silence a warning on Windows. 2015-11-08 20:16:10 +02:00
tuklib_physmem.h Various changes. 2009-09-19 09:47:30 +03:00
tuklib_progname.c Collection of language fixes to comments and docs. 2010-02-12 13:16:15 +02:00
tuklib_progname.h Collection of language fixes to comments and docs. 2010-02-12 13:16:15 +02:00