aboutsummaryrefslogtreecommitdiffstats
path: root/src/libs/3rdparty/syntax-highlighting/syntax-highlighting.qbs
blob: b0495897677377df2866db379789e9b2b4858871 (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
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
import qbs 1.0
import qbs.File
import qbs.FileInfo
import qbs.Environment

Project {
    Product {
        name: "KSyntaxHighlighting"

        Export {
            Depends { name: "qtc" }
            Depends {
                name: "Qt.KSyntaxHighlighting"
                condition: qtc.preferSystemSyntaxHighlighting
                required: false
            }
            Depends {
                name: "KSyntaxHighlighting_bundled"
                required: !qtc.preferSystemSyntaxHighlighting
            }
        }
    }

    QtcLibrary {
        name: "KSyntaxHighlighting_bundled"
        condition: !qtc.preferSystemSyntaxHighlighting || !Qt.KSyntaxHighlighting.present

        cpp.defines: base.concat("KF6SyntaxHighlighting_EXPORTS")
        cpp.includePaths: [
            product.sourceDirectory + "/src/lib/",
            product.sourceDirectory + "/autogenerated/include/",
            product.sourceDirectory + "/autogenerated/src/lib/",
            product.sourceDirectory + "/autogenerated/"
        ]

        Depends { name: "Qt.gui" }
        Depends { name: "Qt.network" }
        Depends {
            name: "Qt.KSyntaxHighlighting"
            condition: qtc.preferSystemSyntaxHighlighting
            required: false
        }

        Group {
            name: "lib"
            prefix: "src/lib/"
            files: [
                "abstracthighlighter.cpp",
                "abstracthighlighter.h",
                "abstracthighlighter_p.h",
                "context.cpp",
                "context_p.h",
                "contextswitch.cpp",
                "contextswitch_p.h",
                "definition.cpp",
                "definition.h",
                "definition_p.h",
                "definitiondownloader.cpp",
                "definitiondownloader.h",
                "definitionref_p.h",
                "dynamicregexpcache_p.h",
                "foldingregion.cpp",
                "foldingregion.h",
                "format.cpp",
                "format.h",
                "format_p.h",
                "highlightingdata.cpp",
                "highlightingdata_p.hpp",
                "htmlhighlighter.cpp",
                "htmlhighlighter.h",
                "keywordlist.cpp",
                "keywordlist_p.h",
                "matchresult_p.h",
                "repository.cpp",
                "repository.h",
                "repository_p.h",
                "rule.cpp",
                "rule_p.h",
                "state.cpp",
                "state.h",
                "state_p.h",
                "syntaxhighlighter.cpp",
                "syntaxhighlighter.h",
                "textstyledata_p.h",
                "theme.cpp",
                "theme.h",
                "themedata.cpp",
                "themedata_p.h",
                "wildcardmatcher.cpp",
                "wildcardmatcher.h",
                "worddelimiters.cpp",
                "worddelimiters_p.h",
                "xml_p.h",
            ]
        }

        Group {
            name: "KSyntaxHighlighting data"
            qbs.install: true
            qbs.installDir: qtc.ide_data_path + "/generic-highlighter/"
            qbs.installSourceBase: project.ide_source_tree + "/src/libs/3rdparty/syntax-highlighting/data/"
            prefix: project.ide_source_tree + "/src/libs/3rdparty/syntax-highlighting/data/"
            files: [
                "syntax/**/*"
            ]
        }

        Group {
            name: "autogenerated lib"
            prefix: "autogenerated/src/lib/"
            files: [
                "*.h",
                "*.cpp"
            ]
        }

        Group {
            name: "theme data"
            prefix: "data/themes/"
            files: [ "theme-data.qrc" ]
        }

        Export {
            Depends { name: "cpp" }
            cpp.includePaths: [
                exportingProduct.sourceDirectory + "/src/lib/",
                exportingProduct.sourceDirectory + "/autogenerated/include/",
                exportingProduct.sourceDirectory + "/autogenerated/src/lib/",
            ]
        }
    }
}