Browse Source

Fixed the auto-compilation in the C# end by adding a reference to System.Core.

Signed-off-by: Dimitar Dobrev <dpldobrev@yahoo.com>
pull/496/merge
Dimitar Dobrev 10 years ago
parent
commit
c0fbdcbb0a
  1. 3
      src/Generator/Driver.cs

3
src/Generator/Driver.cs

@ -358,7 +358,10 @@ namespace CppSharp
CompilerOptions = compilerOptions.ToString() CompilerOptions = compilerOptions.ToString()
}; };
// add references to System and System.Core
compilerParameters.ReferencedAssemblies.Add(typeof(object).Assembly.Location); compilerParameters.ReferencedAssemblies.Add(typeof(object).Assembly.Location);
compilerParameters.ReferencedAssemblies.Add(typeof(Enumerable).Assembly.Location);
var location = Assembly.GetExecutingAssembly().Location; var location = Assembly.GetExecutingAssembly().Location;
var outputDir = Path.GetDirectoryName(location); var outputDir = Path.GetDirectoryName(location);
var locationRuntime = Path.Combine(outputDir, "CppSharp.Runtime.dll"); var locationRuntime = Path.Combine(outputDir, "CppSharp.Runtime.dll");

Loading…
Cancel
Save