Skip to content
This repository
Browse code

Pull in Firefox 6 Spidermonkey

Merge branch 'firefox_6'

Conflicts:
	tasks/tracemonkey.rake
  • Loading branch information...
commit 2ea07ba2342c6ca004a97e7699a862e7b766b30e 2 parents da38073 + 577e027
Jason Smith authored January 07, 2012

Showing 143 changed files with 2 additions and 51,298 deletions. Show diff stats Hide diff stats

  1. 5  Documentation/getting_spidermonkey.txt.md
  2. 705  dependencies/js_src/Makefile.in
  3. 470  dependencies/js_src/Makefile.ref
  4. 54  dependencies/js_src/README.html
  5. 3  dependencies/js_src/SpiderMonkey.rsp
  6. 19  dependencies/js_src/Y.js
  7. 13  dependencies/js_src/aclocal.m4
  8. 110  dependencies/js_src/analysis-tests/Makefile.in
  9. 11  dependencies/js_src/analysis-tests/green-accessred.cpp
  10. 12  dependencies/js_src/analysis-tests/green-callred.cpp
  11. 8  dependencies/js_src/analysis-tests/green-callredptr.cpp
  12. 14  dependencies/js_src/analysis-tests/green-tored-badpath.cpp
  13. 12  dependencies/js_src/analysis-tests/green-tored.cpp
  14. 12  dependencies/js_src/analysis-tests/green-toredptr.cpp
  15. 5  dependencies/js_src/analysis-tests/misdeclared-red-funcptr.cpp
  16. 5  dependencies/js_src/analysis-tests/misdeclared-red-funcptr2.cpp
  17. 11  dependencies/js_src/analysis-tests/red-accessred.cpp
  18. 8  dependencies/js_src/analysis-tests/red-callgreen.cpp
  19. 8  dependencies/js_src/analysis-tests/red-callred.cpp
  20. 11  dependencies/js_src/analysis-tests/red-togreenptr-arg.cpp
  21. 15  dependencies/js_src/analysis-tests/red-togreenptr-field.cpp
  22. 8  dependencies/js_src/analysis-tests/red-togreenptr-initializer-array.cpp
  23. 7  dependencies/js_src/analysis-tests/red-togreenptr-initializer-cast.cpp
  24. 18  dependencies/js_src/analysis-tests/red-togreenptr-initializer-nested.cpp
  25. 12  dependencies/js_src/analysis-tests/red-togreenptr-initializer-struct.cpp
  26. 7  dependencies/js_src/analysis-tests/red-togreenptr-initializer.cpp
  27. 9  dependencies/js_src/analysis-tests/red-togreenptr-return.cpp
  28. 10  dependencies/js_src/analysis-tests/red-togreenptr.cpp
  29. 5  dependencies/js_src/bench.sh
  30. 202  dependencies/js_src/build/autoconf/acoutput-fast.pl
  31. 65  dependencies/js_src/build/autoconf/acwinpaths.m4
  32. 154  dependencies/js_src/build/autoconf/altoptions.m4
  33. 1,537  dependencies/js_src/build/autoconf/config.guess
  34. 1,702  dependencies/js_src/build/autoconf/config.sub
  35. 119  dependencies/js_src/build/autoconf/install-sh
  36. 322  dependencies/js_src/build/autoconf/make-makefile
  37. 101  dependencies/js_src/build/autoconf/match-dir.sh
  38. 136  dependencies/js_src/build/autoconf/moznbytetype.m4
  39. 76  dependencies/js_src/build/autoconf/mozprog.m4
  40. 101  dependencies/js_src/build/autoconf/nspr.m4
  41. 59  dependencies/js_src/build/autoconf/pkg.m4
  42. 75  dependencies/js_src/build/cygwin-wrapper
  43. 111  dependencies/js_src/build/hcc
  44. 155  dependencies/js_src/build/hcpp
  45. 16  dependencies/js_src/build/msys-perl-wrapper
  46. 171  dependencies/js_src/build/unix/mddepend.pl
  47. 63  dependencies/js_src/build/unix/uniq.pl
  48. 40  dependencies/js_src/build/win32/pgomerge.py
  49. 91  dependencies/js_src/builtins.tbl
  50. 193  dependencies/js_src/config.mk
  51. 109  dependencies/js_src/config/Makefile.in
  52. 232  dependencies/js_src/config/Moz/Milestone.pm
  53. 345  dependencies/js_src/config/autoconf.mk.in
  54. 107  dependencies/js_src/config/check-sync-dirs.py
  55. 14  dependencies/js_src/config/check-sync-exceptions
  56. 794  dependencies/js_src/config/config.mk
  57. 66  dependencies/js_src/config/fastcwd.pl
  58. 2  dependencies/js_src/config/gcc_hidden.h
  59. 53  dependencies/js_src/config/insure.mk
  60. 59  dependencies/js_src/config/make-system-wrappers.pl
  61. 112  dependencies/js_src/config/milestone.pl
  62. 13  dependencies/js_src/config/milestone.txt
  63. 83  dependencies/js_src/config/mkdepend/Makefile.in
  64. 233  dependencies/js_src/config/mkdepend/cppsetup.c
  65. 184  dependencies/js_src/config/mkdepend/def.h
  66. 551  dependencies/js_src/config/mkdepend/ifparser.c
  67. 83  dependencies/js_src/config/mkdepend/ifparser.h
  68. 733  dependencies/js_src/config/mkdepend/imakemdep.h
  69. 337  dependencies/js_src/config/mkdepend/include.c
  70. 860  dependencies/js_src/config/mkdepend/main.c
  71. 382  dependencies/js_src/config/mkdepend/mkdepend.man
  72. 686  dependencies/js_src/config/mkdepend/parse.c
  73. 124  dependencies/js_src/config/mkdepend/pr.c
  74. 50  dependencies/js_src/config/nfspwd.pl
  75. 487  dependencies/js_src/config/nsinstall.c
  76. 17  dependencies/js_src/config/nsinstall.exe.manifest
  77. 155  dependencies/js_src/config/nsinstall.py
  78. 711  dependencies/js_src/config/nsinstall_win.c
  79. 247  dependencies/js_src/config/pathsub.c
  80. 74  dependencies/js_src/config/pathsub.h
  81. 671  dependencies/js_src/config/preprocessor.pl
  82. 2,292  dependencies/js_src/config/rules.mk
  83. 1  dependencies/js_src/config/solaris_ia32.map
  84. 21  dependencies/js_src/config/static-checking-config.mk
  85. 108  dependencies/js_src/config/static-checking.js
  86. 61  dependencies/js_src/config/string-format.js
  87. 1,026  dependencies/js_src/config/system-headers
  88. 85  dependencies/js_src/config/version.mk
  89. 436  dependencies/js_src/config/version_win.pl
  90. 5,236  dependencies/js_src/configure.in
  91. 3,331  dependencies/js_src/dtoa.c
  92. 55  dependencies/js_src/editline/Makefile.in
  93. 143  dependencies/js_src/editline/Makefile.ref
  94. 83  dependencies/js_src/editline/README
  95. 175  dependencies/js_src/editline/editline.3
  96. 1,371  dependencies/js_src/editline/editline.c
  97. 135  dependencies/js_src/editline/editline.h
  98. 182  dependencies/js_src/editline/sysunix.c
  99. 82  dependencies/js_src/editline/unix.h
  100. 69  dependencies/js_src/find-child.py
  101. 404  dependencies/js_src/imacro_asm.js.in
  102. 987  dependencies/js_src/imacros.c.out
  103. 724  dependencies/js_src/imacros.jsasm
  104. 73  dependencies/js_src/javascript-trace.d
  105. 97  dependencies/js_src/jitstats.tbl
  106. 87  dependencies/js_src/js-config.h.in
  107. 111  dependencies/js_src/js-config.in
  108. BIN  dependencies/js_src/js.mdp
  109. 329  dependencies/js_src/js.msg
  110. 81  dependencies/js_src/jsapi-tests/Makefile.in
  111. 160  dependencies/js_src/jsapi-tests/README
  112. 20  dependencies/js_src/jsapi-tests/selfTest.cpp
  113. 26  dependencies/js_src/jsapi-tests/testContexts.cpp
  114. 25  dependencies/js_src/jsapi-tests/testDebugger.cpp
  115. 51  dependencies/js_src/jsapi-tests/testDefineGetterSetterNonEnumerable.cpp
  116. 45  dependencies/js_src/jsapi-tests/testExtendedEq.cpp
  117. 13  dependencies/js_src/jsapi-tests/testIntString.cpp
  118. 89  dependencies/js_src/jsapi-tests/testIsAboutToBeFinalized.cpp
  119. 29  dependencies/js_src/jsapi-tests/testLookup.cpp
  120. 31  dependencies/js_src/jsapi-tests/testPropCache.cpp
  121. 21  dependencies/js_src/jsapi-tests/testSameValue.cpp
  122. 10  dependencies/js_src/jsapi-tests/testSeal.cpp
  123. 62  dependencies/js_src/jsapi-tests/testSetPropertyWithNativeGetterStubSetter.cpp
  124. 70  dependencies/js_src/jsapi-tests/testTrap.cpp
  125. 126  dependencies/js_src/jsapi-tests/testXDR.cpp
  126. 83  dependencies/js_src/jsapi-tests/tests.cpp
  127. 238  dependencies/js_src/jsapi-tests/tests.h
  128. 5,758  dependencies/js_src/jsapi.cpp
  129. 2,814  dependencies/js_src/jsapi.h
  130. 450  dependencies/js_src/jsarena.cpp
  131. 289  dependencies/js_src/jsarena.h
  132. 3,611  dependencies/js_src/jsarray.cpp
  133. 238  dependencies/js_src/jsarray.h
  134. 1,268  dependencies/js_src/jsatom.cpp
  135. 508  dependencies/js_src/jsatom.h
  136. 95  dependencies/js_src/jsatominlines.h
  137. 274  dependencies/js_src/jsbit.h
  138. 191  dependencies/js_src/jsbool.cpp
  139. 84  dependencies/js_src/jsbool.h
  140. 465  dependencies/js_src/jsbuiltins.cpp
  141. 582  dependencies/js_src/jsbuiltins.h
  142. 139  dependencies/js_src/jsclist.h
