diff options
Diffstat (limited to 'OpenSim/Region/ScriptEngine/DotNetEngine/Compiler/LSL/Compiler.cs')
-rw-r--r-- | OpenSim/Region/ScriptEngine/DotNetEngine/Compiler/LSL/Compiler.cs | 17 |
1 files changed, 11 insertions, 6 deletions
diff --git a/OpenSim/Region/ScriptEngine/DotNetEngine/Compiler/LSL/Compiler.cs b/OpenSim/Region/ScriptEngine/DotNetEngine/Compiler/LSL/Compiler.cs index 4c2ceb0..c29b9f4 100644 --- a/OpenSim/Region/ScriptEngine/DotNetEngine/Compiler/LSL/Compiler.cs +++ b/OpenSim/Region/ScriptEngine/DotNetEngine/Compiler/LSL/Compiler.cs | |||
@@ -8,6 +8,7 @@ using System.Reflection; | |||
8 | 8 | ||
9 | namespace OpenSim.Region.ScriptEngine.DotNetEngine.Compiler.LSL | 9 | namespace OpenSim.Region.ScriptEngine.DotNetEngine.Compiler.LSL |
10 | { | 10 | { |
11 | |||
11 | public class Compiler | 12 | public class Compiler |
12 | { | 13 | { |
13 | private LSL2CSConverter LSL_Converter = new LSL2CSConverter(); | 14 | private LSL2CSConverter LSL_Converter = new LSL2CSConverter(); |
@@ -52,13 +53,17 @@ namespace OpenSim.Region.ScriptEngine.DotNetEngine.Compiler.LSL | |||
52 | System.CodeDom.Compiler.CompilerParameters parameters = new CompilerParameters(); | 53 | System.CodeDom.Compiler.CompilerParameters parameters = new CompilerParameters(); |
53 | parameters.IncludeDebugInformation = true; | 54 | parameters.IncludeDebugInformation = true; |
54 | // Add all available assemblies | 55 | // Add all available assemblies |
55 | //foreach (Assembly asm in AppDomain.CurrentDomain.GetAssemblies()) | 56 | foreach (Assembly asm in AppDomain.CurrentDomain.GetAssemblies()) |
56 | //{ | 57 | { |
57 | // Console.WriteLine("Adding assembly: " + asm.Location); | 58 | //Console.WriteLine("Adding assembly: " + asm.Location); |
58 | // parameters.ReferencedAssemblies.Add(asm.Location); | 59 | //parameters.ReferencedAssemblies.Add(asm.Location); |
59 | //} | 60 | } |
60 | 61 | ||
61 | parameters.ReferencedAssemblies.Add(this.GetType().Assembly.CodeBase); | 62 | string rootPath = Path.GetDirectoryName(this.GetType().Assembly.Location); |
63 | Console.WriteLine("Assembly location: " + rootPath); | ||
64 | parameters.ReferencedAssemblies.Add(Path.Combine(rootPath, "OpenSim.Region.ScriptEngine.Common.dll")); | ||
65 | parameters.ReferencedAssemblies.Add(Path.Combine(rootPath, "OpenSim.Region.ScriptEngine.DotNetEngine.dll")); | ||
66 | |||
62 | //parameters.ReferencedAssemblies.Add("OpenSim.Region.Environment"); | 67 | //parameters.ReferencedAssemblies.Add("OpenSim.Region.Environment"); |
63 | parameters.GenerateExecutable = false; | 68 | parameters.GenerateExecutable = false; |
64 | parameters.OutputAssembly = OutFile; | 69 | parameters.OutputAssembly = OutFile; |