diff options
author | V3n3RiX <venerix@redcorelinux.org> | 2018-05-14 13:24:06 +0100 |
---|---|---|
committer | V3n3RiX <venerix@redcorelinux.org> | 2018-05-14 13:24:06 +0100 |
commit | 0273a2cc300abeb406dc1fdc00dc069198bb0aeb (patch) | |
tree | d7571e74d251fba76de582970ab35840cb38d173 /dev-qt/qtsingleapplication/files/2.6.1_p20130904-unbundle-qtlockedfile.patch | |
parent | d4f9fcb43e17d54b93bdc16cdc454a57c202974f (diff) |
dev-qt/qtsingleapplication : import from gentoo tree
Diffstat (limited to 'dev-qt/qtsingleapplication/files/2.6.1_p20130904-unbundle-qtlockedfile.patch')
-rw-r--r-- | dev-qt/qtsingleapplication/files/2.6.1_p20130904-unbundle-qtlockedfile.patch | 81 |
1 files changed, 81 insertions, 0 deletions
diff --git a/dev-qt/qtsingleapplication/files/2.6.1_p20130904-unbundle-qtlockedfile.patch b/dev-qt/qtsingleapplication/files/2.6.1_p20130904-unbundle-qtlockedfile.patch new file mode 100644 index 00000000..93c78fab --- /dev/null +++ b/dev-qt/qtsingleapplication/files/2.6.1_p20130904-unbundle-qtlockedfile.patch @@ -0,0 +1,81 @@ +From 62210d463f87abb0584ce699915e1845cacaa480 Mon Sep 17 00:00:00 2001 +From: Davide Pesavento <davidepesa@gmail.com> +Date: Sat, 28 Dec 2013 16:33:15 +0100 +Subject: [PATCH] unbundle qtlockedfile + +--- + src/qtlocalpeer.cpp | 11 +---------- + src/qtlocalpeer.h | 2 +- + src/qtsingleapplication.pri | 1 + + src/qtsinglecoreapplication.pri | 1 + + 4 files changed, 4 insertions(+), 11 deletions(-) + +diff --git a/src/qtlocalpeer.cpp b/src/qtlocalpeer.cpp +index 332b064..f17e662 100644 +--- a/src/qtlocalpeer.cpp ++++ b/src/qtlocalpeer.cpp +@@ -55,15 +55,6 @@ static PProcessIdToSessionId pProcessIdToSessionId = 0; + #include <unistd.h> + #endif + +-namespace QtLP_Private { +-#include "qtlockedfile.cpp" +-#if defined(Q_OS_WIN) +-#include "qtlockedfile_win.cpp" +-#else +-#include "qtlockedfile_unix.cpp" +-#endif +-} +- + const char* QtLocalPeer::ack = "ack"; + + QtLocalPeer::QtLocalPeer(QObject* parent, const QString &appId) +@@ -114,7 +105,7 @@ bool QtLocalPeer::isClient() + if (lockFile.isLocked()) + return false; + +- if (!lockFile.lock(QtLP_Private::QtLockedFile::WriteLock, false)) ++ if (!lockFile.lock(QtLockedFile::WriteLock, false)) + return true; + + bool res = server->listen(socketName); +diff --git a/src/qtlocalpeer.h b/src/qtlocalpeer.h +index 1b533b1..1127735 100644 +--- a/src/qtlocalpeer.h ++++ b/src/qtlocalpeer.h +@@ -68,7 +68,7 @@ protected: + QString id; + QString socketName; + QLocalServer* server; +- QtLP_Private::QtLockedFile lockFile; ++ QtLockedFile lockFile; + + private: + static const char* ack; +diff --git a/src/qtsingleapplication.pri b/src/qtsingleapplication.pri +index 6f2bced..02c9e5b 100644 +--- a/src/qtsingleapplication.pri ++++ b/src/qtsingleapplication.pri +@@ -3,6 +3,7 @@ INCLUDEPATH += $$PWD + DEPENDPATH += $$PWD + QT *= network + greaterThan(QT_MAJOR_VERSION, 4): QT *= widgets ++CONFIG *= qtlockedfile + + qtsingleapplication-uselib:!qtsingleapplication-buildlib { + LIBS += -L$$QTSINGLEAPPLICATION_LIBDIR -l$$QTSINGLEAPPLICATION_LIBNAME +diff --git a/src/qtsinglecoreapplication.pri b/src/qtsinglecoreapplication.pri +index d2d6cc3..f5b8414 100644 +--- a/src/qtsinglecoreapplication.pri ++++ b/src/qtsinglecoreapplication.pri +@@ -4,6 +4,7 @@ HEADERS += $$PWD/qtsinglecoreapplication.h $$PWD/qtlocalpeer.h + SOURCES += $$PWD/qtsinglecoreapplication.cpp $$PWD/qtlocalpeer.cpp + + QT *= network ++CONFIG *= qtlockedfile + + win32:contains(TEMPLATE, lib):contains(CONFIG, shared) { + DEFINES += QT_QTSINGLECOREAPPLICATION_EXPORT=__declspec(dllexport) +-- +1.8.5.2 + |