diff --git a/Directory.Build.targets b/Directory.Build.targets
index 245782faf0..d6092ffb9c 100644
--- a/Directory.Build.targets
+++ b/Directory.Build.targets
@@ -29,4 +29,55 @@
+
+
+ false
+ none
+ all
+ false
+ false
+ %(SetTargetFramework)
+ %(TargetPath)
+ %(Properties)
+
+
+
+
+
+
+ <_PublishProjectReference Include="@(ProjectReferenceWithConfiguration)" Condition="'%(ProjectReferenceWithConfiguration.PublishTargetPath)' != ''">
+ $([System.IO.Path]::GetFileNameWithoutExtension('%(Identity)'))
+ $([MSBuild]::EnsureTrailingSlash(%(ProjectReferenceWithConfiguration.PublishTargetPath)))
+
+
+
+
+
+
+
+
+
+
+
+
+
+ PreserveNewest
+ %(_PublishProjectReferenceOutputItems.PublishTargetPath)\%(_PublishProjectReferenceOutputItems.TargetPath)
+
+
+
+
+
+
+ $(GetPublishProjectReferenceCopyToOutputDirectoryItemsDependsOn);
+ GetPublishProjectReferences;
+ GetPublishProjectReferenceOutputItems;
+ _GetPublishProjectReferenceCopyToOutputDirectoryItems;
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/IKVM.Java/IKVM.Java.targets b/IKVM.Java/IKVM.Java.targets
index c3cc5c0cc8..7e3a3efdac 100644
--- a/IKVM.Java/IKVM.Java.targets
+++ b/IKVM.Java/IKVM.Java.targets
@@ -279,8 +279,8 @@
-
-
+
+
@@ -725,7 +725,6 @@
<_IkvmcArgs Include="-strictfinalfieldsemantics" />
<_IkvmcArgs Include="-removeassertions" />
<_IkvmcArgs Include="-target:library" />
- <_IkvmcArgs Include="-nostdlib" />
<_IkvmcArgs Include="-sharedclassloader" />
<_IkvmcArgs Include="-nowarn:110" />
<_IkvmcArgs Include="-w4" />
diff --git a/IKVM.Reflection/Fusion.cs b/IKVM.Reflection/Fusion.cs
index 69a00b9f4f..5b0979ad2f 100644
--- a/IKVM.Reflection/Fusion.cs
+++ b/IKVM.Reflection/Fusion.cs
@@ -98,7 +98,7 @@ internal static bool CompareAssemblyIdentityPure(string assemblyIdentity1, bool
throw new ArgumentException();
}
- if (name2.Name != null && name2.Name.Equals(Universe.CoreLibName, StringComparison.OrdinalIgnoreCase))
+ if (name2.Name != null && name2.Name.Equals(Universe.StdLibName, StringComparison.OrdinalIgnoreCase))
{
if (name1.Name != null && name1.Name.Equals(name2.Name, StringComparison.OrdinalIgnoreCase))
{
diff --git a/IKVM.Reflection/Universe.cs b/IKVM.Reflection/Universe.cs
index e8ec62e202..fb82836be3 100644
--- a/IKVM.Reflection/Universe.cs
+++ b/IKVM.Reflection/Universe.cs
@@ -24,13 +24,17 @@ Jeroen Frijters
using System;
using System.Collections.Generic;
using System.IO;
-using System.Runtime.InteropServices;
+using System.Linq;
using System.Security;
using System.Text;
using IKVM.Reflection.Emit;
using IKVM.Reflection.Reader;
+#if NETCOREAPP3_1_OR_GREATER
+using Microsoft.Extensions.DependencyModel;
+#endif
+
namespace IKVM.Reflection
{
@@ -145,44 +149,13 @@ public enum UniverseOptions
public sealed class Universe : IDisposable
{
-#if NETCOREAPP3_1
+#if NETCOREAPP3_1_OR_GREATER
- public static readonly string CoreLibName = "netstandard";
-
- public static string ReferenceAssembliesDirectory
- {
- get
- {
- return BuildRefDirFrom(System.Runtime.InteropServices.RuntimeEnvironment.GetRuntimeDirectory());
- }
- }
-
- private static string BuildRefDirFrom(string runtimeDir)
- {
- // transform a thing like
- // C:\Program Files\dotnet\shared\Microsoft.NETCore.App\3.1.7
- // to
- // C:\Program Files\dotnet\packs\Microsoft.NETCore.App.Ref\3.1.0\ref\netcoreapp3.1
-
- var parts = runtimeDir.Split(Path.DirectorySeparatorChar);
- var n = string.IsNullOrEmpty(parts[parts.Length - 1]) ? parts.Length - 2 : parts.Length - 1;
- var versionDir = parts[n--];
- var frameworkDir = parts[n--];
- var newParts = new string[n + 5];
- Array.Copy(parts, newParts, n);
- var suffixParts = new string[] { "packs", frameworkDir + ".Ref", "3.1.0", "ref", "netcoreapp3.1" };
- Array.Copy(suffixParts, 0, newParts, n, suffixParts.Length);
- var dir = Path.Combine(newParts);
- if (!Directory.Exists(dir))
- {
- throw new FileNotFoundException("Reference assemblies directory: " + dir);
- }
- return dir;
- }
+ public static readonly string StdLibName = "netstandard";
#elif NETFRAMEWORK || MONO
- public static readonly string CoreLibName = "mscorlib";
+ public static readonly string StdLibName = "mscorlib";
#endif
@@ -286,7 +259,7 @@ private static bool GetUseNativeFusion()
internal Assembly Mscorlib
{
- get { return Load(CoreLibName); }
+ get { return Load(StdLibName); }
}
private Type ImportMscorlibType(string ns, string name)
@@ -567,7 +540,7 @@ internal Type System_Security_Permissions_SecurityAction
internal bool HasMscorlib
{
- get { return GetLoadedAssembly(CoreLibName) != null; }
+ get { return GetLoadedAssembly(StdLibName) != null; }
}
public event ResolveEventHandler AssemblyResolve
@@ -782,108 +755,41 @@ private Assembly GetDynamicAssembly(string refname)
return null;
}
- public Assembly Load(string refname)
+ public Assembly Load(string refName)
{
- return Load(refname, null, true);
+ return Load(refName, null, true);
}
- internal Assembly Load(string refname, Module requestingModule, bool throwOnError)
+ internal Assembly Load(string refName, Module requestingModule, bool throwOnError)
{
- Assembly asm = GetLoadedAssembly(refname);
- if (asm != null)
- {
- return asm;
- }
- if (resolvers.Count == 0)
- {
- asm = DefaultResolver(refname, throwOnError);
- }
- else
- {
- ResolveEventArgs args = new ResolveEventArgs(refname, requestingModule == null ? null : requestingModule.Assembly);
- foreach (ResolveEventHandler evt in resolvers)
- {
- asm = evt(this, args);
- if (asm != null)
- {
- break;
- }
- }
- if (asm == null)
- {
- asm = GetDynamicAssembly(refname);
- }
- }
- if (asm != null)
- {
- string defname = asm.FullName;
- if (refname != defname)
- {
- assembliesByName.Add(refname, asm);
- }
- return asm;
- }
- if (throwOnError)
- {
- throw new FileNotFoundException(refname);
- }
- return null;
- }
+ // if the assembly is already loaded, just return that
+ var assembly = GetLoadedAssembly(refName);
+ if (assembly != null)
+ return assembly;
- private Assembly DefaultResolver(string refname, bool throwOnError)
- {
- Assembly asm = GetDynamicAssembly(refname);
- if (asm != null)
- {
- return asm;
- }
+ // dispatch a resolve event to the resolvers
+ var arg = new ResolveEventArgs(refName, requestingModule?.Assembly);
+ assembly = resolvers.Select(i => i(this, arg)).FirstOrDefault(i => i != null);
+
+ // still not found, maybe it's a dynamic assembly?
+ if (assembly == null)
+ assembly = GetDynamicAssembly(refName);
-#if NETCOREAPP3_1
- string filepath = Path.Combine(ReferenceAssembliesDirectory, GetSimpleAssemblyName(refname) + ".dll");
- if (File.Exists(filepath))
+ // we did find the assembly
+ if (assembly != null)
{
- using (RawModule module = OpenRawModule(filepath))
- {
- AssemblyComparisonResult result;
- if (module.IsManifestModule && CompareAssemblyIdentity(refname, false, module.GetAssemblyName().FullName, false, out result))
- {
- return LoadAssembly(module);
- }
- }
+ // associate the assembly with our set by name
+ var defName = assembly.FullName;
+ if (refName != defName)
+ assembliesByName.Add(refName, assembly);
+
+ return assembly;
}
+
+ if (throwOnError)
+ throw new FileNotFoundException(refName);
+
return null;
-#else
- string fileName;
- if (throwOnError)
- {
- try
- {
- fileName = System.Reflection.Assembly.ReflectionOnlyLoad(refname).Location;
- }
- catch (System.BadImageFormatException x)
- {
- throw new BadImageFormatException(x.Message, x);
- }
- }
- else
- {
- try
- {
- fileName = System.Reflection.Assembly.ReflectionOnlyLoad(refname).Location;
- }
- catch (System.BadImageFormatException x)
- {
- throw new BadImageFormatException(x.Message, x);
- }
- catch (FileNotFoundException)
- {
- // we intentionally only swallow the FileNotFoundException, if the file exists but isn't a valid assembly,
- // we should throw an exception
- return null;
- }
- }
- return LoadFile(fileName);
-#endif
}
public Type GetType(string assemblyQualifiedTypeName)
diff --git a/IKVM.Runtime/ClassFile.cs b/IKVM.Runtime/ClassFile.cs
index 9752fe8301..016591943c 100644
--- a/IKVM.Runtime/ClassFile.cs
+++ b/IKVM.Runtime/ClassFile.cs
@@ -445,7 +445,7 @@ internal ClassFile(byte[] buf, int offset, int length, string inputClassName, Cl
GetConstantPoolClass(class_index),
null,
null
- };
+ };
}
else
{
@@ -767,16 +767,16 @@ private static object ReadAnnotationElementValue(BigEndianBinaryReader rdr, Clas
ushort type_name_index = rdr.ReadUInt16();
ushort const_name_index = rdr.ReadUInt16();
return new object[] {
- AnnotationDefaultAttribute.TAG_ENUM,
- classFile.GetConstantPoolUtf8String(utf8_cp, type_name_index),
- classFile.GetConstantPoolUtf8String(utf8_cp, const_name_index)
- };
+ AnnotationDefaultAttribute.TAG_ENUM,
+ classFile.GetConstantPoolUtf8String(utf8_cp, type_name_index),
+ classFile.GetConstantPoolUtf8String(utf8_cp, const_name_index)
+ };
}
case (byte)'c':
return new object[] {
- AnnotationDefaultAttribute.TAG_CLASS,
- classFile.GetConstantPoolUtf8String(utf8_cp, rdr.ReadUInt16())
- };
+ AnnotationDefaultAttribute.TAG_CLASS,
+ classFile.GetConstantPoolUtf8String(utf8_cp, rdr.ReadUInt16())
+ };
case (byte)'@':
return ReadAnnotation(rdr, classFile, utf8_cp);
case (byte)'[':
@@ -1241,15 +1241,12 @@ internal string SourcePath
#endif
}
- internal object[] Annotations
- {
- get
- {
- return annotations;
- }
- }
+ ///
+ /// Gets the annotations set on the class.
+ ///
+ internal object[] Annotations => annotations;
- internal string GenericSignature
+ internal string GenericSignature
{
get
{
diff --git a/IKVM.Runtime/ClassLoaderWrapper.cs b/IKVM.Runtime/ClassLoaderWrapper.cs
index 2aaa05c359..1866d383da 100644
--- a/IKVM.Runtime/ClassLoaderWrapper.cs
+++ b/IKVM.Runtime/ClassLoaderWrapper.cs
@@ -1109,12 +1109,12 @@ internal static TypeWrapper GetWrapperFromType(Type type)
}
#if STUB_GENERATOR
- if(type.__IsMissing || type.__ContainsMissingType)
- {
- wrapper = new UnloadableTypeWrapper("Missing/" + type.Assembly.FullName);
- globalTypeToTypeWrapper.Add(type, wrapper);
- return wrapper;
- }
+ if (type.__IsMissing || type.__ContainsMissingType)
+ {
+ wrapper = new UnloadableTypeWrapper("Missing/" + type.Assembly.FullName);
+ globalTypeToTypeWrapper.Add(type, wrapper);
+ return wrapper;
+ }
#endif
string remapped;
if (remappedTypes.TryGetValue(type, out remapped))
diff --git a/IKVM.Runtime/TypeWrapper.cs b/IKVM.Runtime/TypeWrapper.cs
index cad4cbf722..d9b6aa946d 100644
--- a/IKVM.Runtime/TypeWrapper.cs
+++ b/IKVM.Runtime/TypeWrapper.cs
@@ -1627,10 +1627,16 @@ internal static string[] UnescapeInvalidSurrogates(string[] str)
abstract class Annotation
{
+
#if STATIC_COMPILER
+
internal static Annotation LoadAssemblyCustomAttribute(ClassLoaderWrapper loader, object[] def)
{
- Debug.Assert(def[0].Equals(AnnotationDefaultAttribute.TAG_ANNOTATION));
+ if (def.Length == 0)
+ throw new ArgumentException("LoadAssemblyCustomAttribute did not receive any definitions.");
+ if (object.Equals(def[0], AnnotationDefaultAttribute.TAG_ANNOTATION) == false)
+ throw new InternalException("LoadAssemblyCustomAttribute did not receive AnnotationDefaultAttribute.TAG_ANNOTATION.");
+
string annotationClass = (string)def[1];
if (ClassFile.IsValidFieldSig(annotationClass))
{
@@ -1640,10 +1646,12 @@ internal static Annotation LoadAssemblyCustomAttribute(ClassLoaderWrapper loader
}
catch (RetargetableJavaException)
{
+
}
}
return null;
}
+
#endif
#if !STUB_GENERATOR
@@ -2006,8 +2014,9 @@ internal abstract class TypeWrapper
internal TypeWrapper(TypeFlags flags, Modifiers modifiers, string name)
{
Profiler.Count("TypeWrapper");
- // class name should be dotted or null for primitives
- Debug.Assert(name == null || name.IndexOf('/') < 0, name);
+
+ if (name != null && name.IndexOf('/') > -1)
+ throw new InternalException("Class name should be dotted, or null for primitives.");
this.flags = flags;
this.modifiers = modifiers;
diff --git a/IKVM.Runtime/vm.cs b/IKVM.Runtime/vm.cs
index 07b0d7131f..b946812671 100644
--- a/IKVM.Runtime/vm.cs
+++ b/IKVM.Runtime/vm.cs
@@ -39,461 +39,461 @@ Jeroen Frijters
#if !STATIC_COMPILER && !STUB_GENERATOR
namespace IKVM.Internal
{
- public static class Starter
- {
- public static void PrepareForSaveDebugImage()
- {
- JVM.IsSaveDebugImage = true;
- }
-
- public static void SaveDebugImage()
- {
- DynamicClassLoader.SaveDebugImages();
- }
+ public static class Starter
+ {
+ public static void PrepareForSaveDebugImage()
+ {
+ JVM.IsSaveDebugImage = true;
+ }
- public static bool ClassUnloading
- {
+ public static void SaveDebugImage()
+ {
+ DynamicClassLoader.SaveDebugImages();
+ }
+
+ public static bool ClassUnloading
+ {
#if CLASSGC
get { return JVM.classUnloading; }
set { JVM.classUnloading = value; }
#else
- get { return false; }
- set { }
+ get { return false; }
+ set { }
#endif
- }
+ }
- public static bool RelaxedVerification
- {
- get { return JVM.relaxedVerification; }
- set { JVM.relaxedVerification = value; }
- }
+ public static bool RelaxedVerification
+ {
+ get { return JVM.relaxedVerification; }
+ set { JVM.relaxedVerification = value; }
+ }
- public static bool AllowNonVirtualCalls
- {
- get { return JVM.AllowNonVirtualCalls; }
- set { JVM.AllowNonVirtualCalls = value; }
- }
- }
+ public static bool AllowNonVirtualCalls
+ {
+ get { return JVM.AllowNonVirtualCalls; }
+ set { JVM.AllowNonVirtualCalls = value; }
+ }
+ }
}
#endif // !STATIC_COMPILER && !STUB_GENERATOR
namespace IKVM.Internal
{
- static class JVM
- {
- internal const string JarClassList = "--ikvm-classes--/";
+ static class JVM
+ {
+ internal const string JarClassList = "--ikvm-classes--/";
#if STATIC_COMPILER
- internal const bool FinishingForDebugSave = false;
- internal const bool IsSaveDebugImage = false;
+ internal const bool FinishingForDebugSave = false;
+ internal const bool IsSaveDebugImage = false;
#elif !STUB_GENERATOR
- private static bool finishingForDebugSave;
- private static int emitSymbols;
- internal static bool IsSaveDebugImage;
+ private static bool finishingForDebugSave;
+ private static int emitSymbols;
+ internal static bool IsSaveDebugImage;
#if CLASSGC
internal static bool classUnloading = true;
#endif
#endif // STATIC_COMPILER
- private static Assembly coreAssembly;
+ private static Assembly coreAssembly;
#if !STUB_GENERATOR
- internal static bool relaxedVerification = true;
- internal static bool AllowNonVirtualCalls;
- internal static readonly bool DisableEagerClassLoading = SafeGetEnvironmentVariable("IKVM_DISABLE_EAGER_CLASS_LOADING") != null;
+ internal static bool relaxedVerification = true;
+ internal static bool AllowNonVirtualCalls;
+ internal static readonly bool DisableEagerClassLoading = SafeGetEnvironmentVariable("IKVM_DISABLE_EAGER_CLASS_LOADING") != null;
#endif
#if !STATIC_COMPILER && !STUB_GENERATOR && !FIRST_PASS
- static JVM()
- {
- if (SafeGetEnvironmentVariable("IKVM_SAVE_DYNAMIC_ASSEMBLIES") != null)
- {
- IsSaveDebugImage = true;
- java.lang.Runtime.getRuntime().addShutdownHook(new java.lang.Thread(ikvm.runtime.Delegates.toRunnable(DynamicClassLoader.SaveDebugImages)));
- }
- }
+ static JVM()
+ {
+ if (SafeGetEnvironmentVariable("IKVM_SAVE_DYNAMIC_ASSEMBLIES") != null)
+ {
+ IsSaveDebugImage = true;
+ java.lang.Runtime.getRuntime().addShutdownHook(new java.lang.Thread(ikvm.runtime.Delegates.toRunnable(DynamicClassLoader.SaveDebugImages)));
+ }
+ }
#endif
- internal static Version SafeGetAssemblyVersion(System.Reflection.Assembly asm)
- {
- // Assembly.GetName().Version requires FileIOPermission,
- // so we parse the FullName manually :-(
- string name = asm.FullName;
- int start = name.IndexOf(", Version=");
- if(start >= 0)
- {
- start += 10;
- int end = name.IndexOf(',', start);
- if(end >= 0)
- {
- return new Version(name.Substring(start, end - start));
- }
- }
- return new Version();
- }
+ internal static Version SafeGetAssemblyVersion(System.Reflection.Assembly asm)
+ {
+ // Assembly.GetName().Version requires FileIOPermission,
+ // so we parse the FullName manually :-(
+ string name = asm.FullName;
+ int start = name.IndexOf(", Version=");
+ if (start >= 0)
+ {
+ start += 10;
+ int end = name.IndexOf(',', start);
+ if (end >= 0)
+ {
+ return new Version(name.Substring(start, end - start));
+ }
+ }
+ return new Version();
+ }
- internal static string SafeGetEnvironmentVariable(string name)
- {
- try
- {
- return Environment.GetEnvironmentVariable(name);
- }
- catch(SecurityException)
- {
- return null;
- }
- }
+ internal static string SafeGetEnvironmentVariable(string name)
+ {
+ try
+ {
+ return Environment.GetEnvironmentVariable(name);
+ }
+ catch (SecurityException)
+ {
+ return null;
+ }
+ }
- internal static Assembly CoreAssembly
- {
- get
- {
+ internal static Assembly CoreAssembly
+ {
+ get
+ {
#if !STATIC_COMPILER && !STUB_GENERATOR
- if(coreAssembly == null)
- {
+ if (coreAssembly == null)
+ {
#if FIRST_PASS
throw new InvalidOperationException("This version of IKVM.Runtime.dll was compiled with FIRST_PASS defined.");
#else
- coreAssembly = typeof(java.lang.Object).Assembly;
+ coreAssembly = typeof(java.lang.Object).Assembly;
#endif
- }
+ }
#endif // !STATIC_COMPILER
- return coreAssembly;
- }
- set
- {
- coreAssembly = value;
- }
- }
+ return coreAssembly;
+ }
+ set
+ {
+ coreAssembly = value;
+ }
+ }
#if !STATIC_COMPILER && !STUB_GENERATOR
- internal static bool FinishingForDebugSave
- {
- get
- {
- return finishingForDebugSave;
- }
- set
- {
- finishingForDebugSave = value;
- }
- }
+ internal static bool FinishingForDebugSave
+ {
+ get
+ {
+ return finishingForDebugSave;
+ }
+ set
+ {
+ finishingForDebugSave = value;
+ }
+ }
- internal static bool EmitSymbols
- {
- get
- {
- if (emitSymbols == 0)
- {
- int state;
- string debug = System.Configuration.ConfigurationManager.AppSettings["ikvm-emit-symbols"];
- if (debug == null)
- {
- state = Debugger.IsAttached ? 1 : 2;
- }
- else
- {
- state = debug.Equals("True", StringComparison.OrdinalIgnoreCase) ? 1 : 2;
- }
- // make sure we only set the value once, because it isn't allowed to changed as that could cause
- // the compiler to try emitting symbols into a ModuleBuilder that doesn't accept them (and would
- // throw an InvalidOperationException)
- Interlocked.CompareExchange(ref emitSymbols, state, 0);
- }
- return emitSymbols == 1;
- }
- }
+ internal static bool EmitSymbols
+ {
+ get
+ {
+ if (emitSymbols == 0)
+ {
+ int state;
+ string debug = System.Configuration.ConfigurationManager.AppSettings["ikvm-emit-symbols"];
+ if (debug == null)
+ {
+ state = Debugger.IsAttached ? 1 : 2;
+ }
+ else
+ {
+ state = debug.Equals("True", StringComparison.OrdinalIgnoreCase) ? 1 : 2;
+ }
+ // make sure we only set the value once, because it isn't allowed to changed as that could cause
+ // the compiler to try emitting symbols into a ModuleBuilder that doesn't accept them (and would
+ // throw an InvalidOperationException)
+ Interlocked.CompareExchange(ref emitSymbols, state, 0);
+ }
+ return emitSymbols == 1;
+ }
+ }
#endif // !STATIC_COMPILER && !STUB_GENERATOR
- internal static bool IsUnix
- {
- get
- {
- return Environment.OSVersion.Platform == PlatformID.Unix;
- }
- }
-
- internal static string MangleResourceName(string name)
- {
- // FXBUG there really shouldn't be any need to mangle the resource names,
- // but in order for ILDASM/ILASM round tripping to work reliably, we have
- // to make sure that we don't produce resource names that'll cause ILDASM
- // to generate invalid filenames.
- StringBuilder sb = new StringBuilder("ikvm__", name.Length + 6);
- foreach(char c in name)
- {
- if("abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ_-+.()$#@~=&{}[]0123456789`".IndexOf(c) != -1)
- {
- sb.Append(c);
- }
- else if(c == '/')
- {
- sb.Append('!');
- }
- else
- {
- sb.Append('%');
- sb.Append(string.Format("{0:X4}", (int)c));
- }
- }
- return sb.ToString();
- }
+ internal static bool IsUnix
+ {
+ get
+ {
+ return Environment.OSVersion.Platform == PlatformID.Unix;
+ }
+ }
+
+ internal static string MangleResourceName(string name)
+ {
+ // FXBUG there really shouldn't be any need to mangle the resource names,
+ // but in order for ILDASM/ILASM round tripping to work reliably, we have
+ // to make sure that we don't produce resource names that'll cause ILDASM
+ // to generate invalid filenames.
+ StringBuilder sb = new StringBuilder("ikvm__", name.Length + 6);
+ foreach (char c in name)
+ {
+ if ("abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ_-+.()$#@~=&{}[]0123456789`".IndexOf(c) != -1)
+ {
+ sb.Append(c);
+ }
+ else if (c == '/')
+ {
+ sb.Append('!');
+ }
+ else
+ {
+ sb.Append('%');
+ sb.Append(string.Format("{0:X4}", (int)c));
+ }
+ }
+ return sb.ToString();
+ }
- // based on Bret Mulvey's C# port of Jenkins32
- // note that this algorithm cannot be changed, because we persist these hashcodes in the metadata of shared class loader assemblies
- internal static int PersistableHash(string str)
- {
- uint key = 1;
- foreach (char c in str)
- {
- key += c;
- key += (key << 12);
- key ^= (key >> 22);
- key += (key << 4);
- key ^= (key >> 9);
- key += (key << 10);
- key ^= (key >> 2);
- key += (key << 7);
- key ^= (key >> 12);
- }
- return (int)key;
- }
+ // based on Bret Mulvey's C# port of Jenkins32
+ // note that this algorithm cannot be changed, because we persist these hashcodes in the metadata of shared class loader assemblies
+ internal static int PersistableHash(string str)
+ {
+ uint key = 1;
+ foreach (char c in str)
+ {
+ key += c;
+ key += (key << 12);
+ key ^= (key >> 22);
+ key += (key << 4);
+ key ^= (key >> 9);
+ key += (key << 10);
+ key ^= (key >> 2);
+ key += (key << 7);
+ key ^= (key >> 12);
+ }
+ return (int)key;
+ }
#if !STATIC_COMPILER
- internal static void CriticalFailure(string message, Exception x)
- {
- try
- {
- Tracer.Error(Tracer.Runtime, "CRITICAL FAILURE: {0}", message);
- System.Type messageBox = null;
+ internal static void CriticalFailure(string message, Exception x)
+ {
+ try
+ {
+ Tracer.Error(Tracer.Runtime, "CRITICAL FAILURE: {0}", message);
+ System.Type messageBox = null;
#if !STUB_GENERATOR
- // NOTE we use reflection to invoke MessageBox.Show, to make sure we run in environments where WinForms isn't available
- Assembly winForms = IsUnix ? null : Assembly.Load("System.Windows.Forms, Version=1.0.5000.0, Culture=neutral, PublicKeyToken=b77a5c561934e089");
- if(winForms != null)
- {
- messageBox = winForms.GetType("System.Windows.Forms.MessageBox");
- }
+ // NOTE we use reflection to invoke MessageBox.Show, to make sure we run in environments where WinForms isn't available
+ Assembly winForms = IsUnix ? null : Assembly.Load("System.Windows.Forms, Version=1.0.5000.0, Culture=neutral, PublicKeyToken=b77a5c561934e089");
+ if (winForms != null)
+ {
+ messageBox = winForms.GetType("System.Windows.Forms.MessageBox");
+ }
#endif
- message = String.Format("****** Critical Failure: {1} ******{0}{0}" +
- "PLEASE FILE A BUG REPORT FOR IKVM.NET WHEN YOU SEE THIS MESSAGE{0}{0}" +
- (messageBox != null ? "(on Windows you can use Ctrl+C to copy the contents of this message to the clipboard){0}{0}" : "") +
- "{2}{0}" +
- "{3}{0}" +
- "{4} {5}-bit{0}{0}" +
- "{6}{0}" +
- "{7}{0}" +
- "{8}",
- Environment.NewLine,
- message,
- System.Reflection.Assembly.GetExecutingAssembly().FullName,
- System.Runtime.InteropServices.RuntimeEnvironment.GetRuntimeDirectory(),
- Environment.Version,
- IntPtr.Size * 8,
- x,
- x != null ? new StackTrace(x, true).ToString() : "",
- new StackTrace(true));
- if(messageBox != null)
- {
- try
- {
- Version ver = SafeGetAssemblyVersion(typeof(JVM).Assembly);
- messageBox.InvokeMember("Show", System.Reflection.BindingFlags.InvokeMethod | System.Reflection.BindingFlags.Static | System.Reflection.BindingFlags.Public, null, null, new object[] { message, "IKVM.NET " + ver + " Critical Failure" });
- }
- catch
- {
- Console.Error.WriteLine(message);
- }
- }
- else
- {
- Console.Error.WriteLine(message);
- }
- }
- catch(Exception ex)
- {
- Console.Error.WriteLine(ex);
- }
- finally
- {
- Environment.Exit(666);
- }
- }
+ message = String.Format("****** Critical Failure: {1} ******{0}{0}" +
+ "PLEASE FILE A BUG REPORT FOR IKVM.NET WHEN YOU SEE THIS MESSAGE{0}{0}" +
+ (messageBox != null ? "(on Windows you can use Ctrl+C to copy the contents of this message to the clipboard){0}{0}" : "") +
+ "{2}{0}" +
+ "{3}{0}" +
+ "{4} {5}-bit{0}{0}" +
+ "{6}{0}" +
+ "{7}{0}" +
+ "{8}",
+ Environment.NewLine,
+ message,
+ System.Reflection.Assembly.GetExecutingAssembly().FullName,
+ System.Runtime.InteropServices.RuntimeEnvironment.GetRuntimeDirectory(),
+ Environment.Version,
+ IntPtr.Size * 8,
+ x,
+ x != null ? new StackTrace(x, true).ToString() : "",
+ new StackTrace(true));
+ if (messageBox != null)
+ {
+ try
+ {
+ Version ver = SafeGetAssemblyVersion(typeof(JVM).Assembly);
+ messageBox.InvokeMember("Show", System.Reflection.BindingFlags.InvokeMethod | System.Reflection.BindingFlags.Static | System.Reflection.BindingFlags.Public, null, null, new object[] { message, "IKVM.NET " + ver + " Critical Failure" });
+ }
+ catch
+ {
+ Console.Error.WriteLine(message);
+ }
+ }
+ else
+ {
+ Console.Error.WriteLine(message);
+ }
+ }
+ catch (Exception ex)
+ {
+ Console.Error.WriteLine(ex);
+ }
+ finally
+ {
+ Environment.Exit(666);
+ }
+ }
#endif // !STATIC_COMPILER
#if STATIC_COMPILER || STUB_GENERATOR
- internal static Type LoadType(System.Type type)
- {
- return StaticCompiler.GetRuntimeType(type.FullName);
- }
+ internal static Type LoadType(System.Type type)
+ {
+ return StaticCompiler.GetRuntimeType(type.FullName);
+ }
#endif
- // this method resolves types in IKVM.Runtime.dll
- // (the version of IKVM.Runtime.dll that we're running
- // with can be different from the one we're compiling against.)
- internal static Type LoadType(Type type)
- {
+ // this method resolves types in IKVM.Runtime.dll
+ // (the version of IKVM.Runtime.dll that we're running
+ // with can be different from the one we're compiling against.)
+ internal static Type LoadType(Type type)
+ {
#if STATIC_COMPILER || STUB_GENERATOR
- return StaticCompiler.GetRuntimeType(type.FullName);
+ return StaticCompiler.GetRuntimeType(type.FullName);
#else
- return type;
+ return type;
#endif
- }
+ }
- internal static object Box(object val)
- {
+ internal static object Box(object val)
+ {
#if STATIC_COMPILER || FIRST_PASS || STUB_GENERATOR
- return null;
+ return null;
#else
- if(val is byte)
- {
- return java.lang.Byte.valueOf((byte)val);
- }
- else if(val is bool)
- {
- return java.lang.Boolean.valueOf((bool)val);
- }
- else if(val is short)
- {
- return java.lang.Short.valueOf((short)val);
- }
- else if(val is char)
- {
- return java.lang.Character.valueOf((char)val);
- }
- else if(val is int)
- {
- return java.lang.Integer.valueOf((int)val);
- }
- else if(val is float)
- {
- return java.lang.Float.valueOf((float)val);
- }
- else if(val is long)
- {
- return java.lang.Long.valueOf((long)val);
- }
- else if(val is double)
- {
- return java.lang.Double.valueOf((double)val);
- }
- else
- {
- throw new java.lang.IllegalArgumentException();
- }
+ if (val is byte)
+ {
+ return java.lang.Byte.valueOf((byte)val);
+ }
+ else if (val is bool)
+ {
+ return java.lang.Boolean.valueOf((bool)val);
+ }
+ else if (val is short)
+ {
+ return java.lang.Short.valueOf((short)val);
+ }
+ else if (val is char)
+ {
+ return java.lang.Character.valueOf((char)val);
+ }
+ else if (val is int)
+ {
+ return java.lang.Integer.valueOf((int)val);
+ }
+ else if (val is float)
+ {
+ return java.lang.Float.valueOf((float)val);
+ }
+ else if (val is long)
+ {
+ return java.lang.Long.valueOf((long)val);
+ }
+ else if (val is double)
+ {
+ return java.lang.Double.valueOf((double)val);
+ }
+ else
+ {
+ throw new java.lang.IllegalArgumentException();
+ }
#endif
- }
+ }
- internal static object Unbox(object val)
- {
+ internal static object Unbox(object val)
+ {
#if STATIC_COMPILER || FIRST_PASS || STUB_GENERATOR
- return null;
+ return null;
#else
- java.lang.Byte b = val as java.lang.Byte;
- if(b != null)
- {
- return b.byteValue();
- }
- java.lang.Boolean b1 = val as java.lang.Boolean;
- if(b1 != null)
- {
- return b1.booleanValue();
- }
- java.lang.Short s = val as java.lang.Short;
- if(s != null)
- {
- return s.shortValue();
- }
- java.lang.Character c = val as java.lang.Character;
- if(c != null)
- {
- return c.charValue();
- }
- java.lang.Integer i = val as java.lang.Integer;
- if(i != null)
- {
- return i.intValue();
- }
- java.lang.Float f = val as java.lang.Float;
- if(f != null)
- {
- return f.floatValue();
- }
- java.lang.Long l = val as java.lang.Long;
- if(l != null)
- {
- return l.longValue();
- }
- java.lang.Double d = val as java.lang.Double;
- if(d != null)
- {
- return d.doubleValue();
- }
- else
- {
- throw new java.lang.IllegalArgumentException();
- }
+ java.lang.Byte b = val as java.lang.Byte;
+ if (b != null)
+ {
+ return b.byteValue();
+ }
+ java.lang.Boolean b1 = val as java.lang.Boolean;
+ if (b1 != null)
+ {
+ return b1.booleanValue();
+ }
+ java.lang.Short s = val as java.lang.Short;
+ if (s != null)
+ {
+ return s.shortValue();
+ }
+ java.lang.Character c = val as java.lang.Character;
+ if (c != null)
+ {
+ return c.charValue();
+ }
+ java.lang.Integer i = val as java.lang.Integer;
+ if (i != null)
+ {
+ return i.intValue();
+ }
+ java.lang.Float f = val as java.lang.Float;
+ if (f != null)
+ {
+ return f.floatValue();
+ }
+ java.lang.Long l = val as java.lang.Long;
+ if (l != null)
+ {
+ return l.longValue();
+ }
+ java.lang.Double d = val as java.lang.Double;
+ if (d != null)
+ {
+ return d.doubleValue();
+ }
+ else
+ {
+ throw new java.lang.IllegalArgumentException();
+ }
#endif
- }
+ }
#if !STATIC_COMPILER && !STUB_GENERATOR
- internal static object NewAnnotation(java.lang.ClassLoader classLoader, object definition)
- {
+ internal static object NewAnnotation(java.lang.ClassLoader classLoader, object definition)
+ {
#if !FIRST_PASS
- java.lang.annotation.Annotation ann = null;
- try
- {
- ann = (java.lang.annotation.Annotation)ikvm.@internal.AnnotationAttributeBase.newAnnotation(classLoader, definition);
- }
- catch (java.lang.TypeNotPresentException) { }
- if (ann != null && sun.reflect.annotation.AnnotationType.getInstance(ann.annotationType()).retention() == java.lang.annotation.RetentionPolicy.RUNTIME)
- {
- return ann;
- }
+ java.lang.annotation.Annotation ann = null;
+ try
+ {
+ ann = (java.lang.annotation.Annotation)ikvm.@internal.AnnotationAttributeBase.newAnnotation(classLoader, definition);
+ }
+ catch (java.lang.TypeNotPresentException) { }
+ if (ann != null && sun.reflect.annotation.AnnotationType.getInstance(ann.annotationType()).retention() == java.lang.annotation.RetentionPolicy.RUNTIME)
+ {
+ return ann;
+ }
#endif
- return null;
- }
+ return null;
+ }
#endif
#if !STATIC_COMPILER && !STUB_GENERATOR
- internal static object NewAnnotationElementValue(java.lang.ClassLoader classLoader, java.lang.Class expectedClass, object definition)
- {
+ internal static object NewAnnotationElementValue(java.lang.ClassLoader classLoader, java.lang.Class expectedClass, object definition)
+ {
#if FIRST_PASS
return null;
#else
- try
- {
- return ikvm.@internal.AnnotationAttributeBase.decodeElementValue(definition, expectedClass, classLoader);
- }
- catch(java.lang.IllegalAccessException)
- {
- // TODO this shouldn't be here
- return null;
- }
+ try
+ {
+ return ikvm.@internal.AnnotationAttributeBase.decodeElementValue(definition, expectedClass, classLoader);
+ }
+ catch (java.lang.IllegalAccessException)
+ {
+ // TODO this shouldn't be here
+ return null;
+ }
#endif
- }
+ }
#endif
#if !STATIC_COMPILER && !STUB_GENERATOR
- // helper for JNI (which doesn't have access to core library internals)
- internal static object NewDirectByteBuffer(long address, int capacity)
- {
+ // helper for JNI (which doesn't have access to core library internals)
+ internal static object NewDirectByteBuffer(long address, int capacity)
+ {
#if FIRST_PASS
return null;
#else
- return java.nio.DirectByteBuffer.__new(address, capacity);
+ return java.nio.DirectByteBuffer.__new(address, capacity);
#endif
- }
+ }
#endif
- internal static Type Import(System.Type type)
- {
+ internal static Type Import(System.Type type)
+ {
#if STATIC_COMPILER || STUB_GENERATOR
- return StaticCompiler.Universe.Import(type);
+ return StaticCompiler.Universe.Import(type);
#else
- return type;
+ return type;
#endif
- }
- }
+ }
+ }
- static class Experimental
- {
- internal static readonly bool JDK_9 = JVM.SafeGetEnvironmentVariable("IKVM_EXPERIMENTAL_JDK_9") != null;
- }
+ static class Experimental
+ {
+ internal static readonly bool JDK_9 = JVM.SafeGetEnvironmentVariable("IKVM_EXPERIMENTAL_JDK_9") != null;
+ }
}
diff --git a/IKVM.Tests.Util/IKVM.Tests.Util.csproj b/IKVM.Tests.Util/IKVM.Tests.Util.csproj
new file mode 100644
index 0000000000..24858c143b
--- /dev/null
+++ b/IKVM.Tests.Util/IKVM.Tests.Util.csproj
@@ -0,0 +1,11 @@
+
+
+
+ net461;netcoreapp3.1
+
+
+
+
+
+
+
diff --git a/IKVM.Tests/Util/InMemoryCodeUnit.cs b/IKVM.Tests.Util/InMemoryCodeUnit.cs
similarity index 93%
rename from IKVM.Tests/Util/InMemoryCodeUnit.cs
rename to IKVM.Tests.Util/InMemoryCodeUnit.cs
index 121334dd77..d00fcb2546 100644
--- a/IKVM.Tests/Util/InMemoryCodeUnit.cs
+++ b/IKVM.Tests.Util/InMemoryCodeUnit.cs
@@ -1,11 +1,12 @@
using System;
-namespace IKVM.Tests.JNI
+namespace IKVM.Tests.Util
{
+
///
/// Represents a unit of code to compile.
///
- class InMemoryCodeUnit
+ public class InMemoryCodeUnit
{
///
diff --git a/IKVM.Tests/Util/InMemoryCompiler.cs b/IKVM.Tests.Util/InMemoryCompiler.cs
similarity index 76%
rename from IKVM.Tests/Util/InMemoryCompiler.cs
rename to IKVM.Tests.Util/InMemoryCompiler.cs
index 5902d21746..41b2718d93 100644
--- a/IKVM.Tests/Util/InMemoryCompiler.cs
+++ b/IKVM.Tests.Util/InMemoryCompiler.cs
@@ -1,21 +1,25 @@
using System;
using System.Collections.Concurrent;
+using System.IO;
-namespace IKVM.Tests.JNI
+namespace IKVM.Tests.Util
{
+
///
/// Provides methods to compile a set of sources into a Java classes.
///
- class InMemoryCompiler
+ public class InMemoryCompiler
{
+ readonly ConcurrentDictionary classes = new();
+
///
/// Captures the output files from the compilation process.
///
class InMemoryForwardingJavaFileManager : global::javax.tools.ForwardingJavaFileManager
{
- readonly ConcurrentDictionary classes = new();
+ readonly ConcurrentDictionary classes;
///
/// Class loader which reads from the output class files.
@@ -87,10 +91,11 @@ public InMemoryClassFileObject(ConcurrentDictionary
///
- public InMemoryForwardingJavaFileManager(global::javax.tools.JavaFileManager manager) :
+ ///
+ public InMemoryForwardingJavaFileManager(global::javax.tools.JavaFileManager manager, ConcurrentDictionary classes) :
base(manager)
{
-
+ this.classes = classes ?? throw new ArgumentNullException(nameof(classes));
}
///
@@ -163,7 +168,7 @@ public InMemoryCompiler(InMemoryCodeUnit[] source)
this.compiler = global::javax.tools.ToolProvider.getSystemJavaCompiler() ?? throw new Exception();
this.units = source ?? throw new ArgumentNullException(nameof(source));
- this.files = new InMemoryForwardingJavaFileManager(compiler.getStandardFileManager(null, null, null));
+ this.files = new InMemoryForwardingJavaFileManager(compiler.getStandardFileManager(null, null, null), classes);
}
///
@@ -196,16 +201,66 @@ public void Compile()
///
///
///
- public global::java.lang.Class getCompiledClass(string className)
+ public global::java.lang.Class GetClass(string className)
{
var cld = files.getClassLoader(null);
var cls = cld.loadClass(className);
if (cls == null)
- throw new ClassNotFoundException("Class returned by ClassLoader was null!");
+ throw new global::java.lang.ClassNotFoundException("Class returned by ClassLoader was null!");
return cls;
}
+ ///
+ /// Writes the compiled classes to a JAR.
+ ///
+ ///
+ public void WriteJar(string path)
+ {
+ using var jar = File.OpenWrite(path);
+ WriteJar(jar);
+ }
+
+ ///
+ /// Writes the compiled classes to a JAR on the given stream.
+ ///
+ ///
+ public void WriteJar(Stream stream)
+ {
+ // write to temporary stream
+ var buf = new global::java.io.ByteArrayOutputStream();
+ WriteJar(buf);
+ stream.Write(buf.toByteArray(), 0, buf.size());
+ }
+
+ ///
+ /// Writes the compiled classes to a JAR on the given stream.
+ ///
+ ///
+ public void WriteJar(global::java.io.OutputStream stream)
+ {
+ var man = new global::java.util.jar.Manifest();
+ man.getMainAttributes().put(global::java.util.jar.Attributes.Name.MANIFEST_VERSION, "1.0");
+ var jar = new global::java.util.jar.JarOutputStream(stream, man);
+ WriteJar(jar);
+ jar.close();
+ }
+
+ ///
+ /// Writes the compiled classes to a JAR.
+ ///
+ ///
+ public void WriteJar(global::java.util.jar.JarOutputStream jar)
+ {
+ foreach (var i in classes)
+ {
+ var e = new global::java.util.jar.JarEntry(i.Key.Replace(".", "/") + ".class");
+ jar.putNextEntry(e);
+ i.Value.writeTo(jar);
+ jar.closeEntry();
+ }
+ }
+
}
}
diff --git a/IKVM.Tests/IKVM.Tests.csproj b/IKVM.Tests/IKVM.Tests.csproj
index e3242fcd45..0347ec21f2 100644
--- a/IKVM.Tests/IKVM.Tests.csproj
+++ b/IKVM.Tests/IKVM.Tests.csproj
@@ -28,6 +28,7 @@
+
diff --git a/IKVM.Tests/JNI/JniTests.cs b/IKVM.Tests/JNI/JniTests.cs
index 2950c3395d..6657f6ecc0 100644
--- a/IKVM.Tests/JNI/JniTests.cs
+++ b/IKVM.Tests/JNI/JniTests.cs
@@ -3,6 +3,8 @@
using FluentAssertions;
+using IKVM.Tests.Util;
+
using Microsoft.VisualStudio.TestTools.UnitTesting;
namespace IKVM.Tests.JNI
@@ -20,7 +22,7 @@ public void Can_invoke_native_method()
var f = new InMemoryCodeUnit("ikvm.tests.jni.JniTests", s);
var c = new InMemoryCompiler(new[] { f });
c.Compile();
- var z = c.getCompiledClass("ikvm.tests.jni.JniTests");
+ var z = c.GetClass("ikvm.tests.jni.JniTests");
if (z == null)
throw new Exception();
diff --git a/IKVM.artifacts.msbuildproj b/IKVM.artifacts.msbuildproj
index 61a5e80577..51effedee2 100644
--- a/IKVM.artifacts.msbuildproj
+++ b/IKVM.artifacts.msbuildproj
@@ -37,19 +37,19 @@
$(ToolProperties);TargetFramework=netcoreapp3.1;RuntimeIdentifier=linux-x64;PublishDir=$([System.IO.Path]::Combine('$(ArtifactStagingDirectory)', 'tools\netcoreapp3.1\linux-x64'))
- IKVM_Tests:Publish
+ IKVM_Tests:Publish;ikvmc_Tests:Publish;ikvmstub_Tests:Publish
TargetFramework=net461;PublishDir=$([System.IO.Path]::Combine('$(ArtifactStagingDirectory)', 'tests\net461'))
- IKVM_Tests:Publish
+ IKVM_Tests:Publish;ikvmc_Tests:Publish;ikvmc_Exe_Tests:Publish;ikvmstub_Tests:Publish
TargetFramework=netcoreapp3.1;PublishDir=$([System.IO.Path]::Combine('$(ArtifactStagingDirectory)', 'tests\netcoreapp3.1'))
- IKVM_Tests:Publish
+ IKVM_Tests:Publish;ikvmc_Tests:Publish;ikvmstub_Tests:Publish
TargetFramework=net5.0;PublishDir=$([System.IO.Path]::Combine('$(ArtifactStagingDirectory)', 'tests\net5.0'))
- IKVM_Tests:Publish
+ IKVM_Tests:Publish;ikvmc_Tests:Publish;ikvmstub_Tests:Publish
TargetFramework=net6.0;PublishDir=$([System.IO.Path]::Combine('$(ArtifactStagingDirectory)', 'tests\net6.0'))
diff --git a/IKVM.sln b/IKVM.sln
index 8b84717fdc..33538d7558 100644
--- a/IKVM.sln
+++ b/IKVM.sln
@@ -57,220 +57,104 @@ Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "ikvm-tests-native-linux", "
EndProject
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "ikvm-tests-native", "ikvm-tests-native", "{B6083619-C4E8-4D8E-95BD-217E3663134C}"
EndProject
+Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "IKVM.Tests.Util", "IKVM.Tests.Util\IKVM.Tests.Util.csproj", "{066E1713-6D64-4B40-BE1B-7C33C7ADD877}"
+EndProject
+Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "ikvmc.Exe.Tests", "ikvmc.Exe.Tests\ikvmc.Exe.Tests.csproj", "{6B006D99-1082-44ED-8CF9-B1F1E619A6F8}"
+EndProject
+Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "ikvmc.Tests", "ikvmc.Tests\ikvmc.Tests.csproj", "{A1982DB0-3626-4B8B-8CCA-8AF692252701}"
+EndProject
+Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "ikvmstub.Tests", "ikvmstub.Tests\ikvmstub.Tests.csproj", "{B41CDA62-0147-4D57-9D7C-919E041B7478}"
+EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|Any CPU = Debug|Any CPU
- Debug|x64 = Debug|x64
- Debug|x86 = Debug|x86
Release|Any CPU = Release|Any CPU
- Release|x64 = Release|x64
- Release|x86 = Release|x86
EndGlobalSection
GlobalSection(ProjectConfigurationPlatforms) = postSolution
{1DAD30CB-7FF9-47AC-92B2-0F46003EB6A4}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{1DAD30CB-7FF9-47AC-92B2-0F46003EB6A4}.Debug|Any CPU.Build.0 = Debug|Any CPU
- {1DAD30CB-7FF9-47AC-92B2-0F46003EB6A4}.Debug|x64.ActiveCfg = Debug|Any CPU
- {1DAD30CB-7FF9-47AC-92B2-0F46003EB6A4}.Debug|x64.Build.0 = Debug|Any CPU
- {1DAD30CB-7FF9-47AC-92B2-0F46003EB6A4}.Debug|x86.ActiveCfg = Debug|Any CPU
- {1DAD30CB-7FF9-47AC-92B2-0F46003EB6A4}.Debug|x86.Build.0 = Debug|Any CPU
{1DAD30CB-7FF9-47AC-92B2-0F46003EB6A4}.Release|Any CPU.ActiveCfg = Release|Any CPU
{1DAD30CB-7FF9-47AC-92B2-0F46003EB6A4}.Release|Any CPU.Build.0 = Release|Any CPU
- {1DAD30CB-7FF9-47AC-92B2-0F46003EB6A4}.Release|x64.ActiveCfg = Release|Any CPU
- {1DAD30CB-7FF9-47AC-92B2-0F46003EB6A4}.Release|x64.Build.0 = Release|Any CPU
- {1DAD30CB-7FF9-47AC-92B2-0F46003EB6A4}.Release|x86.ActiveCfg = Release|Any CPU
- {1DAD30CB-7FF9-47AC-92B2-0F46003EB6A4}.Release|x86.Build.0 = Release|Any CPU
{FAC669CD-03A2-4120-8B06-68D34E047C1C}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{FAC669CD-03A2-4120-8B06-68D34E047C1C}.Debug|Any CPU.Build.0 = Debug|Any CPU
- {FAC669CD-03A2-4120-8B06-68D34E047C1C}.Debug|x64.ActiveCfg = Debug|Any CPU
- {FAC669CD-03A2-4120-8B06-68D34E047C1C}.Debug|x64.Build.0 = Debug|Any CPU
- {FAC669CD-03A2-4120-8B06-68D34E047C1C}.Debug|x86.ActiveCfg = Debug|Any CPU
- {FAC669CD-03A2-4120-8B06-68D34E047C1C}.Debug|x86.Build.0 = Debug|Any CPU
{FAC669CD-03A2-4120-8B06-68D34E047C1C}.Release|Any CPU.ActiveCfg = Release|Any CPU
{FAC669CD-03A2-4120-8B06-68D34E047C1C}.Release|Any CPU.Build.0 = Release|Any CPU
- {FAC669CD-03A2-4120-8B06-68D34E047C1C}.Release|x64.ActiveCfg = Release|Any CPU
- {FAC669CD-03A2-4120-8B06-68D34E047C1C}.Release|x64.Build.0 = Release|Any CPU
- {FAC669CD-03A2-4120-8B06-68D34E047C1C}.Release|x86.ActiveCfg = Release|Any CPU
- {FAC669CD-03A2-4120-8B06-68D34E047C1C}.Release|x86.Build.0 = Release|Any CPU
{197EF0EC-63E2-4644-AF25-054B931DDB55}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{197EF0EC-63E2-4644-AF25-054B931DDB55}.Debug|Any CPU.Build.0 = Debug|Any CPU
- {197EF0EC-63E2-4644-AF25-054B931DDB55}.Debug|x64.ActiveCfg = Debug|Any CPU
- {197EF0EC-63E2-4644-AF25-054B931DDB55}.Debug|x64.Build.0 = Debug|Any CPU
- {197EF0EC-63E2-4644-AF25-054B931DDB55}.Debug|x86.ActiveCfg = Debug|Any CPU
- {197EF0EC-63E2-4644-AF25-054B931DDB55}.Debug|x86.Build.0 = Debug|Any CPU
{197EF0EC-63E2-4644-AF25-054B931DDB55}.Release|Any CPU.ActiveCfg = Release|Any CPU
{197EF0EC-63E2-4644-AF25-054B931DDB55}.Release|Any CPU.Build.0 = Release|Any CPU
- {197EF0EC-63E2-4644-AF25-054B931DDB55}.Release|x64.ActiveCfg = Release|Any CPU
- {197EF0EC-63E2-4644-AF25-054B931DDB55}.Release|x64.Build.0 = Release|Any CPU
- {197EF0EC-63E2-4644-AF25-054B931DDB55}.Release|x86.ActiveCfg = Release|Any CPU
- {197EF0EC-63E2-4644-AF25-054B931DDB55}.Release|x86.Build.0 = Release|Any CPU
{E4E508BF-7ADF-413F-83E2-908A3C9F7F8D}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{E4E508BF-7ADF-413F-83E2-908A3C9F7F8D}.Debug|Any CPU.Build.0 = Debug|Any CPU
- {E4E508BF-7ADF-413F-83E2-908A3C9F7F8D}.Debug|x64.ActiveCfg = Debug|Any CPU
- {E4E508BF-7ADF-413F-83E2-908A3C9F7F8D}.Debug|x64.Build.0 = Debug|Any CPU
- {E4E508BF-7ADF-413F-83E2-908A3C9F7F8D}.Debug|x86.ActiveCfg = Debug|Any CPU
- {E4E508BF-7ADF-413F-83E2-908A3C9F7F8D}.Debug|x86.Build.0 = Debug|Any CPU
{E4E508BF-7ADF-413F-83E2-908A3C9F7F8D}.Release|Any CPU.ActiveCfg = Release|Any CPU
{E4E508BF-7ADF-413F-83E2-908A3C9F7F8D}.Release|Any CPU.Build.0 = Release|Any CPU
- {E4E508BF-7ADF-413F-83E2-908A3C9F7F8D}.Release|x64.ActiveCfg = Release|Any CPU
- {E4E508BF-7ADF-413F-83E2-908A3C9F7F8D}.Release|x64.Build.0 = Release|Any CPU
- {E4E508BF-7ADF-413F-83E2-908A3C9F7F8D}.Release|x86.ActiveCfg = Release|Any CPU
- {E4E508BF-7ADF-413F-83E2-908A3C9F7F8D}.Release|x86.Build.0 = Release|Any CPU
{0A87FF49-AC9D-479A-ACBB-F4028A0BE1F7}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{0A87FF49-AC9D-479A-ACBB-F4028A0BE1F7}.Debug|Any CPU.Build.0 = Debug|Any CPU
- {0A87FF49-AC9D-479A-ACBB-F4028A0BE1F7}.Debug|x64.ActiveCfg = Debug|Any CPU
- {0A87FF49-AC9D-479A-ACBB-F4028A0BE1F7}.Debug|x64.Build.0 = Debug|Any CPU
- {0A87FF49-AC9D-479A-ACBB-F4028A0BE1F7}.Debug|x86.ActiveCfg = Debug|Any CPU
- {0A87FF49-AC9D-479A-ACBB-F4028A0BE1F7}.Debug|x86.Build.0 = Debug|Any CPU
{0A87FF49-AC9D-479A-ACBB-F4028A0BE1F7}.Release|Any CPU.ActiveCfg = Release|Any CPU
{0A87FF49-AC9D-479A-ACBB-F4028A0BE1F7}.Release|Any CPU.Build.0 = Release|Any CPU
- {0A87FF49-AC9D-479A-ACBB-F4028A0BE1F7}.Release|x64.ActiveCfg = Release|Any CPU
- {0A87FF49-AC9D-479A-ACBB-F4028A0BE1F7}.Release|x64.Build.0 = Release|Any CPU
- {0A87FF49-AC9D-479A-ACBB-F4028A0BE1F7}.Release|x86.ActiveCfg = Release|Any CPU
- {0A87FF49-AC9D-479A-ACBB-F4028A0BE1F7}.Release|x86.Build.0 = Release|Any CPU
{2F29E48C-63C3-4E47-BCBA-A7454B9119CF}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{2F29E48C-63C3-4E47-BCBA-A7454B9119CF}.Debug|Any CPU.Build.0 = Debug|Any CPU
- {2F29E48C-63C3-4E47-BCBA-A7454B9119CF}.Debug|x64.ActiveCfg = Debug|Any CPU
- {2F29E48C-63C3-4E47-BCBA-A7454B9119CF}.Debug|x64.Build.0 = Debug|Any CPU
- {2F29E48C-63C3-4E47-BCBA-A7454B9119CF}.Debug|x86.ActiveCfg = Debug|Any CPU
- {2F29E48C-63C3-4E47-BCBA-A7454B9119CF}.Debug|x86.Build.0 = Debug|Any CPU
{2F29E48C-63C3-4E47-BCBA-A7454B9119CF}.Release|Any CPU.ActiveCfg = Release|Any CPU
{2F29E48C-63C3-4E47-BCBA-A7454B9119CF}.Release|Any CPU.Build.0 = Release|Any CPU
- {2F29E48C-63C3-4E47-BCBA-A7454B9119CF}.Release|x64.ActiveCfg = Release|Any CPU
- {2F29E48C-63C3-4E47-BCBA-A7454B9119CF}.Release|x64.Build.0 = Release|Any CPU
- {2F29E48C-63C3-4E47-BCBA-A7454B9119CF}.Release|x86.ActiveCfg = Release|Any CPU
- {2F29E48C-63C3-4E47-BCBA-A7454B9119CF}.Release|x86.Build.0 = Release|Any CPU
{D13E6D52-AF13-423D-B29D-A935BA32E67C}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{D13E6D52-AF13-423D-B29D-A935BA32E67C}.Debug|Any CPU.Build.0 = Debug|Any CPU
- {D13E6D52-AF13-423D-B29D-A935BA32E67C}.Debug|x64.ActiveCfg = Debug|Any CPU
- {D13E6D52-AF13-423D-B29D-A935BA32E67C}.Debug|x64.Build.0 = Debug|Any CPU
- {D13E6D52-AF13-423D-B29D-A935BA32E67C}.Debug|x86.ActiveCfg = Debug|Any CPU
- {D13E6D52-AF13-423D-B29D-A935BA32E67C}.Debug|x86.Build.0 = Debug|Any CPU
{D13E6D52-AF13-423D-B29D-A935BA32E67C}.Release|Any CPU.ActiveCfg = Release|Any CPU
{D13E6D52-AF13-423D-B29D-A935BA32E67C}.Release|Any CPU.Build.0 = Release|Any CPU
- {D13E6D52-AF13-423D-B29D-A935BA32E67C}.Release|x64.ActiveCfg = Release|Any CPU
- {D13E6D52-AF13-423D-B29D-A935BA32E67C}.Release|x64.Build.0 = Release|Any CPU
- {D13E6D52-AF13-423D-B29D-A935BA32E67C}.Release|x86.ActiveCfg = Release|Any CPU
- {D13E6D52-AF13-423D-B29D-A935BA32E67C}.Release|x86.Build.0 = Release|Any CPU
{01A67032-A76E-400D-9DA8-A58CE10A5FCD}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{01A67032-A76E-400D-9DA8-A58CE10A5FCD}.Debug|Any CPU.Build.0 = Debug|Any CPU
- {01A67032-A76E-400D-9DA8-A58CE10A5FCD}.Debug|x64.ActiveCfg = Debug|Any CPU
- {01A67032-A76E-400D-9DA8-A58CE10A5FCD}.Debug|x64.Build.0 = Debug|Any CPU
- {01A67032-A76E-400D-9DA8-A58CE10A5FCD}.Debug|x86.ActiveCfg = Debug|Any CPU
- {01A67032-A76E-400D-9DA8-A58CE10A5FCD}.Debug|x86.Build.0 = Debug|Any CPU
{01A67032-A76E-400D-9DA8-A58CE10A5FCD}.Release|Any CPU.ActiveCfg = Release|Any CPU
{01A67032-A76E-400D-9DA8-A58CE10A5FCD}.Release|Any CPU.Build.0 = Release|Any CPU
- {01A67032-A76E-400D-9DA8-A58CE10A5FCD}.Release|x64.ActiveCfg = Release|Any CPU
- {01A67032-A76E-400D-9DA8-A58CE10A5FCD}.Release|x64.Build.0 = Release|Any CPU
- {01A67032-A76E-400D-9DA8-A58CE10A5FCD}.Release|x86.ActiveCfg = Release|Any CPU
- {01A67032-A76E-400D-9DA8-A58CE10A5FCD}.Release|x86.Build.0 = Release|Any CPU
{43BA164D-41F3-4563-BDB0-EEF56CE49309}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{43BA164D-41F3-4563-BDB0-EEF56CE49309}.Debug|Any CPU.Build.0 = Debug|Any CPU
- {43BA164D-41F3-4563-BDB0-EEF56CE49309}.Debug|x64.ActiveCfg = Debug|Any CPU
- {43BA164D-41F3-4563-BDB0-EEF56CE49309}.Debug|x64.Build.0 = Debug|Any CPU
- {43BA164D-41F3-4563-BDB0-EEF56CE49309}.Debug|x86.ActiveCfg = Debug|Any CPU
- {43BA164D-41F3-4563-BDB0-EEF56CE49309}.Debug|x86.Build.0 = Debug|Any CPU
{43BA164D-41F3-4563-BDB0-EEF56CE49309}.Release|Any CPU.ActiveCfg = Release|Any CPU
{43BA164D-41F3-4563-BDB0-EEF56CE49309}.Release|Any CPU.Build.0 = Release|Any CPU
- {43BA164D-41F3-4563-BDB0-EEF56CE49309}.Release|x64.ActiveCfg = Release|Any CPU
- {43BA164D-41F3-4563-BDB0-EEF56CE49309}.Release|x64.Build.0 = Release|Any CPU
- {43BA164D-41F3-4563-BDB0-EEF56CE49309}.Release|x86.ActiveCfg = Release|Any CPU
- {43BA164D-41F3-4563-BDB0-EEF56CE49309}.Release|x86.Build.0 = Release|Any CPU
{01563AC3-AE6C-4297-9313-8B835B488738}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{01563AC3-AE6C-4297-9313-8B835B488738}.Debug|Any CPU.Build.0 = Debug|Any CPU
- {01563AC3-AE6C-4297-9313-8B835B488738}.Debug|x64.ActiveCfg = Debug|Any CPU
- {01563AC3-AE6C-4297-9313-8B835B488738}.Debug|x64.Build.0 = Debug|Any CPU
- {01563AC3-AE6C-4297-9313-8B835B488738}.Debug|x86.ActiveCfg = Debug|Any CPU
- {01563AC3-AE6C-4297-9313-8B835B488738}.Debug|x86.Build.0 = Debug|Any CPU
{01563AC3-AE6C-4297-9313-8B835B488738}.Release|Any CPU.ActiveCfg = Release|Any CPU
{01563AC3-AE6C-4297-9313-8B835B488738}.Release|Any CPU.Build.0 = Release|Any CPU
- {01563AC3-AE6C-4297-9313-8B835B488738}.Release|x64.ActiveCfg = Release|Any CPU
- {01563AC3-AE6C-4297-9313-8B835B488738}.Release|x64.Build.0 = Release|Any CPU
- {01563AC3-AE6C-4297-9313-8B835B488738}.Release|x86.ActiveCfg = Release|Any CPU
- {01563AC3-AE6C-4297-9313-8B835B488738}.Release|x86.Build.0 = Release|Any CPU
{BE0445A8-947D-485D-A183-0686D2AE23F8}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{BE0445A8-947D-485D-A183-0686D2AE23F8}.Debug|Any CPU.Build.0 = Debug|Any CPU
- {BE0445A8-947D-485D-A183-0686D2AE23F8}.Debug|x64.ActiveCfg = Debug|Any CPU
- {BE0445A8-947D-485D-A183-0686D2AE23F8}.Debug|x64.Build.0 = Debug|Any CPU
- {BE0445A8-947D-485D-A183-0686D2AE23F8}.Debug|x86.ActiveCfg = Debug|Any CPU
- {BE0445A8-947D-485D-A183-0686D2AE23F8}.Debug|x86.Build.0 = Debug|Any CPU
{BE0445A8-947D-485D-A183-0686D2AE23F8}.Release|Any CPU.ActiveCfg = Release|Any CPU
{BE0445A8-947D-485D-A183-0686D2AE23F8}.Release|Any CPU.Build.0 = Release|Any CPU
- {BE0445A8-947D-485D-A183-0686D2AE23F8}.Release|x64.ActiveCfg = Release|Any CPU
- {BE0445A8-947D-485D-A183-0686D2AE23F8}.Release|x64.Build.0 = Release|Any CPU
- {BE0445A8-947D-485D-A183-0686D2AE23F8}.Release|x86.ActiveCfg = Release|Any CPU
- {BE0445A8-947D-485D-A183-0686D2AE23F8}.Release|x86.Build.0 = Release|Any CPU
{8267A3D1-2B36-471C-9E9F-2E1B0C223632}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{8267A3D1-2B36-471C-9E9F-2E1B0C223632}.Debug|Any CPU.Build.0 = Debug|Any CPU
- {8267A3D1-2B36-471C-9E9F-2E1B0C223632}.Debug|x64.ActiveCfg = Debug|Any CPU
- {8267A3D1-2B36-471C-9E9F-2E1B0C223632}.Debug|x64.Build.0 = Debug|Any CPU
- {8267A3D1-2B36-471C-9E9F-2E1B0C223632}.Debug|x86.ActiveCfg = Debug|Any CPU
- {8267A3D1-2B36-471C-9E9F-2E1B0C223632}.Debug|x86.Build.0 = Debug|Any CPU
{8267A3D1-2B36-471C-9E9F-2E1B0C223632}.Release|Any CPU.ActiveCfg = Release|Any CPU
{8267A3D1-2B36-471C-9E9F-2E1B0C223632}.Release|Any CPU.Build.0 = Release|Any CPU
- {8267A3D1-2B36-471C-9E9F-2E1B0C223632}.Release|x64.ActiveCfg = Release|Any CPU
- {8267A3D1-2B36-471C-9E9F-2E1B0C223632}.Release|x64.Build.0 = Release|Any CPU
- {8267A3D1-2B36-471C-9E9F-2E1B0C223632}.Release|x86.ActiveCfg = Release|Any CPU
- {8267A3D1-2B36-471C-9E9F-2E1B0C223632}.Release|x86.Build.0 = Release|Any CPU
{A333BFF7-1690-486C-BD54-C99A33CE73C6}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{A333BFF7-1690-486C-BD54-C99A33CE73C6}.Debug|Any CPU.Build.0 = Debug|Any CPU
- {A333BFF7-1690-486C-BD54-C99A33CE73C6}.Debug|x64.ActiveCfg = Debug|Any CPU
- {A333BFF7-1690-486C-BD54-C99A33CE73C6}.Debug|x64.Build.0 = Debug|Any CPU
- {A333BFF7-1690-486C-BD54-C99A33CE73C6}.Debug|x86.ActiveCfg = Debug|Any CPU
- {A333BFF7-1690-486C-BD54-C99A33CE73C6}.Debug|x86.Build.0 = Debug|Any CPU
{A333BFF7-1690-486C-BD54-C99A33CE73C6}.Release|Any CPU.ActiveCfg = Release|Any CPU
{A333BFF7-1690-486C-BD54-C99A33CE73C6}.Release|Any CPU.Build.0 = Release|Any CPU
- {A333BFF7-1690-486C-BD54-C99A33CE73C6}.Release|x64.ActiveCfg = Release|Any CPU
- {A333BFF7-1690-486C-BD54-C99A33CE73C6}.Release|x64.Build.0 = Release|Any CPU
- {A333BFF7-1690-486C-BD54-C99A33CE73C6}.Release|x86.ActiveCfg = Release|Any CPU
- {A333BFF7-1690-486C-BD54-C99A33CE73C6}.Release|x86.Build.0 = Release|Any CPU
{D8B580D1-D12B-39CD-A42B-BAEE36602AA1}.Debug|Any CPU.ActiveCfg = Debug|x64
{D8B580D1-D12B-39CD-A42B-BAEE36602AA1}.Debug|Any CPU.Build.0 = Debug|x64
- {D8B580D1-D12B-39CD-A42B-BAEE36602AA1}.Debug|x64.ActiveCfg = Debug|x64
- {D8B580D1-D12B-39CD-A42B-BAEE36602AA1}.Debug|x64.Build.0 = Debug|x64
- {D8B580D1-D12B-39CD-A42B-BAEE36602AA1}.Debug|x86.ActiveCfg = Debug|Win32
- {D8B580D1-D12B-39CD-A42B-BAEE36602AA1}.Debug|x86.Build.0 = Debug|Win32
{D8B580D1-D12B-39CD-A42B-BAEE36602AA1}.Release|Any CPU.ActiveCfg = Release|x64
{D8B580D1-D12B-39CD-A42B-BAEE36602AA1}.Release|Any CPU.Build.0 = Release|x64
- {D8B580D1-D12B-39CD-A42B-BAEE36602AA1}.Release|x64.ActiveCfg = Release|x64
- {D8B580D1-D12B-39CD-A42B-BAEE36602AA1}.Release|x64.Build.0 = Release|x64
- {D8B580D1-D12B-39CD-A42B-BAEE36602AA1}.Release|x86.ActiveCfg = Release|Win32
- {D8B580D1-D12B-39CD-A42B-BAEE36602AA1}.Release|x86.Build.0 = Release|Win32
{F2A81A31-C65F-4B4E-A6FE-B14E71515EA3}.Debug|Any CPU.ActiveCfg = Debug|x64
{F2A81A31-C65F-4B4E-A6FE-B14E71515EA3}.Debug|Any CPU.Build.0 = Debug|x64
- {F2A81A31-C65F-4B4E-A6FE-B14E71515EA3}.Debug|x64.ActiveCfg = Debug|x64
- {F2A81A31-C65F-4B4E-A6FE-B14E71515EA3}.Debug|x64.Build.0 = Debug|x64
- {F2A81A31-C65F-4B4E-A6FE-B14E71515EA3}.Debug|x86.ActiveCfg = Debug|x86
- {F2A81A31-C65F-4B4E-A6FE-B14E71515EA3}.Debug|x86.Build.0 = Debug|x86
{F2A81A31-C65F-4B4E-A6FE-B14E71515EA3}.Release|Any CPU.ActiveCfg = Release|x64
{F2A81A31-C65F-4B4E-A6FE-B14E71515EA3}.Release|Any CPU.Build.0 = Release|x64
- {F2A81A31-C65F-4B4E-A6FE-B14E71515EA3}.Release|x64.ActiveCfg = Release|x64
- {F2A81A31-C65F-4B4E-A6FE-B14E71515EA3}.Release|x64.Build.0 = Release|x64
- {F2A81A31-C65F-4B4E-A6FE-B14E71515EA3}.Release|x86.ActiveCfg = Release|x86
- {F2A81A31-C65F-4B4E-A6FE-B14E71515EA3}.Release|x86.Build.0 = Release|x86
{A275C11D-F06E-475F-AEBA-7F7A1EF8D140}.Debug|Any CPU.ActiveCfg = Debug|x64
{A275C11D-F06E-475F-AEBA-7F7A1EF8D140}.Debug|Any CPU.Build.0 = Debug|x64
- {A275C11D-F06E-475F-AEBA-7F7A1EF8D140}.Debug|x64.ActiveCfg = Debug|x64
- {A275C11D-F06E-475F-AEBA-7F7A1EF8D140}.Debug|x64.Build.0 = Debug|x64
- {A275C11D-F06E-475F-AEBA-7F7A1EF8D140}.Debug|x86.ActiveCfg = Debug|Win32
- {A275C11D-F06E-475F-AEBA-7F7A1EF8D140}.Debug|x86.Build.0 = Debug|Win32
{A275C11D-F06E-475F-AEBA-7F7A1EF8D140}.Release|Any CPU.ActiveCfg = Release|x64
{A275C11D-F06E-475F-AEBA-7F7A1EF8D140}.Release|Any CPU.Build.0 = Release|x64
- {A275C11D-F06E-475F-AEBA-7F7A1EF8D140}.Release|x64.ActiveCfg = Release|x64
- {A275C11D-F06E-475F-AEBA-7F7A1EF8D140}.Release|x64.Build.0 = Release|x64
- {A275C11D-F06E-475F-AEBA-7F7A1EF8D140}.Release|x86.ActiveCfg = Release|Win32
- {A275C11D-F06E-475F-AEBA-7F7A1EF8D140}.Release|x86.Build.0 = Release|Win32
{E566FE94-C551-43A7-843C-5E8199CA7373}.Debug|Any CPU.ActiveCfg = Debug|x64
{E566FE94-C551-43A7-843C-5E8199CA7373}.Debug|Any CPU.Build.0 = Debug|x64
- {E566FE94-C551-43A7-843C-5E8199CA7373}.Debug|x64.ActiveCfg = Debug|x64
- {E566FE94-C551-43A7-843C-5E8199CA7373}.Debug|x64.Build.0 = Debug|x64
- {E566FE94-C551-43A7-843C-5E8199CA7373}.Debug|x86.ActiveCfg = Debug|x86
- {E566FE94-C551-43A7-843C-5E8199CA7373}.Debug|x86.Build.0 = Debug|x86
{E566FE94-C551-43A7-843C-5E8199CA7373}.Release|Any CPU.ActiveCfg = Release|x64
{E566FE94-C551-43A7-843C-5E8199CA7373}.Release|Any CPU.Build.0 = Release|x64
- {E566FE94-C551-43A7-843C-5E8199CA7373}.Release|x64.ActiveCfg = Release|x64
- {E566FE94-C551-43A7-843C-5E8199CA7373}.Release|x64.Build.0 = Release|x64
- {E566FE94-C551-43A7-843C-5E8199CA7373}.Release|x86.ActiveCfg = Release|x86
- {E566FE94-C551-43A7-843C-5E8199CA7373}.Release|x86.Build.0 = Release|x86
+ {066E1713-6D64-4B40-BE1B-7C33C7ADD877}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
+ {066E1713-6D64-4B40-BE1B-7C33C7ADD877}.Debug|Any CPU.Build.0 = Debug|Any CPU
+ {066E1713-6D64-4B40-BE1B-7C33C7ADD877}.Release|Any CPU.ActiveCfg = Release|Any CPU
+ {066E1713-6D64-4B40-BE1B-7C33C7ADD877}.Release|Any CPU.Build.0 = Release|Any CPU
+ {6B006D99-1082-44ED-8CF9-B1F1E619A6F8}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
+ {6B006D99-1082-44ED-8CF9-B1F1E619A6F8}.Debug|Any CPU.Build.0 = Debug|Any CPU
+ {6B006D99-1082-44ED-8CF9-B1F1E619A6F8}.Release|Any CPU.ActiveCfg = Release|Any CPU
+ {6B006D99-1082-44ED-8CF9-B1F1E619A6F8}.Release|Any CPU.Build.0 = Release|Any CPU
+ {A1982DB0-3626-4B8B-8CCA-8AF692252701}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
+ {A1982DB0-3626-4B8B-8CCA-8AF692252701}.Debug|Any CPU.Build.0 = Debug|Any CPU
+ {A1982DB0-3626-4B8B-8CCA-8AF692252701}.Release|Any CPU.ActiveCfg = Release|Any CPU
+ {A1982DB0-3626-4B8B-8CCA-8AF692252701}.Release|Any CPU.Build.0 = Release|Any CPU
+ {B41CDA62-0147-4D57-9D7C-919E041B7478}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
+ {B41CDA62-0147-4D57-9D7C-919E041B7478}.Debug|Any CPU.Build.0 = Debug|Any CPU
+ {B41CDA62-0147-4D57-9D7C-919E041B7478}.Release|Any CPU.ActiveCfg = Release|Any CPU
+ {B41CDA62-0147-4D57-9D7C-919E041B7478}.Release|Any CPU.Build.0 = Release|Any CPU
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE
diff --git a/ikvmc.Exe.Tests/ExeTests.cs b/ikvmc.Exe.Tests/ExeTests.cs
new file mode 100644
index 0000000000..d6312d8d9f
--- /dev/null
+++ b/ikvmc.Exe.Tests/ExeTests.cs
@@ -0,0 +1,144 @@
+using System;
+using System.Collections.Generic;
+using System.IO;
+using System.Runtime.InteropServices;
+using System.Text;
+using System.Threading.Tasks;
+
+using CliWrap;
+
+using FluentAssertions;
+
+using IKVM.Tests.Util;
+
+using Microsoft.VisualStudio.TestTools.UnitTesting;
+
+using System.Linq;
+
+#if NETCOREAPP3_1_OR_GREATER
+using Microsoft.Extensions.DependencyModel;
+#endif
+
+namespace ikvmc.Exe.Tests
+{
+
+ [TestClass]
+ public class ExeTests
+ {
+
+ ///
+ /// Describes the result of executing an exe.
+ ///
+ class ExeResult
+ {
+
+ ///
+ /// Initializes a new instance.
+ ///
+ ///
+ ///
+ ///
+ public ExeResult(int exitCode, string standardOutput, string standardError)
+ {
+ ExitCode = exitCode;
+ StandardOutput = standardOutput;
+ StandardError = standardError;
+ }
+
+ public int ExitCode { get; set; }
+
+ public string StandardOutput { get; set; }
+
+ public string StandardError { get; set; }
+
+ }
+
+ ///
+ /// Executes the IKVMC command line.
+ ///
+ ///
+ ///
+ ///
+ ///
+ async Task ExecuteIkvmc(string target, bool useNetCore, params string[] arguments)
+ {
+ var dir = Path.Combine(Path.GetDirectoryName(typeof(ExeTests).Assembly.Location), $"ikvmc-{target}");
+ var cmd = useNetCore ? Cli.Wrap("dotnet").WithArguments(o => o.Add("exec").Add(Path.Combine(dir, "ikvmc.dll"))) : Cli.Wrap(Path.Combine(dir, "ikvmc.exe"));
+ cmd = cmd.WithArguments(o => o.Add(arguments));
+ cmd = cmd.WithValidation(CommandResultValidation.None);
+ var stdout = new StringBuilder();
+ cmd = cmd.WithStandardOutputPipe(PipeTarget.ToStringBuilder(stdout));
+ var stderr = new StringBuilder();
+ cmd = cmd.WithStandardErrorPipe(PipeTarget.ToStringBuilder(stderr));
+ var tsk = await cmd.ExecuteAsync();
+ return new ExeResult(tsk.ExitCode, stdout.ToString(), stderr.ToString());
+ }
+
+ ///
+ /// Can confirm we can simply execute the ikvmc executable and not have an error code.
+ ///
+ ///
+ ///
+ [DataTestMethod]
+ [DynamicData(nameof(GetVersionsToTest), DynamicDataSourceType.Method)]
+ public async Task Should_display_options_and_exit_successfully_with_no_arguments(string target, bool useNetCore)
+ {
+ var rsl = await ExecuteIkvmc(target, useNetCore);
+ rsl.ExitCode.Should().Be(0);
+ rsl.StandardError.Should().StartWith("IKVM.NET");
+ rsl.StandardError.Should().Contain("Compiler Options:");
+ }
+
+ ///
+ /// Can confirm we can simply execute the ikvmc executable and not have an error code.
+ ///
+ ///
+ ///
+ [DataTestMethod]
+ [DynamicData(nameof(GetVersionsToTest), DynamicDataSourceType.Method)]
+ public async Task Should_convert_simple_jar(string target, bool useNetCore)
+ {
+ var s = new StreamReader(typeof(ExeTests).Assembly.GetManifestResourceStream("ikvmc.Exe.Tests.ExeTests.java")).ReadToEnd();
+ var f = new InMemoryCodeUnit("ikvmc.exe.tests.ExeTests", s);
+ var c = new InMemoryCompiler(new[] { f });
+ c.Compile();
+ var j = Path.Combine(Path.GetTempPath(), Guid.NewGuid().ToString("n") + ".jar");
+ c.WriteJar(j);
+
+#if NET461
+ var a = new[] { $"-lib:{System.Runtime.InteropServices.RuntimeEnvironment.GetRuntimeDirectory()}" };
+#else
+ var a = DependencyContext.Default.CompileLibraries.SelectMany(i => i.ResolveReferencePaths()).Select(i => $"-r:{i}");
+#endif
+
+ var asm = Path.ChangeExtension(j, ".dll");
+ var rsl = await ExecuteIkvmc(target, useNetCore, a.Concat(new[] { "-assembly:ikvmc.Tests.Java", $"-out:{asm}", j }).ToArray());
+ rsl.ExitCode.Should().Be(0);
+ rsl.StandardError.Should().StartWith("IKVM.NET");
+ File.Exists(asm).Should().BeTrue();
+ }
+
+ ///
+ /// Gets the IKVMC builds to test based on the current test OS platform.
+ ///
+ ///
+ public static IEnumerable