From: Jerome Duval Date: Fri, 13 Jun 2014 19:56:27 +0000 (+0000) Subject: Haiku support X-Git-Url: https://git.sesse.net/?a=commitdiff_plain;h=39af8c72e618a544baa06ae427fb2b440861abcd;hp=59683a97b50b34c6282457a959bb6b3e9e7f8c0d;p=x264 Haiku support Add Haiku as supported platform in configure. Haiku has no nice() function, use the platform specific substitute instead. --- diff --git a/common/osdep.h b/common/osdep.h index a94c5250..96596b7d 100644 --- a/common/osdep.h +++ b/common/osdep.h @@ -369,6 +369,10 @@ static ALWAYS_INLINE void x264_prefetch( void *p ) sp.sched_priority -= p;\ pthread_setschedparam( handle, policy, &sp );\ } +#elif SYS_HAIKU +#include +#define x264_lower_thread_priority(p)\ + { UNUSED status_t nice_ret = set_thread_priority( find_thread( NULL ), B_LOW_PRIORITY ); } #else #include #define x264_lower_thread_priority(p) { UNUSED int nice_ret = nice(p); } diff --git a/configure b/configure index 57a47acc..681535c8 100755 --- a/configure +++ b/configure @@ -651,6 +651,9 @@ case $host_os in HAVE_GETOPT_LONG=0 CFLAGS="$CFLAGS -I\$(SRCPATH)/extras" ;; + *haiku*) + SYS="HAIKU" + ;; *) die "Unknown system $host, edit the configure" ;;