update pe parse lib

This commit is contained in:
Andrei Yankovich 2019-03-25 20:13:30 +03:00
parent 02a9f504a5
commit 081f77c24f
12 changed files with 54 additions and 62 deletions

View File

@ -29,7 +29,7 @@ CQtDeployer.depends=QuasarAppLib
CQtDeployer.depends=Deploy
QuasarAppLib.file = $$PWD/QuasarAppLib/QuasarApp.pro
Pe.file = $$PWD/pe/pe-parser-library/pe-parser.pro
Pe.file = $$PWD/pe/pe-parser-library/pe-parser-library.pro
win32:include('$$PWD/CQtDeployerWinBuild.pri')

View File

@ -29,7 +29,7 @@ CONFIG(release, debug|release): {
include('$$PWD/../QuasarAppLib/QuasarLib.pri')
include('$$PWD/../Deploy/Deploy.pri')
include('$$PWD/../pe/pe-parser-library/pe-parser.pri')
include('$$PWD/../pe/pe-parser-library/pe-parser-library.pri')
TARGET = cqtdeployer

View File

@ -37,7 +37,7 @@ CONFIG(release, debug|release): {
}
include('$$PWD/../QuasarAppLib/QuasarLib.pri')
include('$$PWD/../pe/pe-parser-library/pe-parser.pri')
include('$$PWD/../pe/pe-parser-library/pe-parser-library.pri')
SOURCES += \
@ -45,7 +45,6 @@ SOURCES += \
deployutils.cpp \
pe.cpp \
igetlibinfo.cpp \
structs.cpp \
dependenciesscanner.cpp \
../qtTools/src/windeployqt/elfreader.cpp \
elf.cpp
@ -56,7 +55,6 @@ HEADERS += \
deployutils.h \
pe.h \
igetlibinfo.h \
structs.h \
dependenciesscanner.h \
../qtTools/src/windeployqt/elfreader.h \
elf.h

View File

@ -11,7 +11,6 @@
#include <QMultiMap>
#include <QStringList>
#include "deploy_global.h"
#include "structs.h"
#include "pe.h"
#include "elf.h"

View File

@ -16,6 +16,29 @@
QString DeployUtils::qtDir = "";
QStringList DeployUtils::extraPaths = QStringList();
bool LibInfo::operator ==(const LibInfo &other) {
return platform == other.platform &&
name == other.name;
}
QString LibInfo::fullPath() {
return path + "/" + name;
}
void LibInfo::clear() {
path = "";
name = "";
platform = Platform::UnknownPlatform;
dependncies.clear();
}
bool LibInfo::isValid() const {
return platform != Platform::UnknownPlatform &&
name.size() && path.size();
}
QtModuleEntry DeployUtils::qtModuleEntries[] = {
{ QtBluetoothModule, "bluetooth", "Qt5Bluetooth", nullptr },
{ QtConcurrentModule, "concurrent", "Qt5Concurrent", "qtbase" },

View File

@ -19,6 +19,30 @@ struct DEPLOYSHARED_EXPORT QtModuleEntry {
const char *translation;
};
enum Platform {
UnknownPlatform = 0x0,
Win32,
Win64,
Unix32,
Unix64
};
struct DEPLOYSHARED_EXPORT LibInfo {
Platform platform = Platform::UnknownPlatform;
QString name;
QString path;
QStringList dependncies;
bool operator == (const LibInfo& other);
QString fullPath();
void clear();
bool isValid() const;
};
class Deploy;
class DEPLOYSHARED_EXPORT DeployUtils

View File

@ -1,7 +1,7 @@
#ifndef IGETLIBINFO_H
#define IGETLIBINFO_H
#include "structs.h"
#include "deployutils.h"
class IGetLibInfo
{

View File

@ -4,7 +4,7 @@
#include <QFileInfo>
#include <QSet>
#include <QVector>
#include <parse.h>
#include <parser-library/parse.h>
#include <bits/stl_set.h>

View File

@ -1,22 +0,0 @@
#include "structs.h"
bool LibInfo::operator ==(const LibInfo &other) {
return platform == other.platform &&
name == other.name;
}
QString LibInfo::fullPath() {
return path + "/" + name;
}
void LibInfo::clear() {
path = "";
name = "";
platform = Platform::UnknownPlatform;
dependncies.clear();
}
bool LibInfo::isValid() const {
return platform != Platform::UnknownPlatform &&
name.size() && path.size();
}

View File

@ -1,30 +0,0 @@
#ifndef LIBINFO_H
#define LIBINFO_H
#include <QString>
#include <QStringList>
enum Platform {
UnknownPlatform = 0x0,
Win32,
Win64,
Unix32,
Unix64
};
struct LibInfo {
Platform platform = Platform::UnknownPlatform;
QString name;
QString path;
QStringList dependncies;
bool operator == (const LibInfo& other);
QString fullPath();
void clear();
bool isValid() const;
};
#endif // LIBINFO_H

View File

@ -17,7 +17,7 @@ CONFIG(release, debug|release): {
include('$$PWD/../QuasarAppLib/QuasarLib.pri')
include('$$PWD/../Deploy/Deploy.pri')
include('$$PWD/../pe/pe-parser-library/pe-parser.pri')
include('$$PWD/../pe/pe-parser-library/pe-parser-library.pri')
CONFIG += qt console warn_on depend_includepath testcase

2
pe

@ -1 +1 @@
Subproject commit 59c4c1c0de26b2173b4b406e26d601e7ed94896c
Subproject commit cc1c28adc3c097c9660fcdc3421005cb26faff40