From b814d6a7046d1138b624a049a35afcd82c255a4a Mon Sep 17 00:00:00 2001 From: Jesse Noller Date: Wed, 3 Sep 2008 18:10:30 +0000 Subject: Fix issue 3110 - solaris compilation of multiprocessing fails, reviewed by pitrou --- Misc/NEWS | 3 +++ Modules/_multiprocessing/multiprocessing.h | 11 +++++++++++ 2 files changed, 14 insertions(+) diff --git a/Misc/NEWS b/Misc/NEWS index 9f5884b..b4f02b2 100644 --- a/Misc/NEWS +++ b/Misc/NEWS @@ -83,6 +83,9 @@ Library - Issue #3708: os.urandom no longer goes into an infinite loop when passed a non-integer floating point number. +- Issue #3110: multiprocessing fails to compiel on solaris 10 due to missing + SEM_VALUE_MAX. + Extension Modules ----------------- diff --git a/Modules/_multiprocessing/multiprocessing.h b/Modules/_multiprocessing/multiprocessing.h index 57eb7b4..ec5042c 100644 --- a/Modules/_multiprocessing/multiprocessing.h +++ b/Modules/_multiprocessing/multiprocessing.h @@ -37,6 +37,17 @@ #endif /* + * Issue 3110 - Solaris does not define SEM_VALUE_MAX + */ +#ifndef SEM_VALUE_MAX +# ifdef _SEM_VALUE_MAX +# define SEM_VALUE_MAX _SEM_VALUE_MAX +# else +# define SEM_VALUE_MAX INT_MAX +# endif +#endif + +/* * Make sure Py_ssize_t available */ -- cgit v0.12