androiddeployqt: REG: Fix running tools with spaces in path
authorEskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@nokia.com>
Tue, 13 May 2014 16:47:09 +0000 (18:47 +0200)
committerThe Qt Project <gerrit-noreply@qt-project.org>
Wed, 14 May 2014 15:15:27 +0000 (17:15 +0200)
commit16ee0c0f9e58f9db9d8b261fbe63560f631c0597
treecd919bc2138417b4c32002858035aae0c4a6ea4a
parentb4c06e0a4dd685eb57e32da52d409bd9417b2122
androiddeployqt: REG: Fix running tools with spaces in path

The popen() function on Windows executes the command using /s,
probably for legacy reasons, which causes the behavior that it
removes the first and last quotes in the command line and otherwise
preserves it perfectly. This causes strings in which both
the executable name and at least one argument has to be quoted, to
be unparsable by the shell once it has been processed. To work around
this we wrap the string in quotes on Windows.

Since we added quotes to arguments for the jarsigner command in Qt 5.3.0
we introduced a regression that made it impossible to sign APKs on Windows.

Task-number: QTBUG-38962
Change-Id: I2b618e1996753645766d25ca06b14e1985d7eacd
Reviewed-by: Paul Olav Tvete <paul.tvete@digia.com>
src/androiddeployqt/main.cpp