2008-07-25 Simon Hausmann <hausmann@webkit.org>
[WebKit-https.git] / JavaScriptCore / JavaScriptCore.pri
1 # JavaScriptCore - Qt4 build info
2 VPATH += $$PWD
3
4 INCLUDEPATH += tmp
5 INCLUDEPATH += $$PWD $$PWD/kjs $$PWD/wtf $$PWD/wtf/unicode $$PWD/VM $$PWD/profiler $$PWD/API $$PWD/.. \
6                $$PWD/ForwardingHeaders
7 DEFINES += BUILDING_QT__
8
9 isEmpty(GENERATED_SOURCES_DIR):GENERATED_SOURCES_DIR = tmp
10 GENERATED_SOURCES_DIR_SLASH = $$GENERATED_SOURCES_DIR/
11 win32-*: GENERATED_SOURCES_DIR_SLASH ~= s|/|\|
12
13
14 include(pcre/pcre.pri)
15
16 LUT_FILES += \
17     kjs/DatePrototype.cpp \
18     kjs/NumberConstructor.cpp \
19     kjs/StringPrototype.cpp \
20     kjs/ArrayPrototype.cpp \
21     kjs/MathObject.cpp \
22     kjs/RegExpConstructor.cpp \
23     kjs/RegExpObject.cpp
24
25 KEYWORDLUT_FILES += \
26     kjs/keywords.table
27
28 KJSBISON += \
29     kjs/grammar.y
30
31 SOURCES += \
32     wtf/Assertions.cpp \
33     wtf/HashTable.cpp \
34     wtf/MainThread.cpp \
35     wtf/RefCountedLeakCounter.cpp \
36     wtf/unicode/CollatorDefault.cpp \
37     wtf/unicode/icu/CollatorICU.cpp \
38     wtf/unicode/UTF8.cpp \
39     API/JSBase.cpp \
40     API/JSCallbackConstructor.cpp \
41     API/JSCallbackFunction.cpp \
42     API/JSCallbackObject.cpp \
43     API/JSClassRef.cpp \
44     API/JSContextRef.cpp \
45     API/JSObjectRef.cpp \
46     API/JSStringRef.cpp \
47     API/JSValueRef.cpp \
48     kjs/InitializeThreading.cpp \
49     kjs/JSGlobalData.cpp \
50     kjs/JSGlobalObject.cpp \
51     kjs/JSVariableObject.cpp \
52     kjs/JSActivation.cpp \
53     kjs/JSNotAnObject.cpp \
54     VM/CodeBlock.cpp \
55     VM/CodeGenerator.cpp \
56     VM/ExceptionHelpers.cpp \
57     VM/JSPropertyNameIterator.cpp \
58     VM/Machine.cpp \
59     VM/Opcode.cpp \
60     VM/RegisterFile.cpp
61
62 # AllInOneFile.cpp helps gcc analize and optimize code
63 # Other compilers may be able to do this at link time
64 SOURCES += \
65     kjs/ArgList.cpp \
66     kjs/Arguments.cpp \
67     kjs/ArrayConstructor.cpp \
68     kjs/ArrayPrototype.cpp \
69     kjs/BooleanConstructor.cpp \
70     kjs/BooleanObject.cpp \
71     kjs/BooleanPrototype.cpp \
72     kjs/CallData.cpp \
73     kjs/collector.cpp \
74     kjs/CommonIdentifiers.cpp \
75     kjs/ConstructData.cpp \
76     kjs/DateConstructor.cpp \
77     kjs/DateInstance.cpp \
78     kjs/DateMath.cpp \
79     kjs/DatePrototype.cpp \
80     kjs/debugger.cpp \
81     kjs/DebuggerCallFrame.cpp \
82     kjs/dtoa.cpp \
83     kjs/Error.cpp \
84     kjs/ErrorConstructor.cpp \
85     kjs/ErrorInstance.cpp \
86     kjs/ErrorPrototype.cpp \
87     kjs/ExecState.cpp \
88     kjs/FunctionConstructor.cpp \
89     kjs/FunctionPrototype.cpp \
90     kjs/GetterSetter.cpp \
91     kjs/GlobalEvalFunction.cpp \
92     kjs/identifier.cpp \
93     kjs/IndexToNameMap.cpp \
94     kjs/InternalFunction.cpp \
95     kjs/interpreter.cpp \
96     kjs/JSArray.cpp \
97     kjs/JSCell.cpp \
98     kjs/JSFunction.cpp \
99     kjs/JSGlobalObjectFunctions.cpp \
100     kjs/JSImmediate.cpp \
101     kjs/JSLock.cpp \
102     kjs/JSNumberCell.cpp \
103     kjs/JSObject.cpp \
104     kjs/JSString.cpp \
105     kjs/JSValue.cpp \
106     kjs/JSWrapperObject.cpp \
107     kjs/LabelStack.cpp \
108     kjs/lexer.cpp \
109     kjs/lookup.cpp \
110     kjs/MathObject.cpp \
111     kjs/NativeErrorConstructor.cpp \
112     kjs/NativeErrorPrototype.cpp \
113     kjs/nodes.cpp \
114     kjs/nodes2string.cpp \
115     kjs/NumberConstructor.cpp \
116     kjs/NumberObject.cpp \
117     kjs/NumberPrototype.cpp \
118     kjs/ObjectConstructor.cpp \
119     kjs/ObjectPrototype.cpp \
120     kjs/operations.cpp \
121     kjs/Parser.cpp \
122     kjs/PropertyMap.cpp \
123     kjs/PropertyNameArray.cpp \
124     kjs/PropertySlot.cpp \
125     kjs/PrototypeFunction.cpp \
126     kjs/regexp.cpp \
127     kjs/RegExpConstructor.cpp \
128     kjs/RegExpObject.cpp \
129     kjs/RegExpPrototype.cpp \
130     kjs/ScopeChain.cpp \
131     kjs/StringConstructor.cpp \
132     kjs/StringObject.cpp \
133     kjs/StringPrototype.cpp \
134     kjs/ustring.cpp \
135     profiler/HeavyProfile.cpp \
136     profiler/Profile.cpp \
137     profiler/ProfileGenerator.cpp \
138     profiler/ProfileNode.cpp \
139     profiler/Profiler.cpp \
140     profiler/TreeProfile.cpp \
141     wtf/FastMalloc.cpp \
142     wtf/ThreadingQt.cpp \
143     wtf/qt/MainThreadQt.cpp
144
145 # GENERATOR 1-A: LUT creator
146 lut.output = $$GENERATED_SOURCES_DIR/${QMAKE_FILE_BASE}.lut.h
147 lut.commands = perl $$PWD/kjs/create_hash_table ${QMAKE_FILE_NAME} -i > ${QMAKE_FILE_OUT}
148 lut.depend = ${QMAKE_FILE_NAME}
149 lut.input = LUT_FILES
150 lut.CONFIG += no_link
151 addExtraCompiler(lut)
152
153 # GENERATOR 1-B: particular LUT creator (for 1 file only)
154 keywordlut.output = $$GENERATED_SOURCES_DIR/lexer.lut.h
155 keywordlut.commands = perl $$PWD/kjs/create_hash_table ${QMAKE_FILE_NAME} -i > ${QMAKE_FILE_OUT}
156 keywordlut.depend = ${QMAKE_FILE_NAME}
157 keywordlut.input = KEYWORDLUT_FILES
158 keywordlut.CONFIG += no_link
159 addExtraCompiler(keywordlut)
160
161 # GENERATOR 2: bison grammar
162 kjsbison.output = $$GENERATED_SOURCES_DIR/${QMAKE_FILE_BASE}.cpp
163 kjsbison.commands = bison -d -p kjsyy ${QMAKE_FILE_NAME} -o ${QMAKE_FILE_BASE}.tab.c && $(MOVE) ${QMAKE_FILE_BASE}.tab.c ${QMAKE_FILE_OUT} && $(MOVE) ${QMAKE_FILE_BASE}.tab.h $$GENERATED_SOURCES_DIR/${QMAKE_FILE_BASE}.h
164 kjsbison.depend = ${QMAKE_FILE_NAME}
165 kjsbison.input = KJSBISON
166 kjsbison.variable_out = GENERATED_SOURCES
167 kjsbison.dependency_type = TYPE_C
168 kjsbison.CONFIG = target_predeps
169 addExtraCompilerWithHeader(kjsbison)