aboutsummaryrefslogtreecommitdiffstats
path: root/lang/see
diff options
context:
space:
mode:
authorvanilla <vanilla@FreeBSD.org>2015-03-17 20:38:43 +0800
committervanilla <vanilla@FreeBSD.org>2015-03-17 20:38:43 +0800
commitc76b755fd0cc7174f8c586058a8b8a05e7278e3e (patch)
treeae4cb278d9bb8e44bf88415056d01cc9f5904634 /lang/see
parent57b2e7b7f21eafddb422441a38232bb7965f5a6b (diff)
downloadfreebsd-ports-gnome-c76b755fd0cc7174f8c586058a8b8a05e7278e3e.tar.gz
freebsd-ports-gnome-c76b755fd0cc7174f8c586058a8b8a05e7278e3e.tar.zst
freebsd-ports-gnome-c76b755fd0cc7174f8c586058a8b8a05e7278e3e.zip
Enable multi-threading.
PR: 198655 Submitted by: maintainer
Diffstat (limited to 'lang/see')
-rw-r--r--lang/see/Makefile11
-rw-r--r--lang/see/files/patch-libsee_dtoa.c17
2 files changed, 24 insertions, 4 deletions
diff --git a/lang/see/Makefile b/lang/see/Makefile
index 97123098aebe..d40ca2d1331f 100644
--- a/lang/see/Makefile
+++ b/lang/see/Makefile
@@ -3,6 +3,7 @@
PORTNAME= see
PORTVERSION= 3.1.1424
+PORTREVISION= 1
CATEGORIES= lang devel
MASTER_SITES= http://download.openpkg.org/components/cache/see/ \
http://lil.fr.distfiles.macports.org/see/ \
@@ -12,10 +13,12 @@ MASTER_SITES= http://download.openpkg.org/components/cache/see/ \
MAINTAINER= numisemis@yahoo.com
COMMENT= Simple ECMAScript Engine (SEE)
-OPTIONS_DEFINE= GC SEE_DEBUG DOCS
+LICENSE= BSD
+
+OPTIONS_DEFINE= GC DEBUG DOCS
OPTIONS_DEFAULT= GC
GC_DESC= Use Boehm-Weiser garbage collection package
-SEE_DEBUG_DESC= Internal SEE library debugging
+DEBUG_DESC= Internal SEE library debugging
CONFLICTS= see-devel-[0-9]*
@@ -27,11 +30,11 @@ USE_PERL5= build
GNU_CONFIGURE= yes
INSTALL_TARGET= install-strip
-CFLAGS+= -O3 -fomit-frame-pointer
+CFLAGS+= -O3
CPPFLAGS+= -I${LOCALBASE}/include ${PTHREAD_CFLAGS}
LDFLAGS+= -L${LOCALBASE}/lib ${PTHREAD_LIBS}
-SEE_DEBUG_CFLAGS_OFF= -DNDEBUG
+DEBUG_CFLAGS_OFF= -DNDEBUG
GC_LIB_DEPENDS= libgc.so:${PORTSDIR}/devel/boehm-gc
GC_CONFIGURE_WITH= boehm-gc
diff --git a/lang/see/files/patch-libsee_dtoa.c b/lang/see/files/patch-libsee_dtoa.c
new file mode 100644
index 000000000000..978f306a3eaf
--- /dev/null
+++ b/lang/see/files/patch-libsee_dtoa.c
@@ -0,0 +1,17 @@
+--- libsee/dtoa.c.orig 2009-04-26 23:04:58.000000000 +0200
++++ libsee/dtoa.c 2015-03-16 15:46:21.218950229 +0100
+@@ -252,6 +252,14 @@
+ #include "math.h"
+ #endif
+
++#include <pthread.h>
++
++static pthread_mutex_t dtoaLock[2] = { PTHREAD_MUTEX_INITIALIZER, PTHREAD_MUTEX_INITIALIZER };
++
++#define MULTIPLE_THREADS
++#define ACQUIRE_DTOA_LOCK(n) pthread_mutex_lock(&dtoaLock[n]);
++#define FREE_DTOA_LOCK(n) pthread_mutex_unlock(&dtoaLock[n]);
++
+ #ifdef __cplusplus
+ extern "C" {
+ #endif