blob: c2790f044f73db7718edf7b276f2d0bb4f853045 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
|
QT = core qmldevtools-private
CONFIG -= app_bundle
CONFIG += console
LLVM_CONFIG=llvm-config
# Pick up the qmake variable or environment variable for LLVM_INSTALL_DIR. If either was set, change the LLVM_CONFIG to use that.
isEmpty(LLVM_INSTALL_DIR):LLVM_INSTALL_DIR=$$(LLVM_INSTALL_DIR)
!isEmpty(LLVM_INSTALL_DIR):LLVM_CONFIG=$$LLVM_INSTALL_DIR/bin/llvm-config
LIBS += -rdynamic
SOURCES += main.cpp \
qv4codegen.cpp \
qv4ir.cpp \
qmljs_runtime.cpp \
qmljs_objects.cpp \
qv4syntaxchecker.cpp \
qv4ecmaobjects.cpp \
qv4array.cpp \
qv4isel_masm.cpp \
llvm_runtime.cpp
HEADERS += \
qv4codegen_p.h \
qv4ir_p.h \
qmljs_runtime.h \
qmljs_objects.h \
qmljs_math.h \
qv4syntaxchecker_p.h \
qv4ecmaobjects_p.h \
qv4array_p.h \
qv4isel_masm_p.h \
qv4isel_util_p.h
llvm {
SOURCES += \
qv4isel_llvm.cpp
HEADERS += \
qv4isel_llvm_p.h \
qv4_llvm_p.h
INCLUDEPATH += \
$$system($$LLVM_CONFIG --includedir)
QMAKE_CXXFLAGS += $$system($$LLVM_CONFIG --cppflags)
LIBS += \
$$system($$LLVM_CONFIG --ldflags) \
$$system($$LLVM_CONFIG --libs core jit bitreader linker ipo target x86 arm native)
QMAKE_EXTRA_TARGETS += gen_llvm_runtime
GEN_LLVM_RUNTIME_FLAGS = $$system($$LLVM_CONFIG --cppflags)
gen_llvm_runtime.target = llvm_runtime
gen_llvm_runtime.commands = clang -O2 -emit-llvm -c $(INCPATH) $$GEN_LLVM_RUNTIME_FLAGS -DQMLJS_LLVM_RUNTIME llvm_runtime.cpp -o llvm_runtime.bc
} else {
DEFINES += QMLJS_NO_LLVM
}
include(moth/moth.pri)
include(masm/masm.pri)
|