5  Documentation/getting_spidermonkey.txt.md
Source Rendered
@@ -10,9 +10,8 @@ The objective (suggested by Mikeal in this project's infancy) is to pull spiderm
10 10
 
11 11
 1. `hg clone --verbose http://hg.mozilla.org/releases/mozilla-release`
12 12
 1. `hg checkout FIREFOX_6_0_RELEASE`
13  
-1. `cd js/src`
14  
-1. `tar cf /tmp/js_src.tar .`
15  
-1. Move to build-couchdb/dependencies/js_src
  13
+1. `tar cf /tmp/js.tar mfbt js/src`
  14
+1. Move to build-couchdb/dependencies/spidermonkey
16 15
 1. `rm -r *`
17 16
 1. `tar xf /tmp/js_src.tar && rm /tmp/js_src.tar`
18 17
 1. `git add .`
705  dependencies/js_src/Makefile.in
... ...
@@ -1,705 +0,0 @@
1  
-# -*- Mode: makefile -*-
2  
-#
3  
-# ***** BEGIN LICENSE BLOCK *****
4  
-# Version: MPL 1.1/GPL 2.0/LGPL 2.1
5  
-#
6  
-# The contents of this file are subject to the Mozilla Public License Version
7  
-# 1.1 (the "License"); you may not use this file except in compliance with
8  
-# the License. You may obtain a copy of the License at
9  
-# http://www.mozilla.org/MPL/
10  
-#
11  
-# Software distributed under the License is distributed on an "AS IS" basis,
12  
-# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
13  
-# for the specific language governing rights and limitations under the
14  
-# License.
15  
-#
16  
-# The Original Code is Mozilla Communicator client code, released
17  
-# March 31, 1998.
18  
-#
19  
-# The Initial Developer of the Original Code is
20  
-# Netscape Communications Corporation.
21  
-# Portions created by the Initial Developer are Copyright (C) 1998
22  
-# the Initial Developer. All Rights Reserved.
23  
-#
24  
-# Contributor(s):
25  
-#
26  
-# Alternatively, the contents of this file may be used under the terms of
27  
-# either of the GNU General Public License Version 2 or later (the "GPL"),
28  
-# or the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
29  
-# in which case the provisions of the GPL or the LGPL are applicable instead
30  
-# of those above. If you wish to allow use of your version of this file only
31  
-# under the terms of either the GPL or the LGPL, and not to allow others to
32  
-# use your version of this file under the terms of the MPL, indicate your
33  
-# decision by deleting the provisions above and replace them with the notice
34  
-# and other provisions required by the GPL or the LGPL. If you do not delete
35  
-# the provisions above, a recipient may use your version of this file under
36  
-# the terms of any one of the MPL, the GPL or the LGPL.
37  
-#
38  
-# ***** END LICENSE BLOCK *****
39  
-
40  
-DEPTH		= .
41  
-topsrcdir	= @top_srcdir@
42  
-srcdir		= @srcdir@
43  
-
44  
-run_for_side_effects := $(shell echo "MAKE: $(MAKE)")
45  
-include $(DEPTH)/config/autoconf.mk
46  
-
47  
-DIRS		= config
48  
-
49  
-ifdef DEHYDRA_PATH
50  
-DIRS += analysis-tests
51  
-endif
52  
-
53  
-ifdef JS_NATIVE_EDITLINE
54  
-DIRS += editline
55  
-endif
56  
-
57  
-# editline needs to get built before the shell
58  
-ifndef JS_DISABLE_SHELL
59  
-DIRS += shell
60  
-endif
61  
-
62  
-# FIXME: bug 515383 covers getting these working on wince
63  
-ifndef WINCE
64  
-ifdef ENABLE_TESTS
65  
-DIRS += jsapi-tests
66  
-endif
67  
-endif
68  
-
69  
-ifdef ENABLE_TESTS
70  
-DIRS += tests
71  
-endif
72  
-
73  
-MODULE		    = js
74  
-LIBRARY_NAME	    = mozjs
75  
-STATIC_LIBRARY_NAME = js_static
76  
-GRE_MODULE	    = 1
77  
-
78  
-LIBS		= $(NSPR_LIBS) 
79  
-
80  
-ifdef GNU_CXX
81  
-ifdef INTEL_CXX
82  
-# icc gets special optimize flags
83  
-ifdef MOZ_PROFILE_GENERATE
84  
-MODULE_OPTIMIZE_FLAGS = -O0
85  
-else
86  
-MODULE_OPTIMIZE_FLAGS = -O2 -ip
87  
-#XXX: do we want different INTERP_OPTIMIZER flags here?
88  
-endif
89  
-else # not INTEL_CXX
90  
-MODULE_OPTIMIZE_FLAGS = -O3 -fstrict-aliasing $(MOZ_OPTIMIZE_SIZE_TWEAK)
91  
-# Special optimization flags for jsinterp.c
92  
-INTERP_OPTIMIZER = -O3 -fstrict-aliasing
93  
-endif
94  
-else # not GNU_CXX
95  
-ifeq ($(OS_ARCH),SunOS)
96  
-MODULE_OPTIMIZE_FLAGS = -xO4
97  
-endif
98  
-ifeq ($(OS_ARCH),WINNT)
99  
-ifdef WINCE
100  
-# -GL is not supported on windows mobile while we are using the arm-wince-link command
101  
-MODULE_OPTIMIZE_FLAGS = -O2
102  
-else
103  
-MODULE_OPTIMIZE_FLAGS = -O2 -GL
104  
-endif
105  
-endif
106  
-endif
107  
-
108  
-
109  
-# JavaScript must be built shared, even for static builds, as it is used by
110  
-# other modules which are always built shared. Failure to do so results in
111  
-# the js code getting copied into xpinstall and jsd as well as mozilla-bin,
112  
-# and then the static data cells used for locking no longer work.
113  
-#
114  
-# In fact, we now build both a static and a shared library, as the
115  
-# JS shell would like to link to the static library.
116  
-
117  
-FORCE_SHARED_LIB = 1
118  
-FORCE_STATIC_LIB = 1
119  
-
120  
-VPATH		= $(srcdir)
121  
-
122  
-CPPSRCS		= \
123  
-		jsapi.cpp \
124  
-		jsarena.cpp \
125  
-		jsarray.cpp \
126  
-		jsatom.cpp \
127  
-		jsbool.cpp \
128  
-		jscntxt.cpp \
129  
-		jsdate.cpp \
130  
-		jsdbgapi.cpp \
131  
-		jsdhash.cpp \
132  
-		jsdtoa.cpp \
133  
-		jsemit.cpp \
134  
-		jsexn.cpp \
135  
-		jsfun.cpp \
136  
-		jsgc.cpp \
137  
-		jshash.cpp \
138  
-		jsinterp.cpp \
139  
-		jsinvoke.cpp \
140  
-		jsiter.cpp \
141  
-		jslock.cpp \
142  
-		jslog2.cpp \
143  
-		jsmath.cpp \
144  
-		jsnum.cpp \
145  
-		jsobj.cpp \
146  
-		json.cpp \
147  
-		jsopcode.cpp \
148  
-		jsparse.cpp \
149  
-		jsprf.cpp \
150  
-		jsregexp.cpp \
151  
-		jsscan.cpp \
152  
-		jsscope.cpp \
153  
-		jsscript.cpp \
154  
-		jsstr.cpp \
155  
-		jstask.cpp \
156  
-		jstypedarray.cpp \
157  
-		jsutil.cpp \
158  
-		jsxdrapi.cpp \
159  
-		jsxml.cpp \
160  
-		prmjtime.cpp \
161  
-		$(NULL)
162  
-
163  
-ifdef HAVE_DTRACE
164  
-CPPSRCS 	+= \
165  
-		jsdtracef.cpp
166  
-endif
167  
-
168  
-INSTALLED_HEADERS = \
169  
-		js-config.h \
170  
-		jsautocfg.h \
171  
-		$(CURDIR)/jsautokw.h \
172  
-		js.msg \
173  
-		jsapi.h \
174  
-		jsarray.h \
175  
-		jsarena.h \
176  
-		jsatom.h \
177  
-		jsbit.h \
178  
-		jsbool.h \
179  
-		jsclist.h \
180  
-		jscntxt.h \
181  
-		jscompat.h \
182  
-		jsdate.h \
183  
-		jsdbgapi.h \
184  
-		jsdhash.h \
185  
-		jsdtoa.h \
186  
-		jsemit.h \
187  
-		jsfun.h \
188  
-		jsgc.h \
189  
-		jshash.h \
190  
-		jsinterp.h \
191  
-		jsinttypes.h \
192  
-		jsiter.h \
193  
-		jslock.h \
194  
-		jslong.h \
195  
-		jsmath.h \
196  
-		jsnum.h \
197  
-		jsobj.h \
198  
-		jsobjinlines.h \
199  
-		json.h \
200  
-		jsopcode.tbl \
201  
-		jsopcode.h \
202  
-		jsotypes.h \
203  
-		jsparse.h \
204  
-		jsprf.h \
205  
-		jsproto.tbl \
206  
-		jsprvtd.h \
207  
-		jspubtd.h \
208  
-		jsregexp.h \
209  
-		jsscan.h \
210  
-		jsscope.h \
211  
-		jsscript.h \
212  
-		jsscriptinlines.h \
213  
-		jsstaticcheck.h \
214  
-		jsstr.h \
215  
-		jstask.h \
216  
-		jstracer.h \
217  
-		jstypedarray.h \
218  
-		jstypes.h \
219  
-		jsutil.h \
220  
-		jsvector.h \
221  
-		jstl.h \
222  
-		jshashtable.h \
223  
-		jsversion.h \
224  
-		jsxdrapi.h \
225  
-		jsxml.h \
226  
-		$(NULL)
227  
-
228  
-ifdef ENABLE_TRACEJIT
229  
-VPATH		+= $(srcdir)/nanojit
230  
-
231  
-INSTALLED_HEADERS += \
232  
-		jsbuiltins.h    \
233  
-		Assembler.h     \
234  
-		Allocator.h     \
235  
-		CodeAlloc.h     \
236  
-		Containers.h    \
237  
-		LIR.h		\
238  
-		avmplus.h	\
239  
-		Fragmento.h	\
240  
-		Native.h	\
241  
-		Native$(NANOJIT_ARCH).h \
242  
-		njconfig.h  \
243  
-		RegAlloc.h	\
244  
-		nanojit.h	\
245  
-		VMPI.h		\
246  
-		$(NULL)
247  
-
248  
-CPPSRCS += \
249  
-		jstracer.cpp \
250  
-		Assembler.cpp  \
251  
-		Allocator.cpp  \
252  
-		CodeAlloc.cpp  \
253  
-		Containers.cpp \
254  
-		Fragmento.cpp  \
255  
-		LIR.cpp        \
256  
-		njconfig.cpp   \
257  
-		RegAlloc.cpp   \
258  
-		avmplus.cpp    \
259  
-		Native$(NANOJIT_ARCH).cpp \
260  
-		jsbuiltins.cpp         \
261  
-		VMPI.cpp       \
262  
-		$(NULL)
263  
-
264  
-ifdef WINCE
265  
-# don't need -c
266  
-AS_DASH_C_FLAG =
267  
-ASFLAGS += -arch 6
268  
-ASFILES += jswince.asm
269  
-endif
270  
-
271  
-endif # ENABLE_TRACEJIT
272  
-
273  
-ifdef HAVE_DTRACE
274  
-INSTALLED_HEADERS += \
275  
-		jsdtracef.h \
276  
-		$(CURDIR)/javascript-trace.h \
277  
-		$(NULL)
278  
-endif
279  
-
280  
-ifeq (,$(filter-out WINNT WINCE,$(OS_ARCH)))
281  
-INSTALLED_HEADERS += jscpucfg.h
282  
-endif
283  
-
284  
-EXPORTS = $(INSTALLED_HEADERS)
285  
-
286  
-DASH_R		= -r
287  
-
288  
-ifneq (,$(filter OS2 WINCE WINNT,$(OS_ARCH)))
289  
-SDK_LIBRARY = $(IMPORT_LIBRARY)
290  
-else
291  
-SDK_LIBRARY = $(SHARED_LIBRARY)
292  
-endif
293  
-
294  
-include $(topsrcdir)/config/config.mk
295  
-
296  
-EXTRA_DSO_LDOPTS += $(NSPR_LIBS)
297  
-
298  
-ifdef MOZ_MEMORY
299  
-ifeq ($(OS_ARCH),SunOS)
300  
-EXTRA_DSO_LDOPTS += $(call EXPAND_LIBNAME_PATH,jemalloc,$(DIST)/lib)
301  
-endif
302  
-endif
303  
-
304  
-ifndef BUILD_OPT
305  
-MOCHAFILE	= 1
306  
-endif
307  
-
308  
-# Define keyword generator before rules.mk, see bug 323979 comment 50
309  
-
310  
-HOST_SIMPLE_PROGRAMS += host_jskwgen$(HOST_BIN_SUFFIX)
311  
-GARBAGE += jsautokw.h host_jskwgen$(HOST_BIN_SUFFIX)
312  
-
313  
-HOST_SIMPLE_PROGRAMS += host_jsoplengen$(HOST_BIN_SUFFIX)
314  
-GARBAGE += jsautooplen.h host_jsoplengen$(HOST_BIN_SUFFIX)
315  
-
316  
-USE_HOST_CXX = 1
317  
-
318  
-ifdef HAVE_DTRACE
319  
-ifneq ($(OS_ARCH),Darwin)
320  
-DTRACE_PROBE_OBJ = $(LIBRARY_NAME)-dtrace.$(OBJ_SUFFIX)
321  
-endif
322  
-MOZILLA_DTRACE_SRC = $(srcdir)/javascript-trace.d
323  
-endif
324  
-
325  
-default::
326  
-
327  
-ifneq (,$(CROSS_COMPILE)$(filter-out WINNT OS2,$(OS_ARCH)))
328  
-ifneq (,$(filter-out SYMBIAN WINCE,$(OS_ARCH)))
329  
-# nsinstall doesn't get built until we enter config/ in the exports phase,
330  
-# so we'll have to manually ensure it gets built here if we want to use
331  
-# $(EXPORTS)
332  
-export:: config/nsinstall$(HOST_BIN_SUFFIX)
333  
-$(PUBLIC) $(SDK_PUBLIC): config/nsinstall$(HOST_BIN_SUFFIX)
334  
-
335  
-config/nsinstall$(HOST_BIN_SUFFIX): $(srcdir)/config/nsinstall.c $(srcdir)/config/pathsub.c
336  
-	$(MAKE) -C config/ nsinstall$(HOST_BIN_SUFFIX)
337  
-endif
338  
-endif
339  
-
340  
-include $(topsrcdir)/config/rules.mk
341  
-
342  
-ifdef MOZ_SYNC_BUILD_FILES
343  
-# Because the SpiderMonkey can be distributed and built independently
344  
-# of the Mozilla source tree, it contains its own copies of many of
345  
-# the files used by the top-level Mozilla build process, from the
346  
-# 'config' and 'build' subtrees.
347  
-#
348  
-# To make it simpler to keep the copies in sync, we follow the policy
349  
-# that the SpiderMonkey copies must always be exact copies of those in
350  
-# the containing Mozilla tree.  If you've made a change in one, it
351  
-# belongs in the other as well.  If the change isn't right for both
352  
-# places, then that's something to bring up with the other developers.
353  
-#
354  
-# Some files are reasonable to diverge; for  example,
355  
-# js/config/autoconf.mk.in doesn't need most of the stuff in
356  
-# config/autoconf.mk.in.
357  
-check-sync-dirs = $(PYTHON) $(srcdir)/config/check-sync-dirs.py
358  
-check::
359  
-	$(check-sync-dirs) $(srcdir)/config $(MOZ_SYNC_BUILD_FILES)/config
360  
-	$(check-sync-dirs) $(srcdir)/build $(MOZ_SYNC_BUILD_FILES)/build
361  
-
362  
-check-valgrind::
363  
-	$(check-sync-dirs) $(srcdir)/config $(MOZ_SYNC_BUILD_FILES)/config
364  
-	$(check-sync-dirs) $(srcdir)/build $(MOZ_SYNC_BUILD_FILES)/build
365  
-endif
366  
-
367  
-ifdef ENABLE_TRACEJIT
368  
-ifndef WINCE
369  
-check::
370  
-	$(wildcard $(RUN_TEST_PROGRAM)) $(PYTHON) -u $(srcdir)/trace-test/trace-test.py \
371  
-	        --no-slow --no-progress --tinderbox $(DIST)/bin/js$(BIN_SUFFIX)
372  
-
373  
-check-valgrind::
374  
-	$(wildcard $(RUN_TEST_PROGRAM)) $(PYTHON) -u $(srcdir)/trace-test/trace-test.py \
375  
-	        --valgrind --no-slow --no-progress --tinderbox $(DIST)/bin/js$(BIN_SUFFIX)
376  
-endif
377  
-endif
378  
-
379  
-DIST_GARBAGE = config.cache config.log config.status \
380  
-   unallmakefiles js-config js-config.h js-confdefs.h
381  
-
382  
-distclean::
383  
-	cat unallmakefiles | $(XARGS) rm -f
384  
-	rm -f $(DIST_GARBAGE)
385  
-
386  
-# our build system doesn't handle subdir srcs very gracefully today
387  
-export::
388  
-	mkdir -p nanojit
389  
-
390  
-DEFINES		+= -DEXPORT_JS_API 
391  
-
392  
-INCLUDES	+= -I$(srcdir)
393  
-
394  
-GARBAGE		+= jscpucfg.o jsautocfg.h jsautocfg.tmp jscpucfg
395  
-
396  
-ifneq (,$(CROSS_COMPILE)$(filter-out WINNT,$(OS_ARCH)))
397  
-TARGETS		+= jscpucfg$(HOST_BIN_SUFFIX)
398  
-endif
399  
-
400  
-ifdef JS_THREADSAFE
401  
-DEFINES		+= -DJS_THREADSAFE
402  
-endif
403  
-
404  
-ifdef JS_NO_THIN_LOCKS
405  
-DEFINES		+= -DJS_USE_ONLY_NSPR_LOCKS
406  
-endif
407  
-
408  
-ifdef JS_VERSION
409  
-DEFINES		+= -DJS_VERSION=$(JS_VERSION)
410  
-endif
411  
-
412  
-ifneq ($(findstring -L,$(NSPR_LIBS)),)
413  
-NSPR_STATIC_PATH = $(subst -L,,$(findstring -L,$(NSPR_LIBS)))
414  
-else
415  
-NSPR_STATIC_PATH = $(DIST)/lib
416  
-endif
417  
-
418  
-ifdef MOZ_SHARK
419  
-CFLAGS += -F/System/Library/PrivateFrameworks
420  
-CXXFLAGS += -F/System/Library/PrivateFrameworks
421  
-LDFLAGS += -F/System/Library/PrivateFrameworks -framework CHUD
422  
-endif
423  
-
424  
-ifdef MOZ_VTUNE
425  
-CXXFLAGS += -IC:/Program\ Files/Intel/VTune/Analyzer/Include
426  
-EXTRA_DSO_LDOPTS += C:/Program\ Files/Intel/VTune/Analyzer/Lib/VtuneApi.lib
427  
-LIBS +=  C:/Program\ Files/Intel/VTune/Analyzer/Lib/VtuneApi.lib
428  
-endif
429  
-
430  
-# BeOS and HP-UX do not require the extra linking of "-lm"
431  
-ifeq (,$(filter BeOS HP-UX WINNT WINCE OpenVMS OS2,$(OS_ARCH)))
432  
-EXTRA_LIBS	+= -lm
433  
-endif
434  
-
435  
-# Prevent floating point errors caused by VC++ optimizations
436  
-ifeq ($(OS_ARCH)_$(GNU_CC),WINNT_)
437  
-ifeq (,$(filter-out 1200 1300 1310,$(_MSC_VER)))
438  
-CFLAGS += -Op
439  
-else
440  
-CFLAGS += -fp:precise
441  
-endif
442  
-endif # WINNT
443  
-
444  
-ifeq ($(OS_ARCH),FreeBSD)
445  
-EXTRA_LIBS	+= -pthread
446  
-endif
447  
-ifeq ($(OS_ARCH),IRIX)
448  
-ifdef USE_N32
449  
-DASH_R		+= -n32
450  
-endif
451  
-endif
452  
-ifeq ($(OS_ARCH),Linux)
453  
-EXTRA_LIBS	+= -ldl
454  
-endif
455  
-ifeq ($(OS_ARCH),OSF1)
456  
-EXTRA_LIBS	+= -lc_r
457  
-endif
458  
-ifeq ($(OS_ARCH),SunOS)
459  
-ifeq ($(TARGET_CPU),sparc)
460  
-
461  
-ifdef GNU_CC
462  
-CFLAGS   += -mcpu=v9
463  
-CXXFLAGS += -mcpu=v9
464  
-endif # GNU_CC
465  
-
466  
-endif
467  
-ifeq ($(OS_RELEASE),4.1)
468  
-EXTRA_LIBS	+= -ldl -lnsl
469  
-else
470  
-EXTRA_LIBS	+= -lposix4 -ldl -lnsl -lsocket
471  
-endif
472  
-endif
473  
-
474  
-ifdef MOZ_MEMORY
475  
-ifeq ($(OS_ARCH),Darwin)
476  
-LDFLAGS += -ljemalloc
477  
-endif
478  
-endif
479  
-
480  
-ifdef SOLARIS_SUNPRO_CXX
481  
-# Sun Studio SPARC doesn't work well with gcc inline asm, use lock_SunOS_sparc*.il
482  
-jslock.o: jslock.cpp Makefile.in lock_sparcv8plus.il lock_sparcv9.il
483  
-	$(REPORT_BUILD)
484  
-	@$(MAKE_DEPS_AUTO_CXX)
485  
-ifeq (sparcv9,$(findstring sparcv9,$(OS_TEST)))
486  
-	$(CXX) -o $@ -c $(COMPILE_CFLAGS) $(srcdir)/lock_sparcv9.il $<
487  
-else
488  
-	$(CXX) -o $@ -c $(COMPILE_CFLAGS) $(srcdir)/lock_sparcv8plus.il $<
489  
-endif # sparcv9
490  
-endif # SOLARIS_SUNPRO_CXX
491  
-
492  
-# Allow building jsinterp.c with special optimization flags
493  
-ifdef INTERP_OPTIMIZER
494  
-jsinterp.$(OBJ_SUFFIX): MODULE_OPTIMIZE_FLAGS=$(INTERP_OPTIMIZER)
495  
-endif
496  
-
497  
-ifeq ($(OS_ARCH),IRIX)
498  
-ifndef GNU_CC
499  
-_COMPILE_CFLAGS  = $(patsubst -O%,-O1,$(COMPILE_CFLAGS))
500  
-jsapi.o jsxdrapi.o jsarena.o jsarray.o jsatom.o jsemit.o jsfun.o jsinterp.o jsregexp.o jsparse.o jsopcode.o jsscript.o: %.o: %.cpp Makefile.in
501  
-	$(REPORT_BUILD)
502  
-	@$(MAKE_DEPS_AUTO_CXX)
503  
-	$(CXX) -o $@ -c $(_COMPILE_CFLAGS) $<
504  
-endif
505  
-endif
506  
-
507  
-# An AIX Optimization bug causes PR_dtoa() & JS_dtoa to produce wrong result.
508  
-# This suppresses optimization for this single compilation unit.
509  
-ifeq ($(OS_ARCH),AIX)
510  
-jsatom.o: jsatom.cpp Makefile.in
511  
-	$(REPORT_BUILD)
512  
-	@$(MAKE_DEPS_AUTO_CXX)
513  
-	$(CXX) -o $@ -c $(filter-out $(MOZ_OPTIMIZE_FLAGS), $(COMPILE_CFLAGS)) $<
514  
-jsdtoa.o: jsdtoa.cpp Makefile.in
515  
-	$(REPORT_BUILD)
516  
-	@$(MAKE_DEPS_AUTO_CXX)
517  
-	$(CXX) -o $@ -c $(filter-out $(MOZ_OPTIMIZE_FLAGS), $(COMPILE_CFLAGS)) $<
518  
-endif
519  
-
520  
-export:: jsautocfg.h
521  
-
522  
-ifeq (,$(CROSS_COMPILE)$(GNU_CC)$(filter-out WINNT,$(OS_ARCH)))
523  
-jsautocfg.h:
524  
-	touch $@
525  
-else
526  
-ifeq ($(OS_ARCH),WINCE)
527  
-jsautocfg.h:
528  
-	touch $@
529  
-else
530  
-jsautocfg.h: jscpucfg$(HOST_BIN_SUFFIX)
531  
-	@rm -f $@ jsautocfg.tmp
532  
-	./jscpucfg > jsautocfg.tmp
533  
-	mv jsautocfg.tmp $@
534  
-endif
535  
-endif
536  
-
537  
-# jscpucfg is a strange target
538  
-# Needs to be built with the host compiler but needs to include
539  
-# the mdcpucfg for the target so it needs the appropriate target defines
540  
-ifdef HOST_NSPR_MDCPUCFG
541  
-HOST_CXX := $(HOST_CXX) -DMDCPUCFG=$(TARGET_NSPR_MDCPUCFG)
542  
-HOST_CXXFLAGS := $(patsubst -DXP_%,,$(HOST_CXXFLAGS))
543  
-endif
544  
-
545  
-ifdef CROSS_COMPILE
546  
-# jscpucfg needs to know when it's supposed to produce a config for the target
547  
-JSCPUCFG_DEFINES = $(ACDEFINES)
548  
-endif
549  
-
550  
-ifeq ($(OS_ARCH),QNX)
551  
-ifneq ($(OS_TARGET),NTO)
552  
-# QNX's compiler apparently can't build a binary directly from a source file.
553  
-jscpucfg.o: jscpucfg.cpp Makefile.in
554  
-	$(HOST_CXX) $(HOST_CXXFLAGS) -c $(JSCPUCFG_DEFINES) $(DEFINES) $(NSPR_CFLAGS) -o $@ $<
555  
-
556  
-jscpucfg: jscpucfg.o
557  
-	$(HOST_CXX) $(HOST_CXXFLAGS) $(JSCPUCFG_DEFINES) $(DEFINES) -o $@ $<
558  
-endif
559  
-else
560  
-ifeq ($(OS_ARCH),WINCE)
561  
-jscpucfg$(HOST_BIN_SUFFIX):
562  
-	echo no need to build jscpucfg $<
563  
-else
564  
-jscpucfg$(HOST_BIN_SUFFIX): jscpucfg.cpp Makefile.in
565  
-	$(HOST_CXX) $(HOST_CXXFLAGS) $(JSCPUCFG_DEFINES) $(DEFINES) $(NSPR_CFLAGS) $(HOST_OUTOPTION)$@ $<
566  
-endif
567  
-endif
568  
-
569  
-# Compute the linker flags that programs linking against SpiderMonkey should
570  
-# pass to get SpiderMonkey and its dependencies, beyond just the -L and -l
571  
-# for the SpiderMonkey library itself.
572  
-# - EXTRA_DSO_LDOPTS includes the NSPR -L and -l flags.
573  
-# - OS_LIBS includes libraries selected by the configure script.
574  
-# - EXTRA_LIBS includes libraries selected by this Makefile.
575  
-JS_CONFIG_LIBS=$(EXTRA_DSO_LDOPTS) $(OS_LIBS) $(EXTRA_LIBS) 
576  
-
577  
-# The configure script invokes this rule explicitly at configure time!
578  
-# It's important that js-config be ready by the time we're done
579  
-# configuring, because we may be running other configure scripts that
580  
-# would like to run js-config themselves, before js is built.
581  
-#
582  
-# This file and rules.mk go through a certain amount of work to decide
583  
-# which libraries to build, what to name them, and what flags to pass
584  
-# when linking them (and thus what flags its own clients must pass).
585  
-# All this information needs to go into the js-config script.  To
586  
-# avoid trying to re-compute all that in the configure script, we just
587  
-# have the configure script generate this Makefile, and then invoke
588  
-# this rule.
589  
-at=@
590  
-js-config: js-config.in Makefile $(DEPTH)/config/autoconf.mk $(topsrcdir)/config/config.mk $(topsrcdir)/config/rules.mk
591  
-	rm -f js-config.tmp
592  
-	sed < $< > js-config.tmp \
593  
-	-e 's|$(at)prefix$(at)|$(prefix)|' \
594  
-	-e 's|$(at)exec_prefix$(at)|$(exec_prefix)|' \
595  
-	-e 's|$(at)includedir$(at)|$(includedir)|' \
596  
-	-e 's|$(at)libdir$(at)|$(libdir)|' \
597  
-	-e 's|$(at)MOZILLA_VERSION$(at)|$(MOZILLA_VERSION)|' \
598  
-	-e 's|$(at)LIBRARY_NAME$(at)|$(LIBRARY_NAME)|' \
599  
-	-e 's|$(at)NSPR_CFLAGS$(at)|$(NSPR_CFLAGS)|' \
600  
-	-e 's|$(at)JS_CONFIG_LIBS$(at)|$(JS_CONFIG_LIBS)|' \
601  
-	-e 's|$(at)MOZ_JS_LIBS$(at)|$(MOZ_JS_LIBS)|' \
602  
-	&& mv js-config.tmp $@ && chmod +x $@
603  
-
604  
-SCRIPTS = js-config
605  
-SDK_BINARY = js-config
606  
-
607  
-install:: $(INSTALLED_HEADERS)
608  
-	$(SYSINSTALL) $^ $(DESTDIR)$(includedir)/$(MODULE)
609  
-
610  
-install:: $(SCRIPTS)
611  
-	$(SYSINSTALL) $^ $(DESTDIR)$(bindir)
612  
-
613  
-install:: $(LIBRARY) $(SHARED_LIBRARY) $(IMPORT_LIBRARY)
614  
-ifneq (,$(LIBRARY))
615  
-	$(SYSINSTALL) $(LIBRARY) $(DESTDIR)$(libdir)
616  
-endif
617  
-ifneq (,$(SHARED_LIBRARY))
618  
-	$(SYSINSTALL) $(SHARED_LIBRARY) $(DESTDIR)$(libdir)
619  
-endif
620  
-ifneq (,$(IMPORT_LIBRARY))
621  
-	$(SYSINSTALL) $(IMPORT_LIBRARY) $(DESTDIR)$(libdir)
622  
-endif
623  
-
624  
-# Extra dependancies and rules for auto-generated headers
625  
-host_jskwgen.$(OBJ_SUFFIX): jsversion.h jskeyword.tbl
626  
-
627  
-# Use CURDIR to avoid finding a jsautokw.h in the source tree (from a
628  
-# previous build?) via VPATH when we're building in a separate tree.
629  
-$(CURDIR)/jsautokw.h: host_jskwgen$(HOST_BIN_SUFFIX)
630  
-	./host_jskwgen$(HOST_BIN_SUFFIX) $@
631  
-
632  
-host_jsoplengen.$(OBJ_SUFFIX): jsopcode.tbl
633  
-
634  
-# Use CURDIR to avoid finding a jsautooplen.h in the source tree (from
635  
-# a previous build?) via VPATH when we're building in a separate tree.
636  
-$(CURDIR)/jsautooplen.h: host_jsoplengen$(HOST_BIN_SUFFIX)
637  
-	./host_jsoplengen$(HOST_BIN_SUFFIX) $@
638  
-
639  
-# Force auto-header generation before compiling any source that may use them
640  
-$(CPPSRCS:%.cpp=%.$(OBJ_SUFFIX)): $(CURDIR)/jsautokw.h $(CURDIR)/jsautooplen.h
641  
-
642  
-ifdef HAVE_DTRACE
643  
-$(CURDIR)/javascript-trace.h: $(srcdir)/javascript-trace.d
644  
-	dtrace -h -s $(srcdir)/javascript-trace.d -o javascript-trace.h.in
645  
-	sed 's/if _DTRACE_VERSION/ifdef INCLUDE_MOZILLA_DTRACE/' \
646  
-	    javascript-trace.h.in > javascript-trace.h
647  
-
648  
-# We can't automatically generate dependencies on auto-generated headers;
649  
-# we have to list them explicitly.
650  
-$(addsuffix .$(OBJ_SUFFIX),jsdtracef jsinterp jsobj): $(CURDIR)/javascript-trace.h
651  
-endif
652  
-
653  
-ifdef GNU_CC
654  
-ifndef CROSS_COMPILE
655  
-ifndef QEMU_CANT_RUN_JS_SHELL
656  
-# If we don't have run-mozilla.sh *and* we're linking against NSPR, we don't
657  
-# know how to run the JS binary. Oh well
658  
-
659  
-imacro_asm.js: imacro_asm.js.in jsopcode.tbl
660  
-	$(CC) -c -x c -E -P -I$(srcdir) $< > $@
661  
-
662  
-GARBAGE += imacros.c.tmp imacro_asm.js
663  
-
664  
-ifneq (,$(wildcard $(RUN_TEST_PROGRAM))$(if $(NSPR_LIBS),,1))
665  
-libs:: imacro_asm.js $(srcdir)/imacros.jsasm
666  
-	$(wildcard $(RUN_TEST_PROGRAM)) $(DIST)/bin/js$(BIN_SUFFIX) $< $(srcdir)/imacros.jsasm > imacros.c.tmp
667  
-	@cmp -s imacros.c.tmp $(srcdir)/imacros.c.out || \
668  
-	  (echo "imacros.c.out is out of date. Run 'make update-imacros' to copy it to your source tree."; diff -U 4 $(srcdir)/imacros.c.out imacros.c.out; exit 1)
669  
-	@echo "imacros.c.out is up to date"
670  
-
671  
-update-imacros: imacros.c.tmp
672  
-	cp $< $(srcdir)/imacros.c.out
673  
-
674  
-# Code for importing the nanojit subtree from its repository.
675  
-
676  
-NANOJIT_CENTRAL_REV=$(shell cat $(srcdir)/nanojit-import-rev)
677  
-NANOJIT_CENTRAL_REPO=http://hg.mozilla.org/projects/nanojit-central
678  
-NANOJIT_CENTRAL_LOCAL=$(CURDIR)/nanojit-central
679  
-CUR_REPO=$(srcdir)/../..
680  
-
681  
-update-nanojit:
682  
-	rm -Rf $(NANOJIT_CENTRAL_LOCAL) import-splicemap import-revmap
683  
-	hg clone $(NANOJIT_CENTRAL_REPO) $(NANOJIT_CENTRAL_LOCAL)
684  
-	python $(srcdir)/find-child.py \
685  
-	                   --src=$(NANOJIT_CENTRAL_LOCAL) \
686  
-	                   --dst=$(CUR_REPO) \
687  
-	                   --start=$(NANOJIT_CENTRAL_REV) \
688  
-	                   --filemap=$(srcdir)/nanojit-import-filemap \
689  
-	                   >import-splicemap
690  
-	hg convert --config convert.hg.saverev=True \
691  
-	           --config convert.hg.startrev=`cut -d ' ' -f 1 import-splicemap` \
692  
-	           --filemap=$(srcdir)/nanojit-import-filemap \
693  
-	           --splicemap=import-splicemap \
694  
-	           $(NANOJIT_CENTRAL_LOCAL) \
695  
-	           $(CUR_REPO) \
696  
-	           import-revmap
697  
-	(cd $(srcdir) && hg up)
698  
-	(cd $(NANOJIT_CENTRAL_LOCAL) && hg log -r tip --template "{node}\n") >$(srcdir)/nanojit-import-rev
699  
-	(cd $(srcdir) && hg commit --message="Update nanojit-import-rev stamp." nanojit-import-rev)
700  
-
701  
-.PHONY: update-imacros update-nanojit
702  
-endif
703  
-endif
704  
-endif
705  
-endif
470  dependencies/js_src/Makefile.ref
... ...
@@ -1,470 +0,0 @@
1  
-# -*- Mode: makefile -*-
2  
-# vim: ft=make
3  
-#
4  
-# ***** BEGIN LICENSE BLOCK *****
5  
-# Version: MPL 1.1/GPL 2.0/LGPL 2.1
6  
-#
7  
-# The contents of this file are subject to the Mozilla Public License Version
8  
-# 1.1 (the "License"); you may not use this file except in compliance with
9  
-# the License. You may obtain a copy of the License at
10  
-# http://www.mozilla.org/MPL/
11  
-#
12  
-# Software distributed under the License is distributed on an "AS IS" basis,
13  
-# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
14  
-# for the specific language governing rights and limitations under the
15  
-# License.
16  
-#
17  
-# The Original Code is Mozilla Communicator client code, released
18  
-# March 31, 1998.
19  
-#
20  
-# The Initial Developer of the Original Code is
21  
-# Netscape Communications Corporation.
22  
-# Portions created by the Initial Developer are Copyright (C) 1998
23  
-# the Initial Developer. All Rights Reserved.
24  
-#
25  
-# Contributor(s):
26  
-#   Michael Ang <mang@subcarrier.org>
27  
-#   Kevin Buhr <buhr@stat.wisc.edu>
28  
-#
29  
-# Alternatively, the contents of this file may be used under the terms of
30  
-# either of the GNU General Public License Version 2 or later (the "GPL"),
31  
-# or the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
32  
-# in which case the provisions of the GPL or the LGPL are applicable instead
33  
-# of those above. If you wish to allow use of your version of this file only
34  
-# under the terms of either the GPL or the LGPL, and not to allow others to
35  
-# use your version of this file under the terms of the MPL, indicate your
36  
-# decision by deleting the provisions above and replace them with the notice
37  
-# and other provisions required by the GPL or the LGPL. If you do not delete
38  
-# the provisions above, a recipient may use your version of this file under
39  
-# the terms of any one of the MPL, the GPL or the LGPL.
40  
-#
41  
-# ***** END LICENSE BLOCK *****
42  
-
43  
-#
44  
-# JSRef GNUmake makefile.
45  
-#
46  
-# Note: dependency rules are missing for some files (some
47  
-#       .h, all .msg, etc.)  Re-make clean if in doubt.
48  
-#
49  
-
50  
-
51  
-DEPTH = .
52  
-
53  
-include config.mk
54  
-
55  
-#NS_USE_NATIVE = 1
56  
-
57  
-ifndef NANOJIT_ARCH
58  
-$(warning NANOJIT_ARCH not defined in config/$(OS_CONFIG).mk, JIT disabled)
59  
-else
60  
-ifdef DISABLE_JIT
61  
-$(warning disabling JIT per build specification)
62  
-else
63  
-ENABLE_JIT=1
64  
-endif
65  
-endif
66  
-
67  
-ifdef ENABLE_JIT
68  
-DEFINES += -DJS_TRACER
69  
-DEFINES += -DFEATURE_NANOJIT
70  
-INCLUDES += -Inanojit
71  
-endif
72  
-
73  
-#ifndef BUILD_OPT
74  
-#DEFINES += -Ivprof
75  
-#endif
76  
-
77  
-ifdef NARCISSUS
78  
-DEFINES += -DNARCISSUS
79  
-endif
80  
-
81  
-# Look in OBJDIR to find jsautocfg.h, jsautokw.h, and js-config.h
82  
-INCLUDES   += -I. -I$(OBJDIR)
83  
-
84  
-ifdef JS_THREADSAFE
85  
-DEFINES += -DJS_THREADSAFE
86  
-INCLUDES += -I$(DIST)/include/nspr
87  
-ifdef USE_MSVC
88  
-OTHER_LIBS += $(DIST)/lib/libnspr$(NSPR_LIBSUFFIX).lib
89  
-else
90  
-OTHER_LIBS += -L$(DIST)/lib -lnspr$(NSPR_LIBSUFFIX)
91  
-endif
92  
-endif
93  
-
94  
-ifdef JS_NO_THIN_LOCKS
95  
-DEFINES += -DJS_USE_ONLY_NSPR_LOCKS
96  
-endif
97  
-
98  
-ifdef JS_HAS_FILE_OBJECT
99  
-DEFINES += -DJS_HAS_FILE_OBJECT
100  
-endif
101  
-
102  
-ifdef JS_GC_ZEAL
103  
-DEFINES += -DJS_GC_ZEAL
104  
-endif
105  
-
106  
-#
107  
-# XCFLAGS may be set in the environment or on the gmake command line
108  
-#
109  
-#CFLAGS += -DDEBUG -DDEBUG_brendan -DJS_ARENAMETER -DJS_HASHMETER -DJS_DUMP_PROPTREE_STATS -DJS_DUMP_SCOPE_METERS -DJS_SCOPE_DEPTH_METER -DJS_BASIC_STATS
110  
-CFLAGS          += $(OS_CFLAGS) $(DEFINES) $(INCLUDES) $(XCFLAGS)
111  
-
112  
-LDFLAGS		= $(XLDFLAGS)
113  
-LDFLAGS += $(OS_LDFLAGS)
114  
-
115  
-ifdef MOZ_SHARK
116  
-DEFINES += -DMOZ_SHARK
117  
-CFLAGS += -F/System/Library/PrivateFrameworks
118  
-LDFLAGS += -F/System/Library/PrivateFrameworks -framework CHUD
119  
-endif
120  
-ifdef MOZ_CALLGRIND
121  
-DEFINES += -DMOZ_CALLGRIND
122  
-endif
123  
-ifdef MOZ_VTUNE
124  
-DEFINES += -DMOZ_VTUNE
125  
-CXXFLAGS += -IC:/Program\ Files/Intel/VTune/Analyzer/Include
126  
-OTHER_LIBS += C:/Program\ Files/Intel/VTune/Analyzer/Lib/VtuneApi.lib
127  
-endif
128  
-
129  
-ifndef NO_LIBM
130  
-LDFLAGS += -lm
131  
-endif
132  
-
133  
-# Prevent floating point errors caused by VC++ optimizations
134  
-ifeq ($(OS_ARCH),WINNT)
135  
-_MSC_VER = $(shell $(CXX) 2>&1 | sed -n 's/.*Compiler Version \([0-9]*\)\.\([0-9]*\).*/\1\2/p')
136  
-ifeq (,$(filter-out 1200 1300 1310,$(_MSC_VER)))
137  
-CFLAGS += -Op
138  
-else
139  
-CFLAGS += -fp:precise
140  
-endif
141  
-endif # WINNT
142  
-
143  
-#
144  
-#	Server-related changes :
145  
-#
146  
-ifdef NES40
147  
-DEFINES += -DNES40
148  
-endif
149  
-
150  
-#
151  
-# Line editing support.
152  
-# Define JS_READLINE or JS_EDITLINE to enable line editing in the
153  
-# js command-line interpreter.
154  
-#
155  
-ifdef JS_READLINE
156  
-# For those platforms with the readline library installed.
157  
-DEFINES += -DEDITLINE
158  
-PROG_LIBS += -lreadline -ltermcap
159  
-else
160  
-ifdef JS_EDITLINE
161  
-# Use the editline library, built locally.
162  
-PREDIRS += editline
163  
-DEFINES += -DEDITLINE
164  
-PROG_LIBS += $(OBJDIR)/editline/libedit.a
165  
-endif
166  
-endif
167  
-
168  
-# For purify
169  
-PURE_CFLAGS     = -DXP_UNIX $(OPTIMIZER) $(PURE_OS_CFLAGS) $(DEFINES) \
170  
-                  $(INCLUDES) $(XCFLAGS)
171  
-
172  
-#
173  
-# JS file lists
174  
-#
175  
-JS_HFILES =		\
176  
-	jsarray.h	\
177  
-	jsatom.h	\
178  
-	jsbool.h	\
179  
-	jscntxt.h	\
180  
-	jsdate.h	\
181  
-	jsemit.h	\
182  
-	jsexn.h		\
183  
-	jsfun.h		\
184  
-	jsgc.h		\
185  
-	jsinterp.h	\
186  
-	jsiter.h	\
187  
-	jslibmath.h	\
188  
-	jslock.h	\
189  
-	jsmath.h	\
190  
-	jsnum.h		\
191  
-	jsobj.h		\
192  
-	json.h		\
193  
-	jsopcode.h	\
194  
-	jsparse.h	\
195  
-	jsarena.h	\
196  
-	jsclist.h	\
197  
-	jsdhash.h	\
198  
-	jsdtoa.h	\
199  
-	jshash.h	\
200  
-	jslong.h	\
201  
-	jstypes.h	\
202  
-	jsprvtd.h	\
203  
-	jspubtd.h	\
204  
-	jsregexp.h	\
205  
-	jsscan.h	\
206  
-	jsscope.h	\
207  
-	jsscript.h	\
208  
-	jsstr.h		\
209  
-	jsversion.h	\
210  
-	jsxdrapi.h	\
211  
-	jsxml.h		\
212  
-	$(NULL)
213  
-
214  
-ifdef ENABLE_JIT
215  
-JS_HFILES +=			\
216  
-	jstracer.h		\
217  
-	nanojit/Assembler.h     \
218  
-	nanojit/LIR.h		\
219  
-	nanojit/Native$(NANOJIT_ARCH).h	\
220  
-	nanojit/avmplus.h	\
221  
-	nanojit/vm_fops.h	\
222  
-	nanojit/Fragmento.h	\
223  
-	nanojit/Native.h	\
224  
-	nanojit/RegAlloc.h	\
225  
-	nanojit/nanojit.h	\
226  
-	$(NULL)
227  
-endif
228  
-
229  
-ifndef BUILD_OPT
230  
-#JS_HFILES +=            \
231  
-#        vprof/vprof.h   \
232  
-#        $(NULL)
233  
-endif
234  
-
235  
-API_HFILES =		\
236  
-	jsapi.h		\
237  
-	jsdbgapi.h	\
238  
-	$(NULL)
239  
-
240  
-OTHER_HFILES =		\
241  
-	jsbit.h		\
242  
-	jscompat.h	\
243  
-	jscpucfg.h	\
244  
-	jsotypes.h	\
245  
-	prmjtime.h	\
246  
-	resource.h	\
247  
-	jsopcode.tbl	\
248  
-	jsproto.tbl     \
249  
-	js.msg		\
250  
-	jsshell.msg	\
251  
-	jskeyword.tbl	\
252  
-	$(NULL)
253  
-
254  
-ifndef PREBUILT_CPUCFG
255  
-OTHER_HFILES += $(OBJDIR)/jsautocfg.h
256  
-endif
257  
-OTHER_HFILES += $(OBJDIR)/jsautokw.h $(OBJDIR)/js-config.h
258  
-
259  
-HFILES = $(JS_HFILES) $(API_HFILES) $(OTHER_HFILES)
260  
-
261  
-JS_CPPFILES =		\
262  
-	jsapi.cpp	\
263  
-	jsarena.cpp	\
264  
-	jsarray.cpp	\
265  
-	jsatom.cpp	\
266  
-	jsbool.cpp	\
267  
-	jscntxt.cpp	\
268  
-	jsdate.cpp	\
269  
-	jsdbgapi.cpp	\
270  
-	jsdhash.cpp	\
271  
-	jsdtoa.cpp	\
272  
-	jsemit.cpp	\
273  
-	jsexn.cpp	\
274  
-	jsfun.cpp	\
275  
-	jsgc.cpp	\
276  
-	jshash.cpp	\
277  
-	jsinterp.cpp	\
278  
-	jsinvoke.cpp    \
279  
-	jsiter.cpp	\
280  
-	jslock.cpp	\
281  
-	jslog2.cpp	\
282  
-	jslong.cpp	\
283  
-	jsmath.cpp	\
284  
-	jsnum.cpp	\
285  
-	jsobj.cpp	\
286  
-	json.cpp	\
287  
-	jsopcode.cpp	\
288  
-	jsparse.cpp	\
289  
-	jsprf.cpp	\
290  
-	jsregexp.cpp	\
291  
-	jsscan.cpp	\
292  
-	jsscope.cpp	\
293  
-	jsscript.cpp	\
294  
-	jsstr.cpp	\
295  
-	jsutil.cpp	\
296  
-	jsxdrapi.cpp	\
297  
-	jsxml.cpp	\
298  
-	prmjtime.cpp	\
299  
-	$(NULL)
300  
-
301  
-ifdef ENABLE_JIT
302  
-JS_CPPFILES +=		       \
303  
-	jsbuiltins.cpp         \
304  
-	jstracer.cpp	       \
305  
-	nanojit/Assembler.cpp  \
306  
-	nanojit/Fragmento.cpp  \
307  
-	nanojit/LIR.cpp        \
308  
-	nanojit/Native$(NANOJIT_ARCH).cpp \
309  
-	nanojit/RegAlloc.cpp   \
310  
-	nanojit/avmplus.cpp    \
311  
-	$(NULL)
312  
-
313  
-endif
314  
-
315  
-ifndef BUILD_OPT
316  
-#JS_CPPFILES +=                 \
317  
-#        vprof/vprof.cpp        \
318  
-#        $(NULL)
319  
-endif
320  
-
321  
-ifdef JS_HAS_FILE_OBJECT
322  
-JS_CPPFILES += jsfile.cpp
323  
-JS_HFILES += jsfile.h
324  
-endif
325  
-
326  
-LIB_CPPFILES  = $(JS_CPPFILES)
327  
-LIB_ASFILES := $(wildcard *_$(OS_ARCH).s)
328  
-PROG_CPPFILES = js.cpp
329  
-
330  
-ifdef USE_MSVC
331  
-LIBRARY = $(OBJDIR)/js32.lib
332  
-SHARED_LIBRARY = $(OBJDIR)/js32.dll
333  
-PROGRAM = $(OBJDIR)/js.exe
334  
-else
335  
-LIBRARY = $(OBJDIR)/libjs.a
336  
-SHARED_LIBRARY = $(OBJDIR)/libjs.$(SO_SUFFIX)
337  
-PROGRAM = $(OBJDIR)/js
338  
-endif
339  
-
340  
-include rules.mk
341  
-
342  
-MOZ_DEPTH = ../..
343  
-include jsconfig.mk
344  
-
345  
-nsinstall-target:
346  
-	cd ../../config; $(MAKE) OBJDIR=$(OBJDIR) OBJDIR_NAME=$(OBJDIR)
347  
-
348  
-#
349  
-# Automatic header generation
350  
-#
351  
-
352  
-AUTO_HEADERS =					\
353  
-	$(OBJDIR)/jsautokw.h			\
354  
-	$(OBJDIR)/jsautooplen.h			\
355  
-	$(NULL)
356  
-
357  
-$(OBJDIR)/jsautokw.h: jskeyword.tbl
358  
-
359  
-$(OBJDIR)/jsautooplen.h: jsopcode.tbl