source: webkit/trunk/JavaScriptCore/JavaScriptCore.pri@ 43292

Last change on this file since 43292 was 43292, checked in by Simon Hausmann, 16 years ago

JavaScriptCore:

2009-05-06 Simon Hausmann <[email protected]>

Reviewed by Tor Arne Vestbø.

Tweak JavaScriptCore.pri for being able to override the generated sources dir for the
generated_files target.

WebCore:

2009-05-06 Simon Hausmann <[email protected]>

Reviewed by Tor Arne Vestbø.

Tweak WebCore.pro for being able to override the generated sources dir for the
generated_files target.

File size: 7.6 KB
Line 
1# JavaScriptCore - Qt4 build info
2VPATH += $$PWD
3
4CONFIG(debug, debug|release) {
5 isEmpty(GENERATED_SOURCES_DIR):GENERATED_SOURCES_DIR = generated/debug
6 OBJECTS_DIR = obj/debug
7} else { # Release
8 isEmpty(GENERATED_SOURCES_DIR):GENERATED_SOURCES_DIR = generated/release
9 OBJECTS_DIR = obj/release
10}
11
12INCLUDEPATH += $$GENERATED_SOURCES_DIR
13INCLUDEPATH += $$PWD $$PWD/parser $$PWD/bytecompiler $$PWD/debugger $$PWD/runtime $$PWD/wtf $$PWD/wtf/unicode $$PWD/interpreter $$PWD/jit $$PWD/profiler $$PWD/wrec $$PWD/API $$PWD/.. \
14 $$PWD/ForwardingHeaders $$PWD/bytecode $$PWD/assembler
15DEFINES += BUILDING_QT__
16
17GENERATED_SOURCES_DIR_SLASH = $$GENERATED_SOURCES_DIR/
18win32-* {
19 GENERATED_SOURCES_DIR_SLASH ~= s|/|\|
20 LIBS += -lwinmm
21}
22
23# Default rules to turn JIT on/off
24!contains(DEFINES, ENABLE_JIT=.) {
25 CONFIG(release):isEqual(QT_ARCH,i386) {
26 # Require gcc >= 4.1
27 linux-g++*:greaterThan(QT_GCC_MAJOR_VERSION,3):greaterThan(QT_GCC_MINOR_VERSION,0) {
28 DEFINES += ENABLE_JIT=1
29 }
30 win32-msvc* {
31 DEFINES += ENABLE_JIT=1
32 }
33 }
34}
35
36# Rules when JIT enabled
37contains(DEFINES, ENABLE_JIT=1) {
38 !contains(DEFINES, WREC=.): DEFINES += ENABLE_WREC=1
39 !contains(DEFINES, ENABLE_JIT_OPTIMIZE_CALL=.): DEFINES += ENABLE_JIT_OPTIMIZE_CALL=1
40 !contains(DEFINES, ENABLE_JIT_OPTIMIZE_PROPERTY_ACCESS=.): DEFINES += ENABLE_JIT_OPTIMIZE_PROPERTY_ACCESS=1
41 !contains(DEFINES, ENABLE_JIT_OPTIMIZE_ARITHMETIC=.): DEFINES += ENABLE_JIT_OPTIMIZE_ARITHMETIC=1
42 linux-g++* {
43 !contains(DEFINES, WTF_USE_JIT_STUB_ARGUMENT_VA_LIST=.): DEFINES += WTF_USE_JIT_STUB_ARGUMENT_VA_LIST=1
44 QMAKE_CXXFLAGS += -fno-stack-protector
45 QMAKE_CFLAGS += -fno-stack-protector
46 }
47 win32-msvc* {
48 !contains(DEFINES, WTF_USE_JIT_STUB_ARGUMENT_REGISTER=.): DEFINES += WTF_USE_JIT_STUB_ARGUMENT_REGISTER=1
49 }
50}
51
52include(pcre/pcre.pri)
53
54LUT_FILES += \
55 runtime/DatePrototype.cpp \
56 runtime/NumberConstructor.cpp \
57 runtime/StringPrototype.cpp \
58 runtime/ArrayPrototype.cpp \
59 runtime/MathObject.cpp \
60 runtime/RegExpConstructor.cpp \
61 runtime/RegExpObject.cpp
62
63KEYWORDLUT_FILES += \
64 parser/Keywords.table
65
66JSCBISON += \
67 parser/Grammar.y
68
69SOURCES += \
70 wtf/Assertions.cpp \
71 wtf/ByteArray.cpp \
72 wtf/HashTable.cpp \
73 wtf/MainThread.cpp \
74 wtf/RandomNumber.cpp \
75 wtf/RefCountedLeakCounter.cpp \
76 wtf/TypeTraits.cpp \
77 wtf/unicode/CollatorDefault.cpp \
78 wtf/unicode/icu/CollatorICU.cpp \
79 wtf/unicode/UTF8.cpp \
80 API/JSBase.cpp \
81 API/JSCallbackConstructor.cpp \
82 API/JSCallbackFunction.cpp \
83 API/JSCallbackObject.cpp \
84 API/JSClassRef.cpp \
85 API/JSContextRef.cpp \
86 API/JSObjectRef.cpp \
87 API/JSStringRef.cpp \
88 API/JSValueRef.cpp \
89 API/OpaqueJSString.cpp \
90 runtime/InitializeThreading.cpp \
91 runtime/JSGlobalData.cpp \
92 runtime/JSGlobalObject.cpp \
93 runtime/JSStaticScopeObject.cpp \
94 runtime/JSVariableObject.cpp \
95 runtime/JSActivation.cpp \
96 runtime/JSNotAnObject.cpp \
97 runtime/TimeoutChecker.cpp \
98 bytecode/CodeBlock.cpp \
99 bytecode/StructureStubInfo.cpp \
100 bytecode/JumpTable.cpp \
101 jit/JIT.cpp \
102 jit/JITCall.cpp \
103 jit/JITArithmetic.cpp \
104 jit/JITPropertyAccess.cpp \
105 jit/ExecutableAllocator.cpp \
106 jit/JITStubs.cpp \
107 bytecompiler/BytecodeGenerator.cpp \
108 runtime/ExceptionHelpers.cpp \
109 runtime/JSPropertyNameIterator.cpp \
110 interpreter/Interpreter.cpp \
111 bytecode/Opcode.cpp \
112 bytecode/SamplingTool.cpp \
113 wrec/CharacterClass.cpp \
114 wrec/CharacterClassConstructor.cpp \
115 wrec/WREC.cpp \
116 wrec/WRECFunctors.cpp \
117 wrec/WRECGenerator.cpp \
118 wrec/WRECParser.cpp \
119 interpreter/RegisterFile.cpp
120
121win32-*: SOURCES += jit/ExecutableAllocatorWin.cpp
122else: SOURCES += jit/ExecutableAllocatorPosix.cpp
123
124# AllInOneFile.cpp helps gcc analize and optimize code
125# Other compilers may be able to do this at link time
126SOURCES += \
127 runtime/ArgList.cpp \
128 runtime/Arguments.cpp \
129 runtime/ArrayConstructor.cpp \
130 runtime/ArrayPrototype.cpp \
131 runtime/BooleanConstructor.cpp \
132 runtime/BooleanObject.cpp \
133 runtime/BooleanPrototype.cpp \
134 runtime/CallData.cpp \
135 runtime/Collector.cpp \
136 runtime/CommonIdentifiers.cpp \
137 runtime/ConstructData.cpp \
138 wtf/CurrentTime.cpp \
139 runtime/DateConstructor.cpp \
140 runtime/DateInstance.cpp \
141 runtime/DateMath.cpp \
142 runtime/DatePrototype.cpp \
143 debugger/Debugger.cpp \
144 debugger/DebuggerCallFrame.cpp \
145 debugger/DebuggerActivation.cpp \
146 wtf/dtoa.cpp \
147 runtime/Error.cpp \
148 runtime/ErrorConstructor.cpp \
149 runtime/ErrorInstance.cpp \
150 runtime/ErrorPrototype.cpp \
151 interpreter/CallFrame.cpp \
152 runtime/FunctionConstructor.cpp \
153 runtime/FunctionPrototype.cpp \
154 runtime/GetterSetter.cpp \
155 runtime/GlobalEvalFunction.cpp \
156 runtime/Identifier.cpp \
157 runtime/InternalFunction.cpp \
158 runtime/Completion.cpp \
159 runtime/JSArray.cpp \
160 runtime/JSByteArray.cpp \
161 runtime/JSCell.cpp \
162 runtime/JSFunction.cpp \
163 runtime/JSGlobalObjectFunctions.cpp \
164 runtime/JSImmediate.cpp \
165 runtime/JSLock.cpp \
166 runtime/JSNumberCell.cpp \
167 runtime/JSObject.cpp \
168 runtime/JSString.cpp \
169 runtime/JSValue.cpp \
170 runtime/JSWrapperObject.cpp \
171 parser/Lexer.cpp \
172 runtime/Lookup.cpp \
173 runtime/MathObject.cpp \
174 runtime/NativeErrorConstructor.cpp \
175 runtime/NativeErrorPrototype.cpp \
176 parser/Nodes.cpp \
177 runtime/NumberConstructor.cpp \
178 runtime/NumberObject.cpp \
179 runtime/NumberPrototype.cpp \
180 runtime/ObjectConstructor.cpp \
181 runtime/ObjectPrototype.cpp \
182 runtime/Operations.cpp \
183 parser/Parser.cpp \
184 runtime/PropertyNameArray.cpp \
185 runtime/PropertySlot.cpp \
186 runtime/PrototypeFunction.cpp \
187 runtime/RegExp.cpp \
188 runtime/RegExpConstructor.cpp \
189 runtime/RegExpObject.cpp \
190 runtime/RegExpPrototype.cpp \
191 runtime/ScopeChain.cpp \
192 runtime/SmallStrings.cpp \
193 runtime/StringConstructor.cpp \
194 runtime/StringObject.cpp \
195 runtime/StringPrototype.cpp \
196 runtime/Structure.cpp \
197 runtime/StructureChain.cpp \
198 runtime/UString.cpp \
199 profiler/HeavyProfile.cpp \
200 profiler/Profile.cpp \
201 profiler/ProfileGenerator.cpp \
202 profiler/ProfileNode.cpp \
203 profiler/Profiler.cpp \
204 profiler/TreeProfile.cpp \
205 wtf/FastMalloc.cpp \
206 wtf/Threading.cpp \
207 wtf/qt/ThreadingQt.cpp \
208 wtf/qt/MainThreadQt.cpp
209
210# GENERATOR 1-A: LUT creator
211lut.output = $$GENERATED_SOURCES_DIR/${QMAKE_FILE_BASE}.lut.h
212lut.commands = perl $$PWD/create_hash_table ${QMAKE_FILE_NAME} -i > ${QMAKE_FILE_OUT}
213lut.depend = ${QMAKE_FILE_NAME}
214lut.input = LUT_FILES
215lut.CONFIG += no_link
216addExtraCompiler(lut)
217
218# GENERATOR 1-B: particular LUT creator (for 1 file only)
219keywordlut.output = $$GENERATED_SOURCES_DIR/Lexer.lut.h
220keywordlut.commands = perl $$PWD/create_hash_table ${QMAKE_FILE_NAME} -i > ${QMAKE_FILE_OUT}
221keywordlut.depend = ${QMAKE_FILE_NAME}
222keywordlut.input = KEYWORDLUT_FILES
223keywordlut.CONFIG += no_link
224addExtraCompiler(keywordlut)
225
226# GENERATOR 2: bison grammar
227jscbison.output = $$GENERATED_SOURCES_DIR/${QMAKE_FILE_BASE}.cpp
228jscbison.commands = bison -d -p jscyy ${QMAKE_FILE_NAME} -o $$GENERATED_SOURCES_DIR/${QMAKE_FILE_BASE}.tab.c && $(MOVE) $$GENERATED_SOURCES_DIR/${QMAKE_FILE_BASE}.tab.c ${QMAKE_FILE_OUT} && $(MOVE) $$GENERATED_SOURCES_DIR/${QMAKE_FILE_BASE}.tab.h $$GENERATED_SOURCES_DIR/${QMAKE_FILE_BASE}.h
229jscbison.depend = ${QMAKE_FILE_NAME}
230jscbison.input = JSCBISON
231jscbison.variable_out = GENERATED_SOURCES
232jscbison.dependency_type = TYPE_C
233jscbison.CONFIG = target_predeps
234addExtraCompilerWithHeader(jscbison)
235
Note: See TracBrowser for help on using the repository browser.