Bug 38600

Summary: mkbundle Doesn't support assemblies with spaces in their names.
Product: [Mono] Tools Reporter: Jonathan Pryor <jonp>
Component: otherAssignee: Aleksey Kliger <aleksey>
Severity: normal CC: aleksey, mono-bugs, peter.collins
Priority: ---    
Version: unspecified   
Target Milestone: ---   
Hardware: PC   
OS: Mac OS   
Tags: Is this bug a regression?: ---
Last known good build:
Attachments: bxc-38600.zip

Description Jonathan Pryor 2016-02-09 22:43:56 UTC
mkbundle doesn't support bundling programs and/or assemblies which contain spaces in their name, for example "My App.exe".

Attempting to do so causes `as` to error due to an unexpected token:

> as -m32 -o temp.o temp.s 
> temp.s:2:27: error: unexpected token in directive
>         .globl _assembly_data_My App_exe

Notice that the space in the assembly name appears as-is in the assembly symbol, and isn't escaped or encoded in any way.
Comment 1 Jonathan Pryor 2016-02-09 22:45:23 UTC
Created attachment 14974 [details]
Comment 2 Jonathan Pryor 2016-02-09 22:46:52 UTC
See Attachment #14974 [details] for an example:
Comment 3 Jonathan Pryor 2016-02-09 22:48:11 UTC
See Attachment #14974 [details] for an example:

> curl -o bxc-38600.zip https://bugzilla.xamarin.com/attachment.cgi?id=14974
> unzip bxc-38600.zip
> cd bxc-38600
> make
> mcs "/out:My App.exe" App.cs
> CC="cc -m32 -arch i386 -framework CoreFoundation -lobjc -liconv" AS="as -m32" mkbundle -o "my app" "My App.exe"
> OS is: Darwin
> Sources: 1 Auto-dependencies: False
>    embedding: /Users/jon/tmp/csharp/bxc-38600/My App.exe
> Compiling:
> as -m32 -o temp.o temp.s 
> temp.s:2:27: error: unexpected token in directive
>         .globl _assembly_data_My App_exe
>                                  ^
> temp.s:5:26: error: unexpected token in argument list
Comment 4 Jonathan Pryor 2016-02-09 22:48:23 UTC
*** Bug 34725 has been marked as a duplicate of this bug. ***
Comment 5 Aleksey Kliger 2016-02-19 22:54:38 UTC
Fixed on master 959f4bd8ac8d19dedf8131f3e38bdfcddb6d9653.  Fixed on 4.3.2 branch 82863f05bf029a2fbe0737a6169fd2534a4df394.