Merge remote-tracking branch 'redux/master' into sh4-pool
[tamarin-stm.git] / shell / manifest.mk
blob419305b0a6525dcb04aaaac8037a17827da7bcab
1 # ***** BEGIN LICENSE BLOCK *****
2 # Version: MPL 1.1/GPL 2.0/LGPL 2.1
4 # The contents of this file are subject to the Mozilla Public License Version
5 # 1.1 (the "License"); you may not use this file except in compliance with
6 # the License. You may obtain a copy of the License at
7 # http://www.mozilla.org/MPL/
9 # Software distributed under the License is distributed on an "AS IS" basis,
10 # WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
11 # for the specific language governing rights and limitations under the
12 # License.
14 # The Original Code is [Open Source Virtual Machine.].
16 # The Initial Developer of the Original Code is
17 # Adobe System Incorporated.
18 # Portions created by the Initial Developer are Copyright (C) 2007-2008
19 # the Initial Developer. All Rights Reserved.
21 # Contributor(s):
22 # Adobe AS3 Team
24 # Alternatively, the contents of this file may be used under the terms of
25 # either the GNU General Public License Version 2 or later (the "GPL"), or
26 # the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
27 # in which case the provisions of the GPL or the LGPL are applicable instead
28 # of those above. If you wish to allow use of your version of this file only
29 # under the terms of either the GPL or the LGPL, and not to allow others to
30 # use your version of this file under the terms of the MPL, indicate your
31 # decision by deleting the provisions above and replace them with the notice
32 # and other provisions required by the GPL or the LGPL. If you do not delete
33 # the provisions above, a recipient may use your version of this file under
34 # the terms of any one of the MPL, the GPL or the LGPL.
36 # ***** END LICENSE BLOCK *****
38 PROGRAMS += shell
40 shell_BASENAME = avmshell
41 shell_INCLUDES = -I$(srcdir) -I$(topsrcdir)/extensions
42 shell_DEFINES = -DAVMPLUS_SHELL
43 shell_STATIC_LIBRARIES = zlib MMgc avmplus vmbase
44 shell_DIR := $(curdir)/
45 shell_EXTRA_CPPFLAGS := $(AVMSHELL_CPPFLAGS)
46 shell_EXTRA_LDFLAGS := $(AVMSHELL_LDFLAGS)
48 ifdef ENABLE_SHELL
49 shell_BUILD_ALL = 1
50 endif
52 shell_CXXSRCS := $(shell_CXXSRCS) \
53 $(curdir)/avmshell.cpp \
54 $(curdir)/ConsoleOutputStream.cpp \
55 $(curdir)/DebugCLI.cpp \
56 $(curdir)/DomainClass.cpp \
57 $(curdir)/FileClass.cpp \
58 $(curdir)/FileInputStream.cpp \
59 $(curdir)/ShellCore.cpp \
60 $(curdir)/SystemClass.cpp \
61 $(curdir)/swf.cpp \
62 $(curdir)/../extensions/DictionaryGlue.cpp \
63 $(curdir)/../extensions/JavaGlue.cpp \
64 $(curdir)/../extensions/SamplerScript.cpp \
65 $(curdir)/../extensions/Selftest.cpp \
66 $(curdir)/../extensions/SelftestInit.cpp \
67 $(curdir)/../extensions/ST_avmplus_basics.cpp \
68 $(curdir)/../extensions/ST_avmplus_peephole.cpp \
69 $(curdir)/../extensions/ST_mmgc_basics.cpp \
70 $(curdir)/../extensions/ST_mmgc_dependent.cpp \
71 $(curdir)/../extensions/ST_mmgc_finalize_uninit.cpp \
72 $(curdir)/../extensions/ST_mmgc_threads.cpp \
73 $(curdir)/../extensions/ST_mmgc_weakref.cpp \
74 $(curdir)/../extensions/ST_mmgc_543560.cpp \
75 $(curdir)/../extensions/ST_mmgc_575631.cpp \
76 $(curdir)/../extensions/ST_mmgc_580603.cpp \
77 $(curdir)/../extensions/ST_mmgc_gcheap.cpp \
78 $(curdir)/../extensions/ST_vmbase_concurrency.cpp \
79 $(curdir)/../extensions/ST_vmpi_threads.cpp \
80 $(NULL)
82 ifeq (windows,$(TARGET_OS))
83 shell_CXXSRCS := $(shell_CXXSRCS) \
84 $(curdir)/avmshellWin.cpp \
85 $(curdir)/WinFile.cpp \
86 $(NULL)
87 endif
89 ifeq (darwin,$(TARGET_OS))
90 shell_CXXSRCS := $(shell_CXXSRCS) \
91 $(curdir)/avmshellMac.cpp \
92 $(curdir)/PosixFile.cpp \
93 $(curdir)/PosixPartialPlatform.cpp \
94 $(NULL)
95 endif
97 ifeq (linux,$(TARGET_OS))
98 shell_CXXSRCS := $(shell_CXXSRCS) \
99 $(curdir)/avmshellUnix.cpp \
100 $(curdir)/PosixFile.cpp \
101 $(curdir)/PosixPartialPlatform.cpp \
102 $(NULL)
103 endif
105 ifeq (android,$(TARGET_OS))
106 shell_CXXSRCS := $(shell_CXXSRCS) \
107 $(curdir)/avmshellUnix.cpp \
108 $(curdir)/PosixFile.cpp \
109 $(curdir)/PosixPartialPlatform.cpp \
110 $(NULL)
111 endif
113 ifeq (sunos,$(TARGET_OS))
114 shell_CXXSRCS := $(shell_CXXSRCS) \
115 $(curdir)/avmshellUnix.cpp \
116 $(curdir)/PosixFile.cpp \
117 $(curdir)/PosixPartialPlatform.cpp \
118 $(NULL)
119 endif
121 # See manifest.mk in root directory for the dependencies
122 # on $(topsrcdir)/generated/shell_toplevel.h
124 # Use of '%' [to force a pattern-rule] instead of '$(curdir)/..' or
125 # '$(topsrcdir)' [which would then not be a pattern-rule] is crucial
126 # (ie "deliberate", ie "hack"); see Bug 632086
127 %/generated/shell_toplevel.h %/generated/shell_toplevel.cpp: $(topsrcdir)/shell/shell_toplevel.as
128 cd $(topsrcdir)/shell; python shell_toplevel.py
130 # 1. Use of '$(topsrcdir)/generated' is deliberate; we use absolute
131 # paths for code being generated (or referenced) outside build dir.
133 # 2. Use of '$(curdir)/ShellCore.$(II_SUFFIX)' is also deliberate:
134 # preprocessed file as target must be specified via same path that
135 # is used in root manifest.mk.
137 # Further discussion at Bug 632086.
138 $(curdir)/ShellCore.$(II_SUFFIX): $(topsrcdir)/generated/shell_toplevel.cpp