If you are using GitLab outside of the ILL, then you will need to use HTTPS and not SSH for clone/push/pull operations. SSH will work normally if you are using the VPN.

Commit 62cb6153 authored by Tobias WEBER's avatar Tobias WEBER

got it to compile on mac again

parent 68f1a3a2
......@@ -10,8 +10,13 @@ cmake_minimum_required(VERSION 3.0)
option(DEBUG "debug build" FALSE)
option(BUILD_FOR_MINGW "build a mingw version" FALSE)
option(BUILD_FOR_MAC "build a mac version" FALSE)
option(USE_PLUGINS "use the plugin system" TRUE)
option(USE_STRIP "strip debug info from release binaries" TRUE)
option(USE_GENTAB "build setup utilities" TRUE)
option(USE_RtMp "use auxilliary libraries" TRUE)
option(USE_Dl "use dl libraries" TRUE)
option(USE_Py "search for python" TRUE)
set(USE_TR1_FUNCS FALSE)
......@@ -38,6 +43,7 @@ else()
set(Boost_DEBUG FALSE)
set(Boost_USE_DEBUG_LIBS FALSE)
set(Boost_USE_RELEASE_LIBS TRUE)
#set(Boost_USE_STATIC_LIBS TRUE)
add_definitions(-DNDEBUG -DQT_NO_DEBUG)
#add_definitions(-march=native -s)
......@@ -53,17 +59,22 @@ add_definitions(-std=c++11 -D_GLIBCXX_USE_CXX11_ABI)
add_definitions("-DBUILD_APPLI")
set(SOCK2 "")
if(BUILD_FOR_MINGW)
# stuff needed by mingw
set(SOCK2 "ws2_32")
set(USE_GENTAB FALSE)
set(USE_RtMp FALSE)
set(SEARCH_PY FALSE)
else()
set(SOCK2 "")
set(USE_GENTAB TRUE)
set(USE_RtMp TRUE)
set(SEARCH_PY TRUE)
set(USE_Dl FALSE)
set(USE_Py FALSE)
endif()
if(BUILD_FOR_MAC)
set(USE_GENTAB FALSE)
set(USE_RtMp FALSE)
set(USE_Dl FALSE)
set(USE_Py TRUE)
endif()
......@@ -87,7 +98,7 @@ if(USE_TR1_FUNCS)
list(APPEND BOOST_COMPS regex)
endif()
if(SEARCH_PY)
if(USE_Py)
find_package(Python3 COMPONENTS Interpreter Development)
endif()
......@@ -132,7 +143,7 @@ else()
set(Mp_LIBRARIES "")
endif()
if(USE_PLUGINS AND NOT BUILD_FOR_MINGW)
if(USE_PLUGINS AND USE_Dl AND NOT BUILD_FOR_MINGW)
find_package(Dl REQUIRED)
else()
set(Dl_LIBRARIES "")
......
find_path(QWT_INCLUDE_DIRS
NAMES qwt.h
PATH_SUFFIXES qwt6-qt5 qwt-qt5 qt5/qwt qt5/qwt/qwt qt5/qwt6 qt5 qwt6 qwt
HINTS /usr/local/include /usr/include /opt/local/include
HINTS /usr/local/include /usr/include /opt/local/include /usr/local/Cellar/qwt/6.1.4/lib/qwt.framework/Versions/6/Headers/
DOC "Qwt include directories"
)
......
......@@ -19,7 +19,7 @@
<key>NSPrincipalClass</key> <string>NSApplication</string>
<key>NSHumanReadableCopyright</key>
<string>Copyright (C) 2014-2019 by Tobias Weber (TUM, Garching, Germany and ILL, Grenoble, France). Copyleft: GPLv2.</string>
<string>Copyright (C) 2014-2020 by Tobias Weber (TUM, Garching, Germany and ILL, Grenoble, France). Copyleft: GPLv2.</string>
<key>CFBundleDocumentTypes</key>
<array>
......
......@@ -42,10 +42,10 @@ declare -a SRC_LIBS=(
"/usr/local/opt/libpng/lib/libpng16.16.dylib"
"/usr/local/opt/libjpeg/lib/libjpeg.9.dylib"
"/usr/local/opt/libtiff/lib/libtiff.5.dylib"
"/usr/local/opt/python3/Frameworks/Python.framework/Versions/3.7/Python"
)
# qt plugins
declare -a SRC_PLUGINS=(
"printsupport/libcocoaprintersupport.dylib"
......@@ -96,6 +96,11 @@ cp -v bin/convofit "${PRG}/Contents/MacOS/"
cp -v bin/convoseries "${PRG}/Contents/MacOS/"
cp -v bin/sfact "${PRG}/Contents/MacOS/"
cp -v bin/polextract "${PRG}/Contents/MacOS/"
# data files
cp -v setup_mac/Info.plist "${PRG}/Contents/"
cp -rv data/res "${PRG}/Contents/"
# -----------------------------------------------------------------------------
......
......@@ -11,7 +11,7 @@ PRG="takin.app"
TOOL=install_name_tool
STRIP=strip
QT_VER="5.12.0"
QT_VER="5.15.0"
# files whose linkage is to be changed
......
......@@ -57,17 +57,17 @@ SqwUniformGrid::SqwUniformGrid(const std::string& strDatFile) : m_strDataFile(st
m_indexBlockOffset = *_blockOffs.second.get();
m_hmin = _dims.second[0];
m_hmax = _dims.second[1];
m_hstep = _dims.second[2];
m_hmin = _dims.second.get()[0];
m_hmax = _dims.second.get()[1];
m_hstep = _dims.second.get()[2];
m_kmin = _dims.second[3];
m_kmax = _dims.second[4];
m_kstep = _dims.second[5];
m_kmin = _dims.second.get()[3];
m_kmax = _dims.second.get()[4];
m_kstep = _dims.second.get()[5];
m_lmin = _dims.second[6];
m_lmax = _dims.second[7];
m_lstep = _dims.second[8];
m_lmin = _dims.second.get()[6];
m_lmax = _dims.second.get()[7];
m_lstep = _dims.second.get()[8];
std::size_t numEntries =
std::size_t(((m_hmax-m_hmin) / m_hstep)) *
......
......@@ -121,9 +121,9 @@ ScanViewerDlg::ScanViewerDlg(QWidget* pParent)
QObject::connect(btnParabola, &QToolButton::clicked, pThis, &ScanViewerDlg::FitParabola);
QObject::connect(btnSine, &QToolButton::clicked, pThis, &ScanViewerDlg::FitSine);
#endif
QObject::connect(comboX, static_cast<void (QComboBox::*)(const QString&)>(&QComboBox::currentIndexChanged), pThis, &ScanViewerDlg::XAxisSelected);
QObject::connect(comboY, static_cast<void (QComboBox::*)(const QString&)>(&QComboBox::currentIndexChanged), pThis, &ScanViewerDlg::YAxisSelected);
QObject::connect(comboMon, static_cast<void (QComboBox::*)(const QString&)>(&QComboBox::currentIndexChanged), pThis, &ScanViewerDlg::MonAxisSelected);
QObject::connect(comboX, static_cast<void (QComboBox::*)(int)>(&QComboBox::currentIndexChanged), pThis, &ScanViewerDlg::XAxisSelected);
QObject::connect(comboY, static_cast<void (QComboBox::*)(int)>(&QComboBox::currentIndexChanged), pThis, &ScanViewerDlg::YAxisSelected);
QObject::connect(comboMon, static_cast<void (QComboBox::*)(int)>(&QComboBox::currentIndexChanged), pThis, &ScanViewerDlg::MonAxisSelected);
QObject::connect(checkNorm, static_cast<void (QCheckBox::*)(int)>(&QCheckBox::stateChanged), pThis, &ScanViewerDlg::NormaliseStateChanged);
//QObject::connect(checkLog, static_cast<void (QCheckBox::*)(int)>(&QCheckBox::stateChanged), pThis, &ScanViewerDlg::LogStateChanged);
QObject::connect(spinStart, static_cast<void (QSpinBox::*)(int)>(&QSpinBox::valueChanged), pThis, &ScanViewerDlg::StartOrSkipChanged);
......@@ -363,9 +363,9 @@ void ScanViewerDlg::SelectDir()
}
void ScanViewerDlg::XAxisSelected(const QString& strLab) { PlotScan(); }
void ScanViewerDlg::YAxisSelected(const QString& strLab) { PlotScan(); }
void ScanViewerDlg::MonAxisSelected(const QString& strLab) { PlotScan(); }
void ScanViewerDlg::XAxisSelected(int) { PlotScan(); }
void ScanViewerDlg::YAxisSelected(int) { PlotScan(); }
void ScanViewerDlg::MonAxisSelected(int) { PlotScan(); }
void ScanViewerDlg::NormaliseStateChanged(int iState) { PlotScan(); }
//void ScanViewerDlg::LogStateChanged(int iState) { PlotScan(); }
void ScanViewerDlg::StartOrSkipChanged(int) { PlotScan(); }
......
......@@ -80,9 +80,9 @@ protected slots:
void DirWasModified(const QString&);
void SearchProps(const QString&);
void XAxisSelected(const QString&);
void YAxisSelected(const QString&);
void MonAxisSelected(const QString&);
void XAxisSelected(int);
void YAxisSelected(int);
void MonAxisSelected(int);
void NormaliseStateChanged(int iState);
//void LogStateChanged(int iState);
void StartOrSkipChanged(int);
......
......@@ -76,7 +76,7 @@ ProjLattice::ProjLattice(ProjLatticeScene& scene)
: m_scene(scene)
{
setFlag(QGraphicsItem::ItemIgnoresTransformations);
setAcceptedMouseButtons(0);
setAcceptedMouseButtons(Qt::NoButton);
m_bReady = 1;
}
......
......@@ -107,7 +107,7 @@ RealLattice::RealLattice(LatticeScene& scene)
: m_scene(scene)
{
setFlag(QGraphicsItem::ItemIgnoresTransformations);
setAcceptedMouseButtons(0);
setAcceptedMouseButtons(Qt::NoButton);
m_bReady = 1;
}
......
......@@ -161,7 +161,7 @@ ScatteringTriangle::ScatteringTriangle(ScatteringTriangleScene& scene)
m_scene.addItem(m_pNodeKfQ.get());
m_scene.addItem(m_pNodeGq.get());
setAcceptedMouseButtons(0);
setAcceptedMouseButtons(Qt::NoButton);
m_bReady = m_bUpdate = 1;
}
......
......@@ -82,7 +82,7 @@ TasLayout::TasLayout(TasLayoutScene& scene) : m_scene(scene),
scene.addItem(m_pAna.get());
scene.addItem(m_pDet.get());
setAcceptedMouseButtons(0);
setAcceptedMouseButtons(Qt::NoButton);
m_bUpdate = m_bReady = 1;
}
......
......@@ -74,7 +74,7 @@ TofLayout::TofLayout(TofLayoutScene& scene) : m_scene(scene)
scene.addItem(m_pSample);
scene.addItem(m_pDet);
setAcceptedMouseButtons(0);
setAcceptedMouseButtons(Qt::NoButton);
m_bUpdate = m_bReady = 1;
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment