diff options
author | xtraeme <xtraeme@pkgsrc.org> | 2006-01-27 19:47:21 +0000 |
---|---|---|
committer | xtraeme <xtraeme@pkgsrc.org> | 2006-01-27 19:47:21 +0000 |
commit | d67f542c3eecbb17700ad601c267049131940cb2 (patch) | |
tree | d78d474de3809042572e09dd6813b347e7e700ad /lang | |
parent | cb9d3f25dd99451410f6b4cdb36b1d584be8bacd (diff) | |
download | pkgsrc-d67f542c3eecbb17700ad601c267049131940cb2.tar.gz |
Initial import of spidermonkey-1.5.
SpiderMonkey is the code-name for the Mozilla's C implementation of
JavaScript.
Diffstat (limited to 'lang')
-rw-r--r-- | lang/spidermonkey/DESCR | 2 | ||||
-rw-r--r-- | lang/spidermonkey/Makefile | 35 | ||||
-rw-r--r-- | lang/spidermonkey/PLIST | 11 | ||||
-rw-r--r-- | lang/spidermonkey/buildlink3.mk | 18 | ||||
-rw-r--r-- | lang/spidermonkey/distinfo | 6 | ||||
-rw-r--r-- | lang/spidermonkey/files/pkgsrc.mk | 103 | ||||
-rw-r--r-- | lang/spidermonkey/patches/patch-aa | 31 |
7 files changed, 206 insertions, 0 deletions
diff --git a/lang/spidermonkey/DESCR b/lang/spidermonkey/DESCR new file mode 100644 index 00000000000..eb1cb80fbd6 --- /dev/null +++ b/lang/spidermonkey/DESCR @@ -0,0 +1,2 @@ +SpiderMonkey is the code-name for the Mozilla's C implementation of +JavaScript. diff --git a/lang/spidermonkey/Makefile b/lang/spidermonkey/Makefile new file mode 100644 index 00000000000..f16ad1b307c --- /dev/null +++ b/lang/spidermonkey/Makefile @@ -0,0 +1,35 @@ +# $NetBSD: Makefile,v 1.1.1.1 2006/01/27 19:47:21 xtraeme Exp $ +# + +DISTNAME= js-1.5 +PKGNAME= ${DISTNAME:S/js/spidermonkey/} +CATEGORIES= lang +MASTER_SITES= http://ftp.mozilla.org/pub/mozilla.org/js/ + +MAINTAINER= tech-pkg@NetBSD.org +HOMEPAGE= http://www.mozilla.org/js/spidermonkey/ +COMMENT= Standalone JavaScript implementation in C + +WRKSRC= ${WRKDIR}/js/src + +NO_CONFIGURE= yes +USE_TOOLS+= gmake +MAKEFILE= Makefile.ref + +INSTALLATION_DIRS= bin include lib + +DIST_HEADERS= jsapi.h jsautocfg.h jscompat.h jslong.h \ + jsosdep.h jsotypes.h jspubtd.h jstypes.h + +post-extract: + ${CP} ${FILESDIR}/pkgsrc.mk ${WRKSRC}/config + +do-install: + ${INSTALL_PROGRAM} ${WRKSRC}/pkgsrc_DBG.OBJ/js ${PREFIX}/bin + ${INSTALL_LIB} ${WRKSRC}/pkgsrc_DBG.OBJ/libjs.so ${PREFIX}/lib + ${CP} ${WRKSRC}/pkgsrc_DBG.OBJ/jsautocfg.h ${WRKSRC} +.for f in ${DIST_HEADERS} + ${INSTALL_DATA} ${WRKSRC}/${f} ${PREFIX}/include +.endfor + +.include "../../mk/bsd.pkg.mk" diff --git a/lang/spidermonkey/PLIST b/lang/spidermonkey/PLIST new file mode 100644 index 00000000000..4803af519a0 --- /dev/null +++ b/lang/spidermonkey/PLIST @@ -0,0 +1,11 @@ +@comment $NetBSD: PLIST,v 1.1.1.1 2006/01/27 19:47:21 xtraeme Exp $ +bin/js +include/jsapi.h +include/jsautocfg.h +include/jscompat.h +include/jslong.h +include/jsosdep.h +include/jsotypes.h +include/jspubtd.h +include/jstypes.h +lib/libjs.so diff --git a/lang/spidermonkey/buildlink3.mk b/lang/spidermonkey/buildlink3.mk new file mode 100644 index 00000000000..eb2c89ced18 --- /dev/null +++ b/lang/spidermonkey/buildlink3.mk @@ -0,0 +1,18 @@ +# $NetBSD: buildlink3.mk,v 1.1.1.1 2006/01/27 19:47:21 xtraeme Exp $ + +BUILDLINK_DEPTH:= ${BUILDLINK_DEPTH}+ +SPIDERMONKEY_BUILDLINK3_MK:= ${SPIDERMONKEY_BUILDLINK3_MK}+ + +.if !empty(BUILDLINK_DEPTH:M+) +BUILDLINK_DEPENDS+= spidermonkey +.endif + +BUILDLINK_PACKAGES:= ${BUILDLINK_PACKAGES:Nspidermonkey} +BUILDLINK_PACKAGES+= spidermonkey + +.if !empty(SPIDERMONKEY_BUILDLINK3_MK:M+) +BUILDLINK_DEPENDS.spidermonkey+= spidermonkey>=1.5 +BUILDLINK_PKGSRCDIR.spidermonkey?= ../../lang/spidermonkey +.endif # SPIDERMONKEY_BUILDLINK3_MK + +BUILDLINK_DEPTH:= ${BUILDLINK_DEPTH:S/+$//} diff --git a/lang/spidermonkey/distinfo b/lang/spidermonkey/distinfo new file mode 100644 index 00000000000..81b0d8ead73 --- /dev/null +++ b/lang/spidermonkey/distinfo @@ -0,0 +1,6 @@ +$NetBSD: distinfo,v 1.1.1.1 2006/01/27 19:47:21 xtraeme Exp $ + +SHA1 (js-1.5.tar.gz) = 707755be3a94207d5d10ccd1011ca00babe0a689 +RMD160 (js-1.5.tar.gz) = a1f23d53c259a9fa354f29eecdc1c56472f4f626 +Size (js-1.5.tar.gz) = 958135 bytes +SHA1 (patch-aa) = 61c0b7e452f67528d982a82bb5ef2b71cd40637b diff --git a/lang/spidermonkey/files/pkgsrc.mk b/lang/spidermonkey/files/pkgsrc.mk new file mode 100644 index 00000000000..88707f95a1c --- /dev/null +++ b/lang/spidermonkey/files/pkgsrc.mk @@ -0,0 +1,103 @@ +# -*- Mode: makefile -*- +# +# ***** BEGIN LICENSE BLOCK ***** +# Version: MPL 1.1/GPL 2.0/LGPL 2.1 +# +# The contents of this file are subject to the Mozilla Public License Version +# 1.1 (the "License"); you may not use this file except in compliance with +# the License. You may obtain a copy of the License at +# http://www.mozilla.org/MPL/ +# +# Software distributed under the License is distributed on an "AS IS" basis, +# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License +# for the specific language governing rights and limitations under the +# License. +# +# The Original Code is Mozilla Communicator client code, released +# March 31, 1998. +# +# The Initial Developer of the Original Code is +# Netscape Communications Corporation. +# Portions created by the Initial Developer are Copyright (C) 1998 +# the Initial Developer. All Rights Reserved. +# +# Contributor(s): +# +# Alternatively, the contents of this file may be used under the terms of +# either the GNU General Public License Version 2 or later (the "GPL"), or +# the GNU Lesser General Public License Version 2.1 or later (the "LGPL"), +# in which case the provisions of the GPL or the LGPL are applicable instead +# of those above. If you wish to allow use of your version of this file only +# under the terms of either the GPL or the LGPL, and not to allow others to +# use your version of this file under the terms of the MPL, indicate your +# decision by deleting the provisions above and replace them with the notice +# and other provisions required by the GPL or the LGPL. If you do not delete +# the provisions above, a recipient may use your version of this file under +# the terms of any one of the MPL, the GPL or the LGPL. +# +# ***** END LICENSE BLOCK ***** + +# +# Config for FreeBSD/NetBSD/OpenBSD. +# + +#CC = gcc +#CCC = g++ +CFLAGS += -Wall -Wno-format +OS_CFLAGS = -DXP_UNIX -DSVR4 -DSYSV -D_BSD_SOURCE -DPOSIX_SOURCE # -DHAVE_LOCALTIME_R + +RANLIB = echo +MKSHLIB = $(LD) -shared $(XMKSHLIBOPTS) + +#.c.o: +# $(CC) -c -MD $*.d $(CFLAGS) $< + +CPU_ARCH = $(shell uname -m) +# don't filter in x86-64 architecture +ifneq (x86_64,$(CPU_ARCH)) +ifeq (86,$(findstring 86,$(CPU_ARCH))) +CPU_ARCH = x86 +OS_CFLAGS+= -DX86_LINUX + +ifeq (gcc, $(CC)) +# if using gcc on x86, check version for opt bug +# (http://bugzilla.mozilla.org/show_bug.cgi?id=24892) +GCC_VERSION := $(shell gcc -v 2>&1 | grep version | awk '{ print $$3 }') +GCC_LIST:=$(sort 2.91.66 $(GCC_VERSION) ) + +ifeq (2.91.66, $(firstword $(GCC_LIST))) +CFLAGS+= -DGCC_OPT_BUG +endif +endif +endif +endif + +GFX_ARCH = x + +OS_LIBS = -lm -lc + +ASFLAGS += -x assembler-with-cpp + + +ifeq ($(CPU_ARCH),alpha) + +# Ask the C compiler on alpha linux to let us work with denormalized +# double values, which are required by the ECMA spec. + +OS_CFLAGS += -mieee +endif + +# Use the editline library to provide line-editing support. +JS_EDITLINE = 1 + +ifeq ($(CPU_ARCH),x86_64) +# Use VA_COPY() standard macro on x86-64 +# FIXME: better use it everywhere +OS_CFLAGS += -DHAVE_VA_COPY -DVA_COPY=va_copy +endif + +ifeq ($(CPU_ARCH),x86_64) +# We need PIC code for shared libraries +# FIXME: better patch rules.mk & fdlibm/Makefile* +OS_CFLAGS += -DPIC -fPIC +endif diff --git a/lang/spidermonkey/patches/patch-aa b/lang/spidermonkey/patches/patch-aa new file mode 100644 index 00000000000..ce3f34b19ed --- /dev/null +++ b/lang/spidermonkey/patches/patch-aa @@ -0,0 +1,31 @@ +$NetBSD: patch-aa,v 1.1.1.1 2006/01/27 19:47:21 xtraeme Exp $ + +--- config.mk.orig 2003-11-15 01:10:55.000000000 +0100 ++++ config.mk 2006-01-27 20:42:30.000000000 +0100 +@@ -96,10 +96,26 @@ + ifeq ($(OS_ARCH),Darwin) + OS_CONFIG := Darwin + else ++ifeq ($(OS_ARCH), NetBSD) ++OS_CONFIG := pkgsrc ++else ++ifeq ($(OS_ARCH), FreeBSD) ++OS_CONFIG := pkgsrc ++else ++ifeq ($(OS_ARCH), DragonFlyBSD) ++OS_CONFIG := pkgsrc ++else ++ifeq ($(OS_ARCH), OpenBSD) ++OS_CONFIG := pkgsrc ++else + OS_CONFIG := $(OS_ARCH)$(OS_OBJTYPE)$(OS_RELEASE) + endif + endif + endif ++endif ++endif ++endif ++endif + + ASFLAGS = + DEFINES = |