Update qcad to 3.27.6.7

QCad still segfault but maybe an updated version helps us to debug it.
Reported by Andy Bradford
This commit is contained in:
rsadowski 2022-08-29 15:18:10 +00:00
parent b8af65696c
commit ad55bb8b47
18 changed files with 2319 additions and 97 deletions

View File

@ -2,10 +2,9 @@ COMMENT = Qt-based 2D CAD system
GH_ACCOUNT = qcad
GH_PROJECT = qcad
GH_TAGNAME = v3.24.3.0
REVISION = 2
GH_TAGNAME = v3.27.6.7
SO_VERSION = 1.0
SO_VERSION = 2.0
QCAD_LIBS = qcadcore \
qcadecmaapi \
qcadentity \
@ -38,7 +37,9 @@ MODULES = devel/qmake \
x11/qt5
BUILD_DEPENDS = x11/qt5/qtimageformats
RUN_DEPENDS = devel/desktop-file-utils
LIB_DEPENDS = print/cups,-libs \
textproc/libstemmer \
x11/qt5/qtscript \
@ -46,17 +47,22 @@ LIB_DEPENDS = print/cups,-libs \
x11/qt5/qttools \
x11/qt5/qtxmlpatterns
SEPARATE_BUILD =No
USE_GMAKE = Yes
NO_TEST = Yes
SEPARATE_BUILD = No
USE_GMAKE = Yes
NO_TEST = Yes
pre-configure:
# Do not require specific Qt version
sed -i "s|\$$\$${QT_VERSION}|5.5.0|g" \
sed -i "s|\$$\$${QT_VERSION}|${MODQT5_VERSION}|g" \
${WRKSRC}/src/3rdparty/3rdparty.pro
mkdir ${WRKSRC}/src/3rdparty/qt-labs-qtscriptgenerator-${MODQT5_VERSION}
cp ${WRKSRC}/src/3rdparty/qt-labs-qtscriptgenerator-5.15.2/qt-labs-qtscriptgenerator-5.15.2.pro \
${WRKSRC}/src/3rdparty/qt-labs-qtscriptgenerator-${MODQT5_VERSION}/qt-labs-qtscriptgenerator-${MODQT5_VERSION}.pro
${SUBST_CMD} ${WRKSRC}/src/core/RS.cpp \
${WRKSRC}/src/core/RSettings.cpp
${WRKSRC}/src/core/RSettings.cpp \
${WRKSRC}/scripts/Help/ShowReadme/ShowReadme.js \
${WRKSRC}/scripts/Widgets/LibraryBrowser/LibraryBrowser.js
do-install:
${INSTALL_PROGRAM} ${WRKSRC}/release/qcad-bin ${PREFIX}/bin/qcad

View File

@ -1,2 +1,2 @@
SHA256 (qcad-3.24.3.0.tar.gz) = A1JZf9QfaKQ8+qrFsWufK9Dn2x12mGPJMXDeZMgEv3c=
SIZE (qcad-3.24.3.0.tar.gz) = 33874174
SHA256 (qcad-3.27.6.7.tar.gz) = 28o7+p9nHj+bAfXf8LhIdDwhyPv314x7Gkor1PlzNLM=
SIZE (qcad-3.27.6.7.tar.gz) = 41097738

View File

