fix run script

This commit is contained in:
a.yankovich 2018-09-26 11:11:11 +03:00
parent 5fe0755105
commit 868baa1a1a
4 changed files with 13 additions and 9 deletions

2
.gitignore vendored
View File

@ -54,3 +54,5 @@ snap/\.snapcraft/
sharedQt/
staticQt/
cqtdeployer

View File

@ -10,6 +10,8 @@ QT -= gui
CONFIG += c++11 console
CONFIG -= app_bundle
QMAKE_LFLAGS+=" -static-libgcc -static-libstdc++"
# The following define makes your compiler emit warnings if you use
# any feature of Qt which as been marked deprecated (the exact warnings
# depend on your compiler). Please consult the documentation of the
@ -24,7 +26,7 @@ DEFINES += QT_DEPRECATED_WARNINGS
include('./../QuasarAppLib/deploy.pri');
include('./../QuasarAppLib/QuasarLib.pri');
TARGET = CQtDeployer
TARGET = cqtdeployer
SOURCES += \
main.cpp \

View File

@ -89,12 +89,12 @@ bool Deploy::createRunScript() {
QString content =
"#!/bin/sh\n"
"BASE_DIR=$(dirname \"$(readlink -f \"$0\")\")\n"
"export LD_LIBRARY_PATH=$BASE_DIR/lib:$BASEDIR:$LD_LIBRARY_PATH\n"
"export QML_IMPORT_PATH=$BASE_DIR/qml:QML_IMPORT_PATH\n"
"export QML2_IMPORT_PATH=$BASE_DIR/qml:QML2_IMPORT_PATH\n"
"export QT_PLUGIN_PATH=$BASE_DIR/plugins:QT_PLUGIN_PATH\n"
"export QT_QPA_PLATFORM_PLUGIN_PATH=$BASE_DIR/plugins/platforms:QT_QPA_PLATFORM_PLUGIN_PATH\n"
"$BASE_DIR/%1 \"$@\"";
"export LD_LIBRARY_PATH=\"$BASE_DIR\"/lib:\"$BASE_DIR\":$LD_LIBRARY_PATH\n"
"export QML_IMPORT_PATH=\"$BASE_DIR\"/qml:QML_IMPORT_PATH\n"
"export QML2_IMPORT_PATH=\"$BASE_DIR\"/qml:QML2_IMPORT_PATH\n"
"export QT_PLUGIN_PATH=\"$BASE_DIR\"/plugins:QT_PLUGIN_PATH\n"
"export QT_QPA_PLATFORM_PLUGIN_PATH=\"$BASE_DIR\"/plugins/platforms:QT_QPA_PLATFORM_PLUGIN_PATH\n"
"\"$BASE_DIR\"/%1 \"$@\"";
content = content.arg(QFileInfo(target).fileName());

View File

@ -33,9 +33,9 @@ $BASE_DIR/sharedQt/bin/qmake CQtDeployer.pro
make -j$(nproc)
strip build/*
chmod +x $BASE_DIR/build/CQtDeployer
chmod +x $BASE_DIR/build/cqtdeployer
$BASE_DIR/build/CQtDeployer -runScript cqtdeployer.sh -bin $BASE_DIR/build/CQtDeployer -qmake $BASE_DIR/sharedQt/bin/qmake
$BASE_DIR/build/cqtdeployer -runScript cqtdeployer.sh -bin $BASE_DIR/build/cqtdeployer -qmake $BASE_DIR/sharedQt/bin/qmake
cd $BASE_DIR/build