调整项目输出目录

This commit is contained in:
rankun 2018-11-14 13:11:09 +08:00
commit 588d3fbdb0
22 changed files with 16 additions and 9 deletions

BIN
output/debug/avcodec-58.dll Normal file

Binary file not shown.

Binary file not shown.

BIN
output/debug/avutil-56.dll Normal file

Binary file not shown.

Binary file not shown.

BIN
output/debug/swscale-5.dll Normal file

Binary file not shown.

Binary file not shown.

Binary file not shown.

BIN
output/release/adb.exe Normal file

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

View file

@ -39,7 +39,14 @@ FORMS += \
dialog.ui \
videoform.ui
#子工程
# 指定可执行程序输出目录
CONFIG(debug, debug|release) {
DESTDIR = $$PWD/../output/debug
} else {
DESTDIR = $$PWD/../output/release
}
# 子工程
include ($$PWD/common/common.pri)
include ($$PWD/server/server.pri)
include ($$PWD/adb/adb.pri)

View file

@ -1,9 +1,9 @@
#include "adbprocess.h"
#include <QProcess>
#include <QCoreApplication>
#include <QDebug>
#include "adbprocess.h"
QString AdbProcess::s_adbPath = "";
AdbProcess::AdbProcess(QObject *parent)
@ -24,7 +24,7 @@ const QString& AdbProcess::getAdbPath()
if (s_adbPath.isEmpty()) {
s_adbPath = QString::fromLocal8Bit(qgetenv("QTSCRCPY_ADB_PATH"));
if (s_adbPath.isEmpty()) {
s_adbPath = "adb";
s_adbPath = QCoreApplication::applicationDirPath() + "/adb";
}
}
return s_adbPath;
@ -49,7 +49,7 @@ void AdbProcess::initSignals()
});
connect(this, &QProcess::errorOccurred, this,
[this](QProcess::ProcessError error){
[this](QProcess::ProcessError error){
if (QProcess::FailedToStart == error) {
emit adbProcessResult(AER_ERROR_MISSING_BINARY);
} else {
@ -86,7 +86,6 @@ void AdbProcess::execute(const QString& serial, const QStringList& args)
adbArgs << args;
qDebug() << getAdbPath() << adbArgs.join(" ");
start(getAdbPath(), adbArgs);
//start("C:\\Users\\Barry\\Desktop\\sockettool.exe", Q_NULLPTR);
}
bool AdbProcess::isRuning()

View file

@ -15,8 +15,8 @@ int main(int argc, char *argv[])
Decoder::init();
QApplication a(argc, argv);
qputenv("QTSCRCPY_ADB_PATH", "G:\\mygitcode\\QtScrcpy\\src\\adb.exe");
qputenv("QTSCRCPY_SERVER_PATH", "G:\\mygitcode\\QtScrcpy\\src\\scrcpy-server.jar");
//qputenv("QTSCRCPY_ADB_PATH", "G:\\mygitcode\\QtScrcpy\\src\\adb.exe");
//qputenv("QTSCRCPY_SERVER_PATH", "G:\\mygitcode\\QtScrcpy\\src\\scrcpy-server.jar");
Dialog* w = new Dialog;
w->show();

View file

@ -3,6 +3,7 @@
#include <QThread>
#include <QSize>
#include <QTimerEvent>
#include <QCoreApplication>
#include "server.h"
@ -52,7 +53,7 @@ const QString& Server::getServerPath()
if (m_serverPath.isEmpty()) {
m_serverPath = QString::fromLocal8Bit(qgetenv("QTSCRCPY_SERVER_PATH"));
if (m_serverPath.isEmpty()) {
m_serverPath = "scrcpy-server.jar";
m_serverPath = QCoreApplication::applicationDirPath() + "/scrcpy-server.jar";
}
}
return m_serverPath;