Exclude win from prio drop implementation
authorlucas <lucas@7cbeb6ba-43b4-40fd-8cce-4c39aea84d33>
Thu, 23 Sep 2010 20:58:19 +0000 (20:58 +0000)
committerlucas <lucas@7cbeb6ba-43b4-40fd-8cce-4c39aea84d33>
Thu, 23 Sep 2010 20:58:19 +0000 (20:58 +0000)
Win will use another completely different approach. So, change the
guards to EFL_HAVE_POSIX_THREADS.

Also, include eina_sched.h as should have been done.

git-svn-id: svn+ssh://svn.enlightenment.org/var/svn/e/trunk/eina@52654 7cbeb6ba-43b4-40fd-8cce-4c39aea84d33

src/lib/eina_sched.c

index d1c84de..dbb3da6 100644 (file)
@@ -20,7 +20,7 @@
 # include "config.h"
 #endif
 
-#ifdef EFL_HAVE_THREADS
+#ifdef EFL_HAVE_POSIX_THREADS
 # include <pthread.h>
 # ifdef __linux__
 #  include <sched.h>
@@ -30,6 +30,7 @@
 # endif
 #endif
 
+#include "eina_sched.h"
 #include "eina_log.h"
 
 #define RTNICENESS 5
@@ -50,7 +51,7 @@
 EAPI void
 eina_sched_prio_drop(void)
 {
-#ifdef EFL_HAVE_THREADS
+#ifdef EFL_HAVE_POSIX_THREADS
    struct sched_param param;
    int pol, prio, ret;
    pthread_t pthread_id;
@@ -88,6 +89,7 @@ eina_sched_prio_drop(void)
      }
 #endif
 #else
-   EINA_LOG_ERR("Eina does not have support for threads enabled");
+   EINA_LOG_ERR("Eina does not have support for threads enabled"
+                "or it doesn't support setting scheduler priorities");
 #endif
 }