summaryrefslogtreecommitdiffstats
path: root/src/tools/windeployqt/utils.cpp
diff options
context:
space:
mode:
authorOliver Wolff <[email protected]>2023-08-01 13:43:45 +0200
committerOliver Wolff <[email protected]>2023-08-22 11:15:13 +0200
commit68b16974a72a35e33e4e947f7edfabd6ccd5f6a1 (patch)
tree687383e22fd59a159fd6854f798914d8bd6ac678 /src/tools/windeployqt/utils.cpp
parent634f474300fe27b6decb61937f1c5a5401807fad (diff)
Remove elfreader and other unix leftovers from windeployqt
Back then elfreader and other unix functionality was added for the purpose of having one generic deployment tool but it was never used. Remove the code to be more clear on what to expect. Pick-to: 6.6 Change-Id: I2b7a759de04afe0c5fb210ad65f1c86e32934f18 Reviewed-by: Timothée Keller <[email protected]> Reviewed-by: Fabian Kosmale <[email protected]>
Diffstat (limited to 'src/tools/windeployqt/utils.cpp')
-rw-r--r--src/tools/windeployqt/utils.cpp34
1 files changed, 1 insertions, 33 deletions
diff --git a/src/tools/windeployqt/utils.cpp b/src/tools/windeployqt/utils.cpp
index 09e820abef7..badb81d7c38 100644
--- a/src/tools/windeployqt/utils.cpp
+++ b/src/tools/windeployqt/utils.cpp
@@ -2,7 +2,6 @@
// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only WITH Qt-GPL-exception-1.0
#include "utils.h"
-#include "elfreader.h"
#include <QtCore/QString>
#include <QtCore/QDebug>
@@ -95,7 +94,7 @@ QStringList findSharedLibraries(const QDir &directory, Platform platform,
nameFilter += u'*';
if (debugMatchMode == MatchDebug && platformHasDebugSuffix(platform))
nameFilter += u'd';
- nameFilter += sharedLibrarySuffix(platform);
+ nameFilter += sharedLibrarySuffix();
QStringList result;
QString errorMessage;
const QFileInfoList &dlls = directory.entryInfoList(QStringList(nameFilter), QDir::Files);
@@ -553,37 +552,6 @@ bool updateFile(const QString &sourceFileName, const QStringList &nameFilters,
return true;
}
-bool readElfExecutable(const QString &elfExecutableFileName, QString *errorMessage,
- QStringList *dependentLibraries, unsigned *wordSize,
- bool *isDebug)
-{
- ElfReader elfReader(elfExecutableFileName);
- const ElfData data = elfReader.readHeaders();
- if (data.sectionHeaders.isEmpty()) {
- *errorMessage = QStringLiteral("Unable to read ELF binary \"")
- + QDir::toNativeSeparators(elfExecutableFileName) + QStringLiteral("\": ")
- + elfReader.errorString();
- return false;
- }
- if (wordSize)
- *wordSize = data.elfclass == Elf_ELFCLASS64 ? 64 : 32;
- if (dependentLibraries) {
- dependentLibraries->clear();
- const QList<QByteArray> libs = elfReader.dependencies();
- if (libs.isEmpty()) {
- *errorMessage = QStringLiteral("Unable to read dependenices of ELF binary \"")
- + QDir::toNativeSeparators(elfExecutableFileName) + QStringLiteral("\": ")
- + elfReader.errorString();
- return false;
- }
- for (const QByteArray &l : libs)
- dependentLibraries->push_back(QString::fromLocal8Bit(l));
- }
- if (isDebug)
- *isDebug = data.symbolsType != UnknownSymbols && data.symbolsType != NoSymbols;
- return true;
-}
-
#ifdef Q_OS_WIN
static inline QString stringFromRvaPtr(const void *rvaPtr)