Dex does not work with spaces in the way on new tools of the Android platform (V8)

On new Android platform tools (v8) released with 2.3 SDK, I get an error when running dex from ant script

I typed the usual "ant release" and got an error at the dex stage

-dex:
    [echo] Converting compiled files and external libraries into C:\Documents and Settings\omri\My Documents\myapp\bin\classes.dex...
   [apply] =C:\Documents was unexpected at this time.

I guess it has something to do with spaces along the way. Does anyone know what the problem is and how to fix it?

+3
source share
2 answers

I have the same problem as it seems with spaces in the way, you guessed it. If you specify a path using 8.3 names, there will be no spaces, and dex will work.

For the path above path 8.3 will look like this:

C: \ DOCUME ~ 1 \ Omri \ MyDocu ~ 1 \ MyApp \ Bin

dir/X 8.3.

+3

, - , dex ! blog .

dex.bat 49

REM capture all arguments to process them below 
set params=%*

:nextArg  
if "%params%"=="" goto endArgs

REM capture all arguments to process them below
set params=%*

echo ***** SKIP check the parameter *****
set args=%params%
goto endArgs

:nextArg
if "%params%"=="" goto endArgs

ANT, , , .

+2

Source: https://habr.com/ru/post/1778910/


All Articles