aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region/ScriptEngine/DotNetEngine/Compiler/LSL/Compiler.cs
diff options
context:
space:
mode:
authorTedd Hansen2007-08-12 18:06:02 +0000
committerTedd Hansen2007-08-12 18:06:02 +0000
commita968d05864d205a289f05074338bb1e7165bc4e6 (patch)
tree173655a56b9ec3f997debc37a3c058c97aa807e8 /OpenSim/Region/ScriptEngine/DotNetEngine/Compiler/LSL/Compiler.cs
parentCode comments and cleanup, correct datatypes for key, vector, rotation, (hope... (diff)
downloadopensim-SC-a968d05864d205a289f05074338bb1e7165bc4e6.zip
opensim-SC-a968d05864d205a289f05074338bb1e7165bc4e6.tar.gz
opensim-SC-a968d05864d205a289f05074338bb1e7165bc4e6.tar.bz2
opensim-SC-a968d05864d205a289f05074338bb1e7165bc4e6.tar.xz
LSL BuiltIn implementation is now in Compiler\LSL\LSL_BaseClass. So users won't have to reference every internal command by object.
Diffstat (limited to 'OpenSim/Region/ScriptEngine/DotNetEngine/Compiler/LSL/Compiler.cs')
-rw-r--r--OpenSim/Region/ScriptEngine/DotNetEngine/Compiler/LSL/Compiler.cs10
1 files changed, 8 insertions, 2 deletions
diff --git a/OpenSim/Region/ScriptEngine/DotNetEngine/Compiler/LSL/Compiler.cs b/OpenSim/Region/ScriptEngine/DotNetEngine/Compiler/LSL/Compiler.cs
index 6eadb0e..906b2d3 100644
--- a/OpenSim/Region/ScriptEngine/DotNetEngine/Compiler/LSL/Compiler.cs
+++ b/OpenSim/Region/ScriptEngine/DotNetEngine/Compiler/LSL/Compiler.cs
@@ -4,12 +4,13 @@ using System.Text;
4using System.IO; 4using System.IO;
5using Microsoft.CSharp; 5using Microsoft.CSharp;
6using System.CodeDom.Compiler; 6using System.CodeDom.Compiler;
7using System.Reflection;
7 8
8namespace OpenSim.Region.ScriptEngine.DotNetEngine.Compiler.LSL 9namespace OpenSim.Region.ScriptEngine.DotNetEngine.Compiler.LSL
9{ 10{
10 public class Compiler 11 public class Compiler
11 { 12 {
12 private LSL2CS.Converter.LSL2CSConverter LSL_Converter = new LSL2CS.Converter.LSL2CSConverter(); 13 private LSL2CSConverter LSL_Converter = new LSL2CSConverter();
13 private CSharpCodeProvider codeProvider = new CSharpCodeProvider(); 14 private CSharpCodeProvider codeProvider = new CSharpCodeProvider();
14 //private ICodeCompiler icc = codeProvider.CreateCompiler(); 15 //private ICodeCompiler icc = codeProvider.CreateCompiler();
15 public string Compile(string LSOFileName) 16 public string Compile(string LSOFileName)
@@ -25,7 +26,12 @@ namespace OpenSim.Region.ScriptEngine.DotNetEngine.Compiler.LSL
25 // Do actual compile 26 // Do actual compile
26 System.CodeDom.Compiler.CompilerParameters parameters = new CompilerParameters(); 27 System.CodeDom.Compiler.CompilerParameters parameters = new CompilerParameters();
27 parameters.IncludeDebugInformation = true; 28 parameters.IncludeDebugInformation = true;
28 parameters.ReferencedAssemblies.Add("OpenSim.Region.Environment"); 29 // Add all available assemblies
30 foreach (Assembly asm in AppDomain.CurrentDomain.GetAssemblies())
31 {
32 parameters.ReferencedAssemblies.Add(asm.Location);
33 }
34 //parameters.ReferencedAssemblies.Add("OpenSim.Region.Environment");
29 parameters.GenerateExecutable = false; 35 parameters.GenerateExecutable = false;
30 parameters.OutputAssembly = OutFile; 36 parameters.OutputAssembly = OutFile;
31 CompilerResults results = codeProvider.CompileAssemblyFromSource(parameters, CS_Code); 37 CompilerResults results = codeProvider.CompileAssemblyFromSource(parameters, CS_Code);