From eacc5c645e3d1ae28ae0ca53d2e44841b7648692 Mon Sep 17 00:00:00 2001 From: Arin Alexander Date: Mon, 7 May 2018 22:52:28 +0300 Subject: [PATCH] Build has been fixed --- common.pri | 9 ++++++++- demo_r1/mainwindow.cpp | 6 +++--- limereport/lrdatasourcemanager.cpp | 2 +- limereport/lrreportengine.cpp | 2 +- limereport/serializators/lrxmlreader.cpp | 3 ++- 5 files changed, 15 insertions(+), 7 deletions(-) diff --git a/common.pri b/common.pri index 5db695e..b4a4dce 100644 --- a/common.pri +++ b/common.pri @@ -11,13 +11,20 @@ DEPENDPATH += $$PWD/3rdparty/easyprofiler/easy_profiler_core/include contains(CONFIG, easy_profiler){ message(EasyProfiler) unix|win32: LIBS += -L$$PWD/3rdparty/easyprofiler/build/bin/ -leasy_profiler - DEFINES += BUILD_WITH_EASY_PROFILER + greaterThan(QT_MAJOR_VERSION, 4){ + DEFINES += BUILD_WITH_EASY_PROFILER + } } !contains(CONFIG, qtscriptengine){ greaterThan(QT_MAJOR_VERSION, 4){ +greaterThan(QT_MINOR_VERSION, 5){ CONFIG *= qjsengine } +lessThan(QT_MINOR_VERSION, 6){ + CONFIG *= qtscriptengine +} +} lessThan(QT_MAJOR_VERSION, 5){ CONFIG *= qtscriptengine } diff --git a/demo_r1/mainwindow.cpp b/demo_r1/mainwindow.cpp index 48da52f..7f35de3 100644 --- a/demo_r1/mainwindow.cpp +++ b/demo_r1/mainwindow.cpp @@ -38,7 +38,7 @@ #include #include -#ifndef HAVE_QT4 +#ifdef BUILD_WITH_EASY_PROFILER #include "easy/profiler.h" #else # define EASY_BLOCK(...) @@ -127,7 +127,7 @@ void MainWindow::on_pushButton_clicked() report->setShowProgressDialog(false); report->designReport(); EASY_END_BLOCK; -#ifndef HAVE_QT4 +#ifdef BUILD_WITH_EASY_PROFILER profiler::dumpBlocksToFile("test.prof"); #endif } @@ -145,7 +145,7 @@ void MainWindow::on_pushButton_2_clicked() report->dataManager()->setReportVariable(ui->leVariableName->text(), ui->leVariableValue->text()); } EASY_END_BLOCK; -#ifndef HAVE_QT4 +#ifdef BUILD_WITH_EASY_PROFILER profiler::dumpBlocksToFile("test.prof"); #endif report->previewReport(); diff --git a/limereport/lrdatasourcemanager.cpp b/limereport/lrdatasourcemanager.cpp index 60a61fe..ad1cd58 100644 --- a/limereport/lrdatasourcemanager.cpp +++ b/limereport/lrdatasourcemanager.cpp @@ -37,7 +37,7 @@ #include #include -#ifndef HAVE_QT4 +#ifdef BUILD_WITH_EASY_PROFILER #include "easy/profiler.h" #else # define EASY_BLOCK(...) diff --git a/limereport/lrreportengine.cpp b/limereport/lrreportengine.cpp index d938b2e..b54e13e 100644 --- a/limereport/lrreportengine.cpp +++ b/limereport/lrreportengine.cpp @@ -56,7 +56,7 @@ #include "lrpreviewreportwidget.h" #include "lrpreviewreportwidget_p.h" -#ifndef HAVE_QT4 +#ifdef BUILD_WITH_EASY_PROFILER #include "easy/profiler.h" #else # define EASY_BLOCK(...) diff --git a/limereport/serializators/lrxmlreader.cpp b/limereport/serializators/lrxmlreader.cpp index 8748ae5..7439fc4 100644 --- a/limereport/serializators/lrxmlreader.cpp +++ b/limereport/serializators/lrxmlreader.cpp @@ -36,7 +36,8 @@ #include "lrreporttranslation.h" #include -#ifndef HAVE_QT4 + +#ifdef BUILD_WITH_EASY_PROFILER #include "easy/profiler.h" #else # define EASY_BLOCK(...)