[PATCH 1 of 3] Check for nsi file and convert slashes to backslashes on windows
Wald Commits
scm-commit at wald.intevation.org
Tue Aug 5 15:34:37 CEST 2014
# HG changeset patch
# User Andre Heinecke <andre.heinecke at intevation.de>
# Date 1407245512 -7200
# Node ID 45cf874221af10fa428f5fe7704f26f0c0d86b3b
# Parent 3ae7ad044566d711d2d1efba9a0f524b60be8ee0
Check for nsi file and convert slashes to backslashes on windows
diff -r 3ae7ad044566 -r 45cf874221af ui/createinstallerdialog.cpp
--- a/ui/createinstallerdialog.cpp Tue Aug 05 10:06:31 2014 +0200
+++ b/ui/createinstallerdialog.cpp Tue Aug 05 15:31:52 2014 +0200
@@ -293,6 +293,7 @@
}
arguments << QString::fromLatin1("/D%1=%2").arg(key, value);
}
+ arguments << QString(binDir.path() + "/trustbridge.nsi").replace("/", "\\");
#else
arguments << QString::fromLatin1("-Dfiles_dir=") + mCurrentWorkingDir->path();
arguments << "-Dpath_sep=/";
@@ -304,9 +305,14 @@
}
arguments << QString::fromLatin1("-D%1=%2").arg(key, value);
}
+ arguments << binDir.path() + "/trustbridge.nsi";
#endif
- arguments << binDir.path() + "/trustbridge.nsi";
+
+ QFileInfo nsiFile (binDir.path() + "/trustbridge.nsi");
+ if (!nsiFile.exists()) {
+ showErrorMessage(tr("Failed to find installer script at: %1 ").arg(nsiFile.filePath()));
+ }
qDebug() << "Starting makensis with arguments: " << arguments;
mNSISProc.setArguments(arguments);
More information about the Trustbridge-commits
mailing list