1# -------------------------------------------------------------------
2# Project file for the LLIntOffsetsExtractor binary, used to generate
3# derived sources for JavaScriptCore.
4#
5# See 'Tools/qmake/README' for an overview of the build system
6# -------------------------------------------------------------------
7
8TEMPLATE = app
9TARGET = LLIntOffsetsExtractor
10
11debug_and_release {
12    CONFIG += force_build_all
13    CONFIG += build_all
14}
15
16# Don't try to link against any Qt libraries, but at least
17# pull in include paths as we include qglobal.h.
18INCLUDEPATH += $$QT.core.includes
19CONFIG += console
20CONFIG -= qt
21LIBS =
22
23defineTest(addIncludePaths) {
24    # Just needed for include paths
25    include(JavaScriptCore.pri)
26    include(../WTF/WTF.pri)
27
28    export(INCLUDEPATH)
29}
30
31addIncludePaths()
32
33LLINT_DEPENDENCY = \
34    $$PWD/llint/LowLevelInterpreter.asm \
35    $$PWD/llint/LowLevelInterpreter32_64.asm \
36    $$PWD/llint/LowLevelInterpreter64.asm \
37    $$PWD/offlineasm/arm.rb \
38    $$PWD/offlineasm/ast.rb \
39    $$PWD/offlineasm/backends.rb \
40    $$PWD/offlineasm/generate_offset_extractor.rb \
41    $$PWD/offlineasm/instructions.rb \
42    $$PWD/offlineasm/offsets.rb \
43    $$PWD/offlineasm/opt.rb \
44    $$PWD/offlineasm/parser.rb \
45    $$PWD/offlineasm/registers.rb \
46    $$PWD/offlineasm/self_hash.rb \
47    $$PWD/offlineasm/settings.rb \
48    $$PWD/offlineasm/transform.rb \
49    $$PWD/offlineasm/x86.rb
50
51INPUT_FILES = $$PWD/llint/LowLevelInterpreter.asm
52llint.output = LLIntDesiredOffsets.h
53llint.script = $$PWD/offlineasm/generate_offset_extractor.rb
54llint.input = INPUT_FILES
55llint.depends = $$LLINT_DEPENDENCY
56llint.commands = ruby $$llint.script ${QMAKE_FILE_NAME} ${QMAKE_FILE_OUT}
57llint.CONFIG += no_link
58QMAKE_EXTRA_COMPILERS += llint
59
60macx {
61    DESTDIR = $$targetSubDir()
62    llint.output = $$targetSubDir()/$$llint.output
63    INCLUDEPATH += $$targetSubDir()
64}
65
66# Compilation of this file will automatically depend on LLIntDesiredOffsets.h
67# due to qmake scanning the source file for header dependencies.
68SOURCES = llint/LLIntOffsetsExtractor.cpp
69
70mac: LIBS_PRIVATE += -framework AppKit
71