diff options
author | Christian Stenger <christian.stenger@qt.io> | 2019-02-14 14:58:27 +0100 |
---|---|---|
committer | Christian Stenger <christian.stenger@qt.io> | 2019-03-05 12:29:26 +0000 |
commit | f670e80c8839f2e354515935cfcc2fd0469e5544 (patch) | |
tree | a8aa1f0048764103c1db3036aa623e2004983c84 /src/plugins/texteditor/texteditor.pro | |
parent | 495f98b25652b2e2c96b4fcfd19ebb088a371f98 (diff) | |
download | qt-creator-f670e80c8839f2e354515935cfcc2fd0469e5544.tar.gz |
TextEditor: Allow using KSyntaxHighlighting from system
Set KSYNTAXHIGHLIGHTING_LIB_DIR to the directory that
contains the KSyntaxHighlighting library file
(e.g. libKF5SyntaxHighlighting.{dll,dylib,so}).
This will use the respective files from there and its
related include files instead of the files provided by QC.
If deducing the include directory depending on the library
does not work you can additionally specify
KSYNTAXHIGHLIGHTING_INCLUDE_DIR as well.
Both variables can be set either as qmake variable or
environment variable.
Task-number: QTCREATORBUG-21980
Change-Id: Ie021489d930dfc46ad3e37f9fa02d09fa146ac87
Reviewed-by: David Schulz <david.schulz@qt.io>
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
Diffstat (limited to 'src/plugins/texteditor/texteditor.pro')
-rw-r--r-- | src/plugins/texteditor/texteditor.pro | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/src/plugins/texteditor/texteditor.pro b/src/plugins/texteditor/texteditor.pro index d5bf895ee4..29231afb82 100644 --- a/src/plugins/texteditor/texteditor.pro +++ b/src/plugins/texteditor/texteditor.pro @@ -2,7 +2,19 @@ DEFINES += TEXTEDITOR_LIBRARY QT += gui-private network printsupport xml CONFIG += exceptions CONFIG += include_source_dir # For the highlighter autotest. + +include(../../shared/syntax/syntax_shared.pri) +isEmpty(KSYNTAXHIGHLIGHTING_LIB_DIR) | isEmpty(KSYNTAXHIGHLIGHTING_INCLUDE_DIR) { + QTC_LIB_DEPENDS += syntax-highlighting +} else { + unix:!disable_external_rpath { + !macos: QMAKE_LFLAGS += -Wl,-z,origin + QMAKE_LFLAGS += -Wl,-rpath,$$shell_quote($${KSYNTAXHIGHLIGHTING_LIB_DIR}) + } +} + include(../../qtcreatorplugin.pri) + SOURCES += texteditorplugin.cpp \ plaintexteditorfactory.cpp \ textdocument.cpp \ |