Edit - Reduced to the root of the problem
I'm getting this error when Multi-Dex is enabled.
CREATEMULTIDEXMAINDEXCLASSLIST : error : Expecting class path separator ':' before '.jar' in argument number 2
I have tracked it down to this jar file being included in the ProGuard command line:
obj/Debug/__library_projects__/DeviceAPI_Android/library_project_imports/DeviceAPI_Android.Jars.cw-deviceapi(2016.05.16).jar
It's the brackets in the file name which are causing the error. I've proved this by running the command in a terminal prompt with this jar file removed, and all works fine.
So the question - where is this file coming from? Is it in Packages? I can't see it there.
If I can find that I should be able to correct the name and build the project.
I've tracked it down to a 3rd party binding library called DeviceAPI_Android.dll, which wraps a jar file for controlling the hardware barcode scanner. The jar file does indeed have the brackets and date in its filename.
So the solution is one or more of:
Get a new version of the binding library from the supplier with a better named jar file.
Rebuild the library myself with a better named jar file. Potentially problematic because I'll have to create the transforms etc. from scratch.
Adjust the build tooling/makefile to make the ProGuard command line more resilient to strangely named jar files.
A sample project demonstrating the problem is on GitHub here.
Version Information: === Visual Studio Community 2017 for Mac ===
Version 7.1 (build 1297) Installation UUID: 650b4c91-c7f5-4ee5-ad70-6f178f314906 Runtime: Mono 5.2.0.215 (d15-3/da80840) (64-bit) GTK+ 2.24.23 (Raleigh theme)
Package version: 502000215
=== NuGet ===
Version: 4.3.0.2418
=== .NET Core ===
Runtime: Not installed SDK: Not installed MSBuild SDKs: /Library/Frameworks/Mono.framework/Versions/5.2.0/lib/mono/msbuild/15.0/bin/Sdks
=== Xamarin.Profiler ===
Version: 1.5.5 Location: /Applications/Xamarin Profiler.app/Contents/MacOS/Xamarin Profiler
=== Xamarin.Android ===
Version: 7.4.0.21 (Visual Studio Community) Android SDK: /Users/jameslavery/Library/Developer/Xamarin/android-sdk-macosx Supported Android versions: 2.3 (API level 10) 4.0.3 (API level 15) 4.1 (API level 16) 4.3 (API level 18) 4.4 (API level 19) 5.0 (API level 21) 5.1 (API level 22) 6.0 (API level 23) 7.0 (API level 24) 7.1 (API level 25)
SDK Tools Version: 25.2.5 SDK Platform Tools Version: 25.0.5 SDK Build Tools Version: 25.0.3
Java SDK: /Library/Java/JavaVirtualMachines/jdk1.8.0_144.jdk/Contents/Home java version "1.8.0_144" Java(TM) SE Runtime Environment (build 1.8.0_144-b01) Java HotSpot(TM) 64-Bit Server VM (build 25.144-b01, mixed mode)
Android Designer EPL code available here: https://github.com/xamarin/AndroidDesigner.EPL
=== Apple Developer Tools ===
Xcode 8.0 (11246) Build 8A218a
=== Xamarin.iOS ===
Version: 10.12.0.20 (Visual Studio Community) Hash: 80b8487d Branch: d15-3 Build date: 2017-08-18 16:07:26-0400
=== Xamarin.Mac ===
Version: 3.6.0.19 (Visual Studio Community)
=== Xamarin Inspector ===
Version: 1.2.2 Hash: b71b035 Branch: d15-1 Build date: Fri, 21 Apr 2017 17:57:12 GMT
=== Build Information ===
Release ID: 701001297 Git revision: 9c5299666538b2f8baf501418a5c064d784d64da Build date: 2017-08-07 11:29:35-04 Xamarin addins: 3bb0c32a14f1b7e368bf5ac53a84c3581c019391 Build lane: monodevelop-lion-d15-3
=== Operating System ===
Mac OS X 10.11.6 Darwin 15.6.0 Darwin Kernel Version 15.6.0 Thu Jun 23 18:25:34 PDT 2016 root:xnu-3248.60.10~1/RELEASE_X86_64 x86_64
=== Enabled user installed addins ===
LiveXAML 1.0 Redth's Addins 1.0.9
I have reported the following bug for this issue:
https://bugzilla.xamarin.com/show_bug.cgi?id=59237
Please feel free to CC yourself to this issue to be notified when it gets fixed. For the time being, you will have to workaround this by renaming the .jar in some fashion.
I hope this helps!
This is because there is a binding library with an embedded Jar file with brackets in its filename - which cause the command line for ProGuard to fail.
@jondouglas has submitted Xamarin bug 59237 for this. Hopefully the fix will be to make the command line for ProGuard more resilient to strangely named files.
In the meantime, I will have to get hold of an updated binding library with the embedded jar file not having a name with parentheses (or other character which breaks a command line) in it.
Thanks to @jondouglas for his help in diagnosing the problem.