fix make clean in the qt build to remove all generated files
[WebKit-https.git] / JavaScriptCore / JavaScriptCore.pro
1 # JavaScriptCore - Qt4 build info
2 VPATH += $$PWD
3 TEMPLATE = lib
4 TARGET = JavaScriptCore
5 DESTDIR = ../lib
6 OBJECTS_DIR = tmp
7 INCLUDEPATH += tmp
8 INCLUDEPATH += $$PWD $$PWD/kjs $$PWD/bindings $$PWD/bindings/c $$PWD/bindings/qt $$PWD/wtf
9 DEFINES -= KJS_IDENTIFIER_HIDE_GLOBALS 
10 DEFINES += BUILDING_QT__
11 QT -= gui
12
13 isEmpty(OUTPUT_DIR):OUTPUT_DIR=$$PWD
14 include($$OUTPUT_DIR/config.pri)
15
16 include(pcre/pcre.pri)
17
18 LUT_FILES += \
19     kjs/date_object.cpp \
20     kjs/number_object.cpp \
21     kjs/string_object.cpp \
22     kjs/array_object.cpp \
23     kjs/math_object.cpp \
24     kjs/regexp_object.cpp
25
26 KEYWORDLUT_FILES += \
27     kjs/keywords.table
28
29 KJSBISON += \
30     kjs/grammar.y
31
32 SOURCES += \
33     wtf/TCSystemAlloc.cpp \
34     wtf/Assertions.cpp \
35     wtf/HashTable.cpp \
36     wtf/FastMalloc.cpp \
37     bindings/NP_jsobject.cpp \
38     bindings/npruntime.cpp \
39     bindings/runtime_array.cpp \
40     bindings/runtime.cpp \
41     bindings/runtime_method.cpp \
42     bindings/runtime_object.cpp \
43     bindings/runtime_root.cpp \
44     bindings/c/c_class.cpp \
45     bindings/c/c_instance.cpp \
46     bindings/c/c_runtime.cpp \
47     bindings/c/c_utility.cpp \
48     bindings/qt/qt_class.cpp \
49     bindings/qt/qt_instance.cpp \
50     bindings/qt/qt_runtime.cpp \
51     kjs/DateMath.cpp \
52     kjs/JSWrapperObject.cpp \
53     kjs/PropertyNameArray.cpp \
54     kjs/array_object.cpp \
55     kjs/bool_object.cpp \
56     kjs/collector.cpp \
57     kjs/Context.cpp \
58     kjs/date_object.cpp \
59     kjs/debugger.cpp \
60     kjs/dtoa.cpp \
61     kjs/error_object.cpp \
62     kjs/ExecState.cpp \
63     kjs/fpconst.cpp \
64     kjs/function.cpp \
65     kjs/function_object.cpp \
66     kjs/identifier.cpp \
67     kjs/internal.cpp \
68     kjs/interpreter.cpp \
69     kjs/JSImmediate.cpp \
70     kjs/JSLock.cpp \
71     kjs/lexer.cpp \
72     kjs/list.cpp \
73     kjs/lookup.cpp \
74     kjs/math_object.cpp \
75     kjs/nodes.cpp \
76     kjs/nodes2string.cpp \
77     kjs/number_object.cpp \
78     kjs/object.cpp \
79     kjs/object_object.cpp \
80     kjs/operations.cpp \
81     kjs/Parser.cpp \
82     kjs/property_map.cpp \
83     kjs/property_slot.cpp \
84     kjs/regexp.cpp \
85     kjs/regexp_object.cpp \
86     kjs/scope_chain.cpp \
87     kjs/string_object.cpp \
88     kjs/ustring.cpp \
89     kjs/value.cpp
90
91
92 # GENERATOR 1-A: LUT creator
93 lut.output = tmp/${QMAKE_FILE_BASE}.lut.h
94 lut.commands = perl $$PWD/kjs/create_hash_table ${QMAKE_FILE_NAME} -i > ${QMAKE_FILE_OUT}
95 lut.depend = ${QMAKE_FILE_NAME}
96 lut.input = LUT_FILES
97 lut.CONFIG += no_link
98 QMAKE_EXTRA_COMPILERS += lut
99
100 # GENERATOR 1-B: particular LUT creator (for 1 file only)
101 keywordlut.output = tmp/lexer.lut.h
102 keywordlut.commands = perl $$PWD/kjs/create_hash_table ${QMAKE_FILE_NAME} -i > ${QMAKE_FILE_OUT}
103 keywordlut.depend = ${QMAKE_FILE_NAME}
104 keywordlut.input = KEYWORDLUT_FILES
105 keywordlut.CONFIG += no_link
106 QMAKE_EXTRA_COMPILERS += keywordlut
107
108 # GENERATOR 2: bison grammar
109 kjsbison.output = tmp/${QMAKE_FILE_BASE}.cpp
110 kjsbison.commands = bison -d -p kjsyy ${QMAKE_FILE_NAME} -o ${QMAKE_FILE_BASE}.tab.c && mv ${QMAKE_FILE_BASE}.tab.c ${QMAKE_FILE_OUT} && mv ${QMAKE_FILE_BASE}.tab.h tmp/${QMAKE_FILE_BASE}.h
111 kjsbison.depend = ${QMAKE_FILE_NAME}
112 kjsbison.input = KJSBISON
113 kjsbison.variable_out = GENERATED_SOURCES
114 kjsbison.dependency_type = TYPE_C
115 kjsbison.CONFIG = target_predeps
116 kjsbison.clean = ${QMAKE_FILE_OUT} tmp/${QMAKE_FILE_BASE}.h
117 QMAKE_EXTRA_COMPILERS += kjsbison