diff --git a/Src/IronPython/IronPython.csproj b/Src/IronPython/IronPython.csproj
index ff02ed6ed..2b3bfe40c 100644
--- a/Src/IronPython/IronPython.csproj
+++ b/Src/IronPython/IronPython.csproj
@@ -31,7 +31,7 @@
-
+
diff --git a/Src/IronPythonCompiler/Program.cs b/Src/IronPythonCompiler/Program.cs
index 489b8346f..115b8f502 100644
--- a/Src/IronPythonCompiler/Program.cs
+++ b/Src/IronPythonCompiler/Program.cs
@@ -5,20 +5,19 @@
using System;
using System.Collections.Generic;
using System.IO;
-using System.Linq;
-using System.Text;
-using IronPython.Runtime;
-using IronPython.Runtime.Operations;
-using IronPython.Hosting;
+using System.Resources;
+
using IKVM.Reflection;
using IKVM.Reflection.Emit;
-using System.Resources;
-using Type = IKVM.Reflection.Type;
+using IronPython.Hosting;
+using IronPython.Runtime;
+using IronPython.Runtime.Operations;
-using Microsoft.Scripting.Runtime;
using Microsoft.Scripting.Hosting;
-using Microsoft.Scripting.Hosting.Providers;
+using Microsoft.Scripting.Runtime;
+
+using Type = IKVM.Reflection.Type;
namespace IronPythonCompiler {
@@ -62,9 +61,20 @@ private static void GenerateExe(Config config) {
ConsoleOps.Info("Generating stand alone executable");
config.Embed = true;
+ var embedAssemblies = new HashSet {
+ // DLR
+ "Microsoft.Dynamic",
+ "Microsoft.Scripting",
+ // System.Memory
+ "System.Buffers",
+ "System.Memory",
+ "System.Numerics.Vectors",
+ "System.Runtime.CompilerServices.Unsafe",
+ };
+
foreach (var a in System.AppDomain.CurrentDomain.GetAssemblies()) {
var n = new AssemblyName(a.FullName);
- if (!a.IsDynamic && a.EntryPoint == null && (n.Name.StartsWith("IronPython", StringComparison.Ordinal) || n.Name == "Microsoft.Dynamic" || n.Name == "Microsoft.Scripting")) {
+ if (!a.IsDynamic && a.EntryPoint == null && (n.Name.StartsWith("IronPython", StringComparison.Ordinal) || embedAssemblies.Contains(n.Name))) {
ConsoleOps.Info($"\tEmbedded {n.Name} {n.Version}");
var f = new FileStream(a.Location, FileMode.Open, FileAccess.Read);
mb.DefineManifestResource("Dll." + n.Name, f, IKVM.Reflection.ResourceAttributes.Public);