@ -0,0 +1,15 @@
disable searching outside of the source directory
Index: qcad.pro
--- qcad.pro.orig
+++ qcad.pro
@@ -11,9 +11,6 @@ win32 {
SUBDIRS += ..\\$$dir
}
}
-else {
- SUBDIRS += $$system("ls -d ../qcad?* 2>/dev/null | grep -v $(basename $(pwd))$")
-}
!r_mobile {
exists(support) {

View File

@ -1,7 +1,7 @@
Index: scripts/Help/About/About.js
--- scripts/Help/About/About.js.orig
+++ scripts/Help/About/About.js
@@ -467,6 +467,9 @@ About.prototype.initAboutSystem = function(textEdit) {
@@ -474,6 +474,9 @@ About.prototype.initAboutSystem = function(textEdit) {
if (RS.getSystemId()==="solaris") {
text += "Solaris";
}

View File

@ -0,0 +1,12 @@
Index: scripts/Help/ShowReadme/ShowReadme.js
--- scripts/Help/ShowReadme/ShowReadme.js.orig
+++ scripts/Help/ShowReadme/ShowReadme.js
@@ -19,7 +19,7 @@
include("scripts/Help/Help.js");
-ShowReadme.readmeFile = "readme.txt";
+ShowReadme.readmeFile = "${LOCALBASE}/share/qcadreadme.txt";
function ShowReadme(guiAction) {
Help.call(this, guiAction);

View File

@ -1,7 +1,7 @@
Index: scripts/Widgets/CommandLine/CommandLine.js
--- scripts/Widgets/CommandLine/CommandLine.js.orig
+++ scripts/Widgets/CommandLine/CommandLine.js
@@ -490,6 +490,9 @@ CommandLine.init = function(basePath) {
@@ -498,6 +498,9 @@ CommandLine.init = function(basePath) {
case "solaris":
system = "Solaris";
break;

View File

@ -0,0 +1,18 @@
Index: scripts/Widgets/LibraryBrowser/LibraryBrowser.js
--- scripts/Widgets/LibraryBrowser/LibraryBrowser.js.orig
+++ scripts/Widgets/LibraryBrowser/LibraryBrowser.js
@@ -174,12 +174,12 @@ LibraryBrowser.getSourceList = function() {
var libs;
// no configuration: add all libraries available in libraries subdir:
- librariesDir = new QDir("libraries");
+ librariesDir = new QDir("${LOCALBASE}/share/qcad/libraries");
libs = librariesDir.entryList([], filters, sortFlags);
for (i=0; i<libs.length; i++) {
// always add default library if available:
if (libs[i]==="default" || noSourcesConfigured) {
- sourceList.push(QDir.fromNativeSeparators(new QDir("libraries/%1".arg(libs[i])).absolutePath()));
+ sourceList.push(QDir.fromNativeSeparators(new QDir("%1/%2".arg(librariesDir.absolutePath()).arg(libs[i])).absolutePath()));
}
}

View File

@ -1,7 +1,7 @@
Index: shared_app.pri
--- shared_app.pri.orig
+++ shared_app.pri
@@ -16,7 +16,7 @@ LIBS += \
@@ -19,7 +19,7 @@ LIBS += \
!r_no_opennurbs {
LIBS += \
-lopennurbs \

View File

@ -1,7 +1,7 @@
Index: shared.pri
--- shared.pri.orig
+++ shared.pri
@@ -164,7 +164,7 @@ else {
@@ -193,7 +193,7 @@ else {
CONFIG -= warn_off
CONFIG += warn_on

View File

@ -4,7 +4,7 @@ have in our libc.
Index: src/core/RDebug.cpp
--- src/core/RDebug.cpp.orig
+++ src/core/RDebug.cpp
@@ -34,7 +34,7 @@ QMap<QString, int> RDebug::counter;
@@ -35,7 +35,7 @@ QMap<QString, int> RDebug::counter;
QString RDebug::prefix;
void RDebug::printBacktrace(const QString& prefix) {

View File

@ -1,12 +1,13 @@
Index: src/core/RS.cpp
--- src/core/RS.cpp.orig
+++ src/core/RS.cpp
@@ -150,6 +150,8 @@ QStringList RS::getDirectoryList(const QString& subDir
@@ -169,6 +169,9 @@ QStringList RS::getDirectoryList(const QString& subDir
dirList.append(appDir + "/../Resources/" + subDirectory);
dirList.append(appDir + "/../../../" + subDirectory);
dirList.append(QDir::currentPath() + "/" + subDirectory);
+#elif defined Q_OS_OPENBSD
+ dirList.append("${LOCALBASE}/share/qcad/" + subDirectory);
+ dirList.append(QDir::homePath() + "/.qcad/" + subDirectory);
#else
dirList.append(appDir + "/" + subDirectory);
#endif

View File

@ -1,7 +1,7 @@
Index: src/core/RSettings.cpp
--- src/core/RSettings.cpp.orig
+++ src/core/RSettings.cpp
@@ -363,9 +363,13 @@ QString RSettings::getApplicationPath() {
@@ -364,9 +364,13 @@ QString RSettings::getApplicationPath() {
}
#endif

View File

@ -1,7 +1,7 @@
Index: src/core/core.pro
--- src/core/core.pro.orig
+++ src/core/core.pro
@@ -295,7 +295,7 @@ RC_FILE = core.rc
@@ -309,7 +309,7 @@ RC_FILE = core.rc
OTHER_FILES += core.dox math/math.dox
DEFINES += QCADCORE_LIBRARY

View File

@ -1,9 +1,9 @@
Index: src/gui/RRulerQt.cpp
--- src/gui/RRulerQt.cpp.orig
+++ src/gui/RRulerQt.cpp
@@ -25,6 +25,7 @@
#include "RMdiChildQt.h"
@@ -26,6 +26,7 @@
#include <QApplication>
#include <QPainter>
+#include <QPainterPath>

View File

@ -1,11 +0,0 @@
Index: src/gui/RRulerQt.h
--- src/gui/RRulerQt.h.orig
+++ src/gui/RRulerQt.h
@@ -24,6 +24,7 @@
#include <QFrame>
#include <QMetaType>
+#include <QPainterPath>
#include "RCoordinateListener.h"
#include "RRuler.h"

View File

@ -0,0 +1,18 @@
don't overwrite the plugins directory: remove the applicationDir and add the pluginPaths
Index: src/run/main.cpp
--- src/run/main.cpp.orig
+++ src/run/main.cpp
@@ -285,7 +285,11 @@ int main(int argc, char *argv[]) {
qWarning() << "No plugin paths found";
return -1;
}
- app->setLibraryPaths(pluginPaths);
+
+ app->removeLibraryPath(app->applicationDirPath());
+ foreach (const QString &path, pluginPaths)
+ app->addLibraryPath(path);
+
// make sure basic entities are initialized before loading plugins:
RDimStyleData::initDefaults();

View File

@ -1,11 +0,0 @@
Index: src/run/run.pri
--- src/run/run.pri.orig
+++ src/run/run.pri
@@ -117,7 +117,6 @@ else {
system(cp "$$[QT_INSTALL_PLUGINS]/platforms/libqxcb.so" "$${DESTDIR}/../platforms")
system(cp "$$[QT_INSTALL_PLUGINS]/platforms/libqoffscreen.so" "$${DESTDIR}/../platforms")
system(cp "$$[QT_INSTALL_PLUGINS]/platforms/libqminimal.so" "$${DESTDIR}/../platforms")
- system(cp "$$[QT_INSTALL_PLUGINS]/platforms/libqlinuxfb.so" "$${DESTDIR}/../platforms")
system(cp "$$[QT_INSTALL_PLUGINS]/platforminputcontexts/*.so" "$${DESTDIR}/../platforminputcontexts")
system(cp "$$[QT_INSTALL_PLUGINS]/xcbglintegrations/*.so" "$${DESTDIR}/../xcbglintegrations")
}

File diff suppressed because it is too large Load Diff