@@ -1,20 +1,18 | |||
|
1 | 1 | |
|
2 | QT_PATH=".../Qt/5.8/gcc_64/lib/cmake/" | |
|
3 | ||
|
4 | 2 | export CC=/usr/libexec/ccc-analyzer |
|
5 | 3 | export CXX=/usr/libexec/c++-analyzer |
|
6 | 4 | export CCC_CC=clang |
|
7 | 5 | export CCC_CXX=clang++ |
|
8 | 6 | export LD=clang++ |
|
9 | 7 | export CCC_ANALYZER_VERBOSE=1 |
|
10 | 8 | |
|
11 | 9 | LD_LIBRARY_PATH=/usr/local/lib64 |
|
12 | 10 | export LD_LIBRARY_PATH |
|
13 | 11 | |
|
14 | 12 | rm -rf build_clang-analyzer |
|
15 | 13 | mkdir build_clang-analyzer |
|
16 | 14 | cd build_clang-analyzer |
|
17 | 15 | |
|
18 |
scan-build cmake |
|
|
16 | scan-build cmake -DCMAKE_CXX_COMPILER=clazy -DENABLE_ANALYSIS=false -DENABLE_CPPCHECK=false -DENABLE_FORMATTING=false -DENABLE_CHECKSTYLE=false -BUILD_DOCUMENTATION=false -BUILD_TESTS=false -DCMAKE_BUILD_TYPE=Debug ../../SCIQLOP-Initialisation/ | |
|
19 | 17 | |
|
20 | 18 | scan-build -o clang-analyzer-output make -j2 |
@@ -1,39 +1,39 | |||
|
1 | 1 | /*------------------------------------------------------------------------------ |
|
2 | 2 | -- This file is a part of the QLop Software |
|
3 | 3 | -- Copyright (C) 2015, Plasma Physics Laboratory - CNRS |
|
4 | 4 | -- |
|
5 | 5 | -- This program is free software; you can redistribute it and/or modify |
|
6 | 6 | -- it under the terms of the GNU General Public License as published by |
|
7 | 7 | -- the Free Software Foundation; either version 2 of the License, or |
|
8 | 8 | -- (at your option) any later version. |
|
9 | 9 | -- |
|
10 | 10 | -- This program is distributed in the hope that it will be useful, |
|
11 | 11 | -- but WITHOUT ANY WARRANTY; without even the implied warranty of |
|
12 | 12 | -- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
|
13 | 13 | -- GNU General Public License for more details. |
|
14 | 14 | -- |
|
15 | 15 | -- You should have received a copy of the GNU General Public License |
|
16 | 16 | -- along with this program; if not, write to the Free Software |
|
17 | 17 | -- Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA |
|
18 | 18 | -------------------------------------------------------------------------------*/ |
|
19 | 19 | /*-- Author : Alexis Jeandet |
|
20 | 20 | -- Mail : alexis.jeandet@member.fsf.org |
|
21 | 21 | ----------------------------------------------------------------------------*/ |
|
22 | 22 | #include "mainwindow.h" |
|
23 | 23 | #include <QProcessEnvironment> |
|
24 | 24 | #include <QThread> |
|
25 | 25 | #include <SqpApplication.h> |
|
26 | #include <omp.h> | |
|
27 | 26 | #include <qglobal.h> |
|
28 | 27 | |
|
29 | 28 | int main(int argc, char *argv[]) |
|
30 | 29 | { |
|
30 | int ad; | |
|
31 | 31 | SqpApplication a(argc, argv); |
|
32 | 32 | SqpApplication::setOrganizationName("LPP"); |
|
33 | 33 | SqpApplication::setOrganizationDomain("lpp.fr"); |
|
34 | 34 | SqpApplication::setApplicationName("SciQLop"); |
|
35 | 35 | MainWindow w; |
|
36 | 36 | w.show(); |
|
37 | 37 | |
|
38 | 38 | return a.exec(); |
|
39 | 39 | } |
@@ -1,104 +1,103 | |||
|
1 | 1 | /*------------------------------------------------------------------------------ |
|
2 | 2 | -- This file is a part of the QLop Software |
|
3 | 3 | -- Copyright (C) 2015, Plasma Physics Laboratory - CNRS |
|
4 | 4 | -- |
|
5 | 5 | -- This program is free software; you can redistribute it and/or modify |
|
6 | 6 | -- it under the terms of the GNU General Public License as published by |
|
7 | 7 | -- the Free Software Foundation; either version 2 of the License, or |
|
8 | 8 | -- (at your option) any later version. |
|
9 | 9 | -- |
|
10 | 10 | -- This program is distributed in the hope that it will be useful, |
|
11 | 11 | -- but WITHOUT ANY WARRANTY; without even the implied warranty of |
|
12 | 12 | -- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
|
13 | 13 | -- GNU General Public License for more details. |
|
14 | 14 | -- |
|
15 | 15 | -- You should have received a copy of the GNU General Public License |
|
16 | 16 | -- along with this program; if not, write to the Free Software |
|
17 | 17 | -- Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA |
|
18 | 18 | -------------------------------------------------------------------------------*/ |
|
19 | 19 | /*-- Author : Alexis Jeandet |
|
20 | 20 | -- Mail : alexis.jeandet@member.fsf.org |
|
21 | 21 | ----------------------------------------------------------------------------*/ |
|
22 | 22 | #include "mainwindow.h" |
|
23 | 23 | #include "ui_mainwindow.h" |
|
24 | 24 | #include <QAction> |
|
25 | 25 | #include <QDate> |
|
26 | 26 | #include <QDateTime> |
|
27 | 27 | #include <QDir> |
|
28 | 28 | #include <QFileDialog> |
|
29 | #include <omp.h> | |
|
29 | //#include <omp.h> | |
|
30 | 30 | //#include <network/filedownloader.h> |
|
31 | 31 | //#include <qlopdatabase.h> |
|
32 | 32 | //#include <qlopsettings.h> |
|
33 | 33 | //#include <qlopgui.h> |
|
34 | 34 | //#include <spacedata.h> |
|
35 | 35 | //#include "qlopcore.h" |
|
36 | 36 | //#include "qlopcodecmanager.h" |
|
37 | 37 | //#include "cdfcodec.h" |
|
38 | 38 | //#include "amdatxtcodec.h" |
|
39 | 39 | //#include <qlopplotmanager.h> |
|
40 | 40 | |
|
41 | ||
|
42 | 41 | MainWindow::MainWindow(QWidget *parent) : QMainWindow(parent), ui(new Ui::MainWindow) |
|
43 | 42 | { |
|
44 | 43 | ui->setupUi(this); |
|
45 | 44 | /* QLopGUI::registerMenuBar(menuBar()); |
|
46 | 45 | this->setWindowIcon(QIcon(":/sciqlopLOGO.svg")); |
|
47 | 46 | this->m_progressWidget = new QWidget(); |
|
48 | 47 | this->m_progressLayout = new QVBoxLayout(this->m_progressWidget); |
|
49 | 48 | this->m_progressWidget->setLayout(this->m_progressLayout); |
|
50 | 49 | this->m_progressWidget->setWindowModality(Qt::WindowModal); |
|
51 | 50 | m_progressThreadIds = (int*) malloc(OMP_THREADS*sizeof(int)); |
|
52 | 51 | for(int i=0;i<OMP_THREADS;i++) |
|
53 | 52 | { |
|
54 | 53 | this->m_progress.append(new QProgressBar(this->m_progressWidget)); |
|
55 | 54 | this->m_progress.last()->setMinimum(0); |
|
56 | 55 | this->m_progress.last()->setMaximum(100); |
|
57 | 56 | this->m_progressLayout->addWidget(this->m_progress.last()); |
|
58 | 57 | this->m_progressWidget->hide(); |
|
59 | 58 | this->m_progressThreadIds[i] = -1; |
|
60 | 59 | } |
|
61 | 60 | this->m_progressWidget->setWindowTitle("Loading File"); |
|
62 | 61 | const QList<QLopService*>ServicesToLoad=QList<QLopService*>() |
|
63 | 62 | << QLopCore::self() |
|
64 | 63 | << QLopPlotManager::self() |
|
65 | 64 | << QLopCodecManager::self() |
|
66 | 65 | << FileDownloader::self() |
|
67 | 66 | << QLopDataBase::self() |
|
68 | 67 | << SpaceData::self(); |
|
69 | 68 | |
|
70 | 69 | CDFCodec::registerToManager(); |
|
71 | 70 | AMDATXTCodec::registerToManager(); |
|
72 | 71 | |
|
73 | 72 | |
|
74 | 73 | for(int i=0;i<ServicesToLoad.count();i++) |
|
75 | 74 | { |
|
76 | 75 | qDebug()<<ServicesToLoad.at(i)->serviceName(); |
|
77 | 76 | ServicesToLoad.at(i)->initialize(); //must be called before getGUI |
|
78 | 77 | QDockWidget* wdgt=ServicesToLoad.at(i)->getGUI(); |
|
79 | 78 | if(wdgt) |
|
80 | 79 | { |
|
81 | 80 | wdgt->setAllowedAreas(Qt::AllDockWidgetAreas); |
|
82 | 81 | this->addDockWidget(Qt::TopDockWidgetArea,wdgt); |
|
83 | 82 | } |
|
84 | 83 | PythonQt::self()->getMainModule().addObject(ServicesToLoad.at(i)->serviceName(),(QObject*)ServicesToLoad.at(i)); |
|
85 | 84 | }*/ |
|
86 | 85 | } |
|
87 | 86 | |
|
88 | 87 | MainWindow::~MainWindow() |
|
89 | 88 | { |
|
90 | 89 | delete ui; |
|
91 | 90 | } |
|
92 | 91 | |
|
93 | 92 | |
|
94 | 93 | void MainWindow::changeEvent(QEvent *e) |
|
95 | 94 | { |
|
96 | 95 | QMainWindow::changeEvent(e); |
|
97 | 96 | switch (e->type()) { |
|
98 | 97 | case QEvent::LanguageChange: |
|
99 | 98 | ui->retranslateUi(this); |
|
100 | 99 | break; |
|
101 | 100 | default: |
|
102 | 101 | break; |
|
103 | 102 | } |
|
104 | 103 | } |
@@ -1,99 +1,88 | |||
|
1 | 1 | # |
|
2 | 2 | # sciqlop_params : Define compilation parameters |
|
3 | 3 | # |
|
4 | 4 | # Debug or release |
|
5 | 5 | # |
|
6 | 6 | # As the "NMake Makefiles" forces by default the CMAKE_BUILD_TYPE variable to Debug, SCIQLOP_BUILD_TYPE variable is used to be sure that the debug mode is a user choice |
|
7 | 7 | #SET(SCIQLOP_BUILD_TYPE "Release" CACHE STRING "Choose to compile in Debug or Release mode") |
|
8 | 8 | |
|
9 | #IF(SCIQLOP_BUILD_TYPE MATCHES "Debug") | |
|
10 | # MESSAGE (STATUS "Build in Debug") | |
|
11 | # SET (CMAKE_BUILD_TYPE "Debug") | |
|
12 | # SET (DEBUG_SUFFIX "d") | |
|
13 | #ELSE() | |
|
14 | # MESSAGE (STATUS "Build in Release") | |
|
15 | # SET (CMAKE_BUILD_TYPE "Release") | |
|
16 | # SET (SCIQLOP_BUILD_TYPE "Release") | |
|
17 | # SET (DEBUG_SUFFIX "") | |
|
18 | #ENDIF() | |
|
19 | ||
|
20 | 9 | IF(CMAKE_BUILD_TYPE MATCHES "Debug") |
|
21 | 10 | SET (CMAKE_BUILD_TYPE "Debug") |
|
22 | 11 | SET (DEBUG_SUFFIX "d") |
|
23 | 12 | ELSE() |
|
24 | 13 | MESSAGE (STATUS "Build in Release") |
|
25 | 14 | SET (SCIQLOP_BUILD_TYPE "Release") |
|
26 | 15 | SET (DEBUG_SUFFIX "") |
|
27 | 16 | ENDIF() |
|
28 | 17 | |
|
29 | 18 | # |
|
30 | 19 | # Need to compile tests? |
|
31 | 20 | # |
|
32 | 21 | OPTION (BUILD_TESTS "Build the tests" OFF) |
|
33 | 22 | ENABLE_TESTING(${BUILD_TESTS}) |
|
34 | 23 | |
|
35 | 24 | # |
|
36 | 25 | # Path to the folder for sciqlop's extern libraries. |
|
37 | 26 | # |
|
38 | 27 | # When looking for an external library in sciqlop, we look to the following |
|
39 | 28 | # folders: |
|
40 | 29 | # - The specific folder for the library (generally of the form <LIBRARY>_ROOT_DIR |
|
41 | 30 | # - The global Sciqlop extern folder |
|
42 | 31 | # - The system folders. |
|
43 | 32 | # |
|
44 | 33 | # If a dependency is found in the global extern folder or a specific folder for |
|
45 | 34 | # the library, then it is installed with the sciqlop libraries. If it is found |
|
46 | 35 | # in the system folders, it is not. This behavior can be overriden with the |
|
47 | 36 | # <LIBRARY>_COPY_SHARED_LIBRARIES flag. |
|
48 | 37 | # |
|
49 | 38 | set(SCIQLOP_EXTERN_FOLDER "${CMAKE_CURRENT_SOURCE_DIR}/extern" |
|
50 | 39 | CACHE PATH "Path to the folder for sciqlop's extern libraries") |
|
51 | 40 | option(SCIQLOP_FORCE_UPDATE_EXT_ROOT_DIR "Force the <LIBRARY>_ROOT_DIR to be updated to the global sciqlop extern folder" |
|
52 | 41 | OFF) |
|
53 | 42 | |
|
54 | 43 | if (SCIQLOP_FORCE_UPDATE_EXT_ROOT_DIR) |
|
55 | 44 | set(libRootDirForceValue FORCE) |
|
56 | 45 | else() |
|
57 | 46 | set(libRootDirForceValue) |
|
58 | 47 | endif() |
|
59 | 48 | |
|
60 | 49 | |
|
61 | 50 | |
|
62 | 51 | # |
|
63 | 52 | # Static or shared libraries |
|
64 | 53 | # |
|
65 | 54 | OPTION (BUILD_SHARED_LIBS "Build the shared libraries" ON) |
|
66 | 55 | |
|
67 | 56 | # Generate position independant code (-fPIC) |
|
68 | 57 | SET(CMAKE_POSITION_INDEPENDENT_CODE TRUE) |
|
69 | 58 | |
|
70 | 59 | # |
|
71 | 60 | # Configure installation directories |
|
72 | 61 | # |
|
73 | 62 | IF (UNIX) |
|
74 | 63 | SET(defaultBin "bin") |
|
75 | 64 | SET(defaultInc "include/sciqlop") |
|
76 | 65 | |
|
77 | 66 | # 32 or 64 bits compiler |
|
78 | 67 | IF( CMAKE_SIZEOF_VOID_P EQUAL 8 ) |
|
79 | 68 | SET(defaultLib "lib64/sciqlop") |
|
80 | 69 | ELSE() |
|
81 | 70 | SET(defaultLib "lib/sciqlop") |
|
82 | 71 | ENDIF() |
|
83 | 72 | |
|
84 | 73 | SET(defaultDoc "share/docs/sciqlop") |
|
85 | 74 | ELSE() |
|
86 | 75 | SET(defaultBin "bin") |
|
87 | 76 | SET(defaultInc "include/sciqlop") |
|
88 | 77 | SET(defaultLib "lib/sciqlop") |
|
89 | 78 | SET(defaultDoc "docs/sciqlop") |
|
90 | 79 | ENDIF() |
|
91 | 80 | |
|
92 | 81 | SET(INSTALL_BINARY_DIR "${defaultBin}" CACHE STRING |
|
93 | 82 | "Installation directory for binaries") |
|
94 | 83 | SET(INSTALL_LIBRARY_DIR "${defaultLib}" CACHE STRING |
|
95 | 84 | "Installation directory for libraries") |
|
96 | 85 | SET(INSTALL_INCLUDE_DIR "${defaultInc}" CACHE STRING |
|
97 | 86 | "Installation directory for headers") |
|
98 | 87 | SET(INSTALL_DOCUMENTATION_DIR "${defaultDoc}" CACHE STRING |
|
99 | 88 | "Installation directory for documentations") |
General Comments 0
You need to be logged in to leave comments.
Login now