LP-106 Setup Wizard refresh : Add dual servo setup (dual aileron or
[librepilot.git] / ground / gcs / src / plugin.pri
blobea4764a9e744f6c1cf44efd888e030a848247416
1 include(../gcs.pri)
3 isEmpty(PROVIDER):PROVIDER = "$$ORG_BIG_NAME"
5 DESTDIR = $$GCS_PLUGIN_PATH/$$PROVIDER
6 LIBS += -L$$DESTDIR
7 INCLUDEPATH += $$GCS_SOURCE_TREE/src/plugins
8 DEPENDPATH += $$GCS_SOURCE_TREE/src/plugins
10 QT += widgets
12 # copy the plugin spec
13 isEmpty(TARGET) {
14     error("qtcreatorplugin.pri: You must provide a TARGET")
17 PLUGINSPECS = $${_PRO_FILE_PWD_}/$${TARGET}.pluginspec
18 copy2build.input = PLUGINSPECS
19 copy2build.output = $$DESTDIR/${QMAKE_FUNC_FILE_IN_stripSrcDir}
20 copy2build.variable_out = PRE_TARGETDEPS
21 copy2build.commands = $$QMAKE_COPY ${QMAKE_FILE_IN} ${QMAKE_FILE_OUT}
22 copy2build.name = COPY ${QMAKE_FILE_IN}
23 copy2build.CONFIG += no_link
24 QMAKE_EXTRA_COMPILERS += copy2build
26 TARGET = $$qtLibraryName($$TARGET)
28 macx {
29         QMAKE_LFLAGS_SONAME = -Wl,-install_name,@executable_path/../Plugins/$${PROVIDER}/
30 } else:linux-* {
31     QMAKE_RPATHDIR  = $$shell_quote(\$$ORIGIN)
32     QMAKE_RPATHDIR += $$shell_quote(\$$ORIGIN/$$relative_path($$GCS_LIBRARY_PATH, $$DESTDIR))
33     QMAKE_RPATHDIR += $$shell_quote(\$$ORIGIN/$$relative_path($$GCS_QT_LIBRARY_PATH, $$DESTDIR))
34     include(rpath.pri)
38 contains(QT_CONFIG, reduce_exports):CONFIG += hGCS_symbols
40 CONFIG += plugin plugin_with_soname
42 !macx {
43     target.path = /$$GCS_LIBRARY_BASENAME/gcs/plugins/$$PROVIDER
44     pluginspec.files += $${TARGET}.pluginspec
45     pluginspec.path = /$$GCS_LIBRARY_BASENAME/gcs/plugins/$$PROVIDER
46     INSTALLS += target pluginspec