1
0
mirror of https://git.FreeBSD.org/ports.git synced 2025-02-07 11:49:40 +00:00

- Fix build with python-2.4

PR:		ports/151597
Submitted by:	"Ilya A. Arhipov" <pa36ouHu4er@yandex.ru>
This commit is contained in:
Wen Heping 2010-10-29 08:38:33 +00:00
parent 0b50269aeb
commit 3f6bc74b9b
Notes: svn2git 2021-03-31 03:12:20 +00:00
svn path=/head/; revision=263717
2 changed files with 15 additions and 0 deletions

View File

@ -7,6 +7,7 @@
PORTNAME= jsonlib
PORTVERSION= 1.6.1
PORTREVISION= 1
CATEGORIES= devel python
MASTER_SITES= CHEESESHOP
PKGNAMEPREFIX= ${PYTHON_PKGNAMEPREFIX}

View File

@ -0,0 +1,14 @@
--- _jsonlib.c.orig 2010-10-20 11:09:48.792940743 +0000
+++ _jsonlib.c 2010-10-20 11:11:06.166556561 +0000
@@ -21,6 +21,12 @@
#include <ctype.h>
#include <math.h>
+#if PY_VERSION_HEX < 0x02050000 && !defined(PY_SSIZE_T_MIN)
+typedef int Py_ssize_t;
+#define PY_SSIZE_T_MAX INT_MAX
+#define PY_SSIZE_T_MIN INT_MIN
+#endif
+
/* Parser {{{ */
typedef struct _Parser
{