Disable check for pthreads on win32

And do not use sched_get_priority on mingw with win32 pthreads installed
This commit is contained in:
Fritz Elfert 2011-06-18 01:10:57 +02:00 committed by Arun Raghavan
parent 7f48b79758
commit a13da4e93e
2 changed files with 6 additions and 2 deletions

View file

@ -433,7 +433,9 @@ AC_CHECK_DEFINE([INADDR_NONE], [netinet/in.h], [],
#### POSIX threads ####
ACX_PTHREAD
# Win32 build breaks with win32 pthread installed
AS_IF([test "x$os_is_win32" != "x1"],
[ACX_PTHREAD])
#### Check for libs ####

View file

@ -478,11 +478,13 @@ static int parse_rtprio(const char *filename, unsigned line, const char *section
pa_assert(rvalue);
pa_assert(data);
#ifdef HAVE_SCHED_H
#ifndef OS_IS_WIN32
# ifdef HAVE_SCHED_H
if (pa_atoi(rvalue, &rtprio) < 0 || rtprio < sched_get_priority_min(SCHED_FIFO) || rtprio > sched_get_priority_max(SCHED_FIFO)) {
pa_log("[%s:%u] Invalid realtime priority '%s'.", filename, line, rvalue);
return -1;
}
# endif
#endif
c->realtime_priority = (int) rtprio;