|
|
|
|||||
|
slice2cs commandline parsing issue
It seems that on Windows, slice2cs has issues parsing file paths that have spaces *and* back-slashes in them. For example, this command line gives me the error "input files must end with '.ice':
"%ICE_HOME%\bin\slice2cs.exe" -I"C:\Documents and Settings\Karl\Desktop\Java Web Services\IS2ICE\" -I%ICE_HOME%\slice --output-dir "C:\Documents and Settings\Karl\Desktop\Java Web Services\IS2ICE\StateServer\generated" "C:\Documents and Settings\Karl\Desktop\Java Web Services\IS2ICE\Services.ice" "C:\Documents and Settings\Karl\Desktop\Java Web Services\IS2ICE\StorageServices.ice" However, if I replace all back-slashes with forward-slashes, the error goes away. It looks as if with back-slashes the spaces are interpreted as command line delimiters (even though the paths are enclosed in quotes). The issue seems limited to the -I parameter, as the error also goes away if the include directories in the command line above don't contain spaces. This is especially a problem when I am running this as a build event under VS 2005 because the paths are build macros that are not under my control. Karl Last edited by kwaclaw : 10-21-2007 at 12:53 AM. Reason: Added more information. |
|
|||||
|
Quote:
I tried the single quotes, but it seems slice2cs does not honor the include directory then. I tried this on my work PC, where i did not have spaces in my path, but it still didn't work, specifically: The expanded (from VS macro) include path would be C:\Data\PBS\IS2ICE\, so -IC:\Data\PBS\IS2ICE\ works, but with -I'C:\Data\PBS\IS2ICE\' slice2cs does not find the included files. However, I found an ugly looking way that seems to work: I keep using double quotes, but before the closing double quote I append another back-slash, so the expanded path would end with \\", which will turn into \" when slice2cs parses the command line. Maybe this (or another, better) solution should be added to the docs for the benefit of Windows users. Karl |
|
||||||
|
Hi Karl,
Quote:
Quote:
Quote:
Cheers, Michi. Last edited by michi : 10-23-2007 at 01:37 AM. |
|
||||||
|
Quote:
-I'C:\Data\PBS\IS2ICE\' The problem here is the \' at the end, which escapes the single quote and produces a literal single quote in the output string. Basically, to make things work, you have to either avoid a backslash immediately preceding a single or double quote, or replace the backslash preceding a single or double quote with a double backslash, as you mentioned in your earlier post. Cheers, Michi. |
![]() |
| Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
| Thread Tools | |
| Display Modes | Rate This Thread |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Python Ice Parsing: Bug or User Error? | jae | Help Center | 3 | 04-02-2007 10:36 PM |
| slice2cs - no output | kwaclaw | Help Center | 8 | 06-24-2005 07:52 PM |
| Possible bug in slice2cs version 1.5 | wodi | Bug Reports | 3 | 07-27-2004 11:06 PM |
| Patch for slice2cs, release 1.5.0 | michi | Patches | 0 | 07-27-2004 11:03 PM |
| error in doc for parsing of --Command.Line properties (14.8.3) | shaver | Bug Reports | 1 | 11-30-2003 01:02 PM |