1st qt6 port
This commit is contained in:
parent
c8362269f4
commit
638450c8d4
@ -13,20 +13,20 @@ usage()
|
||||
# Adjustable things
|
||||
top=~/Recoll
|
||||
# The possibly bogus version we have in paths (may be harcoded in the .pro)
|
||||
qtpathversion=5.14.2
|
||||
# Will probably need adjustment on M1
|
||||
path_clang=clang_64
|
||||
# The real version for finding macdeployqt
|
||||
qtversion=5.15.2
|
||||
# qtpathversion=Desktop_Qt_5_15_2
|
||||
qtpathversion=Qt_6_2_4
|
||||
# path_clang=clang_64bit
|
||||
path_clang=for_macOS
|
||||
# qtversion=5.15.2
|
||||
qtversion=6.2.4
|
||||
|
||||
deploy=~/Qt/${qtversion}/${path_clang}/bin/macdeployqt
|
||||
|
||||
qt_ver_sion=`echo $qtpathversion | sed -e 's/\./_/g'`
|
||||
#deploy=~/Qt/${qtversion}/macos/clang_64bit/macdeployqt
|
||||
deploy=~/Qt/${qtversion}/macos/bin/macdeployqt
|
||||
|
||||
toprecoll=$top/recoll/src
|
||||
appdir=$toprecoll/build-recoll-win-Desktop_Qt_${qt_ver_sion}_${path_clang}bit-Release/recoll.app
|
||||
rclindexdir=$toprecoll/windows/build-recollindex-Desktop_Qt_${qt_ver_sion}_${path_clang}bit-Release
|
||||
rclqdir=$toprecoll/windows/build-recollq-Desktop_Qt_${qt_ver_sion}_${path_clang}bit-Release
|
||||
appdir=$toprecoll/build-recoll-win-${qtpathversion}_${path_clang}-Release/recoll.app
|
||||
rclindexdir=$toprecoll/windows/build-recollindex-${qtpathversion}_${path_clang}-Release
|
||||
rclqdir=$toprecoll/windows/build-recollq-${qtpathversion}_${path_clang}-Release
|
||||
bindir=$appdir/Contents/MacOS
|
||||
datadir=$appdir/Contents/Resources
|
||||
|
||||
|
||||
@ -28,7 +28,6 @@
|
||||
#include <QRadioButton>
|
||||
#include <QButtonGroup>
|
||||
#include <QMessageBox>
|
||||
#include <QXmlDefaultHandler>
|
||||
|
||||
#include "fragbuts.h"
|
||||
#include "pathut.h"
|
||||
|
||||
@ -18,6 +18,7 @@
|
||||
|
||||
#include <algorithm>
|
||||
#include <cstdio>
|
||||
#include <sstream>
|
||||
|
||||
// Programs built with gcc 4.8.4 (e.g.: Ubuntu Trusty), crash at startup while initializing stdc++
|
||||
// regular expression objects (and also crash if we make them non-static).
|
||||
|
||||
@ -22,7 +22,6 @@
|
||||
|
||||
#include <qapplication.h>
|
||||
#include <qtranslator.h>
|
||||
#include <qtextcodec.h>
|
||||
#include <qtimer.h>
|
||||
#include <qthread.h>
|
||||
#include <qmessagebox.h>
|
||||
@ -345,7 +344,7 @@ int main(int argc, char **argv)
|
||||
}
|
||||
QTranslator qt_trans(0);
|
||||
qt_trans.load(QString("qt_%1").arg(slang),
|
||||
QLibraryInfo::location(QLibraryInfo::TranslationsPath));
|
||||
QLibraryInfo::path(QLibraryInfo::TranslationsPath));
|
||||
app.installTranslator(&qt_trans);
|
||||
|
||||
// Translations for Recoll
|
||||
|
||||
@ -23,6 +23,7 @@
|
||||
#include <QMenu>
|
||||
#include <QPushButton>
|
||||
#include <QMessageBox>
|
||||
#include <QActionGroup>
|
||||
|
||||
void RclMain::buildMenus()
|
||||
{
|
||||
|
||||
@ -248,13 +248,14 @@ void RclMain::startNativeViewer(Rcl::Doc doc, int pagenum, QString qterm)
|
||||
.arg(mt).arg(path2qs(lcmd.front()));
|
||||
|
||||
switch(QMessageBox::warning(0, "Recoll", message,
|
||||
"Yes", "No", 0, 0, 1)) {
|
||||
case 0:
|
||||
QMessageBox::Yes|QMessageBox::No, QMessageBox::No)) {
|
||||
case QMessageBox::Yes:
|
||||
showUIPrefs();
|
||||
if (uiprefs)
|
||||
uiprefs->showViewAction(mt);
|
||||
break;
|
||||
case 1:
|
||||
case QMessageBox::No:
|
||||
default:
|
||||
break;
|
||||
}
|
||||
// The user will have to click on the link again to try the
|
||||
|
||||
@ -44,6 +44,7 @@
|
||||
#include <QSettings>
|
||||
#include <QToolTip>
|
||||
#include <QStandardItemModel>
|
||||
#include <QActionGroup>
|
||||
|
||||
#include "recoll.h"
|
||||
#include "log.h"
|
||||
@ -1089,7 +1090,7 @@ void RclMain::eraseSearchHistory()
|
||||
int rep = QMessageBox::warning(
|
||||
0, tr("Confirm"),
|
||||
tr("Erasing simple and advanced search history lists, please click Ok to confirm"),
|
||||
QMessageBox::Ok, QMessageBox::Cancel, QMessageBox::NoButton);
|
||||
QMessageBox::Ok|QMessageBox::Cancel, QMessageBox::NoButton);
|
||||
if (rep == QMessageBox::Ok) {
|
||||
prefs.ssearchHistory.clear();
|
||||
if (sSearch)
|
||||
|
||||
@ -157,6 +157,7 @@ windows {
|
||||
}
|
||||
|
||||
mac {
|
||||
QMAKE_APPLE_DEVICE_ARCHS = x86_64 arm64
|
||||
QMAKE_CXXFLAGS += -std=c++11 -pthread -Wno-unused-parameter
|
||||
|
||||
HEADERS += \
|
||||
@ -176,8 +177,8 @@ mac {
|
||||
rtitool.ui
|
||||
|
||||
LIBS += \
|
||||
../windows/build-librecoll-Desktop_Qt_5_14_2_clang_64bit-Release/liblibrecoll.a \
|
||||
../../../xapian-core-1.4.18/.libs/libxapian.a \
|
||||
../windows/build-librecoll-Qt_6_2_4_for_macOS-Release/liblibrecoll.a \
|
||||
../windows/build-libxapian-Qt_6_2_4_for_macOS-Release/liblibxapian.a \
|
||||
-lxslt -lxml2 -liconv -lz
|
||||
|
||||
ICON = images/recoll.icns
|
||||
|
||||
@ -153,10 +153,10 @@ void SearchClauseW::setFromClause(SearchDataClauseSimple *cl)
|
||||
case SCLT_PHRASE: case SCLT_NEAR:
|
||||
if (!field.isEmpty()) {
|
||||
int idx = fldCMB->findText(field);
|
||||
if (field >= 0) {
|
||||
fldCMB->setCurrentIndex(idx);
|
||||
if (idx >= 0) {
|
||||
fldCMB->setCurrentIndex(idx);
|
||||
} else {
|
||||
fldCMB->setEditText(field);
|
||||
fldCMB->setEditText(field);
|
||||
}
|
||||
}
|
||||
/* FALLTHROUGH */
|
||||
|
||||
@ -170,14 +170,15 @@ void ViewAction::editActions()
|
||||
except0 = except;
|
||||
} else {
|
||||
if ((action != action0 || except != except0) && dowarnmultiple) {
|
||||
switch (QMessageBox::warning(0, "Recoll",
|
||||
tr("Changing entries with "
|
||||
"different current values"),
|
||||
"Continue",
|
||||
"Cancel",
|
||||
0, 0, 1)) {
|
||||
case 0: dowarnmultiple = false; break;
|
||||
case 1: return;
|
||||
switch (QMessageBox::warning(
|
||||
0, "Recoll", tr("Changing entries with different current values"),
|
||||
QMessageBox::Ignore | QMessageBox::Cancel, QMessageBox::Cancel)) {
|
||||
case QMessageBox::Ignore:
|
||||
dowarnmultiple = false;
|
||||
break;
|
||||
case QMessageBox::Cancel:
|
||||
default:
|
||||
return;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@ -176,6 +176,7 @@ unix:!mac {
|
||||
|
||||
mac {
|
||||
CONFIG += staticlib
|
||||
QMAKE_APPLE_DEVICE_ARCHS = x86_64 arm64
|
||||
# This is necessary to avoid an undefined impl__xmlFree.
|
||||
# See comment in libxml/xmlexports.h
|
||||
DEFINES += LIBXML_STATIC
|
||||
|
||||
@ -3,11 +3,18 @@ QT -= core gui
|
||||
TARGET = libxapian
|
||||
TEMPLATE = lib
|
||||
|
||||
DEFINES += __WIN32__
|
||||
DEFINES += UNICODE
|
||||
DEFINES += HAVE_CONFIG_H
|
||||
|
||||
XAPIANDIR = ../../../../recolldeps/msvc/xapian-core/
|
||||
windows {
|
||||
XAPIANDIR = ../../../../recolldeps/msvc/xapian-core/
|
||||
DEFINES += __WIN32__
|
||||
DEFINES += UNICODE
|
||||
}
|
||||
mac {
|
||||
XAPIANDIR = ../../../../xapian-core-1.4.18/
|
||||
CONFIG += staticlib
|
||||
QMAKE_APPLE_DEVICE_ARCHS = x86_64 arm64
|
||||
}
|
||||
|
||||
SOURCES += \
|
||||
$$XAPIANDIR/api/compactor.cc \
|
||||
|
||||
@ -58,6 +58,7 @@ windows {
|
||||
}
|
||||
|
||||
mac {
|
||||
QMAKE_APPLE_DEVICE_ARCHS = x86_64 arm64
|
||||
QMAKE_CXXFLAGS += -std=c++11 -pthread -Wno-unused-parameter
|
||||
SOURCES += \
|
||||
../../utils/closefrom.cpp \
|
||||
@ -66,7 +67,7 @@ mac {
|
||||
../../utils/rclionice.cpp
|
||||
|
||||
LIBS += \
|
||||
../build-librecoll-Desktop_Qt_5_14_2_clang_64bit-Release/liblibrecoll.a \
|
||||
../../../../xapian-core-1.4.18/.libs/libxapian.a \
|
||||
../build-librecoll-Qt_6_2_4_for_macOS-Release/liblibrecoll.a \
|
||||
../build-libxapian-Qt_6_2_4_for_macOS-Release/liblibxapian.a \
|
||||
-lxslt -lxml2 -liconv -lz
|
||||
}
|
||||
|
||||
@ -45,6 +45,7 @@ windows {
|
||||
}
|
||||
|
||||
mac {
|
||||
QMAKE_APPLE_DEVICE_ARCHS = x86_64 arm64
|
||||
QMAKE_CXXFLAGS += -std=c++11 -pthread -Wno-unused-parameter
|
||||
SOURCES += \
|
||||
../../utils/closefrom.cpp \
|
||||
@ -52,7 +53,7 @@ mac {
|
||||
../../utils/netcon.cpp \
|
||||
../../utils/rclionice.cpp
|
||||
LIBS += \
|
||||
../build-librecoll-Desktop_Qt_5_14_2_clang_64bit-Release/liblibrecoll.a \
|
||||
../../../../xapian-core-1.4.18/.libs/libxapian.a \
|
||||
../build-librecoll-Qt_6_2_4_for_macOS-Release/liblibrecoll.a \
|
||||
../build-libxapian-Qt_6_2_4_for_macOS-Release/liblibxapian.a \
|
||||
-lxslt -lxml2 -liconv -lz
